@arcgis/core 4.34.0-next.36 → 4.34.0-next.37

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 (613) hide show
  1. package/AttributeBinsGraphic.js +1 -1
  2. package/Basemap.js +1 -1
  3. package/Camera.js +1 -1
  4. package/CameraLayout.js +1 -1
  5. package/Graphic.js +1 -1
  6. package/Ground.js +1 -1
  7. package/Map.js +1 -1
  8. package/PopupTemplate.js +1 -1
  9. package/WebDocument2D.js +1 -1
  10. package/WebScene.js +1 -1
  11. package/analysis/Analysis.js +1 -1
  12. package/analysis/DimensionSimpleStyle.js +1 -1
  13. package/analysis/ElevationProfileLine.js +1 -1
  14. package/analysis/ElevationProfileLineChartOptions.js +1 -1
  15. package/analysis/ElevationProfileLineViewOptions.js +1 -1
  16. package/analysis/ElevationProfileUnits.js +1 -1
  17. package/analysis/LengthDimension.js +1 -1
  18. package/analysis/LineOfSightAnalysisObserver.js +1 -1
  19. package/analysis/LineOfSightAnalysisTarget.js +1 -1
  20. package/analysis/SlicePlane.js +1 -1
  21. package/analysis/Viewshed.js +1 -1
  22. package/analysis/VolumeMeasurement/CutFillOptions.js +1 -1
  23. package/analysis/support/AnalysisOriginWebScene.js +1 -1
  24. package/arcade/featureSetUtils.js +1 -1
  25. package/assets/esri/core/workers/RemoteClient.js +1 -1
  26. package/assets/esri/core/workers/chunks/02435c653064f879f547.js +1 -0
  27. package/assets/esri/core/workers/chunks/040a233ce6fbcc061cdb.js +1 -0
  28. package/assets/esri/core/workers/chunks/{4930bf8f57f481f3a4a3.js → 053086e0a043b00f1cca.js} +1 -1
  29. package/assets/esri/core/workers/chunks/05d6ccca0cf38c012873.js +1 -0
  30. package/assets/esri/core/workers/chunks/06bd2f5358c6b85d5420.js +1 -0
  31. package/assets/esri/core/workers/chunks/0801f9dde41ec5f36cca.js +1 -0
  32. package/assets/esri/core/workers/chunks/08b4a4c9f3d6478df40a.js +1 -0
  33. package/assets/esri/core/workers/chunks/0906f977d50b1c5d6ed5.js +1 -0
  34. package/assets/esri/core/workers/chunks/170fa807b71babedd185.js +1 -0
  35. package/assets/esri/core/workers/chunks/183130521210c855c565.js +1 -0
  36. package/assets/esri/core/workers/chunks/{ce8f0ed9179c0d314df8.js → 1a5ddb6d36249fe09cc8.js} +1 -1
  37. package/assets/esri/core/workers/chunks/1c87ed3a5960f8f06fc8.js +1 -0
  38. package/assets/esri/core/workers/chunks/1c8dbdb833a66f7183fc.js +1 -0
  39. package/assets/esri/core/workers/chunks/2177c0ef06c8e7e3e28e.js +1 -0
  40. package/assets/esri/core/workers/chunks/{a82d7e2eecfe654a65de.js → 21ea48186d01bf459ef6.js} +1 -1
  41. package/assets/esri/core/workers/chunks/23e0fd2d921f74834b12.js +1 -0
  42. package/assets/esri/core/workers/chunks/2b9c403f4b20b8f62804.js +1 -0
  43. package/assets/esri/core/workers/chunks/2d7bbd001b64138db3c1.js +1 -0
  44. package/assets/esri/core/workers/chunks/2f52a57e8c05a3ca1de8.js +1 -0
  45. package/assets/esri/core/workers/chunks/307df66d00ba5f88780d.js +1 -0
  46. package/assets/esri/core/workers/chunks/33aafaabea07b4f80209.js +1 -0
  47. package/assets/esri/core/workers/chunks/{209c70ba2925171ef742.js → 36d15d1dd19417b37d2f.js} +1 -1
  48. package/assets/esri/core/workers/chunks/{d6b2ab614f308db50c4a.js → 47cdd5a6351e0db3b2e9.js} +10 -10
  49. package/assets/esri/core/workers/chunks/4c7162883b228db563c6.js +1 -0
  50. package/assets/esri/core/workers/chunks/{236fc659747e812f6424.js → 4c77102f083198ae2a6a.js} +1 -1
  51. package/assets/esri/core/workers/chunks/4d2dcd667b30a98dd341.js +1 -0
  52. package/assets/esri/core/workers/chunks/4ff7c8420c77256f595a.js +1 -0
  53. package/assets/esri/core/workers/chunks/{82c10f2418e2f754388c.js → 50f56b417992eb30243e.js} +1 -1
  54. package/assets/esri/core/workers/chunks/5228f535719f5fc38b28.js +1 -0
  55. package/assets/esri/core/workers/chunks/{bd6c6acf23db2a2e8ef8.js → 53e166944a42af027345.js} +1 -1
  56. package/assets/esri/core/workers/chunks/54a686643e1ec1ea00ac.js +1 -0
  57. package/assets/esri/core/workers/chunks/568f49f9e50c505b2736.js +1 -0
  58. package/assets/esri/core/workers/chunks/56aafa6f8862629070d8.js +1 -0
  59. package/assets/esri/core/workers/chunks/5c5509147bda78ce338a.js +1 -0
  60. package/assets/esri/core/workers/chunks/{9742804f8ee350bf8052.js → 5c5678b15b59f9964bf0.js} +1 -1
  61. package/assets/esri/core/workers/chunks/5cdeb6dc72f452d6d1bc.js +1 -0
  62. package/assets/esri/core/workers/chunks/5d4e74eb4c659e8f42d6.js +1 -0
  63. package/assets/esri/core/workers/chunks/5fac0b2a5aa33e8a3a84.js +1 -0
  64. package/assets/esri/core/workers/chunks/64553b5eae4edc7f46dc.js +1 -0
  65. package/assets/esri/core/workers/chunks/67627b1965b27b2f1857.js +1 -0
  66. package/assets/esri/core/workers/chunks/{0e7e4426daba4a008849.js → 68edbc3b124eb8e28dd6.js} +1 -1
  67. package/assets/esri/core/workers/chunks/69dc5a7abc1fda2474ad.js +1 -0
  68. package/assets/esri/core/workers/chunks/{d6eff6cc30acdca04835.js → 6c167daf115cd6abb3e5.js} +1 -1
  69. package/assets/esri/core/workers/chunks/6f122e4a2a1f913523b4.js +1 -0
  70. package/assets/esri/core/workers/chunks/{1dc410bc070cabb7198d.js → 72e0fda211d980572292.js} +1 -1
  71. package/assets/esri/core/workers/chunks/761dab8780495286ec4e.js +1 -0
  72. package/assets/esri/core/workers/chunks/7641e24ffa0215d51c34.js +1 -0
  73. package/assets/esri/core/workers/chunks/7e9d5beca1991c961ed8.js +1 -0
  74. package/assets/esri/core/workers/chunks/826e4bf6374f324d7f19.js +1 -0
  75. package/assets/esri/core/workers/chunks/{69d44e08861fb8cdd954.js → 82de1b50ae286f1e6c44.js} +1 -1
  76. package/assets/esri/core/workers/chunks/860bd6d6f0c74ca301a4.js +1 -0
  77. package/assets/esri/core/workers/chunks/8e7dced4a8d089185c3a.js +1 -0
  78. package/assets/esri/core/workers/chunks/{7d25f57299c642e727a6.js → 938baf4f99332dfdf29d.js} +1 -1
  79. package/assets/esri/core/workers/chunks/9a4d0006c118ae5b45c0.js +1 -0
  80. package/assets/esri/core/workers/chunks/a1591d7f82e06cab5de4.js +1 -0
  81. package/assets/esri/core/workers/chunks/a76792c4edd1d688fba2.js +1 -0
  82. package/assets/esri/core/workers/chunks/ada46055fafb8ae21dbe.js +1 -0
  83. package/assets/esri/core/workers/chunks/{9f43736d6d80c8e858b2.js → ae667084cb6a08b97c37.js} +1 -1
  84. package/assets/esri/core/workers/chunks/{0550e775677597f3752c.js → afb51b8562f8cb29b97e.js} +1 -1
  85. package/assets/esri/core/workers/chunks/{b00ad853fa4826d0ceb3.js → b12c44faa1efa60067b0.js} +1 -1
  86. package/assets/esri/core/workers/chunks/{c9fe9792312f0161ef5a.js → b1b6300451cc4ccefd46.js} +1 -1
  87. package/assets/esri/core/workers/chunks/b2f2c1108fb7cbdd1a68.js +1 -0
  88. package/assets/esri/core/workers/chunks/{37bfc1a771792b6697fd.js → b3466edccd553ae0a5d0.js} +2 -2
  89. package/assets/esri/core/workers/chunks/b45dbbeae54cea2bbc10.js +1 -0
  90. package/assets/esri/core/workers/chunks/b49b73e2d0d643dfa351.js +1 -0
  91. package/assets/esri/core/workers/chunks/b810e2f87c9c59ae04b1.js +1 -0
  92. package/assets/esri/core/workers/chunks/{20a96c17d1a117dfdf77.js → b8c1a08020d44ee03a17.js} +1 -1
  93. package/assets/esri/core/workers/chunks/bb0c5275e51d170ac795.js +1 -0
  94. package/assets/esri/core/workers/chunks/{7a4730c1e6a5355b7a05.js → bb1213adeb05d89fbfdb.js} +1 -1
  95. package/assets/esri/core/workers/chunks/bd1ba44362b967977003.js +1 -0
  96. package/assets/esri/core/workers/chunks/c18ac2018aea6ba97eec.js +1 -0
  97. package/assets/esri/core/workers/chunks/c3d3e55abf01dae271fb.js +1 -0
  98. package/assets/esri/core/workers/chunks/c5c9f0c8da5f7bf41728.js +1 -0
  99. package/assets/esri/core/workers/chunks/c78d98ab82f31ddda362.js +1 -0
  100. package/assets/esri/core/workers/chunks/ca5f63c0297612059486.js +1 -0
  101. package/assets/esri/core/workers/chunks/cab294fd04f2a5eda81d.js +1 -0
  102. package/assets/esri/core/workers/chunks/cca36750c86352c6d1f9.js +1 -0
  103. package/assets/esri/core/workers/chunks/ccf3f29d0b1bde90c3cf.js +1 -0
  104. package/assets/esri/core/workers/chunks/cd9e6b86ab0103044370.js +1 -0
  105. package/assets/esri/core/workers/chunks/ce211163d078d3d742ce.js +1 -0
  106. package/assets/esri/core/workers/chunks/{0ca8d6516323fc28dd58.js → cf1f8fd1d62be0e02e10.js} +1 -1
  107. package/assets/esri/core/workers/chunks/d16484b389d56a43d204.js +1 -0
  108. package/assets/esri/core/workers/chunks/d54e18e0f30734610f35.js +1 -0
  109. package/assets/esri/core/workers/chunks/d7ec905d87a19a1061e7.js +1 -0
  110. package/assets/esri/core/workers/chunks/{e9a366c225b0687293e3.js → d80e26a1f4a61b1c4cf9.js} +1 -1
  111. package/assets/esri/core/workers/chunks/{eec36628e638e244f452.js → ddeaf688d72b2873c4ac.js} +1 -1
  112. package/assets/esri/core/workers/chunks/debd832b6c2c0b2ea362.js +1 -0
  113. package/assets/esri/core/workers/chunks/dfa3ad5d750d7b143a06.js +1 -0
  114. package/assets/esri/core/workers/chunks/dfc5936fbbd26f27a92a.js +1 -0
  115. package/assets/esri/core/workers/chunks/e01fa6389bd0b1ae51a5.js +1 -0
  116. package/assets/esri/core/workers/chunks/e4d08a85d158c705aa3d.js +1 -0
  117. package/assets/esri/core/workers/chunks/e59fdb8f625e9080f097.js +1 -0
  118. package/assets/esri/core/workers/chunks/ed1cd90e899dc9c15ee3.js +1 -0
  119. package/assets/esri/core/workers/chunks/ee28cd411a93245fb90c.js +1 -0
  120. package/assets/esri/core/workers/chunks/f5bb7c90f48cae594bc3.js +1 -0
  121. package/assets/esri/core/workers/chunks/f79c9b37f2842ed88a9b.js +1 -0
  122. package/assets/esri/core/workers/chunks/f88fe2e8fbc763bdc940.js +1 -0
  123. package/assets/esri/core/workers/chunks/faa0cfee8c1de9b5b78c.js +1 -0
  124. package/assets/esri/core/workers/chunks/fae53d825dd9fef0426c.js +1 -0
  125. package/chunks/TimeInterval.js +1 -1
  126. package/chunks/languageUtils.js +1 -1
  127. package/config.js +1 -1
  128. package/core/Clonable.d.ts +1 -1
  129. package/core/Clonable.js +1 -1
  130. package/core/Collection.js +1 -1
  131. package/core/Evented.d.ts +1 -1
  132. package/core/Evented.js +1 -1
  133. package/core/Identifiable.d.ts +1 -1
  134. package/core/Identifiable.js +1 -1
  135. package/core/Loadable.d.ts +1 -1
  136. package/core/Loadable.js +1 -1
  137. package/core/loadAll.js +1 -1
  138. package/editing/sharedTemplates/SharedTemplate.js +1 -1
  139. package/editing/sharedTemplates/SharedTemplateProvider.js +1 -1
  140. package/editing/sharedTemplates/templateDefinitions/TemplateDefinitionBase.js +1 -1
  141. package/effects/FocusArea.js +1 -1
  142. package/effects/FocusAreaOutline.js +1 -1
  143. package/effects/FocusAreas.js +1 -1
  144. package/form/elements/UtilityNetworkAssociationsElement.js +1 -1
  145. package/form/elements/inputs/attachments/Input.js +1 -1
  146. package/geometry/Mesh.js +1 -1
  147. package/geometry/support/MeshComponent.js +1 -1
  148. package/geometry/support/MeshGeoreferencedVertexSpace.js +1 -1
  149. package/geometry/support/MeshLocalVertexSpace.js +1 -1
  150. package/geometry/support/MeshMaterial.js +1 -1
  151. package/geometry/support/MeshTexture.js +1 -1
  152. package/geometry/support/MeshTextureTransform.js +1 -1
  153. package/geometry/support/MeshTransform.js +1 -1
  154. package/geometry/support/MeshVertexAttributes.js +1 -1
  155. package/geometry/support/meshUtils/Metadata.js +1 -1
  156. package/graphic/GeoRSSGraphicOrigin.d.ts +4 -0
  157. package/graphic/GeoRSSGraphicOrigin.js +5 -0
  158. package/graphic/GraphicOrigin.js +1 -1
  159. package/graphic/KnowledgeGraphGraphicOrigin.d.ts +4 -0
  160. package/graphic/KnowledgeGraphGraphicOrigin.js +5 -0
  161. package/graphic/MapImageGraphicOrigin.d.ts +4 -0
  162. package/graphic/MapImageGraphicOrigin.js +5 -0
  163. package/graphic/MapNotesGraphicOrigin.d.ts +4 -0
  164. package/graphic/MapNotesGraphicOrigin.js +5 -0
  165. package/graphic/OrientedImageryGraphicOrigin.d.ts +4 -0
  166. package/graphic/OrientedImageryGraphicOrigin.js +5 -0
  167. package/graphic/ParquetGraphicOrigin.d.ts +4 -0
  168. package/graphic/ParquetGraphicOrigin.js +5 -0
  169. package/graphic/SubtypeGroupGraphicOrigin.d.ts +4 -0
  170. package/graphic/SubtypeGroupGraphicOrigin.js +5 -0
  171. package/graphic/TileGraphicOrigin.d.ts +4 -0
  172. package/graphic/TileGraphicOrigin.js +5 -0
  173. package/graphic/graphicOrigins.d.ts +8 -0
  174. package/graphic/graphicOrigins.js +1 -1
  175. package/{views/3d/terrain/RenderOrder.js → graphic/isGeoRSSGraphicOrigin.js} +1 -0
  176. package/graphic/isKnowledgeGraphGraphicOrigin.js +5 -0
  177. package/graphic/isMapImageGraphicOrigin.js +5 -0
  178. package/graphic/isMapNotesGraphicOrigin.js +5 -0
  179. package/graphic/isOrientedImageryGraphicOrigin.js +5 -0
  180. package/graphic/isParquetGraphicOrigin.js +5 -0
  181. package/graphic/isSubtypeGroupGraphicOrigin.js +5 -0
  182. package/graphic/isTileGraphicOrigin.js +5 -0
  183. package/identity/IdentityManagerBase.js +1 -1
  184. package/interfaces.d.ts +228 -0
  185. package/kernel.js +1 -1
  186. package/layers/CSVLayer.js +1 -1
  187. package/layers/FeatureLayer.js +1 -1
  188. package/layers/GeoJSONLayer.js +1 -1
  189. package/layers/ImageryLayer.js +1 -1
  190. package/layers/ImageryTileLayer.js +1 -1
  191. package/layers/Layer.js +1 -1
  192. package/layers/MapNotesLayer.js +1 -1
  193. package/layers/OGCFeatureLayer.js +1 -1
  194. package/layers/OrientedImageryLayer.js +1 -1
  195. package/layers/ParquetLayer.js +1 -1
  196. package/layers/SceneLayer.js +1 -1
  197. package/layers/StreamLayer.js +1 -1
  198. package/layers/SubtypeGroupLayer.js +1 -1
  199. package/layers/WCSLayer.js +1 -1
  200. package/layers/WFSLayer.js +1 -1
  201. package/layers/buildingSublayers/BuildingComponentSublayer.js +1 -1
  202. package/layers/buildingSublayers/BuildingSublayer.js +1 -1
  203. package/layers/graphics/data/FeatureStore.js +1 -1
  204. package/layers/graphics/sources/CSVSource.js +1 -1
  205. package/layers/graphics/sources/FeatureLayerSource.js +1 -1
  206. package/layers/graphics/sources/GeoJSONSource.js +1 -1
  207. package/layers/graphics/sources/MemorySource.js +1 -1
  208. package/layers/graphics/sources/OGCFeatureSource.js +1 -1
  209. package/layers/graphics/sources/ParquetSource.js +1 -1
  210. package/layers/graphics/sources/WFSSource.js +1 -1
  211. package/layers/knowledgeGraph/KnowledgeGraphSublayer.js +1 -1
  212. package/layers/mixins/EditBusLayer.js +1 -1
  213. package/layers/orientedImagery/core/CameraOrientationHPR.js +1 -1
  214. package/layers/orientedImagery/core/CameraOrientationLTP.js +1 -1
  215. package/layers/orientedImagery/core/CameraOrientationOPK.js +1 -1
  216. package/layers/orientedImagery/core/CameraOrientationYPR.js +1 -1
  217. package/layers/orientedImagery/core/ElevationSourceDefinitions.js +1 -1
  218. package/layers/orientedImagery/core/ExposurePoint.js +1 -1
  219. package/layers/support/BuildingSummaryStatistics.js +1 -1
  220. package/layers/support/ControlPointsGeoreference.js +1 -1
  221. package/layers/support/DisplayFilter.js +1 -1
  222. package/layers/support/DisplayFilterInfo.js +1 -1
  223. package/layers/support/EditFieldsInfo.js +1 -1
  224. package/layers/support/ExpressionInfo.js +1 -1
  225. package/layers/support/FeatureIndex.js +1 -1
  226. package/layers/support/FeatureTemplate.js +1 -1
  227. package/layers/support/FeatureType.js +1 -1
  228. package/layers/support/GeometryFieldsInfo.js +1 -1
  229. package/layers/support/GeoreferenceBase.js +1 -1
  230. package/layers/support/KMLSublayer.js +1 -1
  231. package/layers/support/LayerContingentValuesCache.js +1 -1
  232. package/layers/support/LocalMediaElementSource.js +1 -1
  233. package/layers/support/MediaElementBase.js +1 -1
  234. package/layers/support/PlaybackInfo.js +1 -1
  235. package/layers/support/Relationship.js +1 -1
  236. package/layers/support/StreamConnection.js +1 -1
  237. package/layers/support/Sublayer.js +1 -1
  238. package/layers/support/Subtype.js +1 -1
  239. package/layers/support/SubtypeSublayer.js +1 -1
  240. package/layers/support/TelemetryData.js +1 -1
  241. package/layers/support/TelemetryDisplay.js +1 -1
  242. package/layers/support/TimeInfo.js +1 -1
  243. package/layers/support/TrackInfo.js +1 -1
  244. package/layers/support/TrackPartInfo.js +1 -1
  245. package/layers/support/VideoFrame.js +1 -1
  246. package/layers/support/VideoTimeExtent.js +1 -1
  247. package/layers/support/WMSSublayer.js +1 -1
  248. package/layers/voxel/VoxelColorStop.js +1 -1
  249. package/layers/voxel/VoxelDynamicSection.js +1 -1
  250. package/layers/voxel/VoxelIsosurface.js +1 -1
  251. package/layers/voxel/VoxelOpacityStop.js +1 -1
  252. package/layers/voxel/VoxelRangeFilter.js +1 -1
  253. package/layers/voxel/VoxelSection.js +1 -1
  254. package/layers/voxel/VoxelSlice.js +1 -1
  255. package/layers/voxel/VoxelTransferFunctionStyle.js +1 -1
  256. package/layers/voxel/VoxelUniqueValue.js +1 -1
  257. package/linkChart/ChronologicalLayoutSettings.js +1 -1
  258. package/linkChart/LayoutSettings.js +1 -1
  259. package/linkChart/LinkChartProperties.js +1 -1
  260. package/linkChart/NonspatialDataDisplay.js +1 -1
  261. package/linkChart/OrganicLayoutSettings.js +1 -1
  262. package/networks/Network.js +1 -1
  263. package/networks/RulesTable.js +1 -1
  264. package/networks/UtilityNetwork.js +1 -1
  265. package/networks/support/NetworkSystemLayers.js +1 -1
  266. package/networks/support/UtilityNetworkLookupHelper.js +1 -1
  267. package/package.json +1 -1
  268. package/popup/content/AttachmentsContent.js +1 -1
  269. package/popup/content/RelationshipContent.js +1 -1
  270. package/popup/content/UtilityNetworkAssociationsContent.js +1 -1
  271. package/popup/support/AttachmentsOrderByInfo.js +1 -1
  272. package/popup/support/FieldInfoFormat.js +1 -1
  273. package/popup/support/UtilityNetworkAssociationType.js +1 -1
  274. package/portal/Portal.js +1 -1
  275. package/portal/PortalItem.js +1 -1
  276. package/renderers/PieChartRenderer.js +1 -1
  277. package/renderers/support/HeatmapLegendOptions.js +1 -1
  278. package/renderers/support/OthersCategory.js +1 -1
  279. package/renderers/support/RasterPresetRenderer.js +1 -1
  280. package/renderers/support/RendererLegendOptions.js +1 -1
  281. package/renderers/support/UniqueValue.js +1 -1
  282. package/renderers/support/UniqueValueClass.js +1 -1
  283. package/renderers/support/UniqueValueGroup.js +1 -1
  284. package/renderers/visualVariables/support/VisualVariableLegendOptions.js +1 -1
  285. package/rest/featureService/FeatureService.js +1 -1
  286. package/rest/support/AttributeBinsFeatureSet.js +1 -1
  287. package/rest/support/AttributeBinsGrouping.js +1 -1
  288. package/rest/support/AttributeBinsQuery.js +1 -1
  289. package/rest/support/BinParametersBase.js +1 -1
  290. package/rest/support/ClosestFacilityParameters.js +1 -1
  291. package/rest/support/DataLayer.js +1 -1
  292. package/rest/support/DateBinTimeInterval.js +1 -1
  293. package/rest/support/DirectionLine.js +1 -1
  294. package/rest/support/DirectionPoint.js +1 -1
  295. package/rest/support/FindImagesParameters.js +1 -1
  296. package/rest/support/FullTextSearch.js +1 -1
  297. package/rest/support/ImageBoundaryParameters.js +1 -1
  298. package/rest/support/ImageGPSInfoParameters.js +1 -1
  299. package/rest/support/ImageToMapMultirayParameters.js +1 -1
  300. package/rest/support/ImageToMapParameters.js +1 -1
  301. package/rest/support/ImageUrlParameters.js +1 -1
  302. package/rest/support/ImageVolumeParameters.js +1 -1
  303. package/rest/support/MapToImageParameters.js +1 -1
  304. package/rest/support/NetworkUrl.js +1 -1
  305. package/rest/support/PointBarrier.js +1 -1
  306. package/rest/support/PolygonBarrier.js +1 -1
  307. package/rest/support/PolylineBarrier.js +1 -1
  308. package/rest/support/RouteInfo.js +1 -1
  309. package/rest/support/RouteParameters.js +1 -1
  310. package/rest/support/ServiceAreaParameters.js +1 -1
  311. package/rest/support/Stop.js +1 -1
  312. package/rest/support/TravelMode.js +1 -1
  313. package/smartMapping/raster/support/adapters/RasterLayerAdapter.js +1 -1
  314. package/smartMapping/support/adapters/LayerAdapter.js +1 -1
  315. package/support/actions/ActionBase.js +1 -1
  316. package/support/revision.js +1 -1
  317. package/symbols/LineStyleMarker3D.js +1 -1
  318. package/symbols/PathSymbol3DLayer.js +1 -1
  319. package/symbols/support/ElevationInfo.js +1 -1
  320. package/symbols/support/Symbol3DTextBackground.js +1 -1
  321. package/symbols/support/previewSymbol3D.js +1 -1
  322. package/tables/elements/AttributeTableAttachmentElement.js +1 -1
  323. package/tables/elements/AttributeTableFieldElement.js +1 -1
  324. package/tables/elements/AttributeTableGroupElement.js +1 -1
  325. package/tables/elements/AttributeTableRelationshipElement.js +1 -1
  326. package/tables/support/FieldOrder.js +1 -1
  327. package/undoredo/support/Services.js +1 -1
  328. package/versionManagement/VersionManagementService.js +1 -1
  329. package/versionManagement/VersioningState.js +1 -1
  330. package/views/2d/constraints/GeometryConstraint.js +1 -1
  331. package/views/2d/constraints/RotationConstraint.js +1 -1
  332. package/views/2d/constraints/ZoomConstraint.js +1 -1
  333. package/views/2d/engine/DisplayObject.js +1 -1
  334. package/views/2d/engine/ManagedCanvas.js +1 -1
  335. package/views/2d/engine/vectorTiles/decluttering/CollisionJob.js +1 -1
  336. package/views/2d/engine/vectorTiles/shaders/VTLBackgroundMaterial.js +1 -1
  337. package/views/2d/engine/vectorTiles/shaders/VTLCircleMaterial.js +1 -1
  338. package/views/2d/engine/vectorTiles/shaders/VTLFillMaterial.js +1 -1
  339. package/views/2d/engine/vectorTiles/shaders/VTLLineMaterial.js +1 -1
  340. package/views/2d/engine/vectorTiles/shaders/VTLMaterial.js +1 -1
  341. package/views/2d/engine/vectorTiles/shaders/VTLSymbolMaterial.js +1 -1
  342. package/views/2d/engine/webgl/Profiler.js +1 -1
  343. package/views/2d/engine/webgl/TextureManager.js +1 -1
  344. package/views/2d/engine/webgl/collisions/LabelMetric.js +1 -1
  345. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
  346. package/views/2d/interactive/editingTools/ControlPointsTransformTool.js +1 -1
  347. package/views/2d/interactive/editingTools/TransformTool.js +1 -1
  348. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  349. package/views/2d/layers/GeoRSSLayerView2D.js +1 -1
  350. package/views/2d/layers/StreamLayerView2D.js +1 -1
  351. package/views/2d/layers/features/FeatureSourceEventLog.js +1 -1
  352. package/views/2d/layers/features/layerAdapters/CatalogFootprintLayerAdapter.js +1 -1
  353. package/views/2d/layers/features/layerAdapters/FeatureLayerAdapter.js +1 -1
  354. package/views/2d/layers/features/layerAdapters/InMemoryLayerAdapter.js +1 -1
  355. package/views/2d/layers/features/layerAdapters/KnowledgeGraphSublayerAdapter.js +1 -1
  356. package/views/2d/layers/features/layerAdapters/OGCFeatureLayerAdapter.js +1 -1
  357. package/views/2d/layers/features/layerAdapters/OrientedImageryLayerAdapter.js +1 -1
  358. package/views/2d/layers/features/layerAdapters/ParquetLayerAdapter.js +1 -1
  359. package/views/2d/layers/features/layerAdapters/StreamLayerAdapter.js +1 -1
  360. package/views/2d/layers/features/layerAdapters/SubtypeGroupLayerAdapter.js +1 -1
  361. package/views/2d/layers/features/processor/AAggregateStrategy.js +1 -1
  362. package/views/2d/layers/features/schema/processor/LabelMatcherSchema.js +1 -1
  363. package/views/2d/layers/features/schema/processor/SimpleProcessorSchema.js +1 -1
  364. package/views/2d/layers/features/schema/processor/SubtypeProcessorSchema.js +1 -1
  365. package/views/2d/layers/features/sources/strategies/StreamLoadStrategy.js +1 -1
  366. package/views/2d/layers/features/sources/strategies/chunks/SourceChunkStore.js +1 -1
  367. package/views/2d/layers/features/support/TileStore.js +1 -1
  368. package/views/2d/layers/graphics/GraphicsView2D.js +1 -1
  369. package/views/2d/layers/support/RouteLayerInteraction.js +1 -1
  370. package/views/3d/analysis/AreaMeasurement/support/AreaMeasurementPathHelper.js +1 -1
  371. package/views/3d/analysis/LineOfSight/LineOfSightController.js +1 -1
  372. package/views/3d/analysis/LineOfSightAnalysisView3D.js +1 -1
  373. package/views/3d/constraints/AltitudeConstraint.js +1 -1
  374. package/views/3d/constraints/ClipDistanceConstraint.js +1 -1
  375. package/views/3d/constraints/Constraints.js +1 -1
  376. package/views/3d/constraints/TiltConstraint.js +1 -1
  377. package/views/3d/environment/EnvironmentManager.js +1 -1
  378. package/views/3d/environment/SunLighting.js +1 -1
  379. package/views/3d/environment/VirtualLighting.js +1 -1
  380. package/views/3d/interactive/Manipulator3D.js +1 -1
  381. package/views/3d/interactive/editingTools/ManipulatedObject3DGraphic.js +1 -1
  382. package/views/3d/interactive/editingTools/ManipulatedObject3DMediaElement.js +1 -1
  383. package/views/3d/interactive/editingTools/manipulations/MoveXYAxisManipulation.js +1 -1
  384. package/views/3d/interactive/editingTools/manipulations/MoveZManipulation.js +1 -1
  385. package/views/3d/interactive/editingTools/media/MediaElementManipulator3D.js +1 -1
  386. package/views/3d/interactive/editingTools/move/MoveTool3D.js +1 -1
  387. package/views/3d/interactive/editingTools/reshape/ReshapeOperation.js +1 -1
  388. package/views/3d/interactive/editingTools/reshape/ReshapeTool3D.js +1 -1
  389. package/views/3d/interactive/editingTools/transform/ExtentTransformTool.js +1 -1
  390. package/views/3d/interactive/editingTools/transform/ScaleRotateTransform.js +1 -1
  391. package/views/3d/interactive/editingTools/transform/TransformTool3D.js +1 -1
  392. package/views/3d/interactive/visualElements/DrapedVisualElementResources.js +1 -1
  393. package/views/3d/interactive/visualElements/OutlineVisualElement.js +1 -1
  394. package/views/3d/layers/BuildingSublayerView3D.js +1 -1
  395. package/views/3d/layers/FlowSubView3D.js +1 -1
  396. package/views/3d/layers/GraphicsView3D.js +1 -1
  397. package/views/3d/layers/GraphicsView3DDummyLayer.js +1 -1
  398. package/views/3d/layers/TiledLayerView3D.js +1 -1
  399. package/views/3d/layers/graphics/GraphicState.js +1 -1
  400. package/views/3d/layers/graphics/Graphics3DElevationAlignment.js +1 -1
  401. package/views/3d/layers/graphics/Graphics3DFeatureStore.js +1 -1
  402. package/views/3d/layers/graphics/pipeline/Feature3DPipelineWorker.js +1 -1
  403. package/views/3d/layers/graphics/pipeline/featureSet/TiledFeatureStore.js +1 -1
  404. package/views/3d/layers/i3s/I3SGraphicsMap.js +1 -1
  405. package/views/3d/layers/i3s/I3SQueryFeatureStore.js +1 -1
  406. package/views/3d/layers/i3s/LayerElevationProvider.js +1 -1
  407. package/views/3d/layers/support/StageLayerElevationProvider.js +1 -1
  408. package/views/3d/state/ViewState.js +1 -1
  409. package/views/3d/support/CombinedElevationProvider.js +1 -1
  410. package/views/3d/support/EventedSet.js +1 -1
  411. package/views/3d/support/GraphicsMap.js +1 -1
  412. package/views/3d/support/LimitGraphicsMap.js +1 -1
  413. package/views/3d/support/flow/geometryUtils.js +1 -1
  414. package/views/3d/support/pointsOfInterest/ContentGeometryUpdates.js +1 -1
  415. package/views/3d/support/pointsOfInterest/SurfaceGeometryUpdates.js +1 -1
  416. package/views/3d/terrain/OverlayRenderer.js +1 -1
  417. package/views/3d/terrain/TerrainRenderer.js +1 -1
  418. package/views/3d/terrain/TerrainSurface.js +1 -1
  419. package/views/3d/terrain/tileUtils.js +1 -1
  420. package/views/3d/webgl-engine/lib/TextTextureAtlas.js +1 -1
  421. package/views/3d/webgl-engine/lib/Texture.js +1 -1
  422. package/views/3d/webgl-engine/lib/TextureRepository.js +1 -1
  423. package/views/3d/webgl-engine/lib/WebGLLayer.js +1 -1
  424. package/views/3d/webgl-engine/lib/lodRendering/InstanceData.js +1 -1
  425. package/views/SelectionManager.js +1 -1
  426. package/views/Theme.js +1 -1
  427. package/views/VideoView.js +1 -1
  428. package/views/View.js +1 -1
  429. package/views/analysis/ElevationProfileResult.js +1 -1
  430. package/views/draw/DrawAction.js +1 -1
  431. package/views/draw/DrawGraphicTool.js +1 -1
  432. package/views/draw/DrawManipulator.js +1 -1
  433. package/views/draw/DrawOperation.js +1 -1
  434. package/views/draw/support/Box.js +1 -1
  435. package/views/draw/support/GraphicMover.js +1 -1
  436. package/views/draw/support/Reshape.js +1 -1
  437. package/views/interactive/GraphicManipulator.js +1 -1
  438. package/views/interactive/InteractiveToolBase.js +1 -1
  439. package/views/interactive/Tooltip.js +1 -1
  440. package/views/interactive/editGeometry/EditGeometry.js +1 -1
  441. package/views/interactive/editGeometry/EditGeometryOperations.js +1 -1
  442. package/views/interactive/snapping/SnappingManager.js +1 -1
  443. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
  444. package/views/layers/LayerView.js +1 -1
  445. package/views/support/GroundViewElevationSampler.js +1 -1
  446. package/views/ui/UI.js +1 -1
  447. package/webdoc/GeotriggersInfo.js +1 -1
  448. package/webdoc/IPSInfo.js +1 -1
  449. package/webdoc/geotriggersInfo/DeviceLocationFeed.js +1 -1
  450. package/webdoc/geotriggersInfo/ExpressionInfo.js +1 -1
  451. package/webdoc/geotriggersInfo/FeatureFenceParameters.js +1 -1
  452. package/webdoc/geotriggersInfo/FeatureFilter.js +1 -1
  453. package/webdoc/geotriggersInfo/FeatureLayerSource.js +1 -1
  454. package/webdoc/geotriggersInfo/Geotrigger.js +1 -1
  455. package/webdoc/geotriggersInfo/GeotriggerNotificationOptions.js +1 -1
  456. package/webdoc/ips/AppleIPSProperties.js +1 -1
  457. package/webdoc/ips/Configuration.js +1 -1
  458. package/webdoc/ips/GNSSProperties.js +1 -1
  459. package/webdoc/ips/PathSnappingProperties.js +1 -1
  460. package/webdoc/ips/PositioningService.js +1 -1
  461. package/webdoc/ips/SmoothingProperties.js +1 -1
  462. package/webmap/Bookmark.js +1 -1
  463. package/webmap/InitialViewProperties.js +1 -1
  464. package/webscene/InitialViewProperties.js +1 -1
  465. package/webscene/Presentation.js +1 -1
  466. package/webscene/Slide.js +1 -1
  467. package/webscene/SlideLegendInfo.js +1 -1
  468. package/webscene/support/Description.js +1 -1
  469. package/webscene/support/FeatureReference.js +1 -1
  470. package/webscene/support/FeatureReferenceId.js +1 -1
  471. package/webscene/support/LayerReference.js +1 -1
  472. package/webscene/support/SlideElements.js +1 -1
  473. package/webscene/support/SlideEnvironment.js +1 -1
  474. package/webscene/support/SlideGround.js +1 -1
  475. package/webscene/support/SlidePopupInfo.js +1 -1
  476. package/webscene/support/SlideVisibleLayer.js +1 -1
  477. package/webscene/support/Title.js +1 -1
  478. package/widgets/AreaMeasurement2D/AreaMeasurement2DTool.js +1 -1
  479. package/widgets/BasemapGallery/BasemapGalleryViewModel.js +1 -1
  480. package/widgets/BasemapGallery/support/BasemapGalleryItem.js +1 -1
  481. package/widgets/BasemapGallery/support/PortalBasemapsSource.js +1 -1
  482. package/widgets/BasemapLayerList/BasemapLayerListViewModel.js +1 -1
  483. package/widgets/BasemapLayerList.js +1 -1
  484. package/widgets/BatchAttributeForm/BatchAttributeFormViewModel.js +1 -1
  485. package/widgets/BatchAttributeForm/templates/ElementTemplateBase.js +1 -1
  486. package/widgets/Bookmarks/BookmarksViewModel.js +1 -1
  487. package/widgets/Bookmarks.js +1 -1
  488. package/widgets/CatalogLayerList/CatalogLayerListViewModel.js +1 -1
  489. package/widgets/CatalogLayerList.js +1 -1
  490. package/widgets/CoordinateConversion/CoordinateConversionViewModel.js +1 -1
  491. package/widgets/Daylight/DaylightViewModel.js +1 -1
  492. package/widgets/DirectionalPad/DirectionalPadViewModel.js +1 -1
  493. package/widgets/Directions/DirectionsViewModel.js +1 -1
  494. package/widgets/DistanceMeasurement2D/DistanceMeasurement2DTool.js +1 -1
  495. package/widgets/Editor/EditorViewModel.js +1 -1
  496. package/widgets/Editor/UpdateFeatureWorkflow.js +1 -1
  497. package/widgets/Editor/Workflow.js +1 -1
  498. package/widgets/Editor/support/SketchController.js +1 -1
  499. package/widgets/ElevationProfile/ElevationProfileInteraction.js +1 -1
  500. package/widgets/ElevationProfile/ElevationProfileLine.js +1 -1
  501. package/widgets/Feature/FeatureRelationship/FeatureRelationshipViewModel.js +1 -1
  502. package/widgets/Feature/FeatureViewModel.js +1 -1
  503. package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
  504. package/widgets/FeatureForm/UtilityNetworkAssociationInput.js +1 -1
  505. package/widgets/FeatureTable/Grid/GridViewModel.js +1 -1
  506. package/widgets/FeatureTemplates/FeatureTemplatesViewModel.js +1 -1
  507. package/widgets/FeatureTemplates/TemplateItemGroup.js +1 -1
  508. package/widgets/Home/HomeViewModel.js +1 -1
  509. package/widgets/LayerList/LayerListViewModel.js +1 -1
  510. package/widgets/LayerList/ListItem.js +1 -1
  511. package/widgets/LayerList/ListItemPanel.js +1 -1
  512. package/widgets/LayerList.js +1 -1
  513. package/widgets/LinkChartLayoutSwitcher/LinkChartLayoutSwitcherViewModel.js +1 -1
  514. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  515. package/widgets/OrientedImageryViewer/components/ImageOverlays.js +1 -1
  516. package/widgets/OrientedImageryViewer/components/ImageViewerViewModel.js +1 -1
  517. package/widgets/OrientedImageryViewer/components/NavigationAction.js +1 -1
  518. package/widgets/PanoramicViewer/PanoramicViewerViewModel.js +1 -1
  519. package/widgets/PanoramicViewer/PanoramicZoomConditions.js +1 -1
  520. package/widgets/Print/PrintViewModel.js +1 -1
  521. package/widgets/Search/SearchSource.js +1 -1
  522. package/widgets/Search/SearchViewModel.js +1 -1
  523. package/widgets/Sketch/SketchViewModel.js +1 -1
  524. package/widgets/Sketch/support/OperationHandle.js +1 -1
  525. package/widgets/TableList/ListItem.js +1 -1
  526. package/widgets/TableList/ListItemPanel.js +1 -1
  527. package/widgets/TableList/TableListViewModel.js +1 -1
  528. package/widgets/TableList.js +1 -1
  529. package/widgets/TimeSlider/TimeSliderViewModel.js +1 -1
  530. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
  531. package/widgets/ValuePicker/ValuePickerViewModel.js +1 -1
  532. package/widgets/Widget.js +1 -1
  533. package/widgets/support/AnchorElementViewModel.js +1 -1
  534. package/widgets/support/GeolocationPositioning.js +1 -1
  535. package/widgets/support/GridControls/GridControlsViewModel.js +1 -1
  536. package/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js +1 -1
  537. package/widgets/support/Selector2D/SelectionOperation.js +1 -1
  538. package/widgets/support/UtilityNetworkAssociations/FeatureUtilityNetworkAssociationsViewModel.js +1 -1
  539. package/assets/esri/core/workers/chunks/038bd2fec9a91b5a949d.js +0 -1
  540. package/assets/esri/core/workers/chunks/093de3942e1ead231990.js +0 -1
  541. package/assets/esri/core/workers/chunks/0997e09fe5b0aba1f804.js +0 -1
  542. package/assets/esri/core/workers/chunks/0c0080b652cf8afc4e6b.js +0 -1
  543. package/assets/esri/core/workers/chunks/0f6207d84d15484a3181.js +0 -1
  544. package/assets/esri/core/workers/chunks/125fdea50620d4db2678.js +0 -1
  545. package/assets/esri/core/workers/chunks/152128775b4740e779ab.js +0 -1
  546. package/assets/esri/core/workers/chunks/173c5b8fa1ac7aa6e072.js +0 -1
  547. package/assets/esri/core/workers/chunks/1e58b1e191498417c21d.js +0 -1
  548. package/assets/esri/core/workers/chunks/2032b649350a75ba294f.js +0 -1
  549. package/assets/esri/core/workers/chunks/2105d2cc75e75bf8f1c0.js +0 -1
  550. package/assets/esri/core/workers/chunks/21246dfe99a4c5906f71.js +0 -1
  551. package/assets/esri/core/workers/chunks/221748295a5ec633177e.js +0 -1
  552. package/assets/esri/core/workers/chunks/2a695b50a384c45ace9a.js +0 -1
  553. package/assets/esri/core/workers/chunks/2ad63b8d6986ac21c398.js +0 -1
  554. package/assets/esri/core/workers/chunks/2c29f8a708a03cb703ab.js +0 -1
  555. package/assets/esri/core/workers/chunks/2df9bfddc737d89c94b8.js +0 -1
  556. package/assets/esri/core/workers/chunks/34ddb8da5c5c8533bd71.js +0 -1
  557. package/assets/esri/core/workers/chunks/40b0c5368b8322498189.js +0 -1
  558. package/assets/esri/core/workers/chunks/427deb82fae9c500b375.js +0 -1
  559. package/assets/esri/core/workers/chunks/4433c195c62a59739c06.js +0 -1
  560. package/assets/esri/core/workers/chunks/4ac6bf9ff1cfbde87c7b.js +0 -1
  561. package/assets/esri/core/workers/chunks/4b9003ddfe61dc3729f4.js +0 -1
  562. package/assets/esri/core/workers/chunks/4bb6148df66e62a5fcf0.js +0 -1
  563. package/assets/esri/core/workers/chunks/4fb13252a985131d3dae.js +0 -1
  564. package/assets/esri/core/workers/chunks/528212fb0474bdb2ec92.js +0 -1
  565. package/assets/esri/core/workers/chunks/5dba8c0c957becedf7f7.js +0 -1
  566. package/assets/esri/core/workers/chunks/5f995450f720483fcffa.js +0 -1
  567. package/assets/esri/core/workers/chunks/61aed9a292c981921869.js +0 -1
  568. package/assets/esri/core/workers/chunks/6aeff5908c41600a5dfc.js +0 -1
  569. package/assets/esri/core/workers/chunks/6c72e2c09ed62cb2fd79.js +0 -1
  570. package/assets/esri/core/workers/chunks/7099ff8dc699fedea931.js +0 -1
  571. package/assets/esri/core/workers/chunks/752eabfbed7b8b65cf3f.js +0 -1
  572. package/assets/esri/core/workers/chunks/7848ea5ca13ec350779a.js +0 -1
  573. package/assets/esri/core/workers/chunks/7a4ec66a577f7f7996c5.js +0 -1
  574. package/assets/esri/core/workers/chunks/81be8d23b8dfa4937eaf.js +0 -1
  575. package/assets/esri/core/workers/chunks/831d58235b8b9eb4cdc8.js +0 -1
  576. package/assets/esri/core/workers/chunks/90a0c1c5c851cc9b6d6d.js +0 -1
  577. package/assets/esri/core/workers/chunks/969a9edba4be8dcbcedd.js +0 -1
  578. package/assets/esri/core/workers/chunks/9a54c96b48e94d816881.js +0 -1
  579. package/assets/esri/core/workers/chunks/a53f2529b7067c28f320.js +0 -1
  580. package/assets/esri/core/workers/chunks/a6b6915b7321f77f765f.js +0 -1
  581. package/assets/esri/core/workers/chunks/aa12ba96fb8c91105473.js +0 -1
  582. package/assets/esri/core/workers/chunks/ab73df4f809430db6249.js +0 -1
  583. package/assets/esri/core/workers/chunks/acb95ae6203f708d71b4.js +0 -1
  584. package/assets/esri/core/workers/chunks/ae7f1499912c86973921.js +0 -1
  585. package/assets/esri/core/workers/chunks/b28855db6a30d4d4f348.js +0 -1
  586. package/assets/esri/core/workers/chunks/b4bbd38df56e57783cc0.js +0 -1
  587. package/assets/esri/core/workers/chunks/b98a049561b12a0555b7.js +0 -1
  588. package/assets/esri/core/workers/chunks/c0718a0461839be41a2a.js +0 -1
  589. package/assets/esri/core/workers/chunks/c0aee315b6218d6456cd.js +0 -1
  590. package/assets/esri/core/workers/chunks/c0ec1600a86bb9a848d4.js +0 -1
  591. package/assets/esri/core/workers/chunks/c9b11c7170c99f9e0e93.js +0 -1
  592. package/assets/esri/core/workers/chunks/ca88859fc69fcb4568c0.js +0 -1
  593. package/assets/esri/core/workers/chunks/cc3ca1729af33688c1e3.js +0 -1
  594. package/assets/esri/core/workers/chunks/cd150c7e1516134c7437.js +0 -1
  595. package/assets/esri/core/workers/chunks/cde79c3644166d4798a8.js +0 -1
  596. package/assets/esri/core/workers/chunks/d092a4b8fe3d37a6333d.js +0 -1
  597. package/assets/esri/core/workers/chunks/d4cadde4a9cbfe2c51d8.js +0 -1
  598. package/assets/esri/core/workers/chunks/d6a188a7d55db69ba30b.js +0 -1
  599. package/assets/esri/core/workers/chunks/d7172dc531b4548a8c60.js +0 -1
  600. package/assets/esri/core/workers/chunks/d88935ae5669d14c5b29.js +0 -1
  601. package/assets/esri/core/workers/chunks/dab82564928265b9f22d.js +0 -1
  602. package/assets/esri/core/workers/chunks/e82b1f91465d569012c4.js +0 -1
  603. package/assets/esri/core/workers/chunks/e892ed8b0b990d7eba28.js +0 -1
  604. package/assets/esri/core/workers/chunks/e897c5ce83db8a71b0a2.js +0 -1
  605. package/assets/esri/core/workers/chunks/efec0f496491a0647051.js +0 -1
  606. package/assets/esri/core/workers/chunks/f01a939af200616eb169.js +0 -1
  607. package/assets/esri/core/workers/chunks/f19426eb53d8430ded51.js +0 -1
  608. package/assets/esri/core/workers/chunks/f255b2232f6f049d462d.js +0 -1
  609. package/assets/esri/core/workers/chunks/f3358b19af0f03f16543.js +0 -1
  610. package/assets/esri/core/workers/chunks/f4c38a9c01c29b5a6244.js +0 -1
  611. package/assets/esri/core/workers/chunks/f6c1854f36b029fa6c37.js +0 -1
  612. package/assets/esri/core/workers/chunks/fa01d418237d7fa67efc.js +0 -1
  613. package/assets/esri/core/workers/chunks/ff736cb5a9fd18368244.js +0 -1
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as o}from"tslib";import r from"../../core/Clonable.js";import s from"../../core/JSONSupport.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import{colorAndTransparencyProperty as p}from"./materialUtils.js";let c=class extends(r.ClonableMixin(s)){constructor(o){super(o),this.color=null}};o([t(p())],c.prototype,"color",void 0),c=o([e("esri.symbols.support.Symbol3DTextBackground")],c);export{c as Symbol3DTextBackground};
5
+ import{__decorate as o}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import s from"../../core/JSONSupport.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import{colorAndTransparencyProperty as p}from"./materialUtils.js";let c=class extends(r(s)){constructor(o){super(o),this.color=null}};o([t(p())],c.prototype,"color",void 0),c=o([e("esri.symbols.support.Symbol3DTextBackground")],c);export{c as Symbol3DTextBackground};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{getAssetUrl as e}from"../../assets.js";import{toHSV as t,toRGB as l}from"../../core/colorUtils.js";import"../../core/has.js";import a from"../../core/Error.js";import s from"../../core/Logger.js";import{pt2px as n}from"../../core/screenUtils.js";import{defaultThematicColor as r,dekebabifyLineStyle as o,getPatternUrlWithColor as i}from"./gfxUtils.js";import{defaultPrimitive as c}from"./IconSymbol3DLayerResource.js";import{defaultPrimitive as p}from"./ObjectSymbol3DLayerResource.js";import{adjustColorComponentBrightness as u,shapes as h,getTetrahedronShapes as m,getDiamondShapes as f,getCylinderShapes as y,getCubeShapes as d,getInvertedConeShapes as b,getConeShapes as k,getPathSymbolShapes as v,getWaterSymbolShapes as g,getExtrudeSymbolShapes as w}from"./previewUtils.js";import{renderSymbol as x,tintImageWithColor as M}from"./renderUtils.js";import{isVolumetricSymbol as L,getIconHref as j}from"./utils.js";import{resolveWebStyleSymbol as z}from"./webStyleSymbolUtils.js";const S=22,P=120,D=80,U=50,O=20;function C(e){const t=e.outline,l=null!=e.material?e.material.color:null,a=null!=l?l.toHex():null;if(null==t||"pattern"in t&&null!=t.pattern&&"style"===t.pattern.type&&"none"===t.pattern.style)return"fill"===e.type&&"#ffffff"===a?{color:"#bdc3c7",width:.75}:null;const s=n(t.size)||0;return{color:"rgba("+(null!=t.color?t.color.toRgba():"255,255,255,1")+")",width:Math.min(s,D),style:"pattern"in t&&null!=t.pattern&&"style"===t.pattern.type?o(t.pattern.style):null,join:"butt",cap:"patternCap"in t?t.patternCap:"butt"}}async function R(t,l){if(t.thumbnail?.url)return t.thumbnail.url;if("icon"===l.type){const e=l?.resource?.href;if(e)return j(l)}const a=e("esri/images/Legend/legend3dsymboldefault.png");if(t.styleOrigin&&(t.styleOrigin.styleName||t.styleOrigin.styleUrl)){const e=await z(t.styleOrigin,{portal:t.styleOrigin.portal}).catch(()=>null);if(e&&"thumbnail"in e&&e.thumbnail?.url)return e.thumbnail.url}return a}function E(e,a=1){const s=e.a,n=t(e),r=n.h,o=n.s/a,i=100-(100-n.v)/a,{r:c,g:p,b:u}=l({h:r,s:o,v:i});return[c,p,u,s]}function q(e){return"water"===e.type?null==e.color?null:e.color:null==e.material?.color?null:e.material.color}function I(e,t=0){const l=q(e);if(!l){if("fill"===e.type)return null;const l=r.r,a=u(l,t);return[a,a,a,100]}const a=l.toRgba();for(let s=0;s<3;s++)a[s]=u(a[s],t);return a}async function Z(t,l){const a=t.style;if("none"===a)return null;return{type:"pattern",x:0,y:0,src:await i(e(`esri/symbols/patterns/${a}.png`),l.toCss(!0)),width:5,height:5}}function H(e){return e.outline?C(e):{color:"rgba(0, 0, 0, 1)",width:1.5}}function N(e,t){const l=q(e);if(!l)return null;let a="rgba(";return a+=u(l.r,t)+",",a+=u(l.g,t)+",",a+=u(l.b,t)+",",a+l.a+");"}function T(e,t){const l=N(e,t);if(!l)return{};if("pattern"in e&&null!=e.pattern&&"style"===e.pattern.type&&"none"===e.pattern.style)return null;return{color:l,width:Math.min(e.size?n(e.size):.75,D),style:"pattern"in e&&null!=e.pattern&&"style"===e.pattern.type?o(e.pattern.style):null,cap:"cap"in e?e.cap:null,join:"join"in e?"miter"===e.join?n(2):e.join:null}}function F(e,t,l){const a=null!=l?.75*l:0;return{type:"linear",x1:a?.25*a:0,y1:a?.5*a:0,x2:a||4,y2:a?.5*a:4,colors:[{color:e,offset:0},{color:t,offset:1}]}}function $(e){const t=e.depth,l=e.height,a=e.width;return 0!==a&&0!==t&&0!==l&&a===t&&null!=a&&null!=l&&a<l}function A(e,t,l){const a=[];if(!e)return a;switch(e.type){case"icon":{const l=0,s=0,n=t,r=t;switch(e.resource?.primitive??c){case"circle":a.push({shape:{type:"circle",cx:0,cy:0,r:.5*t},fill:I(e,0),stroke:C(e)});break;case"square":a.push({shape:{type:"path",path:[{command:"M",values:[l,r]},{command:"L",values:[l,s]},{command:"L",values:[n,s]},{command:"L",values:[n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:C(e)});break;case"triangle":a.push({shape:{type:"path",path:[{command:"M",values:[l,r]},{command:"L",values:[.5*n,s]},{command:"L",values:[n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:C(e)});break;case"cross":a.push({shape:{type:"path",path:[{command:"M",values:[.5*n,s]},{command:"L",values:[.5*n,r]},{command:"M",values:[l,.5*r]},{command:"L",values:[n,.5*r]}]},stroke:H(e)});break;case"x":a.push({shape:{type:"path",path:[{command:"M",values:[l,s]},{command:"L",values:[n,r]},{command:"M",values:[n,s]},{command:"L",values:[l,r]}]},stroke:H(e)});break;case"kite":a.push({shape:{type:"path",path:[{command:"M",values:[l,.5*r]},{command:"L",values:[.5*n,s]},{command:"L",values:[n,.5*r]},{command:"L",values:[.5*n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:C(e)})}break}case"object":switch(e.resource?.primitive??p){case"cone":{const s=F(I(e,0),I(e,-.6),l?O:t),n=k(t,l);a.push({shape:n[0],fill:s},{shape:n[1],fill:s});break}case"inverted-cone":{const l=I(e,0),s=F(l,I(e,-.6),t),n=b(t);a.push({shape:n[0],fill:s},{shape:n[1],fill:l});break}case"cube":{const s=d(t,l);a.push({shape:s[0],fill:I(e,0)},{shape:s[1],fill:I(e,-.3)},{shape:s[2],fill:I(e,-.5)});break}case"cylinder":{const s=F(I(e,0),I(e,-.6),l?O:t),n=y(t,l);a.push({shape:n[0],fill:s},{shape:n[1],fill:s},{shape:n[2],fill:I(e,0)});break}case"diamond":{const l=f(t);a.push({shape:l[0],fill:I(e,-.3)},{shape:l[1],fill:I(e,0)},{shape:l[2],fill:I(e,-.3)},{shape:l[3],fill:I(e,-.7)});break}case"sphere":{const l=F(I(e,0),I(e,-.6));l.x1=0,l.y1=0,l.x2=.25*t,l.y2=.25*t,a.push({shape:{type:"circle",cx:0,cy:0,r:.5*t},fill:l});break}case"tetrahedron":{const l=m(t);a.push({shape:l[0],fill:I(e,-.3)},{shape:l[1],fill:I(e,0)},{shape:l[2],fill:I(e,-.6)});break}}break}return a}function B(e){const t="number"==typeof e?.size?e?.size:null;return t?n(t):null}function G(e){return"icon"===e.type?"multiply":"tint"}async function J(e,t){const l=B(t),a=t?.maxSize?n(t.maxSize):null,r=t?.disableUpsampling??!1,o=e.symbolLayers,i=[],c=[];let p=!1,u=0,h=0,m=0;o.forEach(s=>{if("icon"!==s.type&&"object"!==s.type)return;s&&"icon"===s.type&&(m=Math.max(s.size&&n(s.size),m));const o="icon"===s.type?s.size&&n(s.size):0,f=l||o?Math.ceil(Math.min(l||o,a||P)):S;let y="icon"===s.type?s.angle:null;if(null!=t?.rotation&&(y=(y??0)+t.rotation),c.push(y),s?.resource?.href){const t=R(e,s).then(e=>{const t=s?.material?.color,l=G(s);return M(e,f,t,l,r)}).then(e=>{const t=e.width,l=e.height;return u=Math.max(u,t),h=Math.max(h,l),y&&(p=!0),[{shape:{type:"image",x:0,y:0,width:t,height:l,src:e.url},fill:null,stroke:null}]});i.push(t)}else{let e=f;"icon"===s.type&&l&&(e=f*(o/m));const a="tall"===t?.symbolConfig||t?.symbolConfig?.isTall||"object"===s.type&&$(s);u=Math.max(u,a?O:e),h=Math.max(h,e),y&&s.resource?.primitive&&["square","triangle","x"].includes(s.resource?.primitive)&&(p=!0),i.push(Promise.resolve(A(s,e,a)))}});const f=await Promise.allSettled(i),y=[];return f.forEach(e=>{"fulfilled"===e.status?y.push(e.value):e.reason&&s.getLogger("esri.symbols.support.previewSymbol3D").warn("error while building swatchInfo!",e.reason)}),x(y,[u,h],{node:t?.node,scale:!1,opacity:t?.opacity,ariaLabel:t?.ariaLabel,rotations:c,useRotationSize:p})}function K(e,t){const l=e.symbolLayers,a=[],s=L(e),r=B(t),o=(t?.maxSize?n(t.maxSize):null)||D;let i,c=0,p=0;return l.forEach((e,t)=>{if(!e)return;if("line"!==e.type&&"path"!==e.type)return;const l=[];switch(e.type){case"line":{const a=T(e,0);if(null==a)break;const s=a?.width||0;0===t&&(i=s);const n=Math.min(r||s,o),u=0===t?n:r?n*(s/i):n,h=u>U/2?2*u:U;p=Math.max(p,u),c=Math.max(c,h),a.width=u,l.push({shape:{type:"path",path:[{command:"M",values:[0,.5*p]},{command:"L",values:[c,.5*p]}]},stroke:a});break}case"path":{const t=Math.min(r||S,o),a=I(e,0),s=I(e,-.2),n=N(e,-.4),i=n?{color:n,width:1}:{};if("quad"===e.profile){const t=e.width,n=e.height,r=v(t&&n?t/n:1,0===n,0===t),o={...i,join:"bevel"};l.push({shape:r[0],fill:s,stroke:o},{shape:r[1],fill:s,stroke:o},{shape:r[2],fill:a,stroke:o})}else l.push({shape:h.pathSymbol3DLayer[0],fill:s,stroke:i},{shape:h.pathSymbol3DLayer[1],fill:a,stroke:i});p=Math.max(p,t),c=p}}a.push(l)}),Promise.resolve(x(a,[c,p],{node:t?.node,scale:s,opacity:t?.opacity,ariaLabel:t?.ariaLabel}))}async function Q(e,t){const l="mesh-3d"===e.type,a=e.symbolLayers,s=B(t),r=t?.maxSize?n(t.maxSize):null,o=s||S,i=[];let c=0,p=0,u=!1;for(let n=0;n<a.length;n++){const e=a.at(n),t=[];if(!l||"fill"===e.type){switch(e.type){case"fill":{const a=Math.min(o,r||P);if(c=Math.max(c,a),p=Math.max(p,a),u=!0,l){const l=h.meshSymbol3DFill,a=N(e,-.4),s=a?{color:a,width:1,join:"round"}:{};t.push({shape:l[0],fill:I(e,0),stroke:s},{shape:l[1],fill:I(e,-.2),stroke:s},{shape:l[2],fill:I(e,-.6),stroke:s})}else{let l=I(e,0);const a="pattern"in e?e.pattern:null,s=C(e),n=q(e);null!=a&&"style"===a.type&&"solid"!==a.style&&n&&(l=await Z(a,n)),t.push({shape:h.fill[0],fill:l,stroke:s})}break}case"line":{const l=T(e,0);if(null==l)break;const a={stroke:l,shape:h.fill[0]};c=Math.max(c,S),p=Math.max(p,S),t.push(a);break}case"extrude":{const l={join:"round",width:1,...T(e,-.4)},a=I(e,0),s=I(e,-.2),n=Math.min(o,r||P),i=w(n);l.width=1,t.push({shape:i[0],fill:s,stroke:l},{shape:i[1],fill:s,stroke:l},{shape:i[2],fill:a,stroke:l});const u=S,h=.7*S+.5*n;c=Math.max(c,u),p=Math.max(p,h);break}case"water":{const l=q(e),a=E(l),s=E(l,2),n=E(l,3),i=g();u=!0,t.push({shape:i[0],fill:a},{shape:i[1],fill:s},{shape:i[2],fill:n});const h=Math.min(o,r||P);c=Math.max(c,h),p=Math.max(p,h);break}}i.push(t)}}return x(i,[c,p],{node:t?.node,scale:u,opacity:t?.opacity,ariaLabel:t?.ariaLabel})}function V(e,t){if(0===e.symbolLayers.length)return Promise.reject(new a("symbolPreview: renderPreviewHTML3D","No symbolLayers in the symbol."));switch(e.type){case"point-3d":return J(e,t);case"line-3d":return K(e,t);case"polygon-3d":case"mesh-3d":return Q(e,t)}return Promise.reject(new a("symbolPreview: swatchInfo3D","symbol not supported."))}export{Z as getPatternDescriptor,B as getSizeFromOptions,I as getSymbolLayerFill,V as previewSymbol3D};
5
+ import{getAssetUrl as e}from"../../assets.js";import{toHSV as t,toRGB as l}from"../../core/colorUtils.js";import"../../core/has.js";import a from"../../core/Error.js";import s from"../../core/Logger.js";import{pt2px as n}from"../../core/screenUtils.js";import{defaultThematicColor as r,dekebabifyLineStyle as o,getPatternUrlWithColor as i}from"./gfxUtils.js";import{defaultPrimitive as c}from"./IconSymbol3DLayerResource.js";import{defaultPrimitive as p}from"./ObjectSymbol3DLayerResource.js";import{adjustColorComponentBrightness as u,shapes as h,getTetrahedronShapes as m,getDiamondShapes as f,getCylinderShapes as y,getCubeShapes as d,getInvertedConeShapes as b,getConeShapes as k,getPathSymbolShapes as v,getWaterSymbolShapes as g,getExtrudeSymbolShapes as w}from"./previewUtils.js";import{renderSymbol as x,tintImageWithColor as M}from"./renderUtils.js";import{isVolumetricSymbol as L,getIconHref as j}from"./utils.js";import{resolveWebStyleSymbol as z}from"./webStyleSymbolUtils.js";const S=22,P=120,D=80,U=50,C=20;function O(e){const t=e.outline,l=null!=e.material?e.material.color:null,a=null!=l?l.toHex():null;if(null==t||"pattern"in t&&null!=t.pattern&&"style"===t.pattern.type&&"none"===t.pattern.style)return"fill"===e.type&&"#ffffff"===a?{color:"#bdc3c7",width:.75}:null;const s=n(t.size)||0;return{color:"rgba("+(null!=t.color?t.color.toRgba():"255,255,255,1")+")",width:Math.min(s,D),style:"pattern"in t&&null!=t.pattern&&"style"===t.pattern.type?o(t.pattern.style):null,join:"butt",cap:"patternCap"in t?t.patternCap:"butt"}}async function R(t,l){if(t.thumbnail?.url)return t.thumbnail.url;if("icon"===l.type){const e=l?.resource?.href;if(e)return j(l)}const a=e("esri/images/Legend/legend3dsymboldefault.png");if(t.styleOrigin&&(t.styleOrigin.styleName||t.styleOrigin.styleUrl)){const e=await z(t.styleOrigin,{portal:t.styleOrigin.portal}).catch(()=>null);if(e&&"thumbnail"in e&&e.thumbnail?.url)return e.thumbnail.url}return a}function E(e,a=1){const s=e.a,n=t(e),r=n.h,o=n.s/a,i=100-(100-n.v)/a,{r:c,g:p,b:u}=l({h:r,s:o,v:i});return[c,p,u,s]}function q(e){return"water"===e.type?null==e.color?null:e.color:null==e.material?.color?null:e.material.color}function I(e,t=0){const l=q(e);if(!l){if("fill"===e.type)return null;const l=r.r,a=u(l,t);return[a,a,a,100]}const a=l.toRgba();for(let s=0;s<3;s++)a[s]=u(a[s],t);return a}async function Z(t,l){const a=t.style;if("none"===a)return null;return{type:"pattern",x:0,y:0,src:await i(e(`esri/symbols/patterns/${a}.png`),l.toCss(!0)),width:5,height:5}}function H(e){return e.outline?O(e):{color:"rgba(0, 0, 0, 1)",width:1.5}}function N(e,t){const l=q(e);if(!l)return null;let a="rgba(";return a+=u(l.r,t)+",",a+=u(l.g,t)+",",a+=u(l.b,t)+",",a+l.a+");"}function T(e,t){const l=e.edges;if(!l||!l.color||!l.size)return null;return{color:l.color.toCss(!0),width:Math.min(n(l.size),t,D),join:"round"}}function F(e,t){const l=N(e,t);if(!l)return null;if("pattern"in e&&null!=e.pattern&&"style"===e.pattern.type&&"none"===e.pattern.style)return null;const a={color:l,width:Math.min(e.size?n(e.size):.75,D)};return"pattern"in e&&"style"===e.pattern?.type&&(a.style=o(e.pattern.style)),"cap"in e&&e.cap&&(a.cap=e.cap),"join"in e&&e.join&&(a.join="miter"===e.join?n(2):e.join),a}function $(e,t,l){const a=null!=l?.75*l:0;return{type:"linear",x1:a?.25*a:0,y1:a?.5*a:0,x2:a||4,y2:a?.5*a:4,colors:[{color:e,offset:0},{color:t,offset:1}]}}function A(e){const t=e.depth,l=e.height,a=e.width;return 0!==a&&0!==t&&0!==l&&a===t&&null!=a&&null!=l&&a<l}function B(e,t,l){const a=[];if(!e)return a;switch(e.type){case"icon":{const l=0,s=0,n=t,r=t;switch(e.resource?.primitive??c){case"circle":a.push({shape:{type:"circle",cx:0,cy:0,r:.5*t},fill:I(e,0),stroke:O(e)});break;case"square":a.push({shape:{type:"path",path:[{command:"M",values:[l,r]},{command:"L",values:[l,s]},{command:"L",values:[n,s]},{command:"L",values:[n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:O(e)});break;case"triangle":a.push({shape:{type:"path",path:[{command:"M",values:[l,r]},{command:"L",values:[.5*n,s]},{command:"L",values:[n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:O(e)});break;case"cross":a.push({shape:{type:"path",path:[{command:"M",values:[.5*n,s]},{command:"L",values:[.5*n,r]},{command:"M",values:[l,.5*r]},{command:"L",values:[n,.5*r]}]},stroke:H(e)});break;case"x":a.push({shape:{type:"path",path:[{command:"M",values:[l,s]},{command:"L",values:[n,r]},{command:"M",values:[n,s]},{command:"L",values:[l,r]}]},stroke:H(e)});break;case"kite":a.push({shape:{type:"path",path:[{command:"M",values:[l,.5*r]},{command:"L",values:[.5*n,s]},{command:"L",values:[n,.5*r]},{command:"L",values:[.5*n,r]},{command:"Z",values:[]}]},fill:I(e,0),stroke:O(e)})}break}case"object":switch(e.resource?.primitive??p){case"cone":{const s=$(I(e,0),I(e,-.6),l?C:t),n=k(t,l);a.push({shape:n[0],fill:s},{shape:n[1],fill:s});break}case"inverted-cone":{const l=I(e,0),s=$(l,I(e,-.6),t),n=b(t);a.push({shape:n[0],fill:s},{shape:n[1],fill:l});break}case"cube":{const s=d(t,l);a.push({shape:s[0],fill:I(e,0)},{shape:s[1],fill:I(e,-.3)},{shape:s[2],fill:I(e,-.5)});break}case"cylinder":{const s=$(I(e,0),I(e,-.6),l?C:t),n=y(t,l);a.push({shape:n[0],fill:s},{shape:n[1],fill:s},{shape:n[2],fill:I(e,0)});break}case"diamond":{const l=f(t);a.push({shape:l[0],fill:I(e,-.3)},{shape:l[1],fill:I(e,0)},{shape:l[2],fill:I(e,-.3)},{shape:l[3],fill:I(e,-.7)});break}case"sphere":{const l=$(I(e,0),I(e,-.6));l.x1=0,l.y1=0,l.x2=.25*t,l.y2=.25*t,a.push({shape:{type:"circle",cx:0,cy:0,r:.5*t},fill:l});break}case"tetrahedron":{const l=m(t);a.push({shape:l[0],fill:I(e,-.3)},{shape:l[1],fill:I(e,0)},{shape:l[2],fill:I(e,-.6)});break}}break}return a}function G(e){const t="number"==typeof e?.size?e?.size:null;return t?n(t):null}function J(e){return"icon"===e.type?"multiply":"tint"}async function K(e,t){const l=G(t),a=t?.maxSize?n(t.maxSize):null,r=t?.disableUpsampling??!1,o=e.symbolLayers,i=[],c=[];let p=!1,u=0,h=0,m=0;o.forEach(s=>{if("icon"!==s.type&&"object"!==s.type)return;s&&"icon"===s.type&&(m=Math.max(s.size&&n(s.size),m));const o="icon"===s.type?s.size&&n(s.size):0,f=l||o?Math.ceil(Math.min(l||o,a||P)):S;let y="icon"===s.type?s.angle:null;if(null!=t?.rotation&&(y=(y??0)+t.rotation),c.push(y),s?.resource?.href){const t=R(e,s).then(e=>{const t=s?.material?.color,l=J(s);return M(e,f,t,l,r)}).then(e=>{const t=e.width,l=e.height;return u=Math.max(u,t),h=Math.max(h,l),y&&(p=!0),[{shape:{type:"image",x:0,y:0,width:t,height:l,src:e.url},fill:null,stroke:null}]});i.push(t)}else{let e=f;"icon"===s.type&&l&&(e=f*(o/m));const a="tall"===t?.symbolConfig||t?.symbolConfig?.isTall||"object"===s.type&&A(s);u=Math.max(u,a?C:e),h=Math.max(h,e),y&&s.resource?.primitive&&["square","triangle","x"].includes(s.resource?.primitive)&&(p=!0),i.push(Promise.resolve(B(s,e,a)))}});const f=await Promise.allSettled(i),y=[];return f.forEach(e=>{"fulfilled"===e.status?y.push(e.value):e.reason&&s.getLogger("esri.symbols.support.previewSymbol3D").warn("error while building swatchInfo!",e.reason)}),x(y,[u,h],{node:t?.node,scale:!1,opacity:t?.opacity,ariaLabel:t?.ariaLabel,rotations:c,useRotationSize:p})}function Q(e,t){const l=e.symbolLayers,a=[],s=L(e),r=G(t),o=(t?.maxSize?n(t.maxSize):null)||D;let i,c=0,p=0;return l.forEach((e,t)=>{if(!e)return;if("line"!==e.type&&"path"!==e.type)return;const l=[];switch(e.type){case"line":{const a=F(e,0);if(null==a)break;const s=a?.width||0;0===t&&(i=s);const n=Math.min(r||s,o),u=0===t?n:r?n*(s/i):n,h=u>U/2?2*u:U;p=Math.max(p,u),c=Math.max(c,h),a.width=u,l.push({shape:{type:"path",path:[{command:"M",values:[0,.5*p]},{command:"L",values:[c,.5*p]}]},stroke:a});break}case"path":{const t=Math.min(r||S,o),a=I(e,0),s=I(e,-.2),n=N(e,-.4),i=n?{color:n,width:1}:{};if("quad"===e.profile){const t=e.width,n=e.height,r=v(t&&n?t/n:1,0===n,0===t),o={...i,join:"bevel"};l.push({shape:r[0],fill:s,stroke:o},{shape:r[1],fill:s,stroke:o},{shape:r[2],fill:a,stroke:o})}else l.push({shape:h.pathSymbol3DLayer[0],fill:s,stroke:i},{shape:h.pathSymbol3DLayer[1],fill:a,stroke:i});p=Math.max(p,t),c=p}}a.push(l)}),Promise.resolve(x(a,[c,p],{node:t?.node,scale:s,opacity:t?.opacity,ariaLabel:t?.ariaLabel}))}async function V(e,t){const l="mesh-3d"===e.type,a=e.symbolLayers,s=G(t),r=t?.maxSize?n(t.maxSize):null,o=s||S,i=[];let c=0,p=0,u=!1;for(let n=0;n<a.length;n++){const e=a.at(n),t=[];if(!l||"fill"===e.type){switch(e.type){case"fill":{const a=Math.min(o,r||P);if(c=Math.max(c,a),p=Math.max(p,a),u=!0,l){const l=h.meshSymbol3DFill,s=N(e,-.4),n=T(e,.05*a)??(s?{join:"round",color:s,width:1}:null);t.push({shape:l[0],fill:I(e,0),stroke:n},{shape:l[1],fill:I(e,-.2),stroke:n},{shape:l[2],fill:I(e,-.6),stroke:n})}else{let l=I(e,0);const a="pattern"in e?e.pattern:null,s=O(e),n=q(e);null!=a&&"style"===a.type&&"solid"!==a.style&&n&&(l=await Z(a,n)),t.push({shape:h.fill[0],fill:l,stroke:s})}break}case"line":{const l=F(e,0);if(null==l)break;const a={stroke:l,shape:h.fill[0]};c=Math.max(c,S),p=Math.max(p,S),t.push(a);break}case"extrude":{const l=I(e,0),a=I(e,-.2),s=Math.min(o,r||P),n=w(s),i=S,u=.7*S+.5*s,h=T(e,.1*Math.min(i,u))??{join:"round",...F(e,-.4),width:1};t.push({shape:n[0],fill:a,stroke:h},{shape:n[1],fill:a,stroke:h},{shape:n[2],fill:l,stroke:h}),c=Math.max(c,i),p=Math.max(p,u);break}case"water":{const l=q(e),a=E(l),s=E(l,2),n=E(l,3),i=g();u=!0,t.push({shape:i[0],fill:a},{shape:i[1],fill:s},{shape:i[2],fill:n});const h=Math.min(o,r||P);c=Math.max(c,h),p=Math.max(p,h);break}}i.push(t)}}return x(i,[c,p],{node:t?.node,scale:u,opacity:t?.opacity,ariaLabel:t?.ariaLabel})}function W(e,t){if(0===e.symbolLayers.length)return Promise.reject(new a("symbolPreview: renderPreviewHTML3D","No symbolLayers in the symbol."));switch(e.type){case"point-3d":return K(e,t);case"line-3d":return Q(e,t);case"polygon-3d":case"mesh-3d":return V(e,t)}return Promise.reject(new a("symbolPreview: swatchInfo3D","symbol not supported."))}export{Z as getPatternDescriptor,G as getSizeFromOptions,I as getSymbolLayerFill,W as previewSymbol3D};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import t from"../../core/Clonable.js";import{property as o}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"./AttributeTableElement.js";let p=class extends(t.ClonableMixin(s)){constructor(e){super(e),this.displayType="auto",this.type="attachment"}clone(){return super.clone()}};e([o({type:["auto"],json:{write:!0}})],p.prototype,"displayType",void 0),e([o({type:["attachment"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],p.prototype,"type",void 0),p=e([r("esri.tables.elements.AttributeTableAttachmentElement")],p);const a=p;export{a as default};
5
+ import{__decorate as e}from"tslib";import{ClonableMixin as t}from"../../core/Clonable.js";import{property as o}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"./AttributeTableElement.js";let p=class extends(t(s)){constructor(e){super(e),this.displayType="auto",this.type="attachment"}clone(){return super.clone()}};e([o({type:["auto"],json:{write:!0}})],p.prototype,"displayType",void 0),e([o({type:["attachment"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],p.prototype,"type",void 0),p=e([r("esri.tables.elements.AttributeTableAttachmentElement")],p);const a=p;export{a 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import r from"../../core/Clonable.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import i from"./AttributeTableElement.js";let s=class extends(r.ClonableMixin(i)){constructor(e){super(e),this.description=null,this.fieldName=null,this.label=null,this.type="field"}clone(){return super.clone()}};e([t({type:String,json:{read:!1,write:!1}})],s.prototype,"description",void 0),e([t({type:String,json:{write:{enabled:!0,isRequired:!0}}})],s.prototype,"fieldName",void 0),e([t({type:String,json:{read:!1,write:!1}})],s.prototype,"label",void 0),e([t({type:["field"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],s.prototype,"type",void 0),s=e([o("esri.tables.elements.AttributeTableFieldElement")],s);const l=s;export{l as default};
5
+ import{__decorate as e}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import s from"./AttributeTableElement.js";let i=class extends(r(s)){constructor(e){super(e),this.description=null,this.fieldName=null,this.label=null,this.type="field"}clone(){return super.clone()}};e([t({type:String,json:{read:!1,write:!1}})],i.prototype,"description",void 0),e([t({type:String,json:{write:{enabled:!0,isRequired:!0}}})],i.prototype,"fieldName",void 0),e([t({type:String,json:{read:!1,write:!1}})],i.prototype,"label",void 0),e([t({type:["field"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],i.prototype,"type",void 0),i=e([o("esri.tables.elements.AttributeTableFieldElement")],i);const l=i;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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import r from"../../core/Clonable.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import s from"./AttributeTableElement.js";import{typesWithoutGroup as p}from"../support/tablesUtils.js";let l=class extends(r.ClonableMixin(s)){constructor(e){super(e),this.elements=null,this.type="group"}clone(){return super.clone()}};e([t({types:[p],json:{name:"attributeTableElements",write:!0}})],l.prototype,"elements",void 0),e([t({type:["group"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],l.prototype,"type",void 0),l=e([o("esri.tables.elements.AttributeTableGroupElement")],l);const i=l;export{i as default};
5
+ import{__decorate as e}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import s from"./AttributeTableElement.js";import{typesWithoutGroup as p}from"../support/tablesUtils.js";let l=class extends(r(s)){constructor(e){super(e),this.elements=null,this.type="group"}clone(){return super.clone()}};e([t({types:[p],json:{name:"attributeTableElements",write:!0}})],l.prototype,"elements",void 0),e([t({type:["group"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],l.prototype,"type",void 0),l=e([o("esri.tables.elements.AttributeTableGroupElement")],l);const i=l;export{i 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import r from"../../core/Clonable.js";import{property as o}from"../../core/accessorSupport/decorators/property.js";import{Integer as t}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";import i from"./AttributeTableElement.js";let p=class extends(r.ClonableMixin(i)){constructor(e){super(e),this.relationshipId=null,this.type="relationship"}clone(){return super.clone()}};e([o({type:Number,json:{type:t,write:{enabled:!0,isRequired:!0}}})],p.prototype,"relationshipId",void 0),e([o({type:["relationship"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],p.prototype,"type",void 0),p=e([s("esri.tables.elements.AttributeTableRelationshipElement")],p);const l=p;export{l as default};
5
+ import{__decorate as e}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import{property as o}from"../../core/accessorSupport/decorators/property.js";import{Integer as t}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";import p from"./AttributeTableElement.js";let i=class extends(r(p)){constructor(e){super(e),this.relationshipId=null,this.type="relationship"}clone(){return super.clone()}};e([o({type:Number,json:{type:t,write:{enabled:!0,isRequired:!0}}})],i.prototype,"relationshipId",void 0),e([o({type:["relationship"],readOnly:!0,json:{read:!1,write:{enabled:!0,isRequired:!0}}})],i.prototype,"type",void 0),i=e([s("esri.tables.elements.AttributeTableRelationshipElement")],i);const l=i;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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as o}from"tslib";import r from"../../core/Clonable.js";import e from"../../core/JSONSupport.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";let p=class extends(r.ClonableMixin(e)){constructor(o){super(o),this.field=null,this.order=null}};o([t({type:String,json:{write:!0}})],p.prototype,"field",void 0),o([t({type:["asc","desc"],json:{write:!0}})],p.prototype,"order",void 0),p=o([s("esri.tables.support.FieldOrder")],p);const i=p;export{i as default};
5
+ import{__decorate as r}from"tslib";import{ClonableMixin as o}from"../../core/Clonable.js";import e from"../../core/JSONSupport.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";let p=class extends(o(e)){constructor(r){super(r),this.field=null,this.order=null}};r([t({type:String,json:{write:!0}})],p.prototype,"field",void 0),r([t({type:["asc","desc"],json:{write:!0}})],p.prototype,"order",void 0),p=r([s("esri.tables.support.FieldOrder")],p);const c=p;export{c 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import{id as i}from"../../kernel.js";import r from"../../core/Collection.js";import n from"../../core/Error.js";import s from"../../core/Evented.js";import t from"../../core/Loadable.js";import o from"../../core/Logger.js";import{getOrCreateMapValue as a}from"../../core/MapUtils.js";import d from"../../core/Promise.js";import{debounce as c,throwIfAborted as v}from"../../core/promiseUtils.js";import l from"../../core/ReactiveMap.js";import{whenOnce as p,watch as m}from"../../core/reactiveUtils.js";import{normalize as u}from"../../core/urlUtils.js";import{property as f}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as h}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as g}from"../../core/support/UpdatingHandles.js";import{parse as w}from"../../layers/support/arcgisLayerUrl.js";import{isSubtypeGroupLayer as y,isFeatureLayer as S}from"../../layers/support/layerUtils.js";import I from"../../portal/Portal.js";import{hasUserTypeExtension as _}from"../../portal/support/utils.js";import L from"../../rest/featureService/FeatureService.js";import{ServiceVersionInfo as b}from"./ServiceVersionInfo.js";function V(e){return!e||0===e.trim().length}const A=new Map;function U(e){return a(A,e,()=>{const i=new T({view:e});return e.addHandles({remove(){A.delete(e),i.destroy()}}),i.load().catch(e=>{o.getLogger("esri.views.Services").error("Failed to load service metadata",e)}),i})}let T=class extends(t.LoadableMixin(d.EsriPromiseMixin(s.EventedAccessor))){constructor(e){super(e),this._updatingHandles=new g,this.items=new r,this.tablesAndLayersLookup=new l,this.additionalLayers=new r,this._debouncedCheckAndUpdateServiceInfos=c(async()=>{const e=[];for(const i of this.items){if(0===i.layersAndTables.length)continue;const r=i.layersAndTables.getItemAt(0);r?.gdbVersion!==i.versionInfo?.versionIdentifier.name&&e.push(i)}0!==e.length&&(await p(()=>!this.updating),await this._updateVersionInfos(e))}),this._debouncedLayersChanged=c(async()=>{const e=this._detectNewLayersAndTables();0!==e.length&&(await p(()=>!this._updatingHandles.updating),await this._updatingHandles.addPromise((async()=>{const i=new Set;for(const n of e)if("feature"===n.type||"subtype-group"===n.type){if(!n.url)continue;const e=w(n.url).url.path,s=this._findServiceInfo(e);if(s)this.tablesAndLayersLookup.set(n,s),n.isTable?s.tables.push(n):s.layers.push(n);else if(!i.has(e))try{await this._addServiceInfo(e,n)}catch(r){o.getLogger(this).error(`Failed to load feature service: ${e}`,r)}finally{i.add(e)}}})()))}),this._processed=new Set}destroy(){this._set("view",null),this.items.removeAll(),this.tablesAndLayersLookup.clear()}async load(e){return v(e),this.addHandles([m(()=>this.view.map,()=>{this._reset()}),m(()=>this._allLayersAndTables,()=>{this._debouncedLayersChanged().catch(e=>{o.getLogger(this).warn("Failed to update service info",e)})}),m(()=>this.items.map(e=>e.layersAndTables.map(e=>e.gdbVersion??"").join(",")),()=>{this.checkAndUpdateServiceInfos().catch(e=>{o.getLogger(this).warn("Failed to update service info",e)})})]),this.addResolvingPromise(this._debouncedLayersChanged()),this}get updating(){return"loading"===this.loadStatus||this._updatingHandles.updating}checkAndUpdateServiceInfos(){return this._debouncedCheckAndUpdateServiceInfos()}changeVersion(e,i,r){return this._updatingHandles.addPromise((async()=>{await this._changeVersionInternal(e,i,r)})())}createVersion(e){return this._updatingHandles.addPromise((async()=>{const i=e.featureServerUrl,r=this._findServiceInfo(i);if(!r?.versionService)throw new n("services:no-version-management-service","No version management service");const s=r.hasAdvancedEditingUserTypeExtension,t=r.loggedInServiceUser.toUpperCase(),o=V(e.ownerName)?t:e.ownerName?.trim().toUpperCase();if(o!==t){if(r.featureServiceVersion<=11.1)throw new n("services:versioning-api-error","Version management API too old");if(!s)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service")}if("SDE"===o?.toUpperCase()&&"DEFAULT"===e.versionName.toUpperCase())throw new n("services:no-valid-version-name","No valid version name");{const i=await r.versionService.getVersionInfos();if(i?.find(i=>i.versionIdentifier.name.toUpperCase()===(o+"."+e.versionName).toUpperCase()||i.versionIdentifier.name.toUpperCase()===(t+"."+e.versionName).toUpperCase()))throw new n("services:no-valid-version-name","No valid version name")}const a=await r.versionService.createVersion({versionName:e.versionName,access:o!==t?"public":e.access,description:e.description});if(o!==t){const{guid:i,name:n}=a.versionIdentifier;await r.versionService.alterVersion({guid:i,name:n},{ownerName:o,access:e.access})}e.switchToVersion&&await this._changeVersionInternal(i,a.versionIdentifier.name,a.versionIdentifier.guid),this.emit("version-created",{versionIdentifier:a.versionIdentifier,versionManagementService:r.versionService})})())}deleteVersion(e,i,r){return this._updatingHandles.addPromise((async()=>{const s=this._findServiceInfo(e);if(!s?.versionService)throw new n("services:no-version-management-service","No version management service");if(s.featureServiceVersion<=11.1)throw new n("services:versioning-api-error","Version management API too old");if(!s.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const t={name:i,guid:r};await s.versionService.deleteVersion(t)&&(await this._updateVersionInfo(s),this.emit("version-deleted",{versionIdentifier:t,versionManagementService:s.versionService}))})())}startEditing(e){return this._updatingHandles.addPromise((async()=>{const i=this._findServiceInfo(e);if(!i?.versionService)throw new n("services:no-version-management-service","No version management service");if(!i.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const r=i.versionInfo?.versionIdentifier??{name:i.versionService.defaultVersionIdentifier.name,guid:i.versionService.defaultVersionIdentifier.guid};let s=!0;("none"!==i.versionService.getLockType(r)||(s=await i.versionService.startReading(r),s))&&(s=await i.versionService.startEditing(r),i.updateLockType())})())}finishEditing(e,i){return this._updatingHandles.addPromise((async()=>{const r=this._findServiceInfo(e);if(!r?.versionService)throw new n("services:no-version-management-service","No version management service");if(!r.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const s=r.versionInfo?.versionIdentifier??{name:r.versionService.defaultVersionIdentifier.name,guid:r.versionService.defaultVersionIdentifier.guid},t=r.versionService.getLockType(s);if("none"!==t)return"read"===t?(await r.versionService.stopReading(s),void r.updateLockType()):"edit"===t?(await r.versionService.stopEditing(s,i),await r.versionService.stopReading(s),void r.updateLockType()):void 0})())}async _changeVersionInternal(e,i,r){const s=this._findServiceInfo(e);if(!s?.versionService)throw new n("services:no-version-management-service","No version management service");const t=s.versionInfo?.versionIdentifier??{name:s.versionService.defaultVersionIdentifier.name,guid:s.versionService.defaultVersionIdentifier.guid},o={name:i,guid:r};await s.versionService.changeVersion(this.view?.map,t,o)&&await this._updateVersionInfo(s)}async _updateVersionInfo(e){const i=e.versionService;if(!i)return;if(0===e.layersAndTables.length)return;const r=e.layersAndTables.getItemAt(0)?.gdbVersion,n=r?await i.getVersionIdentifierFromName(r):i.defaultVersionIdentifier;e.versionInfo=await i.getVersionInfoExtended(n)}_findServiceInfo(e){return this.items.find(i=>i.featureService.url===e)??null}_removeFeatureService(e){this.items.remove(e)}_reset(){this.additionalLayers.removeAll(),this._processed.clear(),this.tablesAndLayersLookup.clear(),this.items.removeAll()}async _findPortal(e){const r=i?.findServerInfo(e??"");if(!r?.owningSystemUrl)return null;const n=`${r.owningSystemUrl}/sharing/rest`,s=I.getDefault();if(s?.loaded&&u(s.restUrl)===u(n))return s;return new I({authMode:"immediate",url:r.owningSystemUrl}).load()}_updateVersionInfos(e){return this._updatingHandles.addPromise((async()=>{for(const i of e)await this._updateVersionInfo(i).catch(e=>{o.getLogger(this).error("Failed to update version details",e)})})())}async _addServiceInfo(e,i){const n=new L({url:e});await n.load();const s=await this._findPortal(e),t=s?.user?.username;let o=!1;t&&(o=await _(s,t,"advediting"));let a=null;if(n.versionManagementServiceUrl){a=new(0,(await import("../../versionManagement/VersionManagementService.js")).default)({url:n.versionManagementServiceUrl}),await a.load()}const d=i.isTable?[]:[i],c=i.isTable?[i]:[],v=new b({loggedInServiceUser:t??"",hasAdvancedEditingUserTypeExtension:o,versionInfo:null,lockType:"none",canEditVersionedData:!0,canCreateVersion:!0,featureService:n,versionService:a,layers:new r(d),tables:new r(c)});return a&&await this._updateVersionInfo(v),this.items.push(v),this.tablesAndLayersLookup.set(i,v),i.isTable?v.tables.push(i):v.layers.push(i),v}get _allLayersAndTables(){return[...this.view.map?.allLayers??[],...this.view.map?.allTables??[],...this.additionalLayers]}_detectNewLayersAndTables(){const e=new Set(this._allLayersAndTables),i=[];for(const r of e)"feature"!==r.type&&"subtype-group"!==r.type||this._processed.has(r)||i.push(r);for(const r of this._processed)if(!e.has(r)&&(y(r)||S(r))){const e=this.tablesAndLayersLookup.get(r);if(!e)continue;this.tablesAndLayersLookup.delete(r),r.isTable?e.tables.remove(r):e.layers.remove(r),0===e.layersAndTables.length&&this._removeFeatureService(e)}return this._processed=e,i}};e([f({constructOnly:!0})],T.prototype,"view",void 0),e([f()],T.prototype,"items",void 0),e([f()],T.prototype,"tablesAndLayersLookup",void 0),e([f()],T.prototype,"additionalLayers",void 0),e([f()],T.prototype,"updating",null),e([f()],T.prototype,"_allLayersAndTables",null),T=e([h("esri.undoredo.support.Services")],T);export{T as Services,U as getServices};
5
+ import{__decorate as e}from"tslib";import{id as i}from"../../kernel.js";import r from"../../core/Collection.js";import n from"../../core/Error.js";import{EventedAccessor as s}from"../../core/Evented.js";import{LoadableMixin as t}from"../../core/Loadable.js";import o from"../../core/Logger.js";import{getOrCreateMapValue as a}from"../../core/MapUtils.js";import d from"../../core/Promise.js";import{debounce as c,throwIfAborted as v}from"../../core/promiseUtils.js";import l from"../../core/ReactiveMap.js";import{whenOnce as p,watch as m}from"../../core/reactiveUtils.js";import{normalize as u}from"../../core/urlUtils.js";import{property as f}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as h}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as g}from"../../core/support/UpdatingHandles.js";import{parse as w}from"../../layers/support/arcgisLayerUrl.js";import{isSubtypeGroupLayer as y,isFeatureLayer as S}from"../../layers/support/layerUtils.js";import I from"../../portal/Portal.js";import{hasUserTypeExtension as _}from"../../portal/support/utils.js";import L from"../../rest/featureService/FeatureService.js";import{ServiceVersionInfo as b}from"./ServiceVersionInfo.js";function V(e){return!e||0===e.trim().length}const A=new Map;function U(e){return a(A,e,()=>{const i=new T({view:e});return e.addHandles({remove(){A.delete(e),i.destroy()}}),i.load().catch(e=>{o.getLogger("esri.views.Services").error("Failed to load service metadata",e)}),i})}let T=class extends(t(d.EsriPromiseMixin(s))){constructor(e){super(e),this._updatingHandles=new g,this.items=new r,this.tablesAndLayersLookup=new l,this.additionalLayers=new r,this._debouncedCheckAndUpdateServiceInfos=c(async()=>{const e=[];for(const i of this.items){if(0===i.layersAndTables.length)continue;const r=i.layersAndTables.getItemAt(0);r?.gdbVersion!==i.versionInfo?.versionIdentifier.name&&e.push(i)}0!==e.length&&(await p(()=>!this.updating),await this._updateVersionInfos(e))}),this._debouncedLayersChanged=c(async()=>{const e=this._detectNewLayersAndTables();0!==e.length&&(await p(()=>!this._updatingHandles.updating),await this._updatingHandles.addPromise((async()=>{const i=new Set;for(const n of e)if("feature"===n.type||"subtype-group"===n.type){if(!n.url)continue;const e=w(n.url).url.path,s=this._findServiceInfo(e);if(s)this.tablesAndLayersLookup.set(n,s),n.isTable?s.tables.push(n):s.layers.push(n);else if(!i.has(e))try{await this._addServiceInfo(e,n)}catch(r){o.getLogger(this).error(`Failed to load feature service: ${e}`,r)}finally{i.add(e)}}})()))}),this._processed=new Set}destroy(){this._set("view",null),this.items.removeAll(),this.tablesAndLayersLookup.clear()}async load(e){return v(e),this.addHandles([m(()=>this.view.map,()=>{this._reset()}),m(()=>this._allLayersAndTables,()=>{this._debouncedLayersChanged().catch(e=>{o.getLogger(this).warn("Failed to update service info",e)})}),m(()=>this.items.map(e=>e.layersAndTables.map(e=>e.gdbVersion??"").join(",")),()=>{this.checkAndUpdateServiceInfos().catch(e=>{o.getLogger(this).warn("Failed to update service info",e)})})]),this.addResolvingPromise(this._debouncedLayersChanged()),this}get updating(){return"loading"===this.loadStatus||this._updatingHandles.updating}checkAndUpdateServiceInfos(){return this._debouncedCheckAndUpdateServiceInfos()}changeVersion(e,i,r){return this._updatingHandles.addPromise((async()=>{await this._changeVersionInternal(e,i,r)})())}createVersion(e){return this._updatingHandles.addPromise((async()=>{const i=e.featureServerUrl,r=this._findServiceInfo(i);if(!r?.versionService)throw new n("services:no-version-management-service","No version management service");const s=r.hasAdvancedEditingUserTypeExtension,t=r.loggedInServiceUser.toUpperCase(),o=V(e.ownerName)?t:e.ownerName?.trim().toUpperCase();if(o!==t){if(r.featureServiceVersion<=11.1)throw new n("services:versioning-api-error","Version management API too old");if(!s)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service")}if("SDE"===o?.toUpperCase()&&"DEFAULT"===e.versionName.toUpperCase())throw new n("services:no-valid-version-name","No valid version name");{const i=await r.versionService.getVersionInfos();if(i?.find(i=>i.versionIdentifier.name.toUpperCase()===(o+"."+e.versionName).toUpperCase()||i.versionIdentifier.name.toUpperCase()===(t+"."+e.versionName).toUpperCase()))throw new n("services:no-valid-version-name","No valid version name")}const a=await r.versionService.createVersion({versionName:e.versionName,access:o!==t?"public":e.access,description:e.description});if(o!==t){const{guid:i,name:n}=a.versionIdentifier;await r.versionService.alterVersion({guid:i,name:n},{ownerName:o,access:e.access})}e.switchToVersion&&await this._changeVersionInternal(i,a.versionIdentifier.name,a.versionIdentifier.guid),this.emit("version-created",{versionIdentifier:a.versionIdentifier,versionManagementService:r.versionService})})())}deleteVersion(e,i,r){return this._updatingHandles.addPromise((async()=>{const s=this._findServiceInfo(e);if(!s?.versionService)throw new n("services:no-version-management-service","No version management service");if(s.featureServiceVersion<=11.1)throw new n("services:versioning-api-error","Version management API too old");if(!s.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const t={name:i,guid:r};await s.versionService.deleteVersion(t)&&(await this._updateVersionInfo(s),this.emit("version-deleted",{versionIdentifier:t,versionManagementService:s.versionService}))})())}startEditing(e){return this._updatingHandles.addPromise((async()=>{const i=this._findServiceInfo(e);if(!i?.versionService)throw new n("services:no-version-management-service","No version management service");if(!i.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const r=i.versionInfo?.versionIdentifier??{name:i.versionService.defaultVersionIdentifier.name,guid:i.versionService.defaultVersionIdentifier.guid};let s=!0;("none"!==i.versionService.getLockType(r)||(s=await i.versionService.startReading(r),s))&&(s=await i.versionService.startEditing(r),i.updateLockType())})())}finishEditing(e,i){return this._updatingHandles.addPromise((async()=>{const r=this._findServiceInfo(e);if(!r?.versionService)throw new n("services:no-version-management-service","No version management service");if(!r.hasAdvancedEditingUserTypeExtension)throw new n("services:no-advanced-editing-user-type-extension","No advanced editing extension on service");const s=r.versionInfo?.versionIdentifier??{name:r.versionService.defaultVersionIdentifier.name,guid:r.versionService.defaultVersionIdentifier.guid},t=r.versionService.getLockType(s);if("none"!==t)return"read"===t?(await r.versionService.stopReading(s),void r.updateLockType()):"edit"===t?(await r.versionService.stopEditing(s,i),await r.versionService.stopReading(s),void r.updateLockType()):void 0})())}async _changeVersionInternal(e,i,r){const s=this._findServiceInfo(e);if(!s?.versionService)throw new n("services:no-version-management-service","No version management service");const t=s.versionInfo?.versionIdentifier??{name:s.versionService.defaultVersionIdentifier.name,guid:s.versionService.defaultVersionIdentifier.guid},o={name:i,guid:r};await s.versionService.changeVersion(this.view?.map,t,o)&&await this._updateVersionInfo(s)}async _updateVersionInfo(e){const i=e.versionService;if(!i)return;if(0===e.layersAndTables.length)return;const r=e.layersAndTables.getItemAt(0)?.gdbVersion,n=r?await i.getVersionIdentifierFromName(r):i.defaultVersionIdentifier;e.versionInfo=await i.getVersionInfoExtended(n)}_findServiceInfo(e){return this.items.find(i=>i.featureService.url===e)??null}_removeFeatureService(e){this.items.remove(e)}_reset(){this.additionalLayers.removeAll(),this._processed.clear(),this.tablesAndLayersLookup.clear(),this.items.removeAll()}async _findPortal(e){const r=i?.findServerInfo(e??"");if(!r?.owningSystemUrl)return null;const n=`${r.owningSystemUrl}/sharing/rest`,s=I.getDefault();if(s?.loaded&&u(s.restUrl)===u(n))return s;return new I({authMode:"immediate",url:r.owningSystemUrl}).load()}_updateVersionInfos(e){return this._updatingHandles.addPromise((async()=>{for(const i of e)await this._updateVersionInfo(i).catch(e=>{o.getLogger(this).error("Failed to update version details",e)})})())}async _addServiceInfo(e,i){const n=new L({url:e});await n.load();const s=await this._findPortal(e),t=s?.user?.username;let o=!1;t&&(o=await _(s,t,"advediting"));let a=null;if(n.versionManagementServiceUrl){a=new(0,(await import("../../versionManagement/VersionManagementService.js")).default)({url:n.versionManagementServiceUrl}),await a.load()}const d=i.isTable?[]:[i],c=i.isTable?[i]:[],v=new b({loggedInServiceUser:t??"",hasAdvancedEditingUserTypeExtension:o,versionInfo:null,lockType:"none",canEditVersionedData:!0,canCreateVersion:!0,featureService:n,versionService:a,layers:new r(d),tables:new r(c)});return a&&await this._updateVersionInfo(v),this.items.push(v),this.tablesAndLayersLookup.set(i,v),i.isTable?v.tables.push(i):v.layers.push(i),v}get _allLayersAndTables(){return[...this.view.map?.allLayers??[],...this.view.map?.allTables??[],...this.additionalLayers]}_detectNewLayersAndTables(){const e=new Set(this._allLayersAndTables),i=[];for(const r of e)"feature"!==r.type&&"subtype-group"!==r.type||this._processed.has(r)||i.push(r);for(const r of this._processed)if(!e.has(r)&&(y(r)||S(r))){const e=this.tablesAndLayersLookup.get(r);if(!e)continue;this.tablesAndLayersLookup.delete(r),r.isTable?e.tables.remove(r):e.layers.remove(r),0===e.layersAndTables.length&&this._removeFeatureService(e)}return this._processed=e,i}};e([f({constructOnly:!0})],T.prototype,"view",void 0),e([f()],T.prototype,"items",void 0),e([f()],T.prototype,"tablesAndLayersLookup",void 0),e([f()],T.prototype,"additionalLayers",void 0),e([f()],T.prototype,"updating",null),e([f()],T.prototype,"_allLayersAndTables",null),T=e([h("esri.undoredo.support.Services")],T);export{T as Services,U as getServices};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import t from"../request.js";import r from"../core/Error.js";import s from"../core/JSONSupport.js";import i from"../core/Loadable.js";import{removeTrailingSlash as n,Url as o}from"../core/urlUtils.js";import{property as a}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{reader as u}from"../core/accessorSupport/decorators/reader.js";import{subclass as l}from"../core/accessorSupport/decorators/subclass.js";import{writer as c}from"../core/accessorSupport/decorators/writer.js";import{onApplyEditsEvent as d,emitUpdateMomentEvent as m}from"../layers/mixins/EditBusLayer.js";import{parseUrl as f}from"../rest/utils.js";import g from"./support/EditMomentStack.js";import{versionCollection as p,versionCollectionCount as h,defaultVersionNameLookup as V,currentSessionId as v}from"./support/versionManagementUtils.js";import{createVersionAdapters as y}from"./versionAdapters/utils.js";let w=class extends(s.JSONSupportMixin(i)){constructor(e){super(e),this.url=null,this.sourceJSON=null,this.name=null,this.defaultVersionIdentifier=null,this.capabilities=null,this._isDefault=e=>!e||e===this.defaultVersionIdentifier.name,this._dateEquals=(e,t)=>!e&&!t||!(!e||!t)&&e.toISOString()===t.toISOString(),this._applyEditsHandler=e=>{const{serviceUrl:t,gdbVersion:r,result:s}=e;t===this._featureServiceUrl&&s.then(e=>{const t=e.historicMoment;t&&this._addMomentToVersionItem(r,t)})}}initialize(){this.url=n(this.url),this._featureServiceUrl=this.url.replace(/\/VersionManagementServer/i,"/FeatureServer"),p.has(this.url)||p.set(this.url,new Map);const e=(h.get(this.url)??0)+1;h.set(this.url,e),this.when().then(()=>this.addHandles(d(this._applyEditsHandler)),()=>{})}destroy(){const e=(h.get(this.url)??1)-1;h.set(this.url,e),0===e&&p.delete(this.url),V.delete(this._featureServiceUrl)}read(e,t){this.sourceJSON=e,super.read(e,t)}readDefaultVersionIdentifier(e,t){return{name:t.defaultVersionName,guid:t.defaultVersionGuid}}writeDefaultVersionIdentifier(e,t){t.defaultVersionName=e.name,t.defaultVersionGuid=e.guid}load(e){return this.addResolvingPromise(this._fetchService(this.url,e)),Promise.resolve(this)}async createVersion(e){const[{createVersion:t},{default:r}]=await Promise.all([import("../rest/versionManagement/createVersion.js"),import("../rest/versionManagement/support/CreateVersionParameters.js")]),s=r.from(e);return t(this.url,s)}async deleteVersion(e){const[{deleteVersion:t},{default:r}]=await Promise.all([import("../rest/versionManagement/deleteVersion.js"),import("../rest/versionManagement/support/DeleteVersionParameters.js")]);let s;e.guid&&p.get(this.url)?.has(e.guid)&&(s=v??void 0);const i=new r({versionName:e.name,sessionId:s});return t(this.url,i)}async getVersionInfoExtended(e){const{getVersion:t}=await import("../rest/versionManagement/getVersion.js");return t(this.url,e.guid)}async getVersionInfos(e={}){const[{getVersionInfos:t},{default:r}]=await Promise.all([import("../rest/versionManagement/getVersionInfos.js"),import("../rest/versionManagement/support/GetVersionInfosParameters.js")]),s=r.from(e);return t(this.url,s)}async reconcile(e,t={}){const[{reconcile:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/reconcile.js"),import("../rest/versionManagement/gdbVersion/support/ReconcileParameters.js")]),i=s.from(t);return i.sessionId=v,r(this.url,e.guid,i)}async post(e){const[{post:t},{default:r}]=await Promise.all([import("../rest/versionManagement/gdbVersion/post.js"),import("../rest/versionManagement/gdbVersion/support/PostParameters.js")]),s=r.from({sessionId:v});return t(this.url,e.guid,s)}async alterVersion(e,t){const[{alterVersion:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/alterVersion.js"),import("../rest/versionManagement/gdbVersion/support/AlterVersionParameters.js")]),i=s.from(t);return r(this.url,e.guid,i)}async startReading(e){return(await this.startReadingWithResult(e)).success}async startReadingWithResult(e){const{startReading:t}=await import("../rest/versionManagement/gdbVersion/startReading.js"),r=await t(this.url,e.guid,v);if(r.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate),s={name:t.versionIdentifier.name,moment:r,lockType:"read"};this._addOrUpdateItem(e.guid,s),m(this._featureServiceUrl,null,e.name,r)}return r}async stopReading(e){return(await this.stopReadingWithResult(e)).success}async stopReadingWithResult(e){const{stopReading:t}=await import("../rest/versionManagement/gdbVersion/stopReading.js"),r=await t(this.url,e.guid,v);return r.success&&(p.get(this.url)?.delete(e.guid),m(this._featureServiceUrl,null,e.name,null)),r}async startEditing(e){return(await this.startEditingWithResult(e)).success}async startEditingWithResult(e){const{startEditing:t}=await import("../rest/versionManagement/gdbVersion/startEditing.js"),r=await t(this.url,e.guid,v);if(r.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate),s=new g(r),i={name:e.name,moment:r,lockType:"edit",stack:s};this._addOrUpdateItem(e.guid,i),m(this._featureServiceUrl,null,e.name,r)}return r}async stopEditing(e,t){return(await this.stopEditingWithResult(e,t)).success}async stopEditingWithResult(e,t){if(t){const t=p.get(this.url)?.get(e.guid);if(t?.stack?.canRedo()){const[{deleteForwardEdits:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/deleteForwardEdits.js"),import("../rest/versionManagement/gdbVersion/support/DeleteForwardEditsParameters.js")]),i=await r(this.url,e.guid,new s({sessionId:v,moment:t.moment}));if(!i.success)return i}}const{stopEditing:r}=await import("../rest/versionManagement/gdbVersion/stopEditing.js"),s=await r(this.url,e.guid,v,t);if(s.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate);this._addOrUpdateItem(e.guid,{name:e.name,moment:r,lockType:"read",editMomentStack:void 0}),m(this._featureServiceUrl,null,e.name,r)}return s}getLockType(e){const t=p.get(this.url)?.get(e.guid)?.lockType;return t??"none"}async changeVersion(e,t,s){if(s&&"name"in s&&!await this.getVersionInfoExtended(s))throw new r("version-management-service:invalid-version","version does not exist");if("networkServiceUrl"in e){if(this._featureServiceUrl.toLowerCase()===e.featureServiceUrl.toLowerCase())return this._changeVersionInternal(e,t,s)}else{let r;"layers"in e?(r=e.allTables.concat(e.allLayers),e.utilityNetworks&&e.utilityNetworks.forEach(e=>{this._featureServiceUrl.toLowerCase()===e.featureServiceUrl.toLowerCase()&&this._changeVersionInternal(e,t,s)})):r=e;for(const e of r)if("feature"===e.type||"subtype-group"===e.type){const r=/^(.*\/FeatureServer)\/\d+$/,i=e.url.replace(r,"$1");if(this._featureServiceUrl.toLowerCase()===i.toLowerCase()&&!this._changeVersionInternal(e,t,s))return!1}else if("group"===e.type){const r=e.allTables.concat(e.allLayers);for(const e of r)if("feature"===e.type||"subtype-group"===e.type){const r=/^(.*\/FeatureServer)\/\d+$/,i=e.url.replace(r,"$1");if(this._featureServiceUrl.toLowerCase()===i.toLowerCase()&&!this._changeVersionInternal(e,t,s))return!1}}}return!0}async changeVersionWithResult(e,t,r){let s;if("layers"in e){const t=y(e.allTables.concat(e.allLayers).filter(e=>"group"!==e.type).toArray());e.utilityNetworks&&e.utilityNetworks.forEach(e=>{const r=y([e]);t.push(...r)}),s=t}else s=e;if(r&&"name"in r){if(!await this.getVersionInfoExtended(r)){const e=new Map;for(const t of s)e.set(t,{success:!1});return e}}if(t&&"name"in t){if("none"!==this.getLockType(t)){const e=new Map;for(const t of s)e.set(t,{success:!1});return e}}const i=new Map;for(const n of s)if(n)if(n.featureServiceUrl.toLowerCase()===this._featureServiceUrl.toLowerCase()){const e=this._changeVersionInternalWithResult(n,t,r);i.set(n,e)}else i.set(n,{success:!1});return i}async getVersionIdentifierFromName(e){try{const t=await this.getVersionInfos({includeHidden:!0});return t.find(t=>t.versionIdentifier.name.toUpperCase()===e.toUpperCase())?.versionIdentifier||null}catch{return null}}async getVersionIdentifierFromGuid(e){const{getVersion:t}=await import("../rest/versionManagement/getVersion.js");try{return(await t(this.url,e)).versionIdentifier}catch{return null}}canUndo(e){const t=p.get(this.url)?.get(e.guid);return!!t?.stack?.canUndo()}canRedo(e){const t=p.get(this.url)?.get(e.guid);return!!t?.stack?.canRedo()}undo(e){const t=p.get(this.url)?.get(e.guid),r=t?.stack?.undo()||void 0;if(t&&r){const r=t.stack.peek();m(this._featureServiceUrl,null,e.name,r),p.get(this.url)?.set(e.guid,{...t,moment:r})}}redo(e){const t=p.get(this.url)?.get(e.guid),r=t?.stack?.redo()||void 0;t&&r&&(m(this._featureServiceUrl,null,e.name,r),p.get(this.url)?.set(e.guid,{...t,moment:r}))}_setUpData(e,t){let s=null,i=null,n=null,o=null;const a=e=>{const t=p?.get(this.url)?.get(e.guid);n=e.name,o=t?.moment??null};if(e&&"name"in e){if("none"!==this.getLockType(e))throw new r("version-management-service:version-locked","version is locked");s=e.name,i=null,t&&"name"in t?a(t):(n=this.defaultVersionIdentifier.name,o=t)}else s=this.defaultVersionIdentifier.name,i=e,t&&"name"in t?a(t):(n=this.defaultVersionIdentifier.name,o=t);return{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}}_changeVersionInternal(e,t,r){try{const{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}=this._setUpData(t,r);(this._isDefault(s)&&this._isDefault(e.gdbVersion)&&this._dateEquals(e.historicMoment,i)||s===e.gdbVersion&&this._dateEquals(e.historicMoment,i))&&(e.gdbVersion=n,e.historicMoment=o)}catch(s){return!1}return!0}_changeVersionInternalWithResult(e,t,r){try{const{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}=this._setUpData(t,r);return this._isDefault(s)&&this._isDefault(e.gdbVersion)&&this._dateEquals(e.historicMoment,i)||s===e.gdbVersion&&this._dateEquals(e.historicMoment,i)?(e.gdbVersion=n,e.historicMoment=o,{success:!0}):{success:!1}}catch(s){return{success:!1}}}_addMomentToVersionItem(e,t){const r=p.get(this.url);if(r)for(const[s,i]of r){i.name===e&&this._addToStack(s,t)}}_addToStack(e,t){const r=p.get(this.url),s=r?.get(e);return!!s?.stack&&(S(s.stack.peek(),t)&&s.stack.push(t),r.set(e,{...s,moment:t}),!0)}_addOrUpdateItem(e,t){const r=p.get(this.url),s=r?.get(e);return s?(r.set(e,{...s,...t}),!0):!(!t.name||!t.lockType)&&(r?.set(e,{...t,lockType:t.lockType}),!0)}async _fetchService(e,r){if(this.sourceJSON){this.read(this.sourceJSON,{origin:"service",url:f(e)});const t=new o(this.url).host;return void V.set(t,this.defaultVersionIdentifier.name)}const s=await t(e,{responseType:"json",query:{f:"json"},...r});this.read(s.data)}};function S(e,t){if(e){return e.getTime()<t.getTime()}return!0}e([a()],w.prototype,"url",void 0),e([a()],w.prototype,"sourceJSON",void 0),e([a({type:String,json:{write:!0}})],w.prototype,"name",void 0),e([a({json:{write:{target:{defaultVersionName:{type:String},defaultVersionGuid:{type:String}}},read:{source:["defaultVersionName","defaultVersionGuid"]}}})],w.prototype,"defaultVersionIdentifier",void 0),e([u("defaultVersionIdentifier",["defaultVersionName","defaultVersionGuid"])],w.prototype,"readDefaultVersionIdentifier",null),e([c("defaultVersionIdentifier",{defaultVersionName:{type:String},defaultVersionGuid:{type:String}})],w.prototype,"writeDefaultVersionIdentifier",null),e([a({json:{write:!0}})],w.prototype,"capabilities",void 0),w=e([l("esri.versionManagement.VersionManagementService")],w);const I=w;export{I as default};
5
+ import{__decorate as e}from"tslib";import t from"../request.js";import r from"../core/Error.js";import s from"../core/JSONSupport.js";import{Loadable as i}from"../core/Loadable.js";import{removeTrailingSlash as n,Url as o}from"../core/urlUtils.js";import{property as a}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{reader as u}from"../core/accessorSupport/decorators/reader.js";import{subclass as l}from"../core/accessorSupport/decorators/subclass.js";import{writer as c}from"../core/accessorSupport/decorators/writer.js";import{onApplyEditsEvent as d,emitUpdateMomentEvent as m}from"../layers/mixins/EditBusLayer.js";import{parseUrl as f}from"../rest/utils.js";import g from"./support/EditMomentStack.js";import{versionCollection as p,versionCollectionCount as h,defaultVersionNameLookup as V,currentSessionId as v}from"./support/versionManagementUtils.js";import{createVersionAdapters as y}from"./versionAdapters/utils.js";let w=class extends(s.JSONSupportMixin(i)){constructor(e){super(e),this.url=null,this.sourceJSON=null,this.name=null,this.defaultVersionIdentifier=null,this.capabilities=null,this._isDefault=e=>!e||e===this.defaultVersionIdentifier.name,this._dateEquals=(e,t)=>!e&&!t||!(!e||!t)&&e.toISOString()===t.toISOString(),this._applyEditsHandler=e=>{const{serviceUrl:t,gdbVersion:r,result:s}=e;t===this._featureServiceUrl&&s.then(e=>{const t=e.historicMoment;t&&this._addMomentToVersionItem(r,t)})}}initialize(){this.url=n(this.url),this._featureServiceUrl=this.url.replace(/\/VersionManagementServer/i,"/FeatureServer"),p.has(this.url)||p.set(this.url,new Map);const e=(h.get(this.url)??0)+1;h.set(this.url,e),this.when().then(()=>this.addHandles(d(this._applyEditsHandler)),()=>{})}destroy(){const e=(h.get(this.url)??1)-1;h.set(this.url,e),0===e&&p.delete(this.url),V.delete(this._featureServiceUrl)}read(e,t){this.sourceJSON=e,super.read(e,t)}readDefaultVersionIdentifier(e,t){return{name:t.defaultVersionName,guid:t.defaultVersionGuid}}writeDefaultVersionIdentifier(e,t){t.defaultVersionName=e.name,t.defaultVersionGuid=e.guid}load(e){return this.addResolvingPromise(this._fetchService(this.url,e)),Promise.resolve(this)}async createVersion(e){const[{createVersion:t},{default:r}]=await Promise.all([import("../rest/versionManagement/createVersion.js"),import("../rest/versionManagement/support/CreateVersionParameters.js")]),s=r.from(e);return t(this.url,s)}async deleteVersion(e){const[{deleteVersion:t},{default:r}]=await Promise.all([import("../rest/versionManagement/deleteVersion.js"),import("../rest/versionManagement/support/DeleteVersionParameters.js")]);let s;e.guid&&p.get(this.url)?.has(e.guid)&&(s=v??void 0);const i=new r({versionName:e.name,sessionId:s});return t(this.url,i)}async getVersionInfoExtended(e){const{getVersion:t}=await import("../rest/versionManagement/getVersion.js");return t(this.url,e.guid)}async getVersionInfos(e={}){const[{getVersionInfos:t},{default:r}]=await Promise.all([import("../rest/versionManagement/getVersionInfos.js"),import("../rest/versionManagement/support/GetVersionInfosParameters.js")]),s=r.from(e);return t(this.url,s)}async reconcile(e,t={}){const[{reconcile:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/reconcile.js"),import("../rest/versionManagement/gdbVersion/support/ReconcileParameters.js")]),i=s.from(t);return i.sessionId=v,r(this.url,e.guid,i)}async post(e){const[{post:t},{default:r}]=await Promise.all([import("../rest/versionManagement/gdbVersion/post.js"),import("../rest/versionManagement/gdbVersion/support/PostParameters.js")]),s=r.from({sessionId:v});return t(this.url,e.guid,s)}async alterVersion(e,t){const[{alterVersion:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/alterVersion.js"),import("../rest/versionManagement/gdbVersion/support/AlterVersionParameters.js")]),i=s.from(t);return r(this.url,e.guid,i)}async startReading(e){return(await this.startReadingWithResult(e)).success}async startReadingWithResult(e){const{startReading:t}=await import("../rest/versionManagement/gdbVersion/startReading.js"),r=await t(this.url,e.guid,v);if(r.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate),s={name:t.versionIdentifier.name,moment:r,lockType:"read"};this._addOrUpdateItem(e.guid,s),m(this._featureServiceUrl,null,e.name,r)}return r}async stopReading(e){return(await this.stopReadingWithResult(e)).success}async stopReadingWithResult(e){const{stopReading:t}=await import("../rest/versionManagement/gdbVersion/stopReading.js"),r=await t(this.url,e.guid,v);return r.success&&(p.get(this.url)?.delete(e.guid),m(this._featureServiceUrl,null,e.name,null)),r}async startEditing(e){return(await this.startEditingWithResult(e)).success}async startEditingWithResult(e){const{startEditing:t}=await import("../rest/versionManagement/gdbVersion/startEditing.js"),r=await t(this.url,e.guid,v);if(r.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate),s=new g(r),i={name:e.name,moment:r,lockType:"edit",stack:s};this._addOrUpdateItem(e.guid,i),m(this._featureServiceUrl,null,e.name,r)}return r}async stopEditing(e,t){return(await this.stopEditingWithResult(e,t)).success}async stopEditingWithResult(e,t){if(t){const t=p.get(this.url)?.get(e.guid);if(t?.stack?.canRedo()){const[{deleteForwardEdits:r},{default:s}]=await Promise.all([import("../rest/versionManagement/gdbVersion/deleteForwardEdits.js"),import("../rest/versionManagement/gdbVersion/support/DeleteForwardEditsParameters.js")]),i=await r(this.url,e.guid,new s({sessionId:v,moment:t.moment}));if(!i.success)return i}}const{stopEditing:r}=await import("../rest/versionManagement/gdbVersion/stopEditing.js"),s=await r(this.url,e.guid,v,t);if(s.success){const t=await this.getVersionInfoExtended(e),r=new Date(t.modifiedDate);this._addOrUpdateItem(e.guid,{name:e.name,moment:r,lockType:"read",editMomentStack:void 0}),m(this._featureServiceUrl,null,e.name,r)}return s}getLockType(e){const t=p.get(this.url)?.get(e.guid)?.lockType;return t??"none"}async changeVersion(e,t,s){if(s&&"name"in s&&!await this.getVersionInfoExtended(s))throw new r("version-management-service:invalid-version","version does not exist");if("networkServiceUrl"in e){if(this._featureServiceUrl.toLowerCase()===e.featureServiceUrl.toLowerCase())return this._changeVersionInternal(e,t,s)}else{let r;"layers"in e?(r=e.allTables.concat(e.allLayers),e.utilityNetworks&&e.utilityNetworks.forEach(e=>{this._featureServiceUrl.toLowerCase()===e.featureServiceUrl.toLowerCase()&&this._changeVersionInternal(e,t,s)})):r=e;for(const e of r)if("feature"===e.type||"subtype-group"===e.type){const r=/^(.*\/FeatureServer)\/\d+$/,i=e.url.replace(r,"$1");if(this._featureServiceUrl.toLowerCase()===i.toLowerCase()&&!this._changeVersionInternal(e,t,s))return!1}else if("group"===e.type){const r=e.allTables.concat(e.allLayers);for(const e of r)if("feature"===e.type||"subtype-group"===e.type){const r=/^(.*\/FeatureServer)\/\d+$/,i=e.url.replace(r,"$1");if(this._featureServiceUrl.toLowerCase()===i.toLowerCase()&&!this._changeVersionInternal(e,t,s))return!1}}}return!0}async changeVersionWithResult(e,t,r){let s;if("layers"in e){const t=y(e.allTables.concat(e.allLayers).filter(e=>"group"!==e.type).toArray());e.utilityNetworks&&e.utilityNetworks.forEach(e=>{const r=y([e]);t.push(...r)}),s=t}else s=e;if(r&&"name"in r){if(!await this.getVersionInfoExtended(r)){const e=new Map;for(const t of s)e.set(t,{success:!1});return e}}if(t&&"name"in t){if("none"!==this.getLockType(t)){const e=new Map;for(const t of s)e.set(t,{success:!1});return e}}const i=new Map;for(const n of s)if(n)if(n.featureServiceUrl.toLowerCase()===this._featureServiceUrl.toLowerCase()){const e=this._changeVersionInternalWithResult(n,t,r);i.set(n,e)}else i.set(n,{success:!1});return i}async getVersionIdentifierFromName(e){try{const t=await this.getVersionInfos({includeHidden:!0});return t.find(t=>t.versionIdentifier.name.toUpperCase()===e.toUpperCase())?.versionIdentifier||null}catch{return null}}async getVersionIdentifierFromGuid(e){const{getVersion:t}=await import("../rest/versionManagement/getVersion.js");try{return(await t(this.url,e)).versionIdentifier}catch{return null}}canUndo(e){const t=p.get(this.url)?.get(e.guid);return!!t?.stack?.canUndo()}canRedo(e){const t=p.get(this.url)?.get(e.guid);return!!t?.stack?.canRedo()}undo(e){const t=p.get(this.url)?.get(e.guid),r=t?.stack?.undo()||void 0;if(t&&r){const r=t.stack.peek();m(this._featureServiceUrl,null,e.name,r),p.get(this.url)?.set(e.guid,{...t,moment:r})}}redo(e){const t=p.get(this.url)?.get(e.guid),r=t?.stack?.redo()||void 0;t&&r&&(m(this._featureServiceUrl,null,e.name,r),p.get(this.url)?.set(e.guid,{...t,moment:r}))}_setUpData(e,t){let s=null,i=null,n=null,o=null;const a=e=>{const t=p?.get(this.url)?.get(e.guid);n=e.name,o=t?.moment??null};if(e&&"name"in e){if("none"!==this.getLockType(e))throw new r("version-management-service:version-locked","version is locked");s=e.name,i=null,t&&"name"in t?a(t):(n=this.defaultVersionIdentifier.name,o=t)}else s=this.defaultVersionIdentifier.name,i=e,t&&"name"in t?a(t):(n=this.defaultVersionIdentifier.name,o=t);return{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}}_changeVersionInternal(e,t,r){try{const{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}=this._setUpData(t,r);(this._isDefault(s)&&this._isDefault(e.gdbVersion)&&this._dateEquals(e.historicMoment,i)||s===e.gdbVersion&&this._dateEquals(e.historicMoment,i))&&(e.gdbVersion=n,e.historicMoment=o)}catch(s){return!1}return!0}_changeVersionInternalWithResult(e,t,r){try{const{fromVersionName:s,fromMoment:i,toVersionName:n,toMoment:o}=this._setUpData(t,r);return this._isDefault(s)&&this._isDefault(e.gdbVersion)&&this._dateEquals(e.historicMoment,i)||s===e.gdbVersion&&this._dateEquals(e.historicMoment,i)?(e.gdbVersion=n,e.historicMoment=o,{success:!0}):{success:!1}}catch(s){return{success:!1}}}_addMomentToVersionItem(e,t){const r=p.get(this.url);if(r)for(const[s,i]of r){i.name===e&&this._addToStack(s,t)}}_addToStack(e,t){const r=p.get(this.url),s=r?.get(e);return!!s?.stack&&(S(s.stack.peek(),t)&&s.stack.push(t),r.set(e,{...s,moment:t}),!0)}_addOrUpdateItem(e,t){const r=p.get(this.url),s=r?.get(e);return s?(r.set(e,{...s,...t}),!0):!(!t.name||!t.lockType)&&(r?.set(e,{...t,lockType:t.lockType}),!0)}async _fetchService(e,r){if(this.sourceJSON){this.read(this.sourceJSON,{origin:"service",url:f(e)});const t=new o(this.url).host;return void V.set(t,this.defaultVersionIdentifier.name)}const s=await t(e,{responseType:"json",query:{f:"json"},...r});this.read(s.data)}};function S(e,t){if(e){return e.getTime()<t.getTime()}return!0}e([a()],w.prototype,"url",void 0),e([a()],w.prototype,"sourceJSON",void 0),e([a({type:String,json:{write:!0}})],w.prototype,"name",void 0),e([a({json:{write:{target:{defaultVersionName:{type:String},defaultVersionGuid:{type:String}}},read:{source:["defaultVersionName","defaultVersionGuid"]}}})],w.prototype,"defaultVersionIdentifier",void 0),e([u("defaultVersionIdentifier",["defaultVersionName","defaultVersionGuid"])],w.prototype,"readDefaultVersionIdentifier",null),e([c("defaultVersionIdentifier",{defaultVersionName:{type:String},defaultVersionGuid:{type:String}})],w.prototype,"writeDefaultVersionIdentifier",null),e([a({json:{write:!0}})],w.prototype,"capabilities",void 0),w=e([l("esri.versionManagement.VersionManagementService")],w);const I=w;export{I 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import t from"../core/Collection.js";import r from"../core/Error.js";import s from"../core/JSONSupport.js";import i from"../core/Loadable.js";import n from"../core/Logger.js";import{property as o}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/RandomLCG.js";import{subclass as a}from"../core/accessorSupport/decorators/subclass.js";let c=class extends(s.JSONSupportMixin(i)){constructor(e){super(e),this.versionManagementService=null,this.featureServiceUrl=null,this.url=null,this.currentVersion=null,this.currentVersionInfo=null,this.versionInfos=[],this.versionableItems=new t,this.usePersistentReadSessions=!1,this.state="lock-none"}initialize(){this.url=this.versionManagementService.url,this.featureServiceUrl=this.url.replace(/\/VersionManagementServer/i,"/FeatureServer"),this.addHandles([this.versionableItems.on("before-add",e=>{if(e.item.featureServiceUrl.toLowerCase()!==this.featureServiceUrl.toLowerCase())return e.preventDefault(),void n.getLogger(this).error("#add()","Cannot add versionAdapter, feature service urls do not match.")}),this.versionableItems.on("before-remove",e=>{if(0===this.versionableItems.items.length&&this.currentVersion&&"name"in this.currentVersion&&"none"!==this.versionManagementService.getLockType(this.currentVersion))return e.preventDefault(),void n.getLogger(this).error("#remove()","Cannot remove last versionAdapter.")})])}load(e){return this.addResolvingPromise(this._setUpState(e)),Promise.resolve(this)}get defaultVersionIdentifier(){return this.versionManagementService.defaultVersionIdentifier}get isDefault(){return!this.currentVersion||!!this.currentVersion&&"name"in this.currentVersion&&this.currentVersion.name===this.defaultVersionIdentifier.name}async getVersionInfos(e=!1){return e&&(this.versionInfos=await this.versionManagementService.getVersionInfos()),this.versionInfos}async alterVersion(e,t){if(this.currentVersion&&"guid"in this.currentVersion&&e.guid===this.currentVersion.guid)return!1;const r=await this.versionManagementService.alterVersion(e,t);return r&&await this.getVersionInfos(!0),r}async deleteVersion(e){if(this.currentVersion&&"guid"in this.currentVersion&&e.guid===this.currentVersion.guid)return!1;const t=await this.versionManagementService.deleteVersion(e);return t&&await this.getVersionInfos(!0),t}async getVersionInfoExtended(){return this.currentVersion&&"name"in this.currentVersion?this.versionManagementService.getVersionInfoExtended(this.currentVersion):this.versionManagementService.getVersionInfoExtended(this.defaultVersionIdentifier)}async startEditing(){if(this._isDefaultOrHistoricVersion())return{success:!1};if(!this.usePersistentReadSessions){const e=await this.versionManagementService.startReadingWithResult(this.currentVersion);if(!e.success)return e;this.state="lock-read"}const e=await this.versionManagementService.startEditingWithResult(this.currentVersion);return e.success&&(this.state="lock-write"),e}async stopEditing(e){if(this._isDefaultOrHistoricVersion())return{success:!1};const t=await this.versionManagementService.stopEditingWithResult(this.currentVersion,e);if(!t.success)return t;if(this.state="lock-read",!this.usePersistentReadSessions){const e=await this.versionManagementService.stopReadingWithResult(this.currentVersion);return e.success&&(this.state="lock-none"),e}return t}async changeVersion(e){let t=null;if(this.usePersistentReadSessions){if(this._isDefaultOrHistoricVersion(e))e&&"name"in e?(t=await this.versionManagementService.getVersionInfoExtended(e),this.state="public"===t?.access?"lock-none":"lock-read"):this.state="lock-read";else if(!await this.versionManagementService.startReading(e))throw new r("versioning:failed-lock","Failed to acquire read lock for version: "+e);this._isDefaultOrHistoricVersion(this.currentVersion)||await this.versionManagementService.stopReading(this.currentVersion)}const s=await this.versionManagementService.changeVersionWithResult(this.versionableItems,this.currentVersion,e);let i=!1;return s.forEach((e,t)=>{i=i||e.success}),i&&(this.currentVersion=e,this.currentVersionInfo=t||await this.getVersionInfoExtended(),this._isDefaultOrHistoricVersion()?this.currentVersion&&"name"in this.currentVersion?this.state="public"===this.currentVersionInfo?.access?"lock-none":"lock-read":this.state="lock-read":this.state="read"!==this.versionManagementService.getLockType(this.currentVersion)?"lock-none":"lock-read"),s}async undo(){return this._isDefaultOrHistoricVersion()?{success:!1}:(this.versionManagementService.undo(this.currentVersion),{success:!0})}async redo(){return this._isDefaultOrHistoricVersion()?{success:!1}:(this.versionManagementService.redo(this.currentVersion),{success:!0})}async _setUpState(e){await this.versionManagementService.load(e),this.state="lock-none",this.currentVersionInfo=await this.getVersionInfoExtended(),this.versionableItems.forEach(e=>{this.currentVersion?"name"in this.currentVersion?(e.gdbVersion=this.currentVersion.name,e.historicMoment=null):(e.historicMoment=this.currentVersion,e.gdbVersion=null):(e.gdbVersion=null,e.historicMoment=null)}),this.usePersistentReadSessions&&(this._isDefaultOrHistoricVersion()?this.currentVersion&&"name"in this.currentVersion?this.state="public"===this.currentVersionInfo?.access?"lock-none":"lock-read":this.state="lock-read":await this.versionManagementService.startReading(this.currentVersion)&&(this.state="lock-read"))}_isDefaultOrHistoricVersion(e=this.currentVersion){return!(e&&"name"in e)||e.name===this.versionManagementService.defaultVersionIdentifier.name}};e([o()],c.prototype,"versionManagementService",void 0),e([o()],c.prototype,"featureServiceUrl",void 0),e([o()],c.prototype,"url",void 0),e([o()],c.prototype,"currentVersion",void 0),e([o()],c.prototype,"currentVersionInfo",void 0),e([o()],c.prototype,"versionInfos",void 0),e([o()],c.prototype,"versionableItems",void 0),e([o()],c.prototype,"usePersistentReadSessions",void 0),e([o()],c.prototype,"state",void 0),e([o({readOnly:!0})],c.prototype,"defaultVersionIdentifier",null),e([o({readOnly:!0})],c.prototype,"isDefault",null),c=e([a("esri.versionManagement.VersioningState")],c);const u=c;export{u as default};
5
+ import{__decorate as e}from"tslib";import t from"../core/Collection.js";import r from"../core/Error.js";import s from"../core/JSONSupport.js";import{Loadable as i}from"../core/Loadable.js";import n from"../core/Logger.js";import{property as o}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/RandomLCG.js";import{subclass as a}from"../core/accessorSupport/decorators/subclass.js";let c=class extends(s.JSONSupportMixin(i)){constructor(e){super(e),this.versionManagementService=null,this.featureServiceUrl=null,this.url=null,this.currentVersion=null,this.currentVersionInfo=null,this.versionInfos=[],this.versionableItems=new t,this.usePersistentReadSessions=!1,this.state="lock-none"}initialize(){this.url=this.versionManagementService.url,this.featureServiceUrl=this.url.replace(/\/VersionManagementServer/i,"/FeatureServer"),this.addHandles([this.versionableItems.on("before-add",e=>{if(e.item.featureServiceUrl.toLowerCase()!==this.featureServiceUrl.toLowerCase())return e.preventDefault(),void n.getLogger(this).error("#add()","Cannot add versionAdapter, feature service urls do not match.")}),this.versionableItems.on("before-remove",e=>{if(0===this.versionableItems.items.length&&this.currentVersion&&"name"in this.currentVersion&&"none"!==this.versionManagementService.getLockType(this.currentVersion))return e.preventDefault(),void n.getLogger(this).error("#remove()","Cannot remove last versionAdapter.")})])}load(e){return this.addResolvingPromise(this._setUpState(e)),Promise.resolve(this)}get defaultVersionIdentifier(){return this.versionManagementService.defaultVersionIdentifier}get isDefault(){return!this.currentVersion||!!this.currentVersion&&"name"in this.currentVersion&&this.currentVersion.name===this.defaultVersionIdentifier.name}async getVersionInfos(e=!1){return e&&(this.versionInfos=await this.versionManagementService.getVersionInfos()),this.versionInfos}async alterVersion(e,t){if(this.currentVersion&&"guid"in this.currentVersion&&e.guid===this.currentVersion.guid)return!1;const r=await this.versionManagementService.alterVersion(e,t);return r&&await this.getVersionInfos(!0),r}async deleteVersion(e){if(this.currentVersion&&"guid"in this.currentVersion&&e.guid===this.currentVersion.guid)return!1;const t=await this.versionManagementService.deleteVersion(e);return t&&await this.getVersionInfos(!0),t}async getVersionInfoExtended(){return this.currentVersion&&"name"in this.currentVersion?this.versionManagementService.getVersionInfoExtended(this.currentVersion):this.versionManagementService.getVersionInfoExtended(this.defaultVersionIdentifier)}async startEditing(){if(this._isDefaultOrHistoricVersion())return{success:!1};if(!this.usePersistentReadSessions){const e=await this.versionManagementService.startReadingWithResult(this.currentVersion);if(!e.success)return e;this.state="lock-read"}const e=await this.versionManagementService.startEditingWithResult(this.currentVersion);return e.success&&(this.state="lock-write"),e}async stopEditing(e){if(this._isDefaultOrHistoricVersion())return{success:!1};const t=await this.versionManagementService.stopEditingWithResult(this.currentVersion,e);if(!t.success)return t;if(this.state="lock-read",!this.usePersistentReadSessions){const e=await this.versionManagementService.stopReadingWithResult(this.currentVersion);return e.success&&(this.state="lock-none"),e}return t}async changeVersion(e){let t=null;if(this.usePersistentReadSessions){if(this._isDefaultOrHistoricVersion(e))e&&"name"in e?(t=await this.versionManagementService.getVersionInfoExtended(e),this.state="public"===t?.access?"lock-none":"lock-read"):this.state="lock-read";else if(!await this.versionManagementService.startReading(e))throw new r("versioning:failed-lock","Failed to acquire read lock for version: "+e);this._isDefaultOrHistoricVersion(this.currentVersion)||await this.versionManagementService.stopReading(this.currentVersion)}const s=await this.versionManagementService.changeVersionWithResult(this.versionableItems,this.currentVersion,e);let i=!1;return s.forEach((e,t)=>{i=i||e.success}),i&&(this.currentVersion=e,this.currentVersionInfo=t||await this.getVersionInfoExtended(),this._isDefaultOrHistoricVersion()?this.currentVersion&&"name"in this.currentVersion?this.state="public"===this.currentVersionInfo?.access?"lock-none":"lock-read":this.state="lock-read":this.state="read"!==this.versionManagementService.getLockType(this.currentVersion)?"lock-none":"lock-read"),s}async undo(){return this._isDefaultOrHistoricVersion()?{success:!1}:(this.versionManagementService.undo(this.currentVersion),{success:!0})}async redo(){return this._isDefaultOrHistoricVersion()?{success:!1}:(this.versionManagementService.redo(this.currentVersion),{success:!0})}async _setUpState(e){await this.versionManagementService.load(e),this.state="lock-none",this.currentVersionInfo=await this.getVersionInfoExtended(),this.versionableItems.forEach(e=>{this.currentVersion?"name"in this.currentVersion?(e.gdbVersion=this.currentVersion.name,e.historicMoment=null):(e.historicMoment=this.currentVersion,e.gdbVersion=null):(e.gdbVersion=null,e.historicMoment=null)}),this.usePersistentReadSessions&&(this._isDefaultOrHistoricVersion()?this.currentVersion&&"name"in this.currentVersion?this.state="public"===this.currentVersionInfo?.access?"lock-none":"lock-read":this.state="lock-read":await this.versionManagementService.startReading(this.currentVersion)&&(this.state="lock-read"))}_isDefaultOrHistoricVersion(e=this.currentVersion){return!(e&&"name"in e)||e.name===this.versionManagementService.defaultVersionIdentifier.name}};e([o()],c.prototype,"versionManagementService",void 0),e([o()],c.prototype,"featureServiceUrl",void 0),e([o()],c.prototype,"url",void 0),e([o()],c.prototype,"currentVersion",void 0),e([o()],c.prototype,"currentVersionInfo",void 0),e([o()],c.prototype,"versionInfos",void 0),e([o()],c.prototype,"versionableItems",void 0),e([o()],c.prototype,"usePersistentReadSessions",void 0),e([o()],c.prototype,"state",void 0),e([o({readOnly:!0})],c.prototype,"defaultVersionIdentifier",null),e([o({readOnly:!0})],c.prototype,"isDefault",null),c=e([a("esri.versionManagement.VersioningState")],c);const u=c;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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import r from"../../../core/Accessor.js";import t from"../../../core/Identifiable.js";import o from"../../../core/Logger.js";import{property as s}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/RandomLCG.js";import{subclass as i}from"../../../core/accessorSupport/decorators/subclass.js";import{project as n}from"../../../geometry/projectionUtils.js";import{extentContainsPoint as m,polygonContainsPoint as a}from"../../../geometry/support/contains.js";import{nearestCoordinate as c}from"../../../geometry/support/near.js";var l;let p=l=class extends(t.NumericIdentifiableMixin(r)){constructor(e){super(e),this.geometry=null,this.spatialReference=null}get normalizedGeometry(){if(null==this.geometry||!this.spatialReference)return null;if(!this.spatialReference.equals(this.geometry.spatialReference))try{return n(this.geometry,this.spatialReference)}catch(e){return o.getLogger(this).error("#constraints.geometry","could not project the geometry to the view's spatial reference",{geometry:this.geometry,spatialReference:this.spatialReference,error:e}),null}return this.geometry}constrain(e,r){if(null==this.normalizedGeometry)return e;const t=e.targetGeometry;if("extent"===this.normalizedGeometry.type?m(this.normalizedGeometry,t):a(this.normalizedGeometry,t))return e;const{coordinate:o}=c(this.normalizedGeometry,t);return o?(e.targetGeometry=o,e):e}clone(){return new l({geometry:this.geometry?.clone(),spatialReference:this.spatialReference?.clone()})}};e([s({constructOnly:!0})],p.prototype,"geometry",void 0),e([s({readOnly:!0})],p.prototype,"normalizedGeometry",null),e([s({constructOnly:!0})],p.prototype,"spatialReference",void 0),p=l=e([i("esri.views.2d.constraints.GeometryConstraint")],p);export{p as GeometryConstraint};
5
+ import{__decorate as e}from"tslib";import r from"../../../core/Accessor.js";import{NumericIdentifiableMixin as t}from"../../../core/Identifiable.js";import o from"../../../core/Logger.js";import{property as s}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/RandomLCG.js";import{subclass as i}from"../../../core/accessorSupport/decorators/subclass.js";import{project as n}from"../../../geometry/projectionUtils.js";import{extentContainsPoint as m,polygonContainsPoint as a}from"../../../geometry/support/contains.js";import{nearestCoordinate as c}from"../../../geometry/support/near.js";var l;let p=l=class extends(t(r)){constructor(e){super(e),this.geometry=null,this.spatialReference=null}get normalizedGeometry(){if(null==this.geometry||!this.spatialReference)return null;if(!this.spatialReference.equals(this.geometry.spatialReference))try{return n(this.geometry,this.spatialReference)}catch(e){return o.getLogger(this).error("#constraints.geometry","could not project the geometry to the view's spatial reference",{geometry:this.geometry,spatialReference:this.spatialReference,error:e}),null}return this.geometry}constrain(e,r){if(null==this.normalizedGeometry)return e;const t=e.targetGeometry;if("extent"===this.normalizedGeometry.type?m(this.normalizedGeometry,t):a(this.normalizedGeometry,t))return e;const{coordinate:o}=c(this.normalizedGeometry,t);return o?(e.targetGeometry=o,e):e}clone(){return new l({geometry:this.geometry?.clone(),spatialReference:this.spatialReference?.clone()})}};e([s({constructOnly:!0})],p.prototype,"geometry",void 0),e([s({readOnly:!0})],p.prototype,"normalizedGeometry",null),e([s({constructOnly:!0})],p.prototype,"spatialReference",void 0),p=l=e([i("esri.views.2d.constraints.GeometryConstraint")],p);export{p as GeometryConstraint};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as o}from"tslib";import t from"../../../core/Accessor.js";import r from"../../../core/Identifiable.js";import{property as e}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as s}from"../../../core/accessorSupport/decorators/subclass.js";var i;let n=i=class extends(r.NumericIdentifiableMixin(t)){constructor(){super(...arguments),this.enabled=!0,this.rotationEnabled=!0}constrain(o,t){return this.enabled&&t?(this.rotationEnabled||(o.rotation=t.rotation),o):o}clone(){return new i({enabled:this.enabled,rotationEnabled:this.rotationEnabled})}};o([e()],n.prototype,"enabled",void 0),o([e()],n.prototype,"rotationEnabled",void 0),n=i=o([s("esri.views.2d.constraints.RotationConstraint")],n);const a=n;export{a as default};
5
+ import{__decorate as o}from"tslib";import t from"../../../core/Accessor.js";import{NumericIdentifiableMixin as r}from"../../../core/Identifiable.js";import{property as e}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as s}from"../../../core/accessorSupport/decorators/subclass.js";var a;let n=a=class extends(r(t)){constructor(){super(...arguments),this.enabled=!0,this.rotationEnabled=!0}constrain(o,t){return this.enabled&&t?(this.rotationEnabled||(o.rotation=t.rotation),o):o}clone(){return new a({enabled:this.enabled,rotationEnabled:this.rotationEnabled})}};o([e()],n.prototype,"enabled",void 0),o([e()],n.prototype,"rotationEnabled",void 0),n=a=o([s("esri.views.2d.constraints.RotationConstraint")],n);const i=n;export{i 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import t from"../../../core/Accessor.js";import o from"../../../core/Identifiable.js";import{property as s}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as i}from"../../../core/accessorSupport/decorators/subclass.js";var a;let c=a=class extends(o.NumericIdentifiableMixin(t)){constructor(e){super(e),this._lodByScale={},this._scales=[],this.effectiveLODs=null,this.effectiveMinZoom=-1,this.effectiveMaxZoom=-1,this.effectiveMinScale=0,this.effectiveMaxScale=0,this.lods=null,this.minZoom=-1,this.maxZoom=-1,this.minScale=0,this.maxScale=0,this.snapToZoom=!0}initialize(){let e,{lods:t,minScale:o,maxScale:s,minZoom:i,maxZoom:a}=this,c=-1,r=-1,l=!1,n=!1;if(0!==o&&0!==s&&o<s&&([o,s]=[s,o]),!t?.length)return this._set("effectiveMinScale",o),void this._set("effectiveMaxScale",s);t=t.map(e=>e.clone()),t.sort((e,t)=>t.scale-e.scale),t.forEach((e,t)=>e.level=t);for(const f of t)!l&&o>0&&o>=f.scale&&(c=f.level,l=!0),!n&&s>0&&s>=f.scale&&(r=e?e.level:-1,n=!0),e=f;-1===i&&(i=0===o?0:c),-1===a&&(a=0===s?t.length-1:r),i=Math.max(i,0),i=Math.min(i,t.length-1),a=Math.max(a,0),a=Math.min(a,t.length-1),i>a&&([i,a]=[a,i]),o=t[i].scale,s=t[a].scale,t.splice(0,i),t.splice(a-i+1),t.forEach((e,t)=>{this._lodByScale[e.scale]=e,this._scales[t]=e.scale}),this._set("effectiveLODs",t),this._set("effectiveMinZoom",i),this._set("effectiveMaxZoom",a),this._set("effectiveMinScale",o),this._set("effectiveMaxScale",s)}constrain(e,t){if(t&&e.scale===t.scale)return e;const o=this.effectiveMinScale,s=this.effectiveMaxScale,i=e.targetGeometry,a=t&&t.targetGeometry,c=0!==s&&e.scale<s,r=0!==o&&e.scale>o;if(c||r){const c=r?o:s;if(t&&a){const o=(c-t.scale)/(e.scale-t.scale);i.x=a.x+(i.x-a.x)*o,i.y=a.y+(i.y-a.y)*o}e.scale=c}return this.snapToZoom&&this.effectiveLODs&&(e.scale=this._getClosestScale(e.scale)),e}fit(e){if(!this.effectiveLODs||!this.snapToZoom)return this.constrain(e,null);const t=this.scaleToZoom(e.scale),o=Math.abs(t-Math.floor(t));return e.scale=this.zoomToScale(o>.99?Math.round(t):Math.floor(t)),e}zoomToScale(e){if(!this.effectiveLODs)return 0;e-=this.effectiveMinZoom,e=Math.max(0,e);const t=this._scales;if(e<=0)return t[0];if(e>=t.length)return t[t.length-1];const o=Math.floor(e),s=Math.ceil(e);return t[o]+(e-o)*(t[s]-t[o])}scaleToZoom(e){if(!this.effectiveLODs)return-1;const t=this._scales;let o,s;if(e>=t[0])return this.effectiveMinZoom;if(e<=t[t.length-1])return this.effectiveMaxZoom;for(let i=0;i<t.length-1;i++){if(o=t[i],s=t[i+1],s===e){return i+this.effectiveMinZoom+1}if(o>e&&s<e){return i+this.effectiveMinZoom+1-(e-s)/(o-s)}}return-1}snapToClosestScale(e){if(!this.effectiveLODs)return e;const t=this.scaleToZoom(e);return this.zoomToScale(Math.round(t))}snapToNextScale(e,t=.5){if(!this.effectiveLODs)return e*t;const o=Math.round(this.scaleToZoom(e));return this.zoomToScale(o+1)}snapToPreviousScale(e,t=2){if(!this.effectiveLODs)return e*t;const o=Math.round(this.scaleToZoom(e));return this.zoomToScale(o-1)}clone(){return new a({lods:this.lods,minZoom:this.minZoom,maxZoom:this.maxZoom,minScale:this.minScale,maxScale:this.maxScale})}_getClosestScale(e){return this._lodByScale[e]||(e=this._scales.reduce((t,o)=>Math.abs(o-e)<=Math.abs(t-e)?o:t,this._scales[0])),this._lodByScale[e].scale}};e([s({readOnly:!0})],c.prototype,"effectiveLODs",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMinZoom",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMaxZoom",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMinScale",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMaxScale",void 0),e([s()],c.prototype,"lods",void 0),e([s()],c.prototype,"minZoom",void 0),e([s()],c.prototype,"maxZoom",void 0),e([s()],c.prototype,"minScale",void 0),e([s()],c.prototype,"maxScale",void 0),e([s()],c.prototype,"snapToZoom",void 0),c=a=e([i("esri.views.2d.constraints.ZoomConstraint")],c);const r=c;export{r as default};
5
+ import{__decorate as e}from"tslib";import t from"../../../core/Accessor.js";import{NumericIdentifiableMixin as o}from"../../../core/Identifiable.js";import{property as s}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as i}from"../../../core/accessorSupport/decorators/subclass.js";var a;let c=a=class extends(o(t)){constructor(e){super(e),this._lodByScale={},this._scales=[],this.effectiveLODs=null,this.effectiveMinZoom=-1,this.effectiveMaxZoom=-1,this.effectiveMinScale=0,this.effectiveMaxScale=0,this.lods=null,this.minZoom=-1,this.maxZoom=-1,this.minScale=0,this.maxScale=0,this.snapToZoom=!0}initialize(){let e,{lods:t,minScale:o,maxScale:s,minZoom:i,maxZoom:a}=this,c=-1,r=-1,l=!1,n=!1;if(0!==o&&0!==s&&o<s&&([o,s]=[s,o]),!t?.length)return this._set("effectiveMinScale",o),void this._set("effectiveMaxScale",s);t=t.map(e=>e.clone()),t.sort((e,t)=>t.scale-e.scale),t.forEach((e,t)=>e.level=t);for(const f of t)!l&&o>0&&o>=f.scale&&(c=f.level,l=!0),!n&&s>0&&s>=f.scale&&(r=e?e.level:-1,n=!0),e=f;-1===i&&(i=0===o?0:c),-1===a&&(a=0===s?t.length-1:r),i=Math.max(i,0),i=Math.min(i,t.length-1),a=Math.max(a,0),a=Math.min(a,t.length-1),i>a&&([i,a]=[a,i]),o=t[i].scale,s=t[a].scale,t.splice(0,i),t.splice(a-i+1),t.forEach((e,t)=>{this._lodByScale[e.scale]=e,this._scales[t]=e.scale}),this._set("effectiveLODs",t),this._set("effectiveMinZoom",i),this._set("effectiveMaxZoom",a),this._set("effectiveMinScale",o),this._set("effectiveMaxScale",s)}constrain(e,t){if(t&&e.scale===t.scale)return e;const o=this.effectiveMinScale,s=this.effectiveMaxScale,i=e.targetGeometry,a=t&&t.targetGeometry,c=0!==s&&e.scale<s,r=0!==o&&e.scale>o;if(c||r){const c=r?o:s;if(t&&a){const o=(c-t.scale)/(e.scale-t.scale);i.x=a.x+(i.x-a.x)*o,i.y=a.y+(i.y-a.y)*o}e.scale=c}return this.snapToZoom&&this.effectiveLODs&&(e.scale=this._getClosestScale(e.scale)),e}fit(e){if(!this.effectiveLODs||!this.snapToZoom)return this.constrain(e,null);const t=this.scaleToZoom(e.scale),o=Math.abs(t-Math.floor(t));return e.scale=this.zoomToScale(o>.99?Math.round(t):Math.floor(t)),e}zoomToScale(e){if(!this.effectiveLODs)return 0;e-=this.effectiveMinZoom,e=Math.max(0,e);const t=this._scales;if(e<=0)return t[0];if(e>=t.length)return t[t.length-1];const o=Math.floor(e),s=Math.ceil(e);return t[o]+(e-o)*(t[s]-t[o])}scaleToZoom(e){if(!this.effectiveLODs)return-1;const t=this._scales;let o,s;if(e>=t[0])return this.effectiveMinZoom;if(e<=t[t.length-1])return this.effectiveMaxZoom;for(let i=0;i<t.length-1;i++){if(o=t[i],s=t[i+1],s===e){return i+this.effectiveMinZoom+1}if(o>e&&s<e){return i+this.effectiveMinZoom+1-(e-s)/(o-s)}}return-1}snapToClosestScale(e){if(!this.effectiveLODs)return e;const t=this.scaleToZoom(e);return this.zoomToScale(Math.round(t))}snapToNextScale(e,t=.5){if(!this.effectiveLODs)return e*t;const o=Math.round(this.scaleToZoom(e));return this.zoomToScale(o+1)}snapToPreviousScale(e,t=2){if(!this.effectiveLODs)return e*t;const o=Math.round(this.scaleToZoom(e));return this.zoomToScale(o-1)}clone(){return new a({lods:this.lods,minZoom:this.minZoom,maxZoom:this.maxZoom,minScale:this.minScale,maxScale:this.maxScale})}_getClosestScale(e){return this._lodByScale[e]||(e=this._scales.reduce((t,o)=>Math.abs(o-e)<=Math.abs(t-e)?o:t,this._scales[0])),this._lodByScale[e].scale}};e([s({readOnly:!0})],c.prototype,"effectiveLODs",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMinZoom",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMaxZoom",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMinScale",void 0),e([s({readOnly:!0})],c.prototype,"effectiveMaxScale",void 0),e([s()],c.prototype,"lods",void 0),e([s()],c.prototype,"minZoom",void 0),e([s()],c.prototype,"maxZoom",void 0),e([s()],c.prototype,"minScale",void 0),e([s()],c.prototype,"maxScale",void 0),e([s()],c.prototype,"snapToZoom",void 0),c=a=e([i("esri.views.2d.constraints.ZoomConstraint")],c);const r=c;export{r 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/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{remove as t}from"../../../core/arrayUtils.js";import i from"../../../core/Evented.js";import{FadeTransition as s}from"./transitions/FadeTransition.js";class e extends i{constructor(){super(...arguments),this._transitionables=null,this._clips=null,this._fadeTransition=null,this._isReady=!1,this._opacity=1,this.parent=null,this._stage=null,this._visible=!0}get computedOpacity(){return this._fadeTransition?.computedOpacity??this.opacity}get clips(){return this._clips}set clips(t){this._clips=t,this.requestRender()}get fadeTransitionEnabled(){return null!==this._fadeTransition}set fadeTransitionEnabled(t){!this._fadeTransition&&t?(this._fadeTransition=new s({opacity:this.opacity,visible:this.visible}),this.addTransitionable(this._fadeTransition)):this._fadeTransition&&!t&&(this.removeTransitionable(this._fadeTransition),this._fadeTransition=null)}get inFadeTransition(){return this._fadeTransition?.transitioning??!1}get isReady(){return this._isReady}get opacity(){return this._opacity}set opacity(t){this._opacity!==t&&(this._opacity=Math.min(1,Math.max(t,0)),this._fadeTransition&&(this._fadeTransition.opacity=this._opacity),this.requestRender())}get stage(){return this._stage}set stage(t){if(this._stage===t)return;const i=this._stage;this._stage=t,t?this._stage?.untrashDisplayObject(this)||(this.onAttach(),this.emit("attach")):i?.trashDisplayObject(this)}get transforms(){return null==this._transforms&&(this._transforms=this._createTransforms()),this._transforms}get transitioning(){return this.isTransitioning()}get visible(){return this._visible}set visible(t){this._visible!==t&&(this._visible=t,this._fadeTransition&&(this._fadeTransition.visible=this._visible),this.requestRender())}get hasLabels(){return!1}get hasHighlight(){return!1}get hasBlending(){return!1}addTransitionable(t){this._transitionables??=[],this._transitionables.push(t),this.requestRender()}removeTransitionable(i){i.endTransition(),this._transitionables&&t(this._transitionables,i),this.requestRender()}fadeIn(){this.fadeTransitionEnabled=!0;const t=this._fadeTransition.fadeIn();return this.opacity=1,this.requestRender(),t}fadeOut(){this.fadeTransitionEnabled=!0;const t=this._fadeTransition.fadeOut();return this.opacity=0,this.requestRender(),t}endTransitions(){if(this._transitionables){for(const t of this._transitionables)t.endTransition();this.requestRender()}}beforeRender(t){this.transitionStep(t.deltaTime,t.state.scale),this.setTransform(t.state)}afterRender(t){this.transitioning&&this.requestRender()}remove(){this.parent?.removeChild(this)}setTransform(t){}processRender(t){this.stage&&(this._fadeTransition?.computedVisible??this.visible)&&this.doRender(t)}requestRender(){this.stage&&this.stage.requestRender()}processDetach(){this.endTransitions(),this.onDetach(),this.emit("detach")}isTransitioning(){return this._transitionables?.some(t=>t.transitioning)??!1}transitionStep(t,i){if(this._transitionables)for(const s of this._transitionables)s.transitionStep(t,i)}onAttach(){}onDetach(){}doRender(t){}ready(){this._isReady||(this._isReady=!0,this.emit("isReady"),this.requestRender())}}export{e as DisplayObject};
5
+ import{remove as t}from"../../../core/arrayUtils.js";import{Evented as i}from"../../../core/Evented.js";import{FadeTransition as s}from"./transitions/FadeTransition.js";class e extends i{constructor(){super(...arguments),this._transitionables=null,this._clips=null,this._fadeTransition=null,this._isReady=!1,this._opacity=1,this.parent=null,this._stage=null,this._visible=!0}get computedOpacity(){return this._fadeTransition?.computedOpacity??this.opacity}get clips(){return this._clips}set clips(t){this._clips=t,this.requestRender()}get fadeTransitionEnabled(){return null!==this._fadeTransition}set fadeTransitionEnabled(t){!this._fadeTransition&&t?(this._fadeTransition=new s({opacity:this.opacity,visible:this.visible}),this.addTransitionable(this._fadeTransition)):this._fadeTransition&&!t&&(this.removeTransitionable(this._fadeTransition),this._fadeTransition=null)}get inFadeTransition(){return this._fadeTransition?.transitioning??!1}get isReady(){return this._isReady}get opacity(){return this._opacity}set opacity(t){this._opacity!==t&&(this._opacity=Math.min(1,Math.max(t,0)),this._fadeTransition&&(this._fadeTransition.opacity=this._opacity),this.requestRender())}get stage(){return this._stage}set stage(t){if(this._stage===t)return;const i=this._stage;this._stage=t,t?this._stage?.untrashDisplayObject(this)||(this.onAttach(),this.emit("attach")):i?.trashDisplayObject(this)}get transforms(){return null==this._transforms&&(this._transforms=this._createTransforms()),this._transforms}get transitioning(){return this.isTransitioning()}get visible(){return this._visible}set visible(t){this._visible!==t&&(this._visible=t,this._fadeTransition&&(this._fadeTransition.visible=this._visible),this.requestRender())}get hasLabels(){return!1}get hasHighlight(){return!1}get hasBlending(){return!1}addTransitionable(t){this._transitionables??=[],this._transitionables.push(t),this.requestRender()}removeTransitionable(i){i.endTransition(),this._transitionables&&t(this._transitionables,i),this.requestRender()}fadeIn(){this.fadeTransitionEnabled=!0;const t=this._fadeTransition.fadeIn();return this.opacity=1,this.requestRender(),t}fadeOut(){this.fadeTransitionEnabled=!0;const t=this._fadeTransition.fadeOut();return this.opacity=0,this.requestRender(),t}endTransitions(){if(this._transitionables){for(const t of this._transitionables)t.endTransition();this.requestRender()}}beforeRender(t){this.transitionStep(t.deltaTime,t.state.scale),this.setTransform(t.state)}afterRender(t){this.transitioning&&this.requestRender()}remove(){this.parent?.removeChild(this)}setTransform(t){}processRender(t){this.stage&&(this._fadeTransition?.computedVisible??this.visible)&&this.doRender(t)}requestRender(){this.stage&&this.stage.requestRender()}processDetach(){this.endTransitions(),this.onDetach(),this.emit("detach")}isTransitioning(){return this._transitionables?.some(t=>t.transitioning)??!1}transitionStep(t,i){if(this._transitionables)for(const s of this._transitionables)s.transitionStep(t,i)}onAttach(){}onDetach(){}doRender(t){}ready(){this._isReady||(this._isReady=!0,this.emit("isReady"),this.requestRender())}}export{e as DisplayObject};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../core/Evented.js";import{on as t}from"../../../core/events.js";import{handlesGroup as a}from"../../../core/handleUtils.js";import has from"../../../core/has.js";import{deg2rad as s}from"../../../core/mathUtils.js";import{identity as r,scale as n,rotate as i,translate as o}from"../../../core/libs/gl-matrix-2/math/mat2d.js";import{create as h}from"../../../core/libs/gl-matrix-2/factories/mat2df64.js";class c{constructor(s,r={}){this.events=new e.EventEmitter,this._hasMajorPerformanceCaveat=!1,this._lastRenderFrameCounter=0,null!=s?(this._canvas=document.createElement("canvas"),this._canvas.setAttribute("style","width: 100%; height:100%; display:block; willChange:transform"),s.contains(this._canvas)||s.appendChild(this._canvas)):null!=r.canvas&&(this._canvas=r.canvas);const n={failIfMajorPerformanceCaveat:!0,alpha:!0,antialias:!1,depth:!0,stencil:!0,powerPreference:"high-performance"};let i=this._canvas.getContext("webgl2",n);i||(i=this._canvas.getContext("webgl2",{...n,failIfMajorPerformanceCaveat:!1}),this._hasMajorPerformanceCaveat=!0),this._gl=i,this._handles=a([t(this._canvas,"webglcontextlost",e=>this.events.emit("webgl-context-lost",e))])}destroy(){this._canvas.remove(),this._canvas=null,this._handles.remove(),this._gl=null}get gl(){return this._gl}get canvas(){return this._canvas}render(e,t){if(this._hasMajorPerformanceCaveat||has("esri-force-performance-mode")){if(++this._lastRenderFrameCounter>=has("esri-performance-mode-frames-between-render")&&(t(),this._lastRenderViewState=e.state.clone(),this._lastRenderFrameCounter=0),this._lastRenderViewState){const[t,a,s,r,n,i]=this._computeViewTransform(this._lastRenderViewState,e.state);this._canvas.style.transform=`matrix(${t}, ${a}, ${s}, ${r}, ${n}, ${i})`}}else t()}resize(e){const t=this._canvas,a=t.style,{state:{size:s},pixelRatio:r}=e,n=s[0],i=s[1],o=Math.round(n*r),h=Math.round(i*r);t.width===o&&t.height===h||(t.width=o,t.height=h),a.width=n+"px",a.height=i+"px"}_computeViewTransform(e,t){const[a,c]=e.center,[l,m]=t.center,[f,v]=e.toScreen([0,0],l,m),[_,d]=e.toScreen([0,0],a,c),p=_-f,g=d-v,u=e.scale/t.scale,w=t.rotation-e.rotation,j=h();return r(j),n(j,j,[u,u]),i(j,j,s(w)),o(j,j,[p,g]),j}}export{c as ManagedCanvas};
5
+ import{EventEmitter as e}from"../../../core/Evented.js";import{on as t}from"../../../core/events.js";import{handlesGroup as a}from"../../../core/handleUtils.js";import has from"../../../core/has.js";import{deg2rad as s}from"../../../core/mathUtils.js";import{identity as r,scale as n,rotate as i,translate as o}from"../../../core/libs/gl-matrix-2/math/mat2d.js";import{create as h}from"../../../core/libs/gl-matrix-2/factories/mat2df64.js";class c{constructor(s,r={}){this.events=new e,this._hasMajorPerformanceCaveat=!1,this._lastRenderFrameCounter=0,null!=s?(this._canvas=document.createElement("canvas"),this._canvas.setAttribute("style","width: 100%; height:100%; display:block; willChange:transform"),s.contains(this._canvas)||s.appendChild(this._canvas)):null!=r.canvas&&(this._canvas=r.canvas);const n={failIfMajorPerformanceCaveat:!0,alpha:!0,antialias:!1,depth:!0,stencil:!0,powerPreference:"high-performance"};let i=this._canvas.getContext("webgl2",n);i||(i=this._canvas.getContext("webgl2",{...n,failIfMajorPerformanceCaveat:!1}),this._hasMajorPerformanceCaveat=!0),this._gl=i,this._handles=a([t(this._canvas,"webglcontextlost",e=>this.events.emit("webgl-context-lost",e))])}destroy(){this._canvas.remove(),this._canvas=null,this._handles.remove(),this._gl=null}get gl(){return this._gl}get canvas(){return this._canvas}render(e,t){if(this._hasMajorPerformanceCaveat||has("esri-force-performance-mode")){if(++this._lastRenderFrameCounter>=has("esri-performance-mode-frames-between-render")&&(t(),this._lastRenderViewState=e.state.clone(),this._lastRenderFrameCounter=0),this._lastRenderViewState){const[t,a,s,r,n,i]=this._computeViewTransform(this._lastRenderViewState,e.state);this._canvas.style.transform=`matrix(${t}, ${a}, ${s}, ${r}, ${n}, ${i})`}}else t()}resize(e){const t=this._canvas,a=t.style,{state:{size:s},pixelRatio:r}=e,n=s[0],i=s[1],o=Math.round(n*r),h=Math.round(i*r);t.width===o&&t.height===h||(t.width=o,t.height=h),a.width=n+"px",a.height=i+"px"}_computeViewTransform(e,t){const[a,c]=e.center,[l,m]=t.center,[f,_]=e.toScreen([0,0],l,m),[d,v]=e.toScreen([0,0],a,c),p=d-f,g=v-_,u=e.scale/t.scale,w=t.rotation-e.rotation,j=h();return r(j),n(j,j,[u,u]),i(j,j,s(w)),o(j,j,[p,g]),j}}export{c as ManagedCanvas};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{clone as e}from"../../../../../core/libs/gl-matrix-2/factories/mat3f32.js";import{collisionGridCellSize as t}from"./config.js";import{GridIndex as r}from"./util.js";class s{constructor(s,o,n,i,l,c){this._symbols=s,this._styleRepository=i,this._zoom=l,this._currentLayerCursor=0,this._currentSymbolCursor=0,this._styleProps=new Map,this._allNeededMatrices=new Map,this._gridIndex=new r(o,n,t),this._si=Math.sin(Math.PI*c/180),this._co=Math.cos(Math.PI*c/180),i.cachedStyles&&(this._styleProps=i.cachedStyles);for(const t of s)for(const r of t.symbols)this._allNeededMatrices.has(r.tile)||this._allNeededMatrices.set(r.tile,e(r.tile.transforms.tileUnitsToPixels))}work(e){const t=performance.now();for(;this._currentLayerCursor<this._symbols.length;this._currentLayerCursor++,this._currentSymbolCursor=0){const r=this._symbols[this._currentLayerCursor],s=this._getProperties(r.styleLayerUID),o=this._styleRepository.layerContexts?.get(r.styleLayerUID);for(;this._currentSymbolCursor<r.symbols.length;this._currentSymbolCursor++){if(this._currentSymbolCursor%100==99&&performance.now()-t>e)return!1;const n=r.symbols[this._currentSymbolCursor];if(!n.uniqueSymbol?.show)continue;const i=this._computeCoordinates(n,s,o),l=n.uniqueSymbol;if(!l.show)continue;const{iconAllowOverlap:c,textAllowOverlap:h}=s;for(const e of i){if(!e.enabled)continue;const t=l.parts[e.partIndex];if(!t.show)continue;!(e.partIndex?h:c)&&this._doesCollide(e)&&(e.hard?l.show=!1:t.show=!1)}l.show&&this._insertColliders(l.parts,i,s)}}return!0}_insertColliders(e,t,r){const{iconIgnorePlacement:s,textIgnorePlacement:o}=r;for(const n of t){if(!n.enabled)continue;if(n.partIndex?o:s)continue;if(!e[n.partIndex].show)continue;const t=n.xScreen+n.dxScreen,r=n.yScreen+n.dyScreen,i=t+n.width,l=r+n.height,[c,h,a,d]=this._gridIndex.getCellSpan(t,r,i,l);for(let e=h;e<=d;e++)for(let t=c;t<=a;t++){this._gridIndex.cells[e][t].push(n)}}}_computeCoordinates(e,t,r){const{iconRotationAlignment:s,textRotationAlignment:o,iconTranslate:n,iconTranslateAnchor:i,textTranslate:l,textTranslateAnchor:c}=t,h=this._si,a=this._co,d=this._zoom,y=this._allNeededMatrices.get(e.tile),u=e.uniqueSymbol,x=e.colliders(r);let _=0;for(const f of x){const[e,t]=0===f.partIndex?n:l,r=0===f.partIndex?i:c,u=f.minLod<=d&&d<=f.maxLod;_+=u?0:1,f.enabled=u,f.xScreen=f.xTile*y[0]+f.yTile*y[3]+y[6],f.yScreen=f.xTile*y[1]+f.yTile*y[4]+y[7],0===r?(f.xScreen+=a*e-h*t,f.yScreen+=h*e+a*t):(f.xScreen+=e,f.yScreen+=t),1===(0===f.partIndex?s:o)?(f.dxScreen=f.dxPixels,f.dyScreen=f.dyPixels):(f.dxScreen=a*(f.dxPixels+f.width/2)-h*(f.dyPixels+f.height/2)-f.width/2,f.dyScreen=h*(f.dxPixels+f.width/2)+a*(f.dyPixels+f.height/2)-f.height/2)}return x.length>0&&_===x.length&&u&&(u.show=!1),x}_getProperties(e){const t=this._styleProps.get(e);if(t)return t;const r=this._styleRepository.getLayerStyleProperties?.(e,this._zoom);return this._styleProps.set(e,r),r}_doesCollide(e){const t=e.xScreen+e.dxScreen,r=e.yScreen+e.dyScreen,s=t+e.width,o=r+e.height,[n,i,l,c]=this._gridIndex.getCellSpan(t,r,s,o);for(let h=i;h<=c;h++)for(let e=n;e<=l;e++){const n=this._gridIndex.cells[h][e];for(const e of n){const n=e.xScreen+e.dxScreen,i=e.yScreen+e.dyScreen,l=n+e.width,c=i+e.height;if(!(s<n||t>l||o<i||r>c))return!0}}return!1}}export{s as CollisionJob};
5
+ import{clone as e}from"../../../../../core/libs/gl-matrix-2/factories/mat3f32.js";import{collisionGridCellSize as t}from"./config.js";import{GridIndex as r}from"./util.js";class s{constructor(s,o,n,i,l,c){this._symbols=s,this._styleRepository=i,this._zoom=l,this._currentLayerCursor=0,this._currentSymbolCursor=0,this._styleProps=new Map,this._allNeededMatrices=new Map,this._gridIndex=new r(o,n,t),this._si=Math.sin(Math.PI*c/180),this._co=Math.cos(Math.PI*c/180),i.cachedStyles&&(this._styleProps=i.cachedStyles);for(const t of s)for(const r of t.symbols)this._allNeededMatrices.has(r.tile)||this._allNeededMatrices.set(r.tile,e(r.tile.transforms.tileUnitsToPixels))}work(e){const t=performance.now();for(;this._currentLayerCursor<this._symbols.length;this._currentLayerCursor++,this._currentSymbolCursor=0){const r=this._symbols[this._currentLayerCursor],s=this._getProperties(r.styleLayerUID),o=this._styleRepository.layerContexts?.get(r.styleLayerUID);for(;this._currentSymbolCursor<r.symbols.length;this._currentSymbolCursor++){if(this._currentSymbolCursor%100==99&&performance.now()-t>e)return!1;const n=r.symbols[this._currentSymbolCursor];if(!n.uniqueSymbol?.show)continue;const i=this._computeCoordinates(n,s,o),l=n.uniqueSymbol;if(!l.show)continue;const{iconAllowOverlap:c,textAllowOverlap:h}=s;for(const e of i){if(!e.enabled)continue;const t=l.parts[e.partIndex];if(!t.show)continue;!(e.partIndex?h:c)&&this._doesCollide(e)&&(e.hard?l.show=!1:t.show=!1)}l.show&&this._insertColliders(l.parts,i,s)}}return!0}_insertColliders(e,t,r){const{iconIgnorePlacement:s,textIgnorePlacement:o}=r;for(const n of t){if(!n.enabled)continue;if(n.partIndex?o:s)continue;if(!e[n.partIndex].show)continue;const t=n.xScreen+n.dxScreen,r=n.yScreen+n.dyScreen,i=t+n.width,l=r+n.height,[c,h,a,d]=this._gridIndex.getCellSpan(t,r,i,l);for(let e=h;e<=d;e++)for(let t=c;t<=a;t++){this._gridIndex.cells[e][t].push(n)}}}_computeCoordinates(e,t,r){const{iconRotationAlignment:s,textRotationAlignment:o,iconTranslate:n,iconTranslateAnchor:i,textTranslate:l,textTranslateAnchor:c}=t,h=this._si,a=this._co,d=this._zoom,y=this._allNeededMatrices.get(e.tile),u=e.uniqueSymbol,x=e.colliders(r);let _=0;for(const f of x){const[e,t]=0===f.partIndex?n:l,r=0===f.partIndex?i:c,u=f.minLod<=d&&d<=f.maxLod;_+=u?0:1,f.enabled=u,f.xScreen=f.xTile*y[0]+f.yTile*y[3]+y[6],f.yScreen=f.xTile*y[1]+f.yTile*y[4]+y[7],0===r?(f.xScreen+=a*e-h*t,f.yScreen+=h*e+a*t):(f.xScreen+=e,f.yScreen+=t),1===(0===f.partIndex?s:o)?(f.dxScreen=f.dxPixels,f.dyScreen=f.dyPixels):(f.dxScreen=a*(f.dxPixels+f.width/2)-h*(f.dyPixels+f.height/2)-f.width/2,f.dyScreen=h*(f.dxPixels+f.width/2)+a*(f.dyPixels+f.height/2)-f.height/2)}return x.length>0&&_===x.length&&u&&(u.show=!1),x}_getProperties(e){const t=this._styleProps.get(e);if(t)return t;const r=this._styleRepository.getLayerStyleProperties?.(e,this._zoom);return this._styleProps.set(e,r),r}_doesCollide(e){const t=e.xScreen+e.dxScreen,r=e.yScreen+e.dyScreen,s=t+e.width,o=r+e.height,[n,i,l,c]=this._gridIndex.getCellSpan(t,r,s,o);for(let h=i;h<=c;h++)for(let i=n;i<=l;i++){const n=this._gridIndex.cells[h][i];for(const i of n){if(null!=i.labelId&&null!=e.labelId&&i.labelId===e.labelId)continue;const n=i.xScreen+i.dxScreen,l=i.yScreen+i.dyScreen,c=n+i.width,h=l+i.height;if(!(s<n||t>c||o<l||r>h))return!0}}return!1}}export{s as CollisionJob};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as r}from"../../../../webgl/enums.js";import{VertexElementDescriptor as e}from"../../../../webgl/VertexElementDescriptor.js";class s extends t{static{this.ATTRIBUTES=[]}static{this.GEOMETRY_LAYOUT=[new e("a_pos",2,r.BYTE,0,2)]}static{this.ATTRIBUTES_INFO={}}constructor(t){super(t)}geometryInfo(){return s.GEOMETRY_LAYOUT}opacityInfo(){return null}attributes(){return s.ATTRIBUTES}attributesInfo(){return s.ATTRIBUTES_INFO}}export{s as VTLBackgroundMaterial};
5
+ import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as s}from"../../../../webgl/enums.js";import{VertexElementDescriptor as e}from"../../../../webgl/VertexElementDescriptor.js";class T extends t{static{this.ATTRIBUTES=[]}static{this.GEOMETRY_LAYOUT=[new e("a_pos",2,s.BYTE,0,2)]}static{this.ATTRIBUTES_INFO={}}constructor(t){super(t),this.baseGeometryLayout=T.GEOMETRY_LAYOUT,this.attributes=T.ATTRIBUTES,this.attributesInfo=T.ATTRIBUTES_INFO}}export{T as VTLBackgroundMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{VTLMaterial as r}from"./VTLMaterial.js";import{DataType as e}from"../../../../webgl/enums.js";import{VertexElementDescriptor as t}from"../../../../webgl/VertexElementDescriptor.js";class c extends r{static{this.ATTRIBUTES=["circle-radius","circle-color","circle-opacity","circle-stroke-width","circle-stroke-color","circle-stroke-opacity","circle-blur"]}static{this.GEOMETRY_LAYOUT=[new t("a_pos",2,e.SHORT,0,4)]}static{this.ATTRIBUTES_INFO={"circle-radius":{name:"radius",type:1},"circle-color":{name:"color",type:10},"circle-opacity":{name:"opacity",type:1,precisionFactor:100},"circle-stroke-width":{name:"stroke_width",type:1,precisionFactor:4},"circle-stroke-color":{name:"stroke_color",type:10},"circle-stroke-opacity":{name:"stroke_opacity",type:1,precisionFactor:100},"circle-blur":{name:"blur",type:1,precisionFactor:32}}}constructor(r){super(r)}geometryInfo(){return c.GEOMETRY_LAYOUT}opacityInfo(){return null}attributes(){return c.ATTRIBUTES}attributesInfo(){return c.ATTRIBUTES_INFO}}export{c as VTLCircleMaterial};
5
+ import{VTLMaterial as e}from"./VTLMaterial.js";import{DataType as r}from"../../../../webgl/enums.js";import{VertexElementDescriptor as t}from"../../../../webgl/VertexElementDescriptor.js";class c extends e{static{this.ATTRIBUTES=["circle-radius","circle-color","circle-opacity","circle-stroke-width","circle-stroke-color","circle-stroke-opacity","circle-blur"]}static{this.GEOMETRY_LAYOUT=[new t("a_pos",2,r.SHORT,0,4)]}static{this.ATTRIBUTES_INFO={"circle-radius":{name:"radius",type:1},"circle-color":{name:"color",type:10},"circle-opacity":{name:"opacity",type:1,precisionFactor:100},"circle-stroke-width":{name:"stroke_width",type:1,precisionFactor:4},"circle-stroke-color":{name:"stroke_color",type:10},"circle-stroke-opacity":{name:"stroke_opacity",type:1,precisionFactor:100},"circle-blur":{name:"blur",type:1,precisionFactor:32}}}constructor(e){super(e),this.baseGeometryLayout=c.GEOMETRY_LAYOUT,this.attributes=c.ATTRIBUTES,this.attributesInfo=c.ATTRIBUTES_INFO}}export{c as VTLCircleMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as o}from"../../../../webgl/enums.js";import{VertexElementDescriptor as i}from"../../../../webgl/VertexElementDescriptor.js";class e extends t{static{this.ATTRIBUTES=["fill-color","fill-opacity","fill-pattern"]}static{this.GEOMETRY_LAYOUT=[new i("a_pos",2,o.SHORT,0,4)]}static{this.ATTRIBUTES_INFO={"fill-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100},"fill-pattern":{name:"tlbr",type:12,isOptional:!0}}}constructor(t){super(t)}geometryInfo(){return e.GEOMETRY_LAYOUT}opacityInfo(){return null}attributes(){return e.ATTRIBUTES}attributesInfo(){return e.ATTRIBUTES_INFO}}class l extends t{static{this.ATTRIBUTES_OUTLINE=["fill-outline-color","fill-opacity"]}static{this.ATTRIBUTES_FILL=["fill-color","fill-opacity"]}static{this.GEOMETRY_LAYOUT=[new i("a_pos",2,o.SHORT,0,8),new i("a_offset",2,o.BYTE,4,8),new i("a_xnormal",2,o.BYTE,6,8)]}static{this.ATTRIBUTES_INFO_OUTLINE={"fill-outline-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100}}}static{this.ATTRIBUTES_INFO_FILL={"fill-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100}}}constructor(t,o){super(t),this._usefillColor=o}geometryInfo(){return l.GEOMETRY_LAYOUT}opacityInfo(){return null}attributes(){return this._usefillColor?l.ATTRIBUTES_FILL:l.ATTRIBUTES_OUTLINE}attributesInfo(){return this._usefillColor?l.ATTRIBUTES_INFO_FILL:l.ATTRIBUTES_INFO_OUTLINE}}export{e as VTLFillMaterial,l as VTLOutlineMaterial};
5
+ import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as i}from"../../../../webgl/enums.js";import{VertexElementDescriptor as o}from"../../../../webgl/VertexElementDescriptor.js";class T extends t{static{this.ATTRIBUTES=["fill-color","fill-opacity","fill-pattern"]}static{this.GEOMETRY_LAYOUT=[new o("a_pos",2,i.SHORT,0,4)]}static{this.ATTRIBUTES_INFO={"fill-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100},"fill-pattern":{name:"tlbr",type:12,isOptional:!0}}}constructor(t){super(t),this.baseGeometryLayout=T.GEOMETRY_LAYOUT,this.attributes=T.ATTRIBUTES,this.attributesInfo=T.ATTRIBUTES_INFO}}class e extends t{static{this.ATTRIBUTES_OUTLINE=["fill-outline-color","fill-opacity"]}static{this.ATTRIBUTES_FILL=["fill-color","fill-opacity"]}static{this.GEOMETRY_LAYOUT=[new o("a_pos",2,i.SHORT,0,8),new o("a_offset",2,i.BYTE,4,8),new o("a_xnormal",2,i.BYTE,6,8)]}static{this.ATTRIBUTES_INFO_OUTLINE={"fill-outline-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100}}}static{this.ATTRIBUTES_INFO_FILL={"fill-color":{name:"color",type:10},"fill-opacity":{name:"opacity",type:1,precisionFactor:100}}}constructor(t,i){super(t),this.baseGeometryLayout=e.GEOMETRY_LAYOUT,this.attributes=i?e.ATTRIBUTES_FILL:e.ATTRIBUTES_OUTLINE,this.attributesInfo=i?e.ATTRIBUTES_INFO_FILL:e.ATTRIBUTES_INFO_OUTLINE}}export{T as VTLFillMaterial,e as VTLOutlineMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{VTLMaterial as e}from"./VTLMaterial.js";import{DataType as t}from"../../../../webgl/enums.js";import{VertexElementDescriptor as i}from"../../../../webgl/VertexElementDescriptor.js";class r extends e{static{this.ATTRIBUTES=["line-blur","line-color","line-gap-width","line-offset","line-opacity","line-width","line-pattern","line-dasharray"]}static{this.GEOMETRY_LAYOUT=[new i("a_pos",2,t.SHORT,0,16),new i("a_extrude_offset",4,t.BYTE,4,16),new i("a_dir_normal",4,t.BYTE,8,16),new i("a_accumulatedDistance",2,t.UNSIGNED_SHORT,12,16)]}static{this.ATTRIBUTES_INFO={"line-width":{name:"width",type:1,precisionFactor:2},"line-gap-width":{name:"gap_width",type:1,precisionFactor:2},"line-offset":{name:"offset",type:0,precisionFactor:2},"line-color":{name:"color",type:10},"line-opacity":{name:"opacity",type:1,precisionFactor:100},"line-blur":{name:"blur",type:1,precisionFactor:4},"line-pattern":{name:"tlbr",type:12,isOptional:!0},"line-dasharray":{name:"tlbr",type:11,isOptional:!0}}}constructor(e){super(e)}geometryInfo(){return r.GEOMETRY_LAYOUT}opacityInfo(){return null}attributes(){return r.ATTRIBUTES}attributesInfo(){return r.ATTRIBUTES_INFO}}export{r as VTLLineMaterial};
5
+ import{VTLMaterial as e}from"./VTLMaterial.js";import{DataType as t}from"../../../../webgl/enums.js";import{VertexElementDescriptor as i}from"../../../../webgl/VertexElementDescriptor.js";class a extends e{static{this.ATTRIBUTES=["line-blur","line-color","line-gap-width","line-offset","line-opacity","line-width","line-pattern","line-dasharray"]}static{this.GEOMETRY_LAYOUT=[new i("a_pos",2,t.SHORT,0,16),new i("a_extrude_offset",4,t.BYTE,4,16),new i("a_dir_normal",4,t.BYTE,8,16),new i("a_accumulatedDistance",2,t.UNSIGNED_SHORT,12,16)]}static{this.ATTRIBUTES_INFO={"line-width":{name:"width",type:1,precisionFactor:2},"line-gap-width":{name:"gap_width",type:1,precisionFactor:2},"line-offset":{name:"offset",type:0,precisionFactor:2},"line-color":{name:"color",type:10},"line-opacity":{name:"opacity",type:1,precisionFactor:100},"line-blur":{name:"blur",type:1,precisionFactor:4},"line-pattern":{name:"tlbr",type:12,isOptional:!0},"line-dasharray":{name:"tlbr",type:11,isOptional:!0}}}constructor(e){super(e),this.baseGeometryLayout=a.GEOMETRY_LAYOUT,this.attributes=a.ATTRIBUTES,this.attributesInfo=a.ATTRIBUTES_INFO}}export{a as VTLLineMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import t from"../MemoryBuffer.js";import{DataType as e}from"../../../../webgl/enums.js";import{VertexElementDescriptor as n}from"../../../../webgl/VertexElementDescriptor.js";class o{constructor(t){this._locations=new Map,this._key=t}get key(){return this._key}get type(){return 7&this._key}defines(){return[]}getStride(){return this._layout||this._buildAttributesInfo(),this._stride}getAttributeLocations(){return 0===this._locations.size&&this._buildAttributesInfo(),this._locations}getLayoutInfo(){return this._layout||this._buildAttributesInfo(),this._layout}getEncodingInfos(){return this._propertyEncodingInfo||this._buildAttributesInfo(),this._propertyEncodingInfo}getUniforms(){return this._uniforms||this._buildAttributesInfo(),this._uniforms}getShaderHeader(){return this._shaderHeader||this._buildAttributesInfo(),this._shaderHeader}getShaderMain(){return this._shaderMain||this._buildAttributesInfo(),this._shaderMain}setDataUniforms(t,e,n,o,s){const r=this.getUniforms();for(const i of r){const{name:r,type:a,getValue:c}=i,u=c(n,e,o,s);if(null!==u)switch(a){case"float":t.setUniform1f(r,u);break;case"vec2":t.setUniform2fv(r,u);break;case"vec4":t.setUniform4fv(r,u)}}}encodeAttributes(t,e,n,o){const s=this.attributesInfo(),r=this.getEncodingInfos(),i=[];let a=0,c=0;for(const u of Object.keys(r)){const h=r[u],{type:l,precisionFactor:f,isLayout:d}=s[u],y=d?n.getLayoutProperty(u):n.getPaintProperty(u),_=y.interpolator?.getInterpolationRange(e);let m=0;for(const n of h){const{offset:s,bufferElementsToAdd:r}=n;if(r>0){for(let t=0;t<r;t++)i.push(0);a+=c,c=n.bufferElementsToAdd}const u=o??y.getValue(_?_[m]:e,t);switch(l){case 0:case 1:i[a]|=this._encodeByte(u*(f||1),8*s);break;case 2:case 3:i[a]|=this._encodeShort(u*(f||1),8*s);break;case 4:case 5:i[a]|=this._encodeByte(u*(f||1),8*s),i[a]|=this._encodeByte(u*(f||1),8*s+8);break;case 6:case 7:i[a]|=this._encodeShort(u*(f||1),8*s),i[a]|=this._encodeShort(u*(f||1),8*s+16);break;case 8:case 9:i[a]|=this._encodeByte(u*(f||1),8*s),i[a]|=this._encodeByte(u*(f||1),8*s+8),i[a]|=this._encodeByte(u*(f||1),8*s+16),i[a]|=this._encodeByte(u*(f||1),8*s+24);break;case 10:i[a]=this._encodeColor(u);break;case 11:case 12:this._encodePattern(a,i,u);break;default:throw new Error("Unsupported encoding type")}m++}}return i}getAtributeState(t){let e=0;const n=3+2*t;return e|=this._bit(n),e|=this._bit(n+1)<<1,e}static{this._encodingInfo={0:{dataType:e.BYTE,bytesPerElement:1,count:1,normalized:!1},1:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:1,normalized:!1},2:{dataType:e.SHORT,bytesPerElement:2,count:1,normalized:!1},3:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:1,normalized:!1},4:{dataType:e.BYTE,bytesPerElement:1,count:2,normalized:!1},5:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:2,normalized:!1},6:{dataType:e.SHORT,bytesPerElement:2,count:2,normalized:!1},7:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:2,normalized:!1},8:{dataType:e.BYTE,bytesPerElement:1,count:4,normalized:!1},9:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:4,normalized:!1},10:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:4,normalized:!0},11:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:4,normalized:!1},12:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:4,normalized:!1}}}_buildAttributesInfo(){const t=[],n={},s={};let r=-1;const i=this.attributesInfo(),a=this.attributes();let c=-1;for(const e of a){c++;const a=this.getAtributeState(c);if(0===a||3===a)continue;const u=i[e],h=[];n[e]=h;const l=u.type;for(let e=0;e<a;e++){const{dataType:e,bytesPerElement:n,count:i,normalized:a}=o._encodingInfo[l],c=n*i,u=`${e}-${!0===a}`;let f=s[u],d=0;if(!f||f.count+i>4)r++,f={dataIndex:r,count:0,offset:0},4!==i&&(s[u]=f),t.push({location:-1,name:"a_data_"+r,count:i,type:e,normalized:a}),d=Math.ceil(Math.max(c/4,1));else{const e=t[f.dataIndex];e.count+=i;d=Math.ceil(Math.max(e.count*n/4,1))-Math.ceil(Math.max(f.offset/4,1))}h.push({dataIndex:f.dataIndex,offset:f.offset,bufferElementsToAdd:d}),f.offset+=c,f.count+=i}}for(const o of t)switch(o.type){case e.BYTE:case e.UNSIGNED_BYTE:o.count=4;break;case e.SHORT:case e.UNSIGNED_SHORT:o.count+=o.count%2}this._buildVertexBufferLayout(t);let u=0;const h=this._layout.get("geometry");for(const e of h)this._locations.set(e.name,u++);const l=this._layout.get("opacity");if(l)for(const e of l)this._locations.set(e.name,u++);this._buildShaderInfo(t,n),this._propertyEncodingInfo=n}_buildVertexBufferLayout(t){const e=new Map,o=this.geometryInfo();let r=o[0].stride;if(0===t.length)e.set("geometry",o);else{const i=[];let a=r;for(const e of t)r+=s(e.type)*e.count;for(const t of o)i.push(new n(t.name,t.count,t.type,t.offset,r,t.normalized));for(const e of t)i.push(new n(e.name,e.count,e.type,a,r,e.normalized)),a+=s(e.type)*e.count;e.set("geometry",i)}const i=this.opacityInfo();i&&e.set("opacity",i),this._layout=e,this._stride=r}_buildShaderInfo(t,e){let n="\n",s="\n";const i=[];for(const o of t)n+=`attribute ${this._getType(o.count)} ${o.name};\n`;const a=this.attributes(),c=this.attributesInfo();let u=-1;for(const h of a){u++;const{name:t,type:a,precisionFactor:l,isLayout:f}=c[h],d=l&&1!==l?" * "+1/l:"",{bytesPerElement:y,count:_}=o._encodingInfo[a],m=t=>`a_data_${t.dataIndex}${r(_,t.offset,y)}`;switch(this.getAtributeState(u)){case 0:{const e=this._getType(_),o=`u_${t}`;i.push({name:o,type:e,getValue:(t,e,n,o)=>{const s=f?t.getLayoutValue(h,e):t.getPaintValue(h,e);if(11===a){const n=t.getDashKey(s,t.getLayoutValue("line-cap",e)),r=o.getMosaicItemPosition(n,!1);if(null==r)return null;const{tl:i,br:a}=r;return[i[0],a[1],a[0],i[1]]}if(12===a){const t=o.getMosaicItemPosition(s,!h.includes("line-"));if(null==t)return null;const{tl:e,br:n}=t;return[e[0],n[1],n[0],e[1]]}if(10===a){const t=s[3];return[t*s[0],t*s[1],t*s[2],t]}return s}}),n+=`uniform ${e} ${o};\n`,s+=`${e} ${t} = ${o};\n`}break;case 1:{const n=m(e[h][0]);s+=`${this._getType(_)} ${t} = ${n}${d};\n`}break;case 2:{const o=`u_t_${t}`;i.push({name:o,type:"float",getValue:(t,e,n,o)=>(f?t.getLayoutProperty(h):t.getPaintProperty(h)).interpolator.interpolationUniformValue(n,e)}),n+=`uniform float ${o};\n`;const r=m(e[h][0]),a=m(e[h][1]);s+=`${this._getType(_)} ${t} = mix(${r}${d}, ${a}${d}, ${o});\n`}}}this._shaderHeader=n,this._shaderMain=s,this._uniforms=i}_bit(t){return(this._key&1<<t)>>t}_getType(t){switch(t){case 1:return"float";case 2:return"vec2";case 3:return"vec3";case 4:return"vec4"}throw new Error("Invalid count")}_encodeColor(e){const n=255*e[3];return t.i8888to32(e[0]*n,e[1]*n,e[2]*n,n)}_encodePattern(t,e,n){if(!n?.rect)return;const o=2,s=n.rect,r=n.width,i=n.height;e[t]=this._encodeShort(s.x+o,0),e[t]|=this._encodeShort(s.y+o+i,16),e[t+1]=this._encodeShort(s.x+o+r,0),e[t+1]|=this._encodeShort(s.y+o,16)}_encodeByte(t,e){return(255&t)<<e}_encodeShort(t,e){return(65535&t)<<e}}const s=t=>{switch(t){case e.FLOAT:case e.INT:case e.UNSIGNED_INT:return 4;case e.SHORT:case e.UNSIGNED_SHORT:case e.HALF_FLOAT:return 2;case e.BYTE:case e.UNSIGNED_BYTE:return 1}},r=(t,e,n)=>{const o=e/n;if(1===t)switch(o){case 0:return".x";case 1:return".y";case 2:return".z";case 3:return".w"}else if(2===t)switch(o){case 0:return".xy";case 1:return".yz";case 2:return".zw"}else if(3===t)switch(o){case 0:return".xyz";case 1:return".yzw"}return""};export{o as VTLMaterial};
5
+ import t from"../MemoryBuffer.js";import{DataType as e}from"../../../../webgl/enums.js";import{VertexElementDescriptor as n}from"../../../../webgl/VertexElementDescriptor.js";class o{constructor(t){this._locations=new Map,this._key=t}get key(){return this._key}get type(){return 7&this._key}defines(){return[]}getStride(){return this._layout||this._buildAttributesInfo(),this._stride}getAttributeLocations(){return 0===this._locations.size&&this._buildAttributesInfo(),this._locations}getLayoutInfo(){return this._layout||this._buildAttributesInfo(),this._layout}getEncodingInfos(){return this._propertyEncodingInfo||this._buildAttributesInfo(),this._propertyEncodingInfo}getUniforms(){return this._uniforms||this._buildAttributesInfo(),this._uniforms}getShaderHeader(){return this._shaderHeader||this._buildAttributesInfo(),this._shaderHeader}getShaderMain(){return this._shaderMain||this._buildAttributesInfo(),this._shaderMain}setDataUniforms(t,e,n,o,s){const r=this.getUniforms();for(const a of r){const{name:r,type:i,getValue:c}=a,u=c(n,e,o,s);if(null!==u)switch(i){case"float":t.setUniform1f(r,u);break;case"vec2":t.setUniform2fv(r,u);break;case"vec4":t.setUniform4fv(r,u)}}}encodeAttributes(t,e,n,o){const s=this.attributesInfo,r=this.getEncodingInfos(),a=[];let i=0,c=0;for(const u of Object.keys(r)){const h=r[u],{type:l,precisionFactor:d,isLayout:f}=s[u],y=f?n.getLayoutProperty(u):n.getPaintProperty(u),_=y.interpolator?.getInterpolationRange(e);let m=0;for(const n of h){const{offset:s,bufferElementsToAdd:r}=n;if(r>0){for(let t=0;t<r;t++)a.push(0);i+=c,c=n.bufferElementsToAdd}const u=o??y.getValue(_?_[m]:e,t);switch(l){case 0:case 1:a[i]|=this._encodeByte(u*(d||1),8*s);break;case 2:case 3:a[i]|=this._encodeShort(u*(d||1),8*s);break;case 4:case 5:a[i]|=this._encodeByte(u*(d||1),8*s),a[i]|=this._encodeByte(u*(d||1),8*s+8);break;case 6:case 7:a[i]|=this._encodeShort(u*(d||1),8*s),a[i]|=this._encodeShort(u*(d||1),8*s+16);break;case 8:case 9:a[i]|=this._encodeByte(u*(d||1),8*s),a[i]|=this._encodeByte(u*(d||1),8*s+8),a[i]|=this._encodeByte(u*(d||1),8*s+16),a[i]|=this._encodeByte(u*(d||1),8*s+24);break;case 10:a[i]=this._encodeColor(u);break;case 11:case 12:this._encodePattern(i,a,u);break;default:throw new Error("Unsupported encoding type")}m++}}return a}getAtributeState(t){let e=0;const n=3+2*t;return e|=this._bit(n),e|=this._bit(n+1)<<1,e}static{this._encodingInfo={0:{dataType:e.BYTE,bytesPerElement:1,count:1,normalized:!1},1:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:1,normalized:!1},2:{dataType:e.SHORT,bytesPerElement:2,count:1,normalized:!1},3:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:1,normalized:!1},4:{dataType:e.BYTE,bytesPerElement:1,count:2,normalized:!1},5:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:2,normalized:!1},6:{dataType:e.SHORT,bytesPerElement:2,count:2,normalized:!1},7:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:2,normalized:!1},8:{dataType:e.BYTE,bytesPerElement:1,count:4,normalized:!1},9:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:4,normalized:!1},10:{dataType:e.UNSIGNED_BYTE,bytesPerElement:1,count:4,normalized:!0},11:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:4,normalized:!1},12:{dataType:e.UNSIGNED_SHORT,bytesPerElement:2,count:4,normalized:!1}}}_buildAttributesInfo(){const t=[],n={},{attributesInfo:s,attributes:r}=this,a={};let i=-1,c=-1;for(const e of r){c++;const r=this.getAtributeState(c);if(0===r||3===r)continue;const u=s[e],h=[];n[e]=h;const l=u.type;for(let e=0;e<r;e++){const{dataType:e,bytesPerElement:n,count:s,normalized:r}=o._encodingInfo[l],c=n*s,u=`${e}-${!0===r}`;let d=a[u],f=0;if(!d||d.count+s>4)i++,d={dataIndex:i,count:0,offset:0},4!==s&&(a[u]=d),t.push({location:-1,name:"a_data_"+i,count:s,type:e,normalized:r}),f=Math.ceil(Math.max(c/4,1));else{const e=t[d.dataIndex];e.count+=s;f=Math.ceil(Math.max(e.count*n/4,1))-Math.ceil(Math.max(d.offset/4,1))}h.push({dataIndex:d.dataIndex,offset:d.offset,bufferElementsToAdd:f}),d.offset+=c,d.count+=s}}for(const o of t)switch(o.type){case e.BYTE:case e.UNSIGNED_BYTE:o.count=4;break;case e.SHORT:case e.UNSIGNED_SHORT:o.count+=o.count%2}this._buildVertexBufferLayout(t);let u=0;const h=this._layout.get("geometry");for(const e of h)this._locations.set(e.name,u++);const l=this._layout.get("opacity");if(l)for(const e of l)this._locations.set(e.name,u++);this._buildShaderInfo(t,n),this._propertyEncodingInfo=n}_buildVertexBufferLayout(t){const e=new Map,o=this.baseGeometryLayout;let r=o[0].stride;if(0===t.length)e.set("geometry",o);else{const a=[];let i=r;for(const e of t)r+=s(e.type)*e.count;for(const t of o)a.push(new n(t.name,t.count,t.type,t.offset,r,t.normalized));for(const e of t)a.push(new n(e.name,e.count,e.type,i,r,e.normalized)),i+=s(e.type)*e.count;e.set("geometry",a)}this.opacityLayout&&e.set("opacity",this.opacityLayout),this._layout=e,this._stride=r}_buildShaderInfo(t,e){let n="\n",s="\n";const a=[];for(const o of t)n+=`attribute ${this._getType(o.count)} ${o.name};\n`;const{attributesInfo:i,attributes:c}=this;let u=-1;for(const h of c){u++;const{name:t,type:c,precisionFactor:l,isLayout:d}=i[h],f=l&&1!==l?" * "+1/l:"",{bytesPerElement:y,count:_}=o._encodingInfo[c],m=t=>`a_data_${t.dataIndex}${r(_,t.offset,y)}`;switch(this.getAtributeState(u)){case 0:{const e=this._getType(_),o=`u_${t}`;a.push({name:o,type:e,getValue:(t,e,n,o)=>{const s=d?t.getLayoutValue(h,e):t.getPaintValue(h,e);if(11===c){const n=t.getDashKey(s,t.getLayoutValue("line-cap",e)),r=o.getMosaicItemPosition(n,!1);if(null==r)return null;const{tl:a,br:i}=r;return[a[0],i[1],i[0],a[1]]}if(12===c){const t=o.getMosaicItemPosition(s,!h.includes("line-"));if(null==t)return null;const{tl:e,br:n}=t;return[e[0],n[1],n[0],e[1]]}if(10===c){const t=s[3];return[t*s[0],t*s[1],t*s[2],t]}return s}}),n+=`uniform ${e} ${o};\n`,s+=`${e} ${t} = ${o};\n`}break;case 1:{const n=m(e[h][0]);s+=`${this._getType(_)} ${t} = ${n}${f};\n`}break;case 2:{const o=`u_t_${t}`;a.push({name:o,type:"float",getValue:(t,e,n,o)=>(d?t.getLayoutProperty(h):t.getPaintProperty(h)).interpolator.interpolationUniformValue(n,e)}),n+=`uniform float ${o};\n`;const r=m(e[h][0]),i=m(e[h][1]);s+=`${this._getType(_)} ${t} = mix(${r}${f}, ${i}${f}, ${o});\n`}}}this._shaderHeader=n,this._shaderMain=s,this._uniforms=a}_bit(t){return(this._key&1<<t)>>t}_getType(t){switch(t){case 1:return"float";case 2:return"vec2";case 3:return"vec3";case 4:return"vec4"}throw new Error("Invalid count")}_encodeColor(e){const n=255*e[3];return t.i8888to32(e[0]*n,e[1]*n,e[2]*n,n)}_encodePattern(t,e,n){if(!n?.rect)return;const o=2,s=n.rect,r=n.width,a=n.height;e[t]=this._encodeShort(s.x+o,0),e[t]|=this._encodeShort(s.y+o+a,16),e[t+1]=this._encodeShort(s.x+o+r,0),e[t+1]|=this._encodeShort(s.y+o,16)}_encodeByte(t,e){return(255&t)<<e}_encodeShort(t,e){return(65535&t)<<e}}const s=t=>{switch(t){case e.FLOAT:case e.INT:case e.UNSIGNED_INT:return 4;case e.SHORT:case e.UNSIGNED_SHORT:case e.HALF_FLOAT:return 2;case e.BYTE:case e.UNSIGNED_BYTE:return 1}},r=(t,e,n)=>{const o=e/n;if(1===t)switch(o){case 0:return".x";case 1:return".y";case 2:return".z";case 3:return".w"}else if(2===t)switch(o){case 0:return".xy";case 1:return".yz";case 2:return".zw"}else if(3===t)switch(o){case 0:return".xyz";case 1:return".yzw"}return""};export{o as VTLMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as o}from"../../../../webgl/enums.js";import{VertexElementDescriptor as e}from"../../../../webgl/VertexElementDescriptor.js";const r=[new e("a_pos",2,o.SHORT,0,16),new e("a_vertexOffset",2,o.SHORT,4,16),new e("a_texAngleRange",4,o.UNSIGNED_BYTE,8,16),new e("a_levelInfo",4,o.UNSIGNED_BYTE,12,16)],a=[new e("a_opacityInfo",1,o.UNSIGNED_BYTE,0,1)];class i extends t{static{this.ATTRIBUTES=["icon-color","icon-opacity","icon-halo-blur","icon-halo-color","icon-halo-width","icon-size"]}static{this.ATTRIBUTES_INFO={"icon-color":{name:"color",type:10},"icon-opacity":{name:"opacity",type:1,precisionFactor:100},"icon-halo-color":{name:"halo_color",type:10},"icon-halo-width":{name:"halo_width",type:1,precisionFactor:4},"icon-halo-blur":{name:"halo_blur",type:1,precisionFactor:4},"icon-size":{name:"size",type:1,precisionFactor:32,isLayout:!0}}}constructor(t){super(t)}geometryInfo(){return r}opacityInfo(){return a}attributes(){return i.ATTRIBUTES}attributesInfo(){return i.ATTRIBUTES_INFO}}class n extends t{static{this.ATTRIBUTES=["text-color","text-opacity","text-halo-blur","text-halo-color","text-halo-width","text-size"]}static{this.ATTRIBUTES_INFO={"text-color":{name:"color",type:10},"text-opacity":{name:"opacity",type:1,precisionFactor:100},"text-halo-color":{name:"halo_color",type:10},"text-halo-width":{name:"halo_width",type:1,precisionFactor:4},"text-halo-blur":{name:"halo_blur",type:1,precisionFactor:4},"text-size":{name:"size",type:1,isLayout:!0}}}constructor(t){super(t)}geometryInfo(){return r}opacityInfo(){return a}attributes(){return n.ATTRIBUTES}attributesInfo(){return n.ATTRIBUTES_INFO}}export{i as VTLIconMaterial,n as VTLTextMaterial};
5
+ import{VTLMaterial as t}from"./VTLMaterial.js";import{DataType as o}from"../../../../webgl/enums.js";import{VertexElementDescriptor as e}from"../../../../webgl/VertexElementDescriptor.js";const i=[new e("a_pos",2,o.SHORT,0,16),new e("a_vertexOffset",2,o.SHORT,4,16),new e("a_texAngleRange",4,o.UNSIGNED_BYTE,8,16),new e("a_levelInfo",4,o.UNSIGNED_BYTE,12,16)],a=[new e("a_opacityInfo",1,o.UNSIGNED_BYTE,0,1)];class c extends t{static{this.ATTRIBUTES=["icon-color","icon-opacity","icon-halo-blur","icon-halo-color","icon-halo-width","icon-size"]}static{this.ATTRIBUTES_INFO={"icon-color":{name:"color",type:10},"icon-opacity":{name:"opacity",type:1,precisionFactor:100},"icon-halo-color":{name:"halo_color",type:10},"icon-halo-width":{name:"halo_width",type:1,precisionFactor:4},"icon-halo-blur":{name:"halo_blur",type:1,precisionFactor:4},"icon-size":{name:"size",type:1,precisionFactor:32,isLayout:!0}}}constructor(t){super(t),this.baseGeometryLayout=i,this.opacityLayout=a,this.attributes=c.ATTRIBUTES,this.attributesInfo=c.ATTRIBUTES_INFO}}class r extends t{static{this.ATTRIBUTES=["text-color","text-opacity","text-halo-blur","text-halo-color","text-halo-width","text-size"]}static{this.ATTRIBUTES_INFO={"text-color":{name:"color",type:10},"text-opacity":{name:"opacity",type:1,precisionFactor:100},"text-halo-color":{name:"halo_color",type:10},"text-halo-width":{name:"halo_width",type:1,precisionFactor:4},"text-halo-blur":{name:"halo_blur",type:1,precisionFactor:4},"text-size":{name:"size",type:1,isLayout:!0}}}constructor(t){super(t),this.baseGeometryLayout=i,this.opacityLayout=a,this.attributes=r.ATTRIBUTES,this.attributesInfo=r.ATTRIBUTES_INFO}}export{c as VTLIconMaterial,r as VTLTextMaterial};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../../core/CircularArray.js";import t from"../../../../core/Evented.js";import has from"../../../../core/has.js";import{createDisjointTimerQuery as s}from"../../../webgl/capabilities/DisjointTimerQuery.js";const r=!!has("esri-2d-profiler");class n{constructor(n,i){if(this._events=new t.EventEmitter,this._entries=new Map,this._timings=new e(10),this._currentContainer=null,this._currentPass=null,this._currentBrush=null,this._currentSummary=null,!r)return;this._ext=s(n.gl,{}),this._debugOutput=i;const o=n.gl;if(!this.enableCommandLogging)return;let a;for(a in o)if("function"==typeof o[a]){const e=o[a],t=a.includes("draw");o[a]=(...s)=>(this._events.emit("command",{container:this._currentContainer,pass:this._currentPass,brush:this._currentBrush,method:a,args:s,isDrawCommand:t}),this._currentSummary&&(this._currentSummary.commands++,t&&this._currentSummary.drawCommands++),e.apply(o,s))}}get enableCommandLogging(){return!("object"==typeof r&&r.disableCommands)}recordContainerStart(e){r&&(this._currentContainer=e)}recordContainerEnd(){r&&(this._currentContainer=null)}recordPassStart(e){r&&(this._currentPass=e,this._initSummary())}recordPassEnd(){r&&(this._currentPass=null,this._emitSummary())}recordBrushStart(e){r&&(this._currentBrush=e)}recordBrushEnd(){r&&(this._currentBrush=null)}recordStart(e){if(r&&null!=this._ext){if(this._entries.has(e)){const t=this._entries.get(e),s=this._ext.resultAvailable(t.query),r=this._ext.disjoint();if(s&&!r){const s=this._ext.getResult(t.query)/1e6;let r=0;if(null!=this._timings.enqueue(s)){const e=this._timings.entries,t=e.length;let s=0;for(const r of e)s+=r;r=s/t}const n=s.toFixed(2),i=r?r.toFixed(2):"--";this.enableCommandLogging?(console.groupCollapsed(`Frame report for ${e}, ${n} ms (${i} last 10 avg)\n${t.commandsLen} Commands (${t.drawCommands} draw)`),console.log("RenderPass breakdown: "),console.table(t.summaries),console.log("Commands: ",t.commands),console.groupEnd()):console.log(`Frame report for ${e}, ${n} ms (${i} last 10 avg)`),this._debugOutput.innerHTML=`${n} (${i})`}for(const e of t.handles)e.remove();this._ext.deleteQuery(t.query),this._entries.delete(e)}const t={name:e,query:this._ext.createQuery(),commands:[],commandsLen:0,drawCommands:0,summaries:[],handles:[]};this.enableCommandLogging&&(t.handles.push(this._events.on("command",e=>{t.commandsLen++,t.commands.push(e),e.isDrawCommand&&t.drawCommands++})),t.handles.push(this._events.on("summary",e=>{t.summaries.push(e)}))),this._ext.beginTimeElapsed(t.query),this._entries.set(e,t)}}recordEnd(e){r&&null!=this._ext&&this._entries.has(e)&&this._ext.endTimeElapsed()}_initSummary(){this.enableCommandLogging&&(this._currentSummary={container:this._currentContainer,pass:this._currentPass,drawCommands:0,commands:0})}_emitSummary(){this.enableCommandLogging&&this._currentSummary&&this._events.emit("summary",this._currentSummary)}}export{n as Profiler};
5
+ import e from"../../../../core/CircularArray.js";import{EventEmitter as t}from"../../../../core/Evented.js";import has from"../../../../core/has.js";import{createDisjointTimerQuery as s}from"../../../webgl/capabilities/DisjointTimerQuery.js";const r=!!has("esri-2d-profiler");class n{constructor(n,i){if(this._events=new t,this._entries=new Map,this._timings=new e(10),this._currentContainer=null,this._currentPass=null,this._currentBrush=null,this._currentSummary=null,!r)return;this._ext=s(n.gl,{}),this._debugOutput=i;const o=n.gl;if(!this.enableCommandLogging)return;let a;for(a in o)if("function"==typeof o[a]){const e=o[a],t=a.includes("draw");o[a]=(...s)=>(this._events.emit("command",{container:this._currentContainer,pass:this._currentPass,brush:this._currentBrush,method:a,args:s,isDrawCommand:t}),this._currentSummary&&(this._currentSummary.commands++,t&&this._currentSummary.drawCommands++),e.apply(o,s))}}get enableCommandLogging(){return!("object"==typeof r&&r.disableCommands)}recordContainerStart(e){r&&(this._currentContainer=e)}recordContainerEnd(){r&&(this._currentContainer=null)}recordPassStart(e){r&&(this._currentPass=e,this._initSummary())}recordPassEnd(){r&&(this._currentPass=null,this._emitSummary())}recordBrushStart(e){r&&(this._currentBrush=e)}recordBrushEnd(){r&&(this._currentBrush=null)}recordStart(e){if(r&&null!=this._ext){if(this._entries.has(e)){const t=this._entries.get(e),s=this._ext.resultAvailable(t.query),r=this._ext.disjoint();if(s&&!r){const s=this._ext.getResult(t.query)/1e6;let r=0;if(null!=this._timings.enqueue(s)){const e=this._timings.entries,t=e.length;let s=0;for(const r of e)s+=r;r=s/t}const n=s.toFixed(2),i=r?r.toFixed(2):"--";this.enableCommandLogging?(console.groupCollapsed(`Frame report for ${e}, ${n} ms (${i} last 10 avg)\n${t.commandsLen} Commands (${t.drawCommands} draw)`),console.log("RenderPass breakdown: "),console.table(t.summaries),console.log("Commands: ",t.commands),console.groupEnd()):console.log(`Frame report for ${e}, ${n} ms (${i} last 10 avg)`),this._debugOutput.innerHTML=`${n} (${i})`}for(const e of t.handles)e.remove();this._ext.deleteQuery(t.query),this._entries.delete(e)}const t={name:e,query:this._ext.createQuery(),commands:[],commandsLen:0,drawCommands:0,summaries:[],handles:[]};this.enableCommandLogging&&(t.handles.push(this._events.on("command",e=>{t.commandsLen++,t.commands.push(e),e.isDrawCommand&&t.drawCommands++})),t.handles.push(this._events.on("summary",e=>{t.summaries.push(e)}))),this._ext.beginTimeElapsed(t.query),this._entries.set(e,t)}}recordEnd(e){r&&null!=this._ext&&this._entries.has(e)&&this._ext.endTimeElapsed()}_initSummary(){this.enableCommandLogging&&(this._currentSummary={container:this._currentContainer,pass:this._currentPass,drawCommands:0,commands:0})}_emitSummary(){this.enableCommandLogging&&this._currentSummary&&this._events.emit("summary",this._currentSummary)}}export{n as Profiler};