@arcgis/core 4.24.0-next.20220508 → 4.24.0-next.20220511

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 (338) hide show
  1. package/AggregateGraphic.js +1 -1
  2. package/analysis/Analysis.js +1 -1
  3. package/analysis/DimensioningAnalysis.js +1 -1
  4. package/analysis/LengthDimension.d.ts +4 -0
  5. package/analysis/LengthDimension.js +5 -0
  6. package/analysis/dimensionUtils.js +5 -0
  7. package/arcade/Dictionary.js +1 -1
  8. package/arcade/Feature.js +1 -1
  9. package/arcade/arcade.js +1 -1
  10. package/arcade/arcadeAsyncRuntime.js +1 -1
  11. package/arcade/arcadeCompiler.js +1 -1
  12. package/arcade/credentials.js +1 -1
  13. package/arcade/featureSetCollection.js +1 -1
  14. package/arcade/featureSetUtils.js +1 -1
  15. package/arcade/featureset/actions/Adapted.js +1 -1
  16. package/arcade/featureset/actions/AttributeFilter.js +1 -1
  17. package/arcade/featureset/actions/GroupBy.js +1 -1
  18. package/arcade/featureset/actions/OrderBy.js +1 -1
  19. package/arcade/featureset/actions/SpatialFilter.js +1 -1
  20. package/arcade/featureset/actions/Top.js +1 -1
  21. package/arcade/featureset/sources/Empty.js +1 -1
  22. package/arcade/featureset/sources/FeatureLayerDynamic.js +1 -1
  23. package/arcade/featureset/sources/FeatureLayerMemory.js +1 -1
  24. package/arcade/featureset/sources/FeatureLayerRelated.js +1 -1
  25. package/arcade/featureset/support/FeatureSet.js +1 -1
  26. package/arcade/featureset/support/FeatureSetIterator.js +1 -1
  27. package/arcade/featureset/support/shared.js +1 -1
  28. package/arcade/featureset/support/stats.js +1 -1
  29. package/arcade/functions/featuresetbase.js +1 -1
  30. package/arcade/functions/featuresetgeom.js +1 -1
  31. package/arcade/functions/featuresetstats.js +1 -1
  32. package/arcade/functions/featuresetstring.js +1 -1
  33. package/arcade/functions/geomasync.js +1 -1
  34. package/arcade/languageUtils.js +1 -1
  35. package/arcade/request.js +1 -1
  36. package/assets/esri/core/workers/RemoteClient.js +1 -1
  37. package/assets/esri/core/workers/chunks/0564f1cfa3d17ff1aad3.js +1 -0
  38. package/assets/esri/core/workers/chunks/0806d5d706a864542bfb.js +1 -0
  39. package/assets/esri/core/workers/chunks/0a6977144ea1abf96fbf.js +1 -0
  40. package/assets/esri/core/workers/chunks/13387f56acbc3291561a.js +1 -0
  41. package/assets/esri/core/workers/chunks/16c4e0a32d50d4db984d.js +1 -0
  42. package/assets/esri/core/workers/chunks/{076d1b1101b59af0d389.js → 1c010202b4c7e1d15f23.js} +1 -1
  43. package/assets/esri/core/workers/chunks/26827ec144676e6385f8.js +1 -0
  44. package/assets/esri/core/workers/chunks/287c484fd40eee643f3a.js +1 -0
  45. package/assets/esri/core/workers/chunks/5210f0b42dba27945226.js +1 -0
  46. package/assets/esri/core/workers/chunks/{db6c5b3b4efe8d804f9c.js → 52478ee2d2a1354b6900.js} +1 -1
  47. package/assets/esri/core/workers/chunks/5759af97f96f24c40105.js +1 -0
  48. package/assets/esri/core/workers/chunks/{b85218d44c6094b7e5e6.js → 6d7e2a23a0a5dd9ded1d.js} +1 -1
  49. package/assets/esri/core/workers/chunks/70b6356357e7640c4e8b.js +1 -0
  50. package/assets/esri/core/workers/chunks/7574316b3af61c389e8f.js +1 -0
  51. package/assets/esri/core/workers/chunks/7bc828fbdd54c0b28aac.js +1 -0
  52. package/assets/esri/core/workers/chunks/7e5c22b5a32ac74b1b6e.js +1 -0
  53. package/assets/esri/core/workers/chunks/8102bb78fe96e6197e4e.js +1 -0
  54. package/assets/esri/core/workers/chunks/88384e7cafbfd2348598.js +1 -0
  55. package/assets/esri/core/workers/chunks/9d7533aaeac3b8d145c4.js +1 -0
  56. package/assets/esri/core/workers/chunks/{1eecae5227318f491263.js → 9f4d892abf55e8625bc9.js} +3 -3
  57. package/assets/esri/core/workers/chunks/{98607a0da63626cc4614.js → a054a52712a118c6d505.js} +1 -1
  58. package/assets/esri/core/workers/chunks/{69a20e4d9e28c3e599fc.js → a3bb600bfcb0282622f1.js} +1 -1
  59. package/assets/esri/core/workers/chunks/aa49841b14c6e6df2a07.js +1 -0
  60. package/assets/esri/core/workers/chunks/b089058b64db3912478f.js +1 -0
  61. package/assets/esri/core/workers/chunks/b28539c5a6bedb71b038.js +1 -0
  62. package/assets/esri/core/workers/chunks/b4f171db73355c6f766e.js +1 -0
  63. package/assets/esri/core/workers/chunks/b7572b0921b23aef8b9d.js +1 -0
  64. package/assets/esri/core/workers/chunks/b758f3c419edc2306784.js +1 -0
  65. package/assets/esri/core/workers/chunks/c3e7290fb128d4fefd44.js +1 -0
  66. package/assets/esri/core/workers/chunks/c51c9b5da855f84b9a48.js +1 -0
  67. package/assets/esri/core/workers/chunks/c66ac36da6392b6bf331.js +1 -0
  68. package/assets/esri/core/workers/chunks/d16b328d32a6ddc2fdb9.js +1 -0
  69. package/assets/esri/core/workers/chunks/d94c5f36d52cf71f0bb9.js +1 -0
  70. package/assets/esri/core/workers/chunks/db937849b2c1af87b481.js +1 -0
  71. package/assets/esri/core/workers/chunks/{66cd99e91dad60c5274c.js → dc3ed59f450283d97a19.js} +1 -1
  72. package/assets/esri/core/workers/chunks/dcd0653191cd4a1ccaae.js +2 -0
  73. package/assets/esri/core/workers/chunks/{31df729c17470245288c.js.LICENSE.txt → dcd0653191cd4a1ccaae.js.LICENSE.txt} +2 -2
  74. package/assets/esri/core/workers/chunks/e4fdd1eaf987977d0a51.js +1 -0
  75. package/assets/esri/core/workers/chunks/e51f0e71f2a55af604d3.js +1 -0
  76. package/assets/esri/core/workers/chunks/eb3855d3753d6b8334bd.js +1 -0
  77. package/assets/esri/core/workers/chunks/{7c290763920f52a1f504.js → eeed138930a4a805691d.js} +1 -1
  78. package/assets/esri/core/workers/chunks/f435dc615fdc8917f6ca.js +1 -0
  79. package/assets/esri/core/workers/chunks/{d5c5b9f7f5401f36a3a5.js → f7f3dde4c8f9c687cc1e.js} +1 -1
  80. package/assets/esri/core/workers/chunks/fc6beaf9466ea3898549.js +1 -0
  81. package/assets/esri/libs/vxl/vxlLayer.wasm +0 -0
  82. package/assets/esri/themes/base/widgets/_Tooltip.scss +1 -0
  83. package/assets/esri/themes/base/widgets/_Weather.scss +1 -2
  84. package/assets/esri/themes/dark/main.css +1 -1
  85. package/assets/esri/themes/light/main.css +1 -1
  86. package/assets/esri/themes/light/view.css +1 -1
  87. package/chunks/BlendLayers.glsl.js +6 -6
  88. package/chunks/arcade.js +1 -1
  89. package/chunks/array.js +1 -1
  90. package/chunks/languageUtils.js +1 -1
  91. package/config.js +1 -1
  92. package/core/sql/StandardizedFunctions.js +1 -1
  93. package/geohash/GeohashTree.js +1 -1
  94. package/geometry/support/contains.js +1 -1
  95. package/geometry/support/heightModelInfoUtils.js +1 -1
  96. package/geometry/support/intersects.js +1 -1
  97. package/geometry/support/intersectsBase.js +1 -1
  98. package/geometry/support/normalizeUtilsCommon.js +1 -1
  99. package/geometry/support/spatialReferenceUtils.js +1 -1
  100. package/interfaces.d.ts +685 -37
  101. package/layers/MediaLayer.d.ts +4 -0
  102. package/layers/MediaLayer.js +5 -0
  103. package/layers/VoxelLayer.js +1 -1
  104. package/layers/VoxelWasmPerSceneView.js +5 -0
  105. package/layers/graphics/OptimizedGeometry.js +1 -1
  106. package/layers/graphics/data/BoundsStore.js +1 -1
  107. package/layers/support/CornersGeoreference.d.ts +4 -0
  108. package/layers/support/CornersGeoreference.js +5 -0
  109. package/layers/support/ExtentAndRotationGeoreference.d.ts +4 -0
  110. package/layers/support/ExtentAndRotationGeoreference.js +5 -0
  111. package/layers/support/FeatureReduction.js +1 -1
  112. package/layers/support/FeatureReductionBinning.js +5 -0
  113. package/layers/support/GeoreferenceBase.js +5 -0
  114. package/layers/support/ImageElement.d.ts +4 -0
  115. package/layers/support/ImageElement.js +5 -0
  116. package/layers/support/LocalMediaElementSource.d.ts +4 -0
  117. package/layers/support/LocalMediaElementSource.js +5 -0
  118. package/layers/support/MediaElementBase.d.ts +4 -0
  119. package/layers/support/MediaElementBase.js +5 -0
  120. package/layers/support/RouteStopSymbols.d.ts +4 -0
  121. package/layers/support/RouteSymbols.d.ts +4 -0
  122. package/layers/support/VoxelFormat.d.ts +4 -0
  123. package/layers/support/VoxelStyle.d.ts +4 -0
  124. package/layers/support/VoxelVariable.d.ts +4 -0
  125. package/layers/support/VoxelVolume.d.ts +4 -0
  126. package/layers/support/VoxelVolumeStyle.d.ts +4 -0
  127. package/layers/support/arcgisLayerUrl.js +1 -1
  128. package/layers/support/featureReductionUtils.js +1 -1
  129. package/layers/support/fieldUtils.js +1 -1
  130. package/layers/support/rasterFormats/Lerc.js +1 -1
  131. package/package.json +3 -3
  132. package/request.js +1 -1
  133. package/support/requestUtils.js +1 -1
  134. package/support/revision.js +1 -1
  135. package/symbols/Font.js +1 -1
  136. package/symbols/support/textUtils.js +1 -1
  137. package/views/2d/engine/brushes.js +1 -1
  138. package/views/2d/engine/webgl/FeatureTile.js +1 -1
  139. package/views/2d/engine/webgl/Overlay.js +5 -0
  140. package/views/2d/engine/webgl/OverlayContainer.js +5 -0
  141. package/views/2d/engine/webgl/brushes/BrushOverlay.js +5 -0
  142. package/views/2d/engine/webgl/collisions/CollisionEngine.js +1 -1
  143. package/views/2d/engine/webgl/shaders/OverlayPrograms.js +5 -0
  144. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  145. package/views/2d/layerViewModuleImportUtils.js +1 -1
  146. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  147. package/views/2d/layers/ImageryTileLayerView2D.js +1 -1
  148. package/views/2d/layers/MapImageLayerView2D.js +1 -1
  149. package/views/2d/layers/MediaLayerView2D.js +5 -0
  150. package/views/2d/layers/StreamLayerView2D.js +1 -1
  151. package/views/2d/layers/WMTSLayerView2D.js +1 -1
  152. package/views/2d/layers/features/FeatureStore2D.js +1 -1
  153. package/views/2d/layers/features/Pipeline.js +1 -1
  154. package/views/2d/layers/features/Store2D.js +1 -1
  155. package/views/2d/layers/features/controllers/FeatureController2D.js +1 -1
  156. package/views/2d/layers/features/processors/SymbolProcessor.js +1 -1
  157. package/views/2d/layers/features/schemaUtils.js +1 -1
  158. package/views/2d/layers/features/sources/GeoEventSource.js +1 -1
  159. package/views/2d/layers/features/support/AttributeStore.js +1 -1
  160. package/views/2d/layers/features/support/BinStore.js +5 -0
  161. package/views/2d/layers/features/support/ClusterStore.js +1 -1
  162. package/views/2d/layers/features/tileRenderers/support/WGLFeatureView.js +1 -1
  163. package/views/2d/layers/graphics/GraphicsView2D.js +1 -1
  164. package/views/2d/layers/support/clusterUtils.js +1 -1
  165. package/views/2d/magnifier/MagnifierView2D.js +1 -1
  166. package/views/2d/navigation/actions/Pinch.js +1 -1
  167. package/views/2d/viewpointUtils.js +1 -1
  168. package/views/3d/analysis/AnalysisView3D.js +1 -1
  169. package/views/3d/analysis/Dimensioning/DimensioningTool.js +5 -0
  170. package/views/3d/analysis/Dimensioning/DimensioningVisualization.js +1 -1
  171. package/views/3d/analysis/Dimensioning/LengthDimensionSubTool.js +5 -0
  172. package/views/3d/analysis/Dimensioning/{LinearDimensionVisualization.js → LengthDimensionVisualization.js} +1 -1
  173. package/views/3d/analysis/Dimensioning/settings.js +5 -0
  174. package/views/3d/analysis/LineOfSight/LineOfSightTool.js +1 -1
  175. package/views/3d/analysis/Slice/sliceToolUtils.js +1 -1
  176. package/views/3d/interactive/SegmentLabels3D.js +5 -0
  177. package/views/3d/interactive/SnappingVisualizer3D.js +1 -1
  178. package/views/3d/interactive/editingTools/draw/DrawGraphicTool3D.js +1 -1
  179. package/views/3d/interactive/editingTools/reshapeGraphic/GraphicReshapeTool.js +1 -1
  180. package/views/3d/interactive/editingTools/reshapeGraphic/ReshapeOperation.js +1 -1
  181. package/views/3d/interactive/editingTools/transformGraphic/GraphicTransformTool.js +1 -1
  182. package/views/3d/interactive/editingTools/transformGraphic/ScaleRotateObjectSymbol3DAdapter.js +1 -1
  183. package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DView.js +1 -1
  184. package/views/3d/interactive/visualElements/LabelVisualElement.js +1 -1
  185. package/views/3d/layerViewModuleImportUtils.js +1 -1
  186. package/views/3d/layers/I3SMeshView3D.js +1 -1
  187. package/views/3d/layers/MediaLayerView3D.js +5 -0
  188. package/views/3d/layers/VoxelLayerView3D.js +1 -1
  189. package/views/3d/layers/i3s/IDBCache.js +1 -1
  190. package/views/3d/state/controllers/RotateController.js +1 -1
  191. package/views/3d/state/controllers/local/PinchAndPanController.js +1 -1
  192. package/views/3d/state/controllers/local/ZoomController.js +1 -1
  193. package/views/3d/state/controllers/local/ZoomStepController.js +1 -1
  194. package/views/3d/support/ResourceController.js +1 -1
  195. package/views/3d/support/sunUtils.js +1 -1
  196. package/views/3d/terrain/TerrainRenderer.js +1 -1
  197. package/views/3d/terrain/TerrainSurface.js +1 -1
  198. package/views/3d/terrain/TileCompositor.js +1 -1
  199. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  200. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechniqueConfiguration.js +1 -1
  201. package/views/3d/webgl-engine/core/shaderLibrary/util/BlendLayers.glsl.js +1 -1
  202. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  203. package/views/3d/webgl-engine/materials/WaterGLMaterial.js +1 -1
  204. package/views/3d/webgl-engine/materials/WaterMaterial.js +1 -1
  205. package/views/3d/webgl-engine/materials/WaterTechnique.js +1 -1
  206. package/views/3d/webgl-engine/shaders/TerrainTechniqueConfiguration.js +1 -1
  207. package/views/DOMContainer.js +1 -1
  208. package/views/GroundView.js +1 -1
  209. package/views/SceneView.js +1 -1
  210. package/views/ToolViewManager.js +1 -1
  211. package/views/View.js +1 -1
  212. package/views/draw/DrawOperation.js +1 -1
  213. package/views/draw/support/Reshape.js +1 -1
  214. package/views/interactive/GraphicManipulator.js +1 -1
  215. package/views/interactive/InteractiveToolBase.js +1 -1
  216. package/views/interactive/SegmentLabels.js +5 -0
  217. package/views/interactive/snapping/FeatureSnappingEngine.js +1 -1
  218. package/views/interactive/snapping/LineSnapper.js +1 -1
  219. package/views/interactive/snapping/ParallelLineSnapper.js +1 -1
  220. package/views/interactive/snapping/RightAngleSnapper.js +1 -1
  221. package/views/interactive/snapping/RightAngleTriangleSnapper.js +1 -1
  222. package/views/interactive/snapping/SnappingAlgorithm.js +1 -1
  223. package/views/interactive/snapping/SnappingManager.js +1 -1
  224. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
  225. package/views/interactive/snapping/snappingUtils.js +1 -1
  226. package/views/interactive/support/viewUtils.js +5 -0
  227. package/views/interactive/tooltip/DrawPointTooltipInfo.js +5 -0
  228. package/views/interactive/tooltip/DrawPolygonTooltipInfo.js +5 -0
  229. package/views/interactive/tooltip/DrawPolylineTooltipInfo.js +5 -0
  230. package/views/interactive/tooltip/Tooltip.js +1 -1
  231. package/views/interactive/tooltip/content/TooltipContentDrawPolygon.js +1 -1
  232. package/views/interactive/tooltip/support/measurements.js +5 -0
  233. package/views/layers/FeatureLayerView.js +1 -1
  234. package/views/layers/GroupLayerView.js +1 -1
  235. package/views/overlay/TextOverlayItem.js +1 -1
  236. package/views/support/Scheduler.js +1 -1
  237. package/views/support/screenUtils.js +1 -1
  238. package/webscene/Slide.js +1 -1
  239. package/widgets/Attribution/AttributionViewModel.js +1 -1
  240. package/widgets/Bookmarks.js +1 -1
  241. package/widgets/CoordinateConversion/CoordinateConversionViewModel.js +1 -1
  242. package/widgets/Editor/EditorViewModel.js +1 -1
  243. package/widgets/Editor/UpdateWorkflow.js +1 -1
  244. package/widgets/Editor/workflowUtils.js +1 -1
  245. package/widgets/Editor.js +1 -1
  246. package/widgets/ElevationProfile/support/chartUtils.js +1 -1
  247. package/widgets/ElevationProfile.js +1 -1
  248. package/widgets/Feature/FeatureAttachments.js +1 -1
  249. package/widgets/Feature/FeatureContent/FeatureContentViewModel.js +1 -1
  250. package/widgets/Feature/FeatureExpression/FeatureExpressionViewModel.js +1 -1
  251. package/widgets/Feature/FeatureExpression.js +1 -1
  252. package/widgets/Feature/FeatureFields.js +1 -1
  253. package/widgets/Feature/FeatureViewModel.js +1 -1
  254. package/widgets/Feature.js +1 -1
  255. package/widgets/FeatureForm/InputFieldGroup.js +1 -1
  256. package/widgets/FeatureForm.js +1 -1
  257. package/widgets/FeatureTable/FieldColumn.js +1 -1
  258. package/widgets/FeatureTable/Grid/Column.js +1 -1
  259. package/widgets/FeatureTable/Grid/Grid.js +11 -11
  260. package/widgets/FeatureTable/Grid/support/ButtonMenu.js +1 -1
  261. package/widgets/FeatureTemplates/FeatureTemplatesViewModel.js +1 -1
  262. package/widgets/FeatureTemplates/TemplateItem.js +1 -1
  263. package/widgets/FeatureTemplates.js +1 -1
  264. package/widgets/FloorFilter/FloorFilterViewModel.js +1 -1
  265. package/widgets/FloorFilter.js +1 -1
  266. package/widgets/HistogramRangeSlider.js +1 -1
  267. package/widgets/LayerList/LayerListViewModel.js +1 -1
  268. package/widgets/LayerList/ListItem.js +1 -1
  269. package/widgets/LayerList/ListItemPanel.js +1 -1
  270. package/widgets/LayerList.js +1 -1
  271. package/widgets/Legend/LegendViewModel.js +1 -1
  272. package/widgets/Legend/styles/Card.js +1 -1
  273. package/widgets/Legend/support/ActiveLayerInfo.js +1 -1
  274. package/widgets/Legend.js +1 -1
  275. package/widgets/LineOfSight/LineOfSightViewModel.js +1 -1
  276. package/widgets/Measurement.js +1 -1
  277. package/widgets/NavigationToggle/NavigationToggleViewModel.js +1 -1
  278. package/widgets/Popup/PopupViewModel.js +1 -1
  279. package/widgets/Popup.js +1 -1
  280. package/widgets/Print/FileLink.js +1 -1
  281. package/widgets/Print.js +1 -1
  282. package/widgets/ScaleBar.js +1 -1
  283. package/widgets/ScaleRangeSlider/ScaleRangeSliderViewModel.js +1 -1
  284. package/widgets/ScaleRangeSlider.js +1 -1
  285. package/widgets/Search/SearchViewModel.js +1 -1
  286. package/widgets/Search.js +1 -1
  287. package/widgets/ShadowCast/ShadowCastViewModel.js +1 -1
  288. package/widgets/Sketch/SketchViewModel.js +1 -1
  289. package/widgets/Sketch.js +1 -1
  290. package/widgets/TableList/ListItem.js +1 -1
  291. package/widgets/Weather/LabeledSlider.js +1 -1
  292. package/widgets/Weather/VisibleElements.js +5 -0
  293. package/widgets/Weather/css.js +1 -1
  294. package/widgets/Weather.js +1 -1
  295. package/widgets/support/AnalysisViewModel.js +1 -1
  296. package/widgets/support/InteractiveAnalysisViewModel.js +1 -1
  297. package/analysis/LinearDimension.d.ts +0 -4
  298. package/analysis/LinearDimension.js +0 -5
  299. package/assets/esri/core/workers/chunks/0018053ac16a09feba70.js +0 -1
  300. package/assets/esri/core/workers/chunks/042938ca73f0b9e5a7e2.js +0 -1
  301. package/assets/esri/core/workers/chunks/048645611caa28dca7cd.js +0 -1
  302. package/assets/esri/core/workers/chunks/0b72d123386dc4ec7538.js +0 -1
  303. package/assets/esri/core/workers/chunks/13b04d5bf348ab5054c2.js +0 -1
  304. package/assets/esri/core/workers/chunks/215007e7c44811d90777.js +0 -1
  305. package/assets/esri/core/workers/chunks/31df729c17470245288c.js +0 -2
  306. package/assets/esri/core/workers/chunks/36272141b3c33cb19026.js +0 -1
  307. package/assets/esri/core/workers/chunks/36c8e8de9c3f67d32572.js +0 -1
  308. package/assets/esri/core/workers/chunks/37c428489c59df4b597b.js +0 -1
  309. package/assets/esri/core/workers/chunks/493169fd978fd543ef3b.js +0 -1
  310. package/assets/esri/core/workers/chunks/4f378ad6f4299183df85.js +0 -1
  311. package/assets/esri/core/workers/chunks/58e4c6ce1580427e7b55.js +0 -1
  312. package/assets/esri/core/workers/chunks/6c5441da675a8af35be2.js +0 -1
  313. package/assets/esri/core/workers/chunks/6ea16f6a0df946de480b.js +0 -1
  314. package/assets/esri/core/workers/chunks/7dfd70f4fa1096e56641.js +0 -1
  315. package/assets/esri/core/workers/chunks/88193e61072d7bf957f5.js +0 -1
  316. package/assets/esri/core/workers/chunks/8ccbde593c86c872e525.js +0 -1
  317. package/assets/esri/core/workers/chunks/9c6be39f1f21ab8b1c2d.js +0 -1
  318. package/assets/esri/core/workers/chunks/a73795cce722ba15b3da.js +0 -1
  319. package/assets/esri/core/workers/chunks/a8ed1a938dc164b401d9.js +0 -1
  320. package/assets/esri/core/workers/chunks/a9a73bc4875a5aeaf1b9.js +0 -1
  321. package/assets/esri/core/workers/chunks/adcc5bce6c0971c1b592.js +0 -1
  322. package/assets/esri/core/workers/chunks/afddfe620e6539991e6b.js +0 -1
  323. package/assets/esri/core/workers/chunks/b340c9bdabdb37995c8f.js +0 -1
  324. package/assets/esri/core/workers/chunks/b4c23630d6c85f7b59c0.js +0 -1
  325. package/assets/esri/core/workers/chunks/c180c40838246985479d.js +0 -1
  326. package/assets/esri/core/workers/chunks/caed2365bd296fcc8a75.js +0 -1
  327. package/assets/esri/core/workers/chunks/d85b5b73a151c6fbb658.js +0 -1
  328. package/assets/esri/core/workers/chunks/da6261673c3e1537b6a6.js +0 -1
  329. package/assets/esri/core/workers/chunks/dafe120243db6648a4ab.js +0 -1
  330. package/assets/esri/core/workers/chunks/ec6d138e8183e193f977.js +0 -1
  331. package/assets/esri/core/workers/chunks/ed4519ac9533a4d340f1.js +0 -1
  332. package/assets/esri/core/workers/chunks/f206300eef4560611728.js +0 -1
  333. package/assets/esri/core/workers/chunks/f55cbaf5a1d6ee6ac171.js +0 -1
  334. package/layers/GeoreferencedImageLayer.d.ts +0 -4
  335. package/layers/GeoreferencedImageLayer.js +0 -5
  336. package/layers/VoxelWasmManager.js +0 -5
  337. package/layers/VoxelWasmPerScene.js +0 -5
  338. package/views/3d/interactive/measurementTools/support/viewUtils.js +0 -5
@@ -0,0 +1,4 @@
1
+ import "../interfaces";
2
+
3
+ import MediaLayer = __esri.MediaLayer;
4
+ export default MediaLayer;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as r}from"../chunks/tslib.es6.js";import o from"../core/Collection.js";import{unwrap as e}from"../core/maybe.js";import{property as s}from"../core/accessorSupport/decorators/property.js";import"../core/arrayUtils.js";import"../core/has.js";import{cast as t}from"../core/accessorSupport/decorators/cast.js";import{subclass as c}from"../core/accessorSupport/decorators/subclass.js";import p from"./Layer.js";import{BlendLayer as a}from"./mixins/BlendLayer.js";import{ScaleRangeLayer as i}from"./mixins/ScaleRangeLayer.js";import m from"./support/LocalMediaElementSource.js";let l=class extends(a(i(p))){constructor(r){super(r),this.source=new m,this.type="media"}destroy(){e(this.source)?.destroy()}castSource(r){return r?Array.isArray(r)||r instanceof o?new m({elements:r}):r:null}};r([s({type:["show","hide"]})],l.prototype,"listMode",void 0),r([s()],l.prototype,"source",void 0),r([t("source")],l.prototype,"castSource",null),r([s({readOnly:!0})],l.prototype,"type",void 0),l=r([c("esri.layers.MediaLayer")],l);const y=l;export{y 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.24/esri/copyright.txt for details.
4
4
  */
5
- import{_ as e}from"../chunks/tslib.es6.js";import r from"../core/Collection.js";import t from"../core/Error.js";import s from"../core/Handles.js";import i from"../core/Logger.js";import{destroyMaybe as o,isSome as a,isNone as n}from"../core/maybe.js";import{MultiOriginJSONMixin as l}from"../core/MultiOriginJSONSupport.js";import{throwIfAbortError as p}from"../core/promiseUtils.js";import{watch as m}from"../core/reactiveUtils.js";import{property as c}from"../core/accessorSupport/decorators/property.js";import"../core/arrayUtils.js";import"../core/has.js";import"../core/accessorSupport/ensureType.js";import{reader as d}from"../core/accessorSupport/decorators/reader.js";import{subclass as h}from"../core/accessorSupport/decorators/subclass.js";import{n as u}from"../chunks/vec3.js";import{f as y}from"../chunks/vec3f64.js";import g from"./Layer.js";import f from"./VoxelWasmManager.js";import{APIKeyMixin as V}from"./mixins/APIKeyMixin.js";import{ArcGISService as v}from"./mixins/ArcGISService.js";import{OperationalLayer as b}from"./mixins/OperationalLayer.js";import{PortalLayer as _}from"./mixins/PortalLayer.js";import{ScaleRangeLayer as S}from"./mixins/ScaleRangeLayer.js";import{SceneService as x}from"./mixins/SceneService.js";import{sanitizeUrl as j}from"./support/arcgisLayerUrl.js";import{popupEnabled as I,legendEnabled as T,url as w}from"./support/commonProperties.js";import L from"./support/VoxelDynamicSection.js";import W from"./support/VoxelSection.js";import E from"./support/VoxelSlice.js";import P from"./support/VoxelStyle.js";import{VoxelVariable as A}from"./support/VoxelVariable.js";import N from"./support/VoxelVolume.js";import O from"./support/VoxelVolumeIndex.js";const M=i.getLogger(" esri.layers.VoxelLayer");var D;!function(e){e[e.API=1]="API",e[e.VerboseAPI=2]="VerboseAPI",e[e.Error=3]="Error"}(D||(D={}));let R=class extends(x(v(b(_(S(l(V(g)))))))){constructor(e){super(e),this.serviceRoot="",this.popupEnabled=!0,this.operationalLayerType="Voxel",this.legendEnabled=!0,this.title=null,this.sections=new r,this.style=null,this.opacity=1,this.variables=new r,this.volumes=new r,this.index=null,this.minScale=0,this.maxScale=0,this.type="voxel",this._dbgFlags=new Set,this._handles=new s,this.version={major:Number.NaN,minor:Number.NaN,versionString:""}}set url(e){this._set("url",j(e,M))}destroy(){this._handles=o(this._handles)}_dbg(e,r){this._dbgFlags.has(e)&&(e===D.Error?M.error(r):M.warn(r))}load(e){const r=a(e)?e.signal:null,t=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(p).then((()=>this._fetchService(r))).then((()=>this.serviceRoot=this.url));return this.addResolvingPromise(t),Promise.resolve(this)}getConfiguration(){this._handles.add([m((()=>this._getRenderMode()),(e=>this._pushRenderModeToWasm(e))),m((()=>this._getCurrentVariableId()),(e=>this._pushCurrentVariableIdToWasm(e))),m((()=>this._getDynamicSections()),(e=>this._pushDynamicSectionsToWasm(e))),m((()=>this._getSlices()),(e=>this._pushSlicesToWasm(e))),m((()=>this._getSections()),(e=>this._pushSectionsToWasm(e))),m((()=>this._getVerticalExaggeration()),(e=>this._pushVerticalExaggerationToWasm(e))),m((()=>this._getVerticalOffset()),(e=>this._pushVerticalOffsetToWasm(e)))]);const e={layerType:this.operationalLayerType,version:this.version.versionString,name:this.title,spatialReference:this.spatialReference,fullExtent:this.fullExtent,volumes:this.volumes.toJSON(),variables:this.variables.toJSON(),index:this.index.toJSON(),sections:this.sections.toJSON(),style:this.style};return e.index&&this.index.isValid()?JSON.stringify(e):""}readVersion(e,r){return super.parseVersionString(e)}_getSections(){const e=[];for(const r of this.sections)e.push(new W({enabled:r.enabled,href:r.href,id:r.id,label:r.label,normal:r.normal,point:r.point,sizeInPixel:r.sizeInPixel,slices:r.slices,timeId:r.timeId,variableId:r.variableId}));return e}_pushSectionsToWasm(e){this._dbg(D.VerboseAPI,"VoxelLayer._pushSectionsToWasm() called");f.getInstance().setLayerStaticSections(this,e)||this._dbg(D.Error,"VoxelLayer._pushSectionsToWasm() failed!")}_isPlaneValid(e,r,t){if(!e.point)return!1;if(!Array.isArray(e.point)||3!==e.point.length)return!1;if(!e.normal)return!1;if(!Array.isArray(e.normal)||3!==e.normal.length)return!1;for(let o=0;o<3;++o){const s=e.point[o];if(s<0||s>=t[r[o]].size)return!1}const s=y(e.normal[0],e.normal[1],e.normal[2]);u(s,s);const i=1e-6;return!(Math.abs(s[0])+Math.abs(s[1])+Math.abs(s[2])<i)&&(e.normal[0]=s[0],e.normal[1]=s[1],e.normal[2]=s[2],!0)}getVariableStyle(e){let r=-1;r=a(e)?e:this._getCurrentVariableId();const t=this?.style.variableStyles;if(!t||-1===r)return null;const s=this.style.variableStyles.findIndex((e=>e.variableId===r));return s<0?null:this.style.variableStyles.getItemAt(s)}getVariable(e){let r=-1;if(r=a(e)?e:this._getCurrentVariableId(),!this.variables||-1===r)return null;const t=this.variables.findIndex((e=>e.id===r));return t<0?null:this.variables.getItemAt(t)}getVolume(e){const r=this.getVariable(e);return a(r)?this.volumes.find((({id:e})=>e===r.volumeId)):null}validateLayer(e){if(e.layerType&&e.layerType!==this.operationalLayerType)throw new t("voxel-layer:layer-type-not-supported","VoxelLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor)||this.version.major<3)throw new t("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"});if(this.version.major>3)throw new t("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"})}_getVolumeStyle(e){const r=this.getVariable(e);return a(r)?this.style.volumeStyles.find((({volumeId:e})=>e===r.volumeId)):null}_getSlices(){const e=[],r=this.getVolume(null);if(n(r)||!r.isVolumeValid())return e;const t=this._getVolumeStyle(null);if(n(t))return e;for(const s of t.slices)this._isPlaneValid(s,[0,1,r.getZDimension()],r.dimensions)?e.push(new E({enabled:s.enabled,label:s.label,point:s.point,normal:s.normal})):e.push(new E({enabled:!1,label:"invalid",point:s.point,normal:s.normal}));return e}_pushSlicesToWasm(e){this._dbg(D.VerboseAPI,"VoxelLayer._pushSlicesToWasm() called!");f.getInstance().setLayerSlices(this,e)||this._dbg(D.Error,"VoxelLayer._pushSlicesToWasm() failed!")}_getDynamicSections(){const e=[],r=this.getVolume(null);if(n(r)||!r.isVolumeValid())return e;const t=this._getVolumeStyle(null);if(n(t))return e;for(const s of t.dynamicSections)this._isPlaneValid(s,[0,1,r.getZDimension()],r.dimensions)?e.push(new L({enabled:s.enabled,label:s.label,point:s.point,normal:s.normal})):e.push(new L({enabled:!1,label:"invalid",point:s.point,normal:s.normal}));return e}_pushDynamicSectionsToWasm(e){this._dbg(D.VerboseAPI,"VoxelLayer._pushDynamicSectionsToWasm() called!");f.getInstance().setLayerDynamicSections(this,e)||this._dbg(D.Error,"VoxelLayer._updateDynamicSections() failed!")}_getCurrentVariableId(){return this.style?this.style.currentVariableId:-1}_pushCurrentVariableIdToWasm(e){this._dbg(D.VerboseAPI,"VoxelLayer._pushCurrentVariableIdToWasm() called!");f.getInstance().setLayerCurrentVariable(this,e)||this._dbg(D.Error,"VoxelLayer._pushCurrentVariableIdToWasm() failed!")}_getRenderMode(){return this.style?this.style.renderMode:"volume"}_pushRenderModeToWasm(e){this._dbg(D.VerboseAPI,"VoxelLayer._pushRenderModeToWasm() called!");f.getInstance().setLayerRenderMode(this,e)||this._dbg(D.Error,"VoxelLayer._pushRenderModeToWasm() failed!")}_getVerticalExaggeration(){const e=1,r=this._getVolumeStyle(null);return n(r)?e:r.verticalExaggeration}_pushVerticalExaggerationToWasm(e){const r=this._getVolumeStyle(null);if(n(r))return;this._dbg(D.VerboseAPI,"VoxelLayer._pushVerticalExaggerationToWasm() called!");f.getInstance().setLayerVerticalExaggerationAndOffset(this,r.volumeId,e,r.verticalOffset)||this._dbg(D.Error,"VoxelLayer._pushVerticalExaggerationToWasm() failed!")}_getVerticalOffset(){const e=1,r=this._getVolumeStyle(null);return n(r)?e:r.verticalOffset}_pushVerticalOffsetToWasm(e){const r=this._getVolumeStyle(null);if(n(r))return;this._dbg(D.VerboseAPI,"VoxelLayer._pushVerticalOffsetToWasm() called!");f.getInstance().setLayerVerticalExaggerationAndOffset(this,r.volumeId,r.verticalExaggeration,e)||this._dbg(D.Error,"VoxelLayer._pushVerticalOffsetToWasm() failed!")}};e([c(I)],R.prototype,"popupEnabled",void 0),e([c({type:["Voxel"]})],R.prototype,"operationalLayerType",void 0),e([c(T)],R.prototype,"legendEnabled",void 0),e([c({json:{write:!0}})],R.prototype,"title",void 0),e([c(w)],R.prototype,"url",null),e([c({type:r.ofType(W),json:{write:!0,origins:{"web-scene":{name:"layerDefinition.sections",write:!0},service:{write:!1}}}})],R.prototype,"sections",void 0),e([c({type:P,json:{write:!0,origins:{"web-scene":{name:"layerDefinition.style",write:!0},service:{write:!1}}}})],R.prototype,"style",void 0),e([c({type:["show","hide"]})],R.prototype,"listMode",void 0),e([c({type:Number,range:{min:0,max:1},nonNullable:!0,json:{read:!1,write:!1,origins:{"web-scene":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],R.prototype,"opacity",void 0),e([c({type:r.ofType(A)})],R.prototype,"variables",void 0),e([c({type:r.ofType(N)})],R.prototype,"volumes",void 0),e([c({type:O})],R.prototype,"index",void 0),e([c({type:Number,json:{name:"layerDefinition.minScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],R.prototype,"minScale",void 0),e([c({type:Number,json:{name:"layerDefinition.maxScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],R.prototype,"maxScale",void 0),e([c({json:{read:!1},readOnly:!0})],R.prototype,"type",void 0),e([c({readOnly:!0,json:{name:"serviceVersion"}})],R.prototype,"version",void 0),e([d("service","version")],R.prototype,"readVersion",null),R=e([h("esri.layers.VoxelLayer")],R);const C=R;export{C as default};
5
+ import{_ as e}from"../chunks/tslib.es6.js";import r from"../core/Collection.js";import t from"../core/Error.js";import o from"../core/Logger.js";import{isSome as i,isNone as s}from"../core/maybe.js";import{MultiOriginJSONMixin as n}from"../core/MultiOriginJSONSupport.js";import{throwIfAbortError as l}from"../core/promiseUtils.js";import{property as a}from"../core/accessorSupport/decorators/property.js";import"../core/arrayUtils.js";import"../core/has.js";import"../core/accessorSupport/ensureType.js";import{reader as p}from"../core/accessorSupport/decorators/reader.js";import{subclass as m}from"../core/accessorSupport/decorators/subclass.js";import{n as u}from"../chunks/vec3.js";import{f as c}from"../chunks/vec3f64.js";import y from"./Layer.js";import{APIKeyMixin as d}from"./mixins/APIKeyMixin.js";import{ArcGISService as h}from"./mixins/ArcGISService.js";import{OperationalLayer as v}from"./mixins/OperationalLayer.js";import{PortalLayer as f}from"./mixins/PortalLayer.js";import{ScaleRangeLayer as b}from"./mixins/ScaleRangeLayer.js";import{SceneService as g}from"./mixins/SceneService.js";import{sanitizeUrl as S}from"./support/arcgisLayerUrl.js";import{popupEnabled as V,legendEnabled as x,url as j}from"./support/commonProperties.js";import w from"./support/VoxelDynamicSection.js";import I from"./support/VoxelSection.js";import N from"./support/VoxelSlice.js";import L from"./support/VoxelStyle.js";import{VoxelVariable as T}from"./support/VoxelVariable.js";import O from"./support/VoxelVolume.js";import P from"./support/VoxelVolumeIndex.js";const E=o.getLogger(" esri.layers.VoxelLayer");let A=class extends(g(h(v(f(b(n(d(y)))))))){constructor(e){super(e),this.serviceRoot="",this.popupEnabled=!0,this.operationalLayerType="Voxel",this.legendEnabled=!0,this.title=null,this.sections=new r,this.style=null,this.opacity=1,this.variables=new r,this.volumes=new r,this.index=null,this.minScale=0,this.maxScale=0,this.type="voxel",this.version={major:Number.NaN,minor:Number.NaN,versionString:""}}set url(e){this._set("url",S(e,E))}load(e){const r=i(e)?e.signal:null,t=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(l).then((()=>this._fetchService(r))).then((()=>this.serviceRoot=this.url));return this.addResolvingPromise(t),Promise.resolve(this)}readVersion(e,r){return super.parseVersionString(e)}validateLayer(e){if(e.layerType&&e.layerType!==this.operationalLayerType)throw new t("voxel-layer:layer-type-not-supported","VoxelLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor)||this.version.major<3)throw new t("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"});if(this.version.major>3)throw new t("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"})}getConfiguration(){const e={layerType:this.operationalLayerType,version:this.version.versionString,name:this.title,spatialReference:this.spatialReference,fullExtent:this.fullExtent,volumes:this.volumes.toJSON(),variables:this.variables.toJSON(),index:this.index.toJSON(),sections:this.sections.toJSON(),style:this.style};return e.index&&this.index.isValid()?JSON.stringify(e):""}getVariableStyle(e){let r=-1;r=i(e)?e:this.getCurrentVariableId();const t=this?.style.variableStyles;if(!t||-1===r)return null;const o=this.style.variableStyles.findIndex((e=>e.variableId===r));return o<0?null:this.style.variableStyles.getItemAt(o)}getVariable(e){let r=-1;if(r=i(e)?e:this.getCurrentVariableId(),!this.variables||-1===r)return null;const t=this.variables.findIndex((e=>e.id===r));return t<0?null:this.variables.getItemAt(t)}getSections(){const e=[];for(const r of this.sections)e.push(new I({enabled:r.enabled,href:r.href,id:r.id,label:r.label,normal:r.normal,point:r.point,sizeInPixel:r.sizeInPixel,slices:r.slices,timeId:r.timeId,variableId:r.variableId}));return e}getVolume(e){const r=this.getVariable(e);return i(r)?this.volumes.find((({id:e})=>e===r.volumeId)):null}getVolumeStyle(e){const r=this.getVariable(e);return i(r)?this.style.volumeStyles.find((({volumeId:e})=>e===r.volumeId)):null}getSlices(){const e=[],r=this.getVolume(null);if(s(r)||!r.isVolumeValid())return e;const t=this.getVolumeStyle(null);if(s(t))return e;for(const o of t.slices)this._isPlaneValid(o,[0,1,r.getZDimension()],r.dimensions)?e.push(new N({enabled:o.enabled,label:o.label,point:o.point,normal:o.normal})):e.push(new N({enabled:!1,label:"invalid",point:o.point,normal:o.normal}));return e}getDynamicSections(){const e=[],r=this.getVolume(null);if(s(r)||!r.isVolumeValid())return e;const t=this.getVolumeStyle(null);if(s(t))return e;for(const o of t.dynamicSections)this._isPlaneValid(o,[0,1,r.getZDimension()],r.dimensions)?e.push(new w({enabled:o.enabled,label:o.label,point:o.point,normal:o.normal})):e.push(new w({enabled:!1,label:"invalid",point:o.point,normal:o.normal}));return e}getCurrentVariableId(){return this.style?this.style.currentVariableId:-1}getRenderMode(){return this.style?this.style.renderMode:"volume"}getVerticalExaggeration(){const e=1,r=this.getVolumeStyle(null);return s(r)?e:r.verticalExaggeration}getVerticalOffset(){const e=1,r=this.getVolumeStyle(null);return s(r)?e:r.verticalOffset}_isPlaneValid(e,r,t){if(!e.point)return!1;if(!Array.isArray(e.point)||3!==e.point.length)return!1;if(!e.normal)return!1;if(!Array.isArray(e.normal)||3!==e.normal.length)return!1;for(let s=0;s<3;++s){const o=e.point[s];if(o<0||o>=t[r[s]].size)return!1}const o=c(e.normal[0],e.normal[1],e.normal[2]);u(o,o);const i=1e-6;return!(Math.abs(o[0])+Math.abs(o[1])+Math.abs(o[2])<i)&&(e.normal[0]=o[0],e.normal[1]=o[1],e.normal[2]=o[2],!0)}};e([a(V)],A.prototype,"popupEnabled",void 0),e([a({type:["Voxel"]})],A.prototype,"operationalLayerType",void 0),e([a(x)],A.prototype,"legendEnabled",void 0),e([a({json:{write:!0}})],A.prototype,"title",void 0),e([a(j)],A.prototype,"url",null),e([a({type:r.ofType(I),json:{write:!0,origins:{"web-scene":{name:"layerDefinition.sections",write:!0},service:{write:!1}}}})],A.prototype,"sections",void 0),e([a({type:L,json:{write:!0,origins:{"web-scene":{name:"layerDefinition.style",write:!0},service:{write:!1}}}})],A.prototype,"style",void 0),e([a({type:["show","hide"]})],A.prototype,"listMode",void 0),e([a({type:Number,range:{min:0,max:1},nonNullable:!0,json:{read:!1,write:!1,origins:{"web-scene":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],A.prototype,"opacity",void 0),e([a({type:r.ofType(T)})],A.prototype,"variables",void 0),e([a({type:r.ofType(O)})],A.prototype,"volumes",void 0),e([a({type:P})],A.prototype,"index",void 0),e([a({type:Number,json:{name:"layerDefinition.minScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],A.prototype,"minScale",void 0),e([a({type:Number,json:{name:"layerDefinition.maxScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],A.prototype,"maxScale",void 0),e([a({json:{read:!1},readOnly:!0})],A.prototype,"type",void 0),e([a({readOnly:!0,json:{name:"serviceVersion"}})],A.prototype,"version",void 0),e([p("service","version")],A.prototype,"readVersion",null),A=e([m("esri.layers.VoxelLayer")],A);const D=A;export{D as default};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import e from"../request.js";import t from"../core/has.js";import i from"../core/Logger.js";import{isSome as r,removeMaybe as s}from"../core/maybe.js";import{isAbortError as n}from"../core/promiseUtils.js";import{watch as a}from"../core/reactiveUtils.js";import{WasmCullMode as o,VoxelRequestType as l,UpdateFlags as h}from"../libs/vxl/enums.js";import{loadVoxelWASM as d}from"../libs/vxl/VxlModule.js";import{RenderPass as _}from"../views/3d/webgl-engine/lib/RenderPass.js";import{RenderSlot as c}from"../views/3d/webgl-engine/lib/RenderSlot.js";import{ContextType as u}from"../views/webgl/context-util.js";import{CompareFunction as g,Face as x,StencilOperation as m}from"../views/webgl/enums.js";const v=i.getLogger("esri.layers.VoxelWasmPerSceneView");var y;!function(e){e[e.Lifetime=1]="Lifetime",e[e.RequestResponse=2]="RequestResponse",e[e.Rendering=3]="Rendering",e[e.Error=4]="Error"}(y||(y={}));class p{constructor(e){this._halfIntTexturesAvailable=!1,this._textureFloatLinearAvailable=!1,this._havePreparedWithAllLayers=!1,this._renderPluginContext=null,this._vxl=null,this._pluginIsActive=!1,this._moreToLoad=!1,this._viewportWidth=-1,this._viewportHeight=-1,this._newLayers=[],this._layers=new Map,this._renderPass=_.MATERIAL,this._renderSlot=c.VOXEL,this._rctx=null,this._renderTargetToRestore=null,this._lastFrameWasStationary=!1,this._wasmMemBlockSizes=[512,1024,2048,4096,8192,16384,32768,65536],this._wasmMemBlocks=new Map,this._dbgFlags=new Set,this._view=e,this._initialize()}get canRender(){return!!this._vxl&&"local"===this._view.viewingMode}_dbg(e,t){this._dbgFlags.has(e)&&(e===y.Error?v.error(t):v.warn(t))}_removeRenderPlugin(){this._pluginIsActive&&this._view._stage&&(this._dbg(y.Lifetime,"--removeRenderPlugin--"),this._view._stage.removeRenderPlugin(this)),this._pluginIsActive=!1}_initialize(){this._dbg(y.Lifetime,"--initialize--");for(const e of this._wasmMemBlockSizes)this._wasmMemBlocks.set(e,0);this._readyWatchHandle=a((()=>this._view.ready),(e=>{e&&"local"===this._view.viewingMode?(this._dbg(y.Lifetime,"view ready status changed to ready on a local view, calling addRenderPlugin"),this._view._stage.addRenderPlugin([this._renderSlot],this),this._pluginIsActive=!0):(this._dbg(y.Lifetime,"view ready status changed, not ready or not a local view!"),this._removeRenderPlugin())}),{initial:!0}),this._qualityWatchHandle=a((()=>this._view?.qualityProfile),(e=>{this._dbg(y.Rendering,"qualityProfile changed to "+e),this._vxl&&this._vxl.set_quality(this._toWasmQuality(e))}),{initial:!0}),this._timeExtentWatchHandle=a((()=>this._view?.timeExtent),(()=>{if(this._vxl){const e=this._getTimeArgs(this._view?.timeExtent);this._dbg(y.Rendering,"sceneView timeExtent changed to useTime="+e.useTime+" st="+e.startTime+" et="+e.endTime),this._vxl.set_scene_time_extent(e.startTime,e.endTime,e.useTime),this._renderPluginContext.requestRender()}}),{initial:!0}),this._stationaryWatchHandle=a((()=>this._view?.stationary),(e=>{this._vxl&&e&&!this._lastFrameWasStationary&&this._renderPluginContext.requestRender()}))}initializeRenderContext(e){this._dbg(y.Lifetime,"--initializeRenderContext--");const t=e.renderContext.rctx;t.type===u.WEBGL2?(this._renderPluginContext=e,this._rctx=e.renderContext.rctx,this._halfIntTexturesAvailable=!!this._rctx.capabilities.textureNorm16,this._textureFloatLinearAvailable=this._rctx.capabilities.textureFloatLinear,this._initializeWasm(t.gl)):this._dbg(y.Error,"WebGL 1 context only!")}uninitializeRenderContext(){this._renderPluginContext=null,this._rctx=null,this._dbg(y.Lifetime,"--uninitializeRenderContext--")}_restoreFramebuffer(){if(!this._renderTargetToRestore)return;const e=this._renderTargetToRestore.fbo;if(!!!this._rctx)return void this._dbg(y.Error,"no context in restoreFramebuffer!");this._rctx.bindFramebuffer(e,!0);const t=this._renderTargetToRestore.viewport;this._rctx.setViewport(t.x,t.y,t.width,t.height)}_bindPreviousDepthToSlot(e,t){const i=!!this._rctx,r=!!this._renderTargetToRestore;if(!i||!r)return 0;const s=this._renderTargetToRestore.fbo.depthStencilTexture;return s?(0===t?this._rctx.bindTexture(null,e,!0):this._rctx.bindTexture(s,e,!0),1):(this._dbg(y.Error,"no depth/stencil texture exists!"),0)}_modifyResourceCount(e,t,i){if(!this._rctx)return void this._dbg(y.Error,"modifyAllocation callback has no rendering context!");const r=e;1===i?this._rctx.instanceCounter.increment(r,t):this._rctx.instanceCounter.decrement(r,t)}_setBlendState(e,t,i,r){this._rctx?(this._rctx.setBlendingEnabled(1===e),this._rctx.setBlendFunction(t,i),this._rctx.setBlendEquation(r)):this._dbg(y.Error,"setBlendState callback has no rendering context!")}_setFrontFace(e){this._rctx?this._rctx.setFrontFace(e):this._dbg(y.Error,"setFrontFace callback has no rendering context!")}_setDepthStencilStateFunction(e,t,i){this._rctx?(this._rctx.setDepthFunction(i),this._rctx.setDepthTestEnabled(1===e),this._rctx.setDepthWriteEnabled(1===t),this._rctx.setStencilTestEnabled(!1),this._rctx.setStencilFunction(g.ALWAYS,0,255),this._rctx.setStencilOpSeparate(x.FRONT,m.KEEP,m.INCR,m.KEEP),this._rctx.setStencilOpSeparate(x.BACK,m.KEEP,m.DECR,m.KEEP)):this._dbg(y.Error,"setDepthStencilStateFunction callback has no rendering context!")}_setRasterizerState(e){if(this._rctx)switch(e){case o.None:this._rctx.setFaceCullingEnabled(!1);break;case o.Back:this._rctx.setCullFace(x.BACK),this._rctx.setFaceCullingEnabled(!0);break;case o.Front:this._rctx.setCullFace(x.FRONT),this._rctx.setFaceCullingEnabled(!0)}else this._dbg(y.Error,"setRasterizerState callback has no rendering context!")}_setViewport(e,t,i,r){this._rctx?this._rctx.setViewport(e,t,i,r):this._dbg(y.Error,"setViewport callback has no rendering context!")}_updateMemoryUsage(){this._layers.forEach(((e,t)=>{if(e.needMemoryUsageUpdate){const i=this._vxl.estimate_memory_usage(t);i>=0&&(e.needMemoryUsageUpdate=!1,e.layerView.setUsedMemory(i))}}))}_syncRequestsResponses(){this._layers.forEach(((t,i)=>{const r=[];t.responses.forEach(((e,s)=>{r.push(s),this._dbg(y.RequestResponse,"responding for requestID:"+s+" size:"+e.size),this._vxl.respond(i,s,e),e.requestType!==l.TreeIndex&&e.requestType!==l.Section||(t.needMemoryUsageUpdate=!0)}));const s=t.responses;for(const e of r)s.delete(e);const a=this._vxl.get_new_requests(i),o=t.abortController.signal;for(const l in a){t.outstandingRequestCount+=1,1===t.outstandingRequestCount&&t.layerView.updatingFlagChanged();const i=a[l],r={responseType:"array-buffer",signal:o};this._dbg(y.RequestResponse,"making requestID:"+l+" url:"+i.url),e(i.url,r).then((e=>{t.outstandingRequestCount-=1,0===t.outstandingRequestCount&&t.layerView.updatingFlagChanged(),this._dbg(y.RequestResponse,"have response for requestID:"+l);let r=0;if(e.data.byteLength>0){r=this._vxl._malloc(e.data.byteLength);const t=new Uint8Array(this._vxl.HEAPU8.buffer,r,e.data.byteLength),i=new Uint8Array(e.data);for(let r=0;r<e.data.byteLength;++r)t[r]=i[r]}s.set(+l,{responseType:i.responseType,ptr:r,size:e.data.byteLength,success:!0,requestType:i.requestType})})).catch((e=>{t.outstandingRequestCount-=1,0===t.outstandingRequestCount&&t.layerView.updatingFlagChanged(),n(e)||(this._dbg(y.Error,`requestID:${l} failed, error=${e.toString()}`),s.set(+l,{responseType:i.responseType,ptr:0,size:0,success:!1,requestType:i.requestType}))}))}}))}updateWasmCamera(e){this._vxl.set_projection_matrix.apply(this._vxl,e.projectionMatrix),this._vxl.set_view_matrix.apply(this._vxl,e.viewMatrix),this._vxl.set_near_far(e.near,e.far)}isUpdating(e){return!(this._vxl||!this._vxlPromise)||!!this._layers.has(e)&&this._layers.get(e).outstandingRequestCount>0}setEnabled(e,t){this._layers.forEach(((i,r)=>{i.layerView.wasmLayerId===e.wasmLayerId&&(this._vxl.set_enabled(r,t),i.needMemoryUsageUpdate=!0,this._renderPluginContext.requestRender())}))}setSlices(e,t){const i={mask:h.Slices,slices:{planes:t,currentEditPlane:-1}};return this._doMaskedUIUpdate(e,i,!0)}setDynamicSections(e,t){const i={mask:h.DynamicSections,dynamicSections:{planes:t,currentEditPlane:-1}};return this._doMaskedUIUpdate(e,i,!0)}setStaticSections(e,t){const i={mask:h.StaticSections,staticSections:t};return this._doMaskedUIUpdate(e,i,!0)}setCurrentVariable(e,t){const i={mask:h.CurrentVariable,currentVariable:t};return this._doMaskedUIUpdate(e,i,!0)}setRenderMode(e,t){const i={mask:h.RenderMode,renderMode:t};return this._doMaskedUIUpdate(e,i,!0)}setVerticalExaggerationAndOffset(e,t,i,r){const s={mask:h.ExaggerationAndOffset,volStyleDesc:{volumeId:t,verticalExaggeration:i,verticalOffset:r}};return this._doMaskedUIUpdate(e,s,!0)}_doMaskedUIUpdate(e,t,i){if(!this._vxl)return!1;let r=!1;return this._layers.forEach(((i,s)=>{if(i.layerView.wasmLayerId===e.wasmLayerId){const e={str:JSON.stringify(t),byteCount:0,ptr:0,isReusable:!1};this._allocateBlock(e)&&(r=1===this._vxl.handle_masked_ui_update(s,e.ptr,e.byteCount),e.isReusable||this._vxl._free(e.ptr))}})),r&&i&&this._renderPluginContext.requestRender(),r}addVoxelLayer(e){if(!this._vxl){const t={layerView:e,resolveCallback:null,rejectCallback:null},i=new Promise(((e,i)=>{t.resolveCallback=e,t.rejectCallback=i}));return this._newLayers.push(t),i}const t=this._addVoxelLayer(e);return t<0?Promise.reject(-1):Promise.resolve(t)}removeVoxelLayer(e){if(!this._vxl){const t=this._newLayers.findIndex((t=>e.uid===t.layerView.uid));t>=0&&(this._newLayers[t].resolveCallback(-1),this._newLayers.splice(t,1));const i=this._newLayers.length;return 0===i&&(this._dbg(y.Lifetime," no voxel layers left after removing a layer, removing RenderPlugin and destroying"),this.destroy()),i}let t=-1;this._layers.forEach(((i,r)=>{i.layerView.wasmLayerId===e.wasmLayerId&&(t=r,i.abortController.abort(),this._vxl.remove_layer(t))})),t>=0&&this._layers.delete(t);const i=this._layers.size;return 0===i&&(this._dbg(y.Lifetime," no voxel layers left after removing a layer, removing RenderPlugin and destroying"),this.destroy()),i}_getBlockSize(e){for(const t of this._wasmMemBlockSizes)if(e<t)return t;return-1}_allocateBlock(e){e.byteCount=this._vxl.lengthBytesUTF8(e.str)+1;const t=this._getBlockSize(e.byteCount);return t<0?(e.isReusable=!1,e.ptr=this._vxl._malloc(e.byteCount)):(e.isReusable=!0,e.ptr=this._wasmMemBlocks.get(t),0===e.ptr&&(e.ptr=this._vxl._malloc(t),this._wasmMemBlocks.set(t,e.ptr))),0!==e.ptr&&(this._vxl.stringToUTF8(e.str,e.ptr,e.byteCount),!0)}_getTimeArgs(e){let t=-Number.MAX_VALUE,i=Number.MAX_VALUE,s=!1;return r(e)&&(e.isAllTime?s=!0:(r(e.start)&&(s=!0,t=e.start.getTime()/1e3),r(e.end)&&(s=!0,i=e.end.getTime()/1e3))),{startTime:t,endTime:i,useTime:s}}_addVoxelLayer(e){const i=e.layer;let r=-1;const s=i.getConfiguration();if(s.length<1)return-1;const n={str:s,byteCount:0,ptr:0,isReusable:!1};if(!this._allocateBlock(n))return-1;const a=this._getTimeArgs(this._view?.timeExtent),o=this._view.spatialReference.isWGS84&&i.spatialReference.isWGS84?111319.49079327357:1;if(r=this._vxl.add_layer(i.serviceRoot,n.ptr,n.byteCount,o,o,a.startTime,a.endTime,a.useTime,this._toWasmQuality(this._view.qualityProfile)),n.isReusable||this._vxl._free(n.ptr),r>=0){const i=new AbortController;if(this._layers.set(r,{layerView:e,responses:new Map,outstandingRequestCount:0,abortController:i,needMemoryUsageUpdate:!1}),!this._halfIntTexturesAvailable||t("mac")){const t=[];let i="";for(const r of e.layer.variables)"Int16"!==r.renderingFormat.type&&"UInt16"!==r.renderingFormat.type||(t.push(r.name),r.id===e.layer.style.currentVariableId&&(i=r.name));""!==i&&v.error("#addVoxelLayer_error()",e.layer,`The voxel layer '${e.layer.title}' cannot render the current variable '${i}' in this browser`),t.length>0&&v.warn("#addVoxelLayer_warning()",e.layer,`The voxel layer '${e.layer.title}' cannot render the variables '${t.toString()}' in this browser`)}if(!this._textureFloatLinearAvailable){const t=[];let i="";for(const r of e.layer.variables)"Float32"===r.renderingFormat.type&&(t.push(r.name),r.id===e.layer.style.currentVariableId&&(i=r.name));""!==i&&v.error("#addVoxelLayer_error()",e.layer,`The voxel layer '${e.layer.title}' cannot render the current variable '${i}' in this browser`),t.length>0&&v.warn("#addVoxelLayer_warning()",e.layer,`The voxel layer '${e.layer.title}' cannot render the variables '${t.toString()}' in this browser`)}return t("esri-mobile")&&v.warnOnce("Mobile support differs across devices. Voxel layer might not display as expected."),r}return-1}prepareRender(e){if(!this._vxl)return;const t=e.bindParameters.camera.viewForward,i=e.bindParameters.camera.eye;this._vxl.update_camera_pos_and_direction(i[0],i[1],i[2],t[0],t[1],t[2]);const r=this._vxl.cull();this._dbg(y.RequestResponse,"missingResourceCount="+r),this._moreToLoad=r>0,this._havePreparedWithAllLayers=0===this._newLayers.length,this._updateMemoryUsage()}render(e){if(!this._vxl||e.pass!==this._renderPass||e.bindParameters.slot!==this._renderSlot)return;for(const i of this._newLayers){const e=this._addVoxelLayer(i.layerView);-1===e?i.rejectCallback(-1):i.resolveCallback(e)}if(this._newLayers=[],0===this._layers.size)return void this._dbg(y.Error,"No voxel layers but RenderPlugin instance is being asked to render!");this._renderTargetToRestore={fbo:this._rctx.getBoundFramebufferObject(),viewport:this._rctx.getViewport()},this._syncRequestsResponses(),this._lastFrameWasStationary=this._view.stationary,this._rctx.setPolygonOffsetFillEnabled(!1),this._rctx.setScissorTestEnabled(!1),this._rctx.setColorMask(!0,!0,!0,!0),this._vxl.begin_color_frame(!this._view.stationary||this._moreToLoad,e.bindParameters.lighting.lightingMainDirection[0],e.bindParameters.lighting.lightingMainDirection[1],e.bindParameters.lighting.lightingMainDirection[2]);const t=this._renderTargetToRestore.viewport;t.width===this._viewportWidth&&t.height===this._viewportHeight||(this._viewportWidth=t.width,this._viewportHeight=t.height,this._vxl.set_viewport(t.width,t.height),this._layers.forEach((e=>{e.needMemoryUsageUpdate=!0}))),0===t.x&&0===t.y||this._dbg(y.Error,"Unsupported viewport parameters detected!"),this.updateWasmCamera(e.bindParameters.camera),this._vxl.draw(),this._renderTargetToRestore.fbo=null,e.rctx.externalTextureUnitUpdate(this._vxl.get_texture_units_bound_in_frame(),this._vxl.get_active_texture_unit()),e.rctx.externalVertexArrayObjectUpdate(),e.rctx.externalVertexBufferUpdate(),this._rctx.externalProgramUpdate(),(this._moreToLoad||!this._havePreparedWithAllLayers&&this._layers.size>0)&&this._renderPluginContext.requestRender()}destroy(){this._dbg(y.Lifetime,"--destroy--"),this._removeRenderPlugin(),this._readyWatchHandle=s(this._readyWatchHandle),this._qualityWatchHandle=s(this._qualityWatchHandle),this._timeExtentWatchHandle=s(this._timeExtentWatchHandle),this._stationaryWatchHandle=s(this._stationaryWatchHandle),this._vxl&&(this._layers.forEach((e=>{e.abortController.abort()})),this._wasmMemBlocks.forEach((e=>{0!==e&&this._vxl._free(e)})),this._vxl.uninitialize_voxel_wasm(),this._vxl=null)}_initializeWasm(e){return this._vxl?Promise.resolve():(this._vxlPromise||(this._vxlPromise=d(e).then((e=>{if(this._vxl=e,this._vxlPromise=null,this._newLayers.length<=0)return this._dbg(y.Lifetime," no voxel layers left after WASM downloaded, removing RenderPlugin and destroying"),void this.destroy();const i=this._getTimeArgs(this._view?.timeExtent),r=this._vxl.addFunction(this._restoreFramebuffer.bind(this),"v"),s=this._vxl.addFunction(this._setBlendState.bind(this),"viiii"),n=this._vxl.addFunction(this._setFrontFace.bind(this),"vi"),a=this._vxl.addFunction(this._setRasterizerState.bind(this),"vi"),o=this._vxl.addFunction(this._setDepthStencilStateFunction.bind(this),"viii"),l=this._vxl.addFunction(this._setViewport.bind(this),"viiii"),h=this._vxl.addFunction(this._bindPreviousDepthToSlot.bind(this),"iii"),d=this._vxl.addFunction(this._modifyResourceCount.bind(this),"viii"),_=this._halfIntTexturesAvailable&&!t("mac"),c=this._textureFloatLinearAvailable;this._vxl.initialize_voxel_wasm(r,s,n,a,o,l,h,d,i.startTime,i.endTime,i.useTime,_,c),this._renderPluginContext&&this._renderPluginContext.requestRender()})).catch((()=>{for(const e of this._newLayers)e.rejectCallback(-2);this._dbg(y.Error," WASM failed to download, removing RenderPlugin and destroying"),this.destroy()}))),this._vxlPromise)}pickDepth(e,t,i){if(!this._vxl||!this._rctx||0===this._layers.size)return null;const r=i.viewport[3]-t;if(e<0||e>i.viewport[2]||t<0||t>i.viewport[3])return this._dbg(y.Error,`pickDepth: outOfRange, screenXY=[${e}, ${r}], vp=[${i.viewport.toString()}]`),null;this._renderTargetToRestore={fbo:this._rctx.getBoundFramebufferObject(),viewport:this._rctx.getViewport()};const s=i.viewForward,n=i.eye;this._vxl.update_camera_pos_and_direction(n[0],n[1],n[2],s[0],s[1],s[2]),this.updateWasmCamera(i),this._vxl.begin_frame();const a=this._vxl.pick_depth(e,r);if(this._renderTargetToRestore.fbo=null,this._rctx.externalTextureUnitUpdate(this._vxl.get_texture_units_bound_in_frame(),this._vxl.get_active_texture_unit()),this._rctx.externalVertexArrayObjectUpdate(),this._rctx.externalVertexBufferUpdate(),this._rctx.externalProgramUpdate(),a.success){return a.distanceToCamera}return null}_toWasmQuality(e){switch(e){case"low":return 0;case"medium":return 1;case"high":return 2}}}export{p 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.24/esri/copyright.txt for details.
4
4
  */
5
- class t{constructor(t=[],e=[],s=!1){this.lengths=t??[],this.coords=e??[],this.hasIndeterminateRingOrder=s}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((t,e)=>t+e))}forEachVertex(t){let e=0;this.lengths.length||t(this.coords[0],this.coords[1]);for(let s=0;s<this.lengths.length;s++){const h=this.lengths[s];for(let s=0;s<h;s++){t(this.coords[2*(s+e)],this.coords[2*(s+e)+1])}e+=h}}clone(e){return e?(e.set(this.coords),new t(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new t(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}export{t as default};
5
+ class t{constructor(t=[],e=[],s=!1){this.lengths=t??[],this.coords=e??[],this.hasIndeterminateRingOrder=s}static fromRect(e){const[s,h,n,r]=e,i=n-s,o=r-h;return new t([5],[s,h,i,0,0,o,-i,0,0,-o])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((t,e)=>t+e))}forEachVertex(t){let e=0;this.lengths.length||t(this.coords[0],this.coords[1]);for(let s=0;s<this.lengths.length;s++){const h=this.lengths[s];for(let s=0;s<h;s++){t(this.coords[2*(s+e)],this.coords[2*(s+e)+1])}e+=h}}clone(e){return e?(e.set(this.coords),new t(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new t(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}export{t 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.24/esri/copyright.txt for details.
4
4
  */
5
- import i from"../../../core/has.js";import{PooledRBush as s}from"../../../core/libs/rbush/PooledRBush.js";const d=5e4,n={minX:0,minY:0,maxX:0,maxY:0};function t(i,s,d){n.minX=s[0],n.minY=s[1],n.maxX=s[2],n.maxY=s[3],i.search(n,d)}class e{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s(9,i("esri-csp-restrictions")?i=>({minX:i[0],minY:i[1],maxX:i[2],maxY:i[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const i=new Array(this._idByBounds.size);let s=0;this._idByBounds.forEach(((d,n)=>{i[s++]=n})),this._indexInvalid=!1,this._index.clear(),this._index.load(i)}else this._boundsToLoad.length&&(this._index.load(this._boundsToLoad.filter((i=>this._idByBounds.has(i)))),this._boundsToLoad.length=0)}}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(i){const s=this._boundsById.get(i);this._boundsById.delete(i),s&&(this._idByBounds.delete(s),this._indexInvalid||this._index.remove(s))}forEachInBounds(i,s){this._loadIndex(),t(this._index,i,(i=>s(this._idByBounds.get(i))))}get(i){return this._boundsById.get(i)}has(i){return this._boundsById.has(i)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(i,s){if(!this._indexInvalid){const s=this._boundsById.get(i);s&&(this._index.remove(s),this._idByBounds.delete(s))}this._boundsById.set(i,s),s&&(this._idByBounds.set(s,i),this._indexInvalid||(this._boundsToLoad.push(s),this._boundsToLoad.length>d&&this._loadIndex()))}}export{e as BoundsStore};
5
+ import i from"../../../core/has.js";import{PooledRBush as s}from"../../../core/libs/rbush/PooledRBush.js";const d=5e4,n={minX:0,minY:0,maxX:0,maxY:0};function t(i){n.minX=i[0],n.minY=i[1],n.maxX=i[2],n.maxY=i[3]}function e(i,s,d){t(s),i.search(n,d)}class o{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s(9,i("esri-csp-restrictions")?i=>({minX:i[0],minY:i[1],maxX:i[2],maxY:i[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const i=new Array(this._idByBounds.size);let s=0;this._idByBounds.forEach(((d,n)=>{i[s++]=n})),this._indexInvalid=!1,this._index.clear(),this._index.load(i)}else this._boundsToLoad.length&&(this._index.load(this._boundsToLoad.filter((i=>this._idByBounds.has(i)))),this._boundsToLoad.length=0)}}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(i){const s=this._boundsById.get(i);this._boundsById.delete(i),s&&(this._idByBounds.delete(s),this._indexInvalid||this._index.remove(s))}forEachInBounds(i,s){this._loadIndex(),e(this._index,i,(i=>s(this._idByBounds.get(i))))}get(i){return this._boundsById.get(i)}has(i){return this._boundsById.has(i)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(i,s){if(!this._indexInvalid){const s=this._boundsById.get(i);s&&(this._index.remove(s),this._idByBounds.delete(s))}this._boundsById.set(i,s),s&&(this._idByBounds.set(s,i),this._indexInvalid||(this._boundsToLoad.push(s),this._boundsToLoad.length>d&&this._loadIndex()))}}export{o as BoundsStore};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import CornersGeoreference = __esri.CornersGeoreference;
4
+ export default CornersGeoreference;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as t}from"../../chunks/tslib.es6.js";import{isNone as o}from"../../core/maybe.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import s from"../../geometry/Point.js";import{fromValues as p}from"../../geometry/support/aaBoundingRect.js";import i from"./GeoreferenceBase.js";let m=class extends i{constructor(t){super(t),this.bottomLeft=null,this.bottomRight=null,this.topLeft=null,this.topRight=null,this.type="corners"}get bounds(){const{coords:t}=this;if(o(t))return null;const r=t.map((t=>t[0])),e=t.map((t=>t[1])),s=Math.min(...r),i=Math.min(...e),m=Math.max(...r),n=Math.max(...e);return p(s,i,m,n)}get coords(){const{topLeft:t,topRight:r,bottomLeft:e,bottomRight:s}=this;return o(t)||o(r)||o(e)||o(s)?null:[[e.x,e.y],[t.x,t.y],[r.x,r.y],[s.x,s.y]]}};t([r({readOnly:!0})],m.prototype,"bounds",null),t([r({readOnly:!0})],m.prototype,"coords",null),t([r({type:s})],m.prototype,"bottomLeft",void 0),t([r({type:s})],m.prototype,"bottomRight",void 0),t([r({type:s})],m.prototype,"topLeft",void 0),t([r({type:s})],m.prototype,"topRight",void 0),m=t([e("esri.layers.support.CornersGeoreference")],m);const n=m;export{n as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import ExtentAndRotationGeoreference = __esri.ExtentAndRotationGeoreference;
4
+ export default ExtentAndRotationGeoreference;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as t}from"../../chunks/tslib.es6.js";import{isNone as o}from"../../core/maybe.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import{t as s}from"../../chunks/common.js";import n from"../../geometry/Extent.js";import{fromValues as i}from"../../geometry/support/aaBoundingRect.js";import a from"./GeoreferenceBase.js";let p=class extends a{constructor(t){super(t),this.extent=null,this.rotation=0,this.type="extent-and-rotation"}get bounds(){const{coords:t}=this;if(o(t))return null;const r=t.map((t=>t[0])),e=t.map((t=>t[1])),s=Math.min(...r),n=Math.min(...e),a=Math.max(...r),p=Math.max(...e);return i(s,n,a,p)}get coords(){if(o(this.extent))return null;const{xmin:t,ymin:r,xmax:e,ymax:s}=this.extent;if(!this.rotation)return[[t,r],[t,s],[e,s],[e,r]];const{x:n,y:i}=this.extent.center,a=c(n,i,this.rotation);return[a(t,r),a(t,s),a(e,s),a(e,r)]}};function c(t,o,r){const e=s(r),n=Math.cos(e),i=Math.sin(e);return(r,e)=>[n*(r-t)+i*(e-o)+t,n*(e-o)-i*(r-t)+o]}t([r({readOnly:!0})],p.prototype,"bounds",null),t([r({readOnly:!0})],p.prototype,"coords",null),t([r({type:n})],p.prototype,"extent",void 0),t([r({type:Number})],p.prototype,"rotation",void 0),p=t([e("esri.layers.support.ExtentAndRotationGeoreference")],p);const m=p;export{m 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.24/esri/copyright.txt for details.
4
4
  */
5
- import{_ as r}from"../../chunks/tslib.es6.js";import{JSONSupport as o}from"../../core/JSONSupport.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";let t=class extends o{constructor(){super(...arguments),this.type=null}};r([s({type:["selection","cluster"],readOnly:!0,json:{read:!1,write:!0}})],t.prototype,"type",void 0),t=r([e("esri.layers.support.FeatureReduction")],t);export{t as FeatureReduction};
5
+ import{_ as r}from"../../chunks/tslib.es6.js";import{JSONSupport as o}from"../../core/JSONSupport.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";let t=class extends o{constructor(){super(...arguments),this.type=null}};r([s({type:["selection","cluster","binning"],readOnly:!0,json:{read:!1,write:!0}})],t.prototype,"type",void 0),t=r([e("esri.layers.support.FeatureReduction")],t);export{t as FeatureReduction};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import r from"../../PopupTemplate.js";import"../../renderers/ClassBreaksRenderer.js";import"../../renderers/DictionaryRenderer.js";import"../../renderers/DotDensityRenderer.js";import"../../renderers/HeatmapRenderer.js";import"../../renderers/Renderer.js";import"../../renderers/SimpleRenderer.js";import"../../renderers/UniqueValueRenderer.js";import"../../renderers/support/jsonUtils.js";import{rendererTypes as o}from"../../renderers/support/types.js";import{clone as t}from"../../core/lang.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/accessorSupport/ensureType.js";import{enumeration as i}from"../../core/accessorSupport/decorators/enumeration.js";import{subclass as p}from"../../core/accessorSupport/decorators/subclass.js";import n from"./AggregateField.js";import{labelsVisible as l,popupEnabled as a}from"./commonProperties.js";import{FeatureReduction as d}from"./FeatureReduction.js";import m from"./LabelClass.js";var u;let c=u=class extends d{constructor(){super(...arguments),this.type="binning",this.fixedBinLevel=3,this.labelingInfo=null,this.labelsVisible=!0,this.popupEnabled=!0,this.popupTemplate=null,this.fields=[]}clone(){return new u({fields:t(this.fields),fixedBinLevel:this.fixedBinLevel,labelingInfo:t(this.labelingInfo),labelsVisible:this.labelsVisible,popupEnabled:this.popupEnabled,popupTemplate:t(this.popupTemplate),renderer:t(this.renderer)})}};e([i({binning:"binning"})],c.prototype,"type",void 0),e([s({type:Number,json:{write:!0}})],c.prototype,"fixedBinLevel",void 0),e([s({type:[m],json:{read:{source:"drawingInfo.labelingInfo"},write:{target:"drawingInfo.labelingInfo"}}})],c.prototype,"labelingInfo",void 0),e([s(l)],c.prototype,"labelsVisible",void 0),e([s(a)],c.prototype,"popupEnabled",void 0),e([s({type:r,json:{name:"popupInfo",write:!0}})],c.prototype,"popupTemplate",void 0),e([s({type:[n],json:{write:!0,origins:{"web-document":{write:!1},"portal-item":{write:!1}}}})],c.prototype,"fields",void 0),e([s({types:o,json:{write:!0}})],c.prototype,"renderer",void 0),c=u=e([p("esri.layers.support.FeatureReductionBinning")],c);const f=c;export{f as default};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as r}from"../../chunks/tslib.es6.js";import{Clonable as s}from"../../core/Clonable.js";import"../../core/Logger.js";import"../../core/accessorSupport/ensureType.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/set.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";let e=class extends s{};e=r([o("esri.layers.support.GeoreferenceBase")],e);const t=e;export{t as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import ImageElement = __esri.ImageElement;
4
+ export default ImageElement;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import s from"../../request.js";import o from"../../core/Logger.js";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import a from"./MediaElementBase.js";let i=class extends a{constructor(e){super(e),this.loadedImage=null,this.type="image",this.image=null}load(){const e=this.image;if("string"==typeof e){const o=s(e,{responseType:"image"}).then((({data:e})=>{this._set("loadedImage",e)}));this.addResolvingPromise(o)}else if(e instanceof HTMLImageElement){const s=e.decode().then((()=>{this._set("loadedImage",e)}));this.addResolvingPromise(s)}else this._set("loadedImage",e);return Promise.resolve(this)}set image(e){"not-loaded"===this.loadStatus?this._set("image",e):o.getLogger(this.declaredClass).error("#image","Image cannot be changed after it was loaded.")}};e([t()],i.prototype,"image",null),e([t({readOnly:!0})],i.prototype,"loadedImage",void 0),i=e([r("esri.layers.support.ImageElement")],i);const m=i;export{m as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import LocalMediaElementSource = __esri.LocalMediaElementSource;
4
+ export default LocalMediaElementSource;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import t from"../../core/Collection.js";import{referenceSetter as s}from"../../core/collectionUtils.js";import o from"../../core/Evented.js";import{HandleOwnerMixin as r}from"../../core/HandleOwner.js";import{unwrap as i,isSome as n}from"../../core/maybe.js";import{throwIfAborted as m}from"../../core/promiseUtils.js";import{watch as a}from"../../core/reactiveUtils.js";import{property as c}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as p}from"../../core/accessorSupport/decorators/subclass.js";import{fromExtent as d}from"../../geometry/support/aaBoundingRect.js";import{extentIntersectsRings as l}from"../../geometry/support/intersectsBase.js";import{BoundsStore as h}from"../graphics/data/BoundsStore.js";import u from"./ImageElement.js";const f={key:"type",defaultKeyValue:"image",base:u,typeMap:{image:u}},j=t.ofType(f);let y=class extends(r(o.EventedAccessor)){constructor(e){super(e),this._index=new h,this.elements=new j}initialize(){this.handles.add(this.elements.on("change",(e=>{this._updateIndex(e.added,e.removed)}))),this._updateIndex(this.elements.items,[])}set elements(e){this._set("elements",s(e,this._get("elements"),j))}async queryElements(e,t){await Promise.resolve(),m(t);const s=[];return this._index.forEachInBounds(d(e),(t=>{const o=i(t.georeference)?.coords;n(o)&&l(e,[o])&&s.push(t)})),s}_updateIndex(e,t){for(const s of t)this._index.delete(s),this.handles.remove(s);for(const s of e){const e=a((()=>i(s.georeference)?.bounds),(()=>this._updateIndexForElement(s,!1)));this._updateIndexForElement(s,!0),this.handles.add(e,s)}this.emit("refresh")}_updateIndexForElement(e,t){const s=i(e.georeference)?.bounds,o=this._index.has(e),r=null!=s;this._index.delete(e),n(s)&&this._index.set(e,s),t||o===r||this.emit("refresh")}};e([c()],y.prototype,"elements",null),y=e([p("esri.layers.support.LocalMediaElementSource")],y);const _=y;export{_ as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import MediaElementBase = __esri.MediaElementBase;
4
+ export default MediaElementBase;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
+ */
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import r from"../../core/Loadable.js";import{property as o}from"../../core/accessorSupport/decorators/property.js";import"../../core/arrayUtils.js";import"../../core/has.js";import"../../core/accessorSupport/ensureType.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";import t from"./CornersGeoreference.js";import p from"./ExtentAndRotationGeoreference.js";import c from"./GeoreferenceBase.js";const a={key:"type",base:c,typeMap:{corners:t,"extent-and-rotation":p}};let i=class extends r{constructor(){super(...arguments),this.georeference=null,this.opacity=1}};e([o({types:a})],i.prototype,"georeference",void 0),e([o()],i.prototype,"opacity",void 0),i=e([s("esri.layers.support.MediaElementBase")],i);const n=i;export{n as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import RouteStopSymbols = __esri.RouteStopSymbols;
4
+ export default RouteStopSymbols;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import RouteSymbols = __esri.RouteSymbols;
4
+ export default RouteSymbols;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import VoxelFormat = __esri.VoxelFormat;
4
+ export default VoxelFormat;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import VoxelStyle = __esri.VoxelStyle;
4
+ export default VoxelStyle;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import VoxelVariable = __esri.VoxelVariable;
4
+ export = VoxelVariable;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import VoxelVolume = __esri.VoxelVolume;
4
+ export default VoxelVolume;
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import VoxelVolumeStyle = __esri.VoxelVolumeStyle;
4
+ export = VoxelVolumeStyle;
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as e}from"../../core/maybe.js";import{urlToObject as r,removeTrailingSlash as t,removeQueryParameters as s,join as n,Url as u,makeAbsolute as i}from"../../core/urlUtils.js";import{w as l}from"../../chunks/persistableUrlUtils.js";const o={mapserver:"MapServer",imageserver:"ImageServer",featureserver:"FeatureServer",sceneserver:"SceneServer",streamserver:"StreamServer",vectortileserver:"VectorTileServer"},c=Object.values(o),a=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/rest\\/services\\/(.+?)\\/(${c.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),f=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/([^\\/\\n]+)\\/(${c.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),v=/(.*?)\/(?:layers\/)?(\d+)\/?$/i;function p(e){return!!a.test(e)}function d(e){const t=r(e),s=t.path.match(a)||t.path.match(f);if(!s)return null;const[,n,u,i,l]=s,c=u.indexOf("/");return{title:w(-1!==c?u.slice(c+1):u),serverType:o[i.toLowerCase()],sublayer:null!=l&&""!==l?parseInt(l,10):null,url:{path:n}}}function m(e){const t=r(e).path.match(v);return t?{serviceUrl:t[1],sublayerId:Number(t[2])}:null}function w(e){return(e=e.replace(/\s*[/_]+\s*/g," "))[0].toUpperCase()+e.slice(1)}function h(r,t){const s=[];if(r){const t=d(r);e(t)&&t.title&&s.push(t.title)}if(t){const e=w(t);s.push(e)}if(2===s.length){if(s[0].toLowerCase().includes(s[1].toLowerCase()))return s[0];if(s[1].toLowerCase().includes(s[0].toLowerCase()))return s[1]}return s.join(" - ")}function y(e){if(!e)return!1;const r=".arcgis.com/",t="//services",s="//tiles",n="//features",u=(e=e.toLowerCase()).includes(r),i=e.includes(t)||e.includes(s)||e.includes(n);return u&&i}function g(e,r){return r&&e&&e.toLowerCase().includes(r.toLowerCase())}function C(e,r){return e?t(s(e,r)):e}function S(n){let{url:u}=n;if(!u)return{url:u};u=s(u,n.logger);const i=r(u),l=d(i.path);let o;if(e(l))null!=l.sublayer&&null==n.layer.layerId&&(o=l.sublayer),u=l.url.path;else if(n.nonStandardUrlAllowed){const r=m(i.path);e(r)&&(u=r.serviceUrl,o=r.sublayerId)}return{url:t(u),layerId:o}}function L(e,r,t,s,u){l(r,s,"url",u),s.url&&null!=e.layerId&&(s.url=n(s.url,t,e.layerId.toString()))}function b(e){if(!e)return!1;const r=e.toLowerCase(),t=r.includes("/services/"),s=r.includes("/mapserver/wmsserver"),n=r.includes("/imageserver/wmsserver"),u=r.includes("/wmsserver");return t&&(s||n||u)}function I(e){if(!e)return!1;const r=new u(i(e)).authority.toLowerCase();return"server.arcgisonline.com"===r||"services.arcgisonline.com"===r}function j(e){if(!e)return!1;return new u(i(e)).authority.toLowerCase().includes("arcgis.com")}export{w as cleanTitle,j as isAGOLUrl,p as isArcGISUrl,y as isHostedAgolService,g as isHostedSecuredProxyService,I as isServerOrServicesAGOLUrl,b as isWmsServer,d as parse,m as parseNonStandardSublayerUrl,C as sanitizeUrl,S as sanitizeUrlWithLayerId,c as serverTypes,h as titleFromUrlAndName,L as writeUrlWithLayerId};
5
+ import{isNone as e,isSome as r}from"../../core/maybe.js";import{urlToObject as t,removeTrailingSlash as n,removeQueryParameters as s,join as u,Url as i,makeAbsolute as l}from"../../core/urlUtils.js";import{w as o}from"../../chunks/persistableUrlUtils.js";const c={mapserver:"MapServer",imageserver:"ImageServer",featureserver:"FeatureServer",sceneserver:"SceneServer",streamserver:"StreamServer",vectortileserver:"VectorTileServer"},a=Object.values(c),f=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/rest\\/services\\/(.+?)\\/(${a.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),v=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/([^\\/\\n]+)\\/(${a.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),p=/(.*?)\/(?:layers\/)?(\d+)\/?$/i;function d(e){return!!f.test(e)}function m(r){if(e(r))return null;const n=t(r),s=n.path.match(f)||n.path.match(v);if(!s)return null;const[,u,i,l,o]=s,a=i.indexOf("/");return{title:h(-1!==a?i.slice(a+1):i),serverType:c[l.toLowerCase()],sublayer:null!=o&&""!==o?parseInt(o,10):null,url:{path:u}}}function w(e){const r=t(e).path.match(p);return r?{serviceUrl:r[1],sublayerId:Number(r[2])}:null}function h(e){return(e=e.replace(/\s*[/_]+\s*/g," "))[0].toUpperCase()+e.slice(1)}function y(e,t){const n=[];if(e){const t=m(e);r(t)&&t.title&&n.push(t.title)}if(t){const e=h(t);n.push(e)}if(2===n.length){if(n[0].toLowerCase().includes(n[1].toLowerCase()))return n[0];if(n[1].toLowerCase().includes(n[0].toLowerCase()))return n[1]}return n.join(" - ")}function g(e){if(!e)return!1;const r=".arcgis.com/",t="//services",n="//tiles",s="//features",u=(e=e.toLowerCase()).includes(r),i=e.includes(t)||e.includes(n)||e.includes(s);return u&&i}function C(e,r){return r&&e&&e.toLowerCase().includes(r.toLowerCase())}function S(e,r){return e?n(s(e,r)):e}function L(e){let{url:u}=e;if(!u)return{url:u};u=s(u,e.logger);const i=t(u),l=m(i.path);let o;if(r(l))null!=l.sublayer&&null==e.layer.layerId&&(o=l.sublayer),u=l.url.path;else if(e.nonStandardUrlAllowed){const e=w(i.path);r(e)&&(u=e.serviceUrl,o=e.sublayerId)}return{url:n(u),layerId:o}}function b(e,r,t,n,s){o(r,n,"url",s),n.url&&null!=e.layerId&&(n.url=u(n.url,t,e.layerId.toString()))}function I(e){if(!e)return!1;const r=e.toLowerCase(),t=r.includes("/services/"),n=r.includes("/mapserver/wmsserver"),s=r.includes("/imageserver/wmsserver"),u=r.includes("/wmsserver");return t&&(n||s||u)}function j(e){if(!e)return!1;const r=new i(l(e)).authority.toLowerCase();return"server.arcgisonline.com"===r||"services.arcgisonline.com"===r}function U(e){if(!e)return!1;return new i(l(e)).authority.toLowerCase().includes("arcgis.com")}export{h as cleanTitle,U as isAGOLUrl,d as isArcGISUrl,g as isHostedAgolService,C as isHostedSecuredProxyService,j as isServerOrServicesAGOLUrl,I as isWmsServer,m as parse,w as parseNonStandardSublayerUrl,S as sanitizeUrl,L as sanitizeUrlWithLayerId,a as serverTypes,y as titleFromUrlAndName,b as writeUrlWithLayerId};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import{FeatureReduction as e}from"./FeatureReduction.js";import t from"./FeatureReductionCluster.js";import o from"./FeatureReductionSelection.js";const p={key:"type",base:e,typeMap:{selection:t}},s={types:{key:"type",base:e,typeMap:{selection:o,cluster:t}},json:{name:"layerDefinition.featureReduction",write:{allowNull:!0},origins:{"web-map":{types:p},"portal-item":{types:p},"web-scene":{types:{key:"type",base:e,typeMap:{selection:o}}}}}};export{s as featureReductionProperty};
5
+ import{FeatureReduction as e}from"./FeatureReduction.js";import t from"./FeatureReductionBinning.js";import i from"./FeatureReductionCluster.js";import o from"./FeatureReductionSelection.js";const n={key:"type",base:e,typeMap:{selection:i}},p={types:{key:"type",base:e,typeMap:{selection:o,cluster:i,binning:t}},json:{name:"layerDefinition.featureReduction",write:{allowNull:!0},origins:{"web-map":{types:n},"portal-item":{types:n},"web-scene":{types:{key:"type",base:e,typeMap:{selection:o}}}}}};export{p as featureReductionProperty};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../core/Error.js";import{isNone as n,isSome as i}from"../../core/maybe.js";import{getDeepValue as t,setDeepValue as r}from"../../core/object.js";import{validateDomainValue as o,getDomainRange as l,DomainValidationError as s}from"./domainUtils.js";import{loadArcade as a}from"../../support/arcadeOnDemand.js";const u=["field","field2","field3","normalizationField","rotationInfo.field","proportionalSymbolInfo.field","proportionalSymbolInfo.normalizationField","colorInfo.field","colorInfo.normalizationField"],f=["field","normalizationField"];function c(e,n){if(null!=e&&null!=n)for(const i of Array.isArray(e)?e:[e])if(d(u,i,n),"visualVariables"in i&&i.visualVariables)for(const e of i.visualVariables)d(f,e,n)}function d(e,n,i){if(e)for(const o of e){const e=t(o,n),l=e&&"function"!=typeof e&&i.get(e);l&&r(o,l.name,n)}}function m(e,n){if(null!=e&&n?.fields.length)if("startField"in e){const i=n.get(e.startField),t=n.get(e.endField);e.startField=i&&i.name||null,e.endField=t&&t.name||null}else{const i=n.get(e.startTimeField),t=n.get(e.endTimeField);e.startTimeField=i&&i.name||null,e.endTimeField=t&&t.name||null}}const p=new Set;function y(e,n){return e&&n?(p.clear(),g(p,e,n),Array.from(p).sort()):[]}function g(e,n,i){if(i)if(n?.fields?.length)if(i.includes("*"))for(const{name:t}of n.fields)e.add(t);else for(const t of i)F(e,n,t);else{if(i.includes("*"))return e.clear(),void e.add("*");for(const n of i)e.add(n)}}function F(e,n,i){if("string"==typeof i)if(n){const t=n.get(i);t&&e.add(t.name)}else e.add(i)}function I(e,i){return n(i)||n(e)?[]:i.includes("*")?e.fields.map((e=>e.name)):i}function x(e,n,i=1){if(!n||!e)return[];if(n.includes("*"))return["*"];const t=y(e,n);return t.length/e.fields.length>=i?["*"]:t}async function b(e,n,i){if(!i)return;const{arcadeUtils:t}=await a(),r=t.extractFieldNames(i,n?.fields?.map((e=>e.name)));for(const o of r)F(e,n,o)}async function T(n,i,t){if(t&&"1=1"!==t){const r=(await import("../../core/sql/WhereClause.js")).WhereClause.create(t,i);if(!r.isStandardized)throw new e("fieldUtils:collectFilterFields","Where clause is not standardized");g(n,i,r.fieldNames)}}function h({displayField:e,fields:n}){return e||(n&&n.length?S(n,"name-or-title")||S(n,"unique-identifier")||S(n,"type-or-category")||w(n):null)}function w(e){for(const n of e){if(!n||!n.name)continue;const e=n.name.toLowerCase();if(e.includes("name")||e.includes("title"))return n.name}return null}function S(e,n){for(const i of e)if(i&&i.valueType&&i.valueType===n)return i.name;return null}async function v(e){if(!e)return[];const n=new Set;return await A(n,e),Array.from(n).sort()}async function A(e,n){if(!n)return;const i=t("elevationInfo.featureExpressionInfo",n);return i?i.collectRequiredFields(e,n.fieldsIndex):void 0}async function E(e,n,i){i.outStatistic.onStatisticValueExpression?b(e,n,i.outStatistic.onStatisticValueExpression):e.add(i.outStatistic.onStatisticField)}async function N(e,n,i){if(!n||!i||"cluster"!==i.type)return;const t=[];if(i.popupTemplate?.expressionInfos&&t.push(...i.popupTemplate.expressionInfos.map((i=>b(e,n.fieldsIndex,i.expression)))),Array.isArray(i.popupTemplate?.content)){const r=i.popupTemplate.content;for(const i of r)"expression"===i.type&&i.expressionInfo&&t.push(b(e,n.fieldsIndex,i.expressionInfo.expression))}i.fields&&t.push(...i.fields.map((i=>E(e,n.fieldsIndex,i)))),await Promise.all(t)}async function V(e,n,t){n&&(n.timeInfo&&i(t)&&t.timeExtent&&g(e,n.fieldsIndex,[n.timeInfo.startField,n.timeInfo.endField]),n.floorInfo&&g(e,n.fieldsIndex,[n.floorInfo.floorField]),i(t)&&i(t.where)&&await T(e,n.fieldsIndex,t.where))}async function _(e,n,i){n&&i&&await Promise.all(i.map((i=>D(e,n,i))))}async function D(e,n,i){n&&i&&(i.valueExpression?await b(e,n.fieldsIndex,i.valueExpression):i.field&&F(e,n.fieldsIndex,i.field))}async function $(e){if(!e)return[];const n="timeInfo"in e&&e.timeInfo;return n?y(e.fieldsIndex,[e.trackIdField,n.startField,n.endField]):[]}function L(e){if(!e)return[];const n="editFieldsInfo"in e&&e.editFieldsInfo;return n?y(e.fieldsIndex,[n&&n.creatorField,n&&n.creationDateField,n&&n.editorField,n&&n.editDateField]):[]}function O(e){if(!e)return[];const n=e.geometryFieldsInfo;return n?y(e.fieldsIndex,[n.shapeAreaField,n.shapeLengthField]):[]}async function U(e){if(!e)return[];const n=new Set;return await j(n,e),Array.from(n).sort()}async function j(e,n){const{labelingInfo:i,fieldsIndex:t}=n;i&&i.length&&await Promise.all(i.map((n=>z(e,t,n))))}async function z(e,n,i){if(!i)return;const t=i.getLabelExpression(),r=i.where;if("arcade"===t.type)await b(e,n,t.expression);else{const i=t.expression.match(/{[^}]*}/g);i&&i.forEach((i=>{F(e,n,i.slice(1,-1))}))}await T(e,n,r)}function P(e){const n=e.defaultValue;return void 0!==n&&Y(e,n)?n:e.nullable?null:void 0}function k(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}function C(e){return null===e||k(e)}const R="isInteger"in Number?Number.isInteger:e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e;function G(e){return null===e||R(e)}function W(e){return null!=e&&"string"==typeof e}function q(e){return null===e||W(e)}function M(){return!0}function Y(e,n){let i;switch(e.type){case"date":case"integer":case"long":case"small-integer":case"esriFieldTypeDate":case"esriFieldTypeInteger":case"esriFieldTypeLong":case"esriFieldTypeSmallInteger":i=e.nullable?G:R;break;case"double":case"single":case"esriFieldTypeSingle":case"esriFieldTypeDouble":i=e.nullable?C:k;break;case"string":case"esriFieldTypeString":i=e.nullable?q:W;break;default:i=M}return 1===arguments.length?i:i(n)}const J=["integer","small-integer","single","double"],X=new Set([...J,"esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeSingle","esriFieldTypeDouble"]);function B(e){return null!=e&&X.has(e.type)}function H(e){return null!=e&&("string"===e.type||"esriFieldTypeString"===e.type)}function K(e){return null!=e&&("date"===e.type||"esriFieldTypeDate"===e.type)}function Q(e,n){return null===ie(e,n)}var Z,ee;function ne(e){return null==e||"number"==typeof e&&isNaN(e)?null:e}function ie(e,n){return e.nullable&&null===n?null:B(e)&&!te(e.type,Number(n))?Z.OUT_OF_RANGE:Y(e,n)?e.domain?o(e.domain,n):null:ee.INVALID_TYPE}function te(e,n){const i="string"==typeof e?oe(e):e;return!!i&&(i.isInteger?R(n)&&n>=i.min&&n<=i.max:n>=i.min&&n<=i.max)}function re(e){const n=l(e.domain);return n||(B(e)?oe(e.type):void 0)}function oe(e){switch(e){case"esriFieldTypeSmallInteger":case"small-integer":return se;case"esriFieldTypeInteger":case"integer":return ae;case"esriFieldTypeSingle":case"single":return ue;case"esriFieldTypeDouble":case"double":return fe}}function le(e){if(!k(e))return null;if(R(e)){if(e>=se.min&&e<=se.max)return"esriFieldTypeSmallInteger";if(e>=ae.min&&e<=ae.max)return"esriFieldTypeInteger"}return e>=ue.min&&e<=ue.max?"esriFieldTypeSingle":"esriFieldTypeDouble"}!function(e){e.OUT_OF_RANGE="numeric-range-validation-error::out-of-range"}(Z||(Z={})),function(e){e.INVALID_TYPE="type-validation-error::invalid-type"}(ee||(ee={}));const se={min:-32768,max:32767,isInteger:!0},ae={min:-2147483648,max:2147483647,isInteger:!0},ue={min:-34e37,max:12e37,isInteger:!1},fe={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1};function ce(e,n,i){switch(e){case s.INVALID_CODED_VALUE:return`Value ${i} is not in the coded domain - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case s.VALUE_OUT_OF_RANGE:return`Value ${i} is out of the range of valid values - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case ee.INVALID_TYPE:return`Value ${i} is not a valid value for the field type - field: ${n.name}, type: ${n.type}, nullable: ${n.nullable}`;case Z.OUT_OF_RANGE:{const{min:e,max:t}=oe(n.type);return`Value ${i} is out of range for the number type - field: ${n.name}, type: ${n.type}, value range is ${e} to ${t}`}}}function de(e,n){return!me(e,n,null)}function me(e,n,t){if(!n||!n.attributes||!e){if(i(t))for(const n of e)t.add(n);return!0}const r=n.attributes;let o=!1;for(const l of e)if(!(l in r)){if(o=!0,!i(t))break;t.add(l)}return o}async function pe(e,n){const i=new Set;for(const t of n)await b(i,e.fieldsIndex,t);return Array.from(i).sort()}function ye(e){return["raster.itempixelvalue","raster.servicepixelvalue"].some((n=>e.toLowerCase().startsWith(n)))}export{Z as NumericRangeValidationError,ee as TypeValidationError,b as collectArcadeFieldNames,A as collectElevationFields,N as collectFeatureReductionFields,F as collectField,g as collectFields,V as collectFilterFields,j as collectLabelingFields,_ as collectOrderByInfos,fe as doubleRange,de as featureHasFields,y as fixFields,c as fixRendererFields,m as fixTimeInfoFields,h as getDisplayFieldName,v as getElevationFields,pe as getExpressionFields,L as getFeatureEditFields,O as getFeatureGeometryFields,P as getFieldDefaultValue,re as getFieldRange,U as getLabelingFields,le as getNumericTypeForValue,$ as getTimeFields,ae as integerRange,K as isDateField,te as isNumberInRange,B as isNumericField,ye as isRasterPixelValueField,H as isStringField,Q as isValidFieldValue,Y as isValueMatchingFieldType,J as numericTypes,x as packFields,me as populateMissingFields,u as rendererFields,ne as sanitizeNullFieldValue,ue as singleRange,se as smallIntegerRange,I as unpackFieldNames,ie as validateFieldValue,ce as validationErrorToString,f as visualVariableFields};
5
+ import e from"../../core/Error.js";import{isNone as n,isSome as i}from"../../core/maybe.js";import{getDeepValue as t,setDeepValue as r}from"../../core/object.js";import{validateDomainValue as o,getDomainRange as l,DomainValidationError as s}from"./domainUtils.js";import{loadArcade as a}from"../../support/arcadeOnDemand.js";const u=["field","field2","field3","normalizationField","rotationInfo.field","proportionalSymbolInfo.field","proportionalSymbolInfo.normalizationField","colorInfo.field","colorInfo.normalizationField"],f=["field","normalizationField"];function c(e,n){if(null!=e&&null!=n)for(const i of Array.isArray(e)?e:[e])if(d(u,i,n),"visualVariables"in i&&i.visualVariables)for(const e of i.visualVariables)d(f,e,n)}function d(e,n,i){if(e)for(const o of e){const e=t(o,n),l=e&&"function"!=typeof e&&i.get(e);l&&r(o,l.name,n)}}function m(e,n){if(null!=e&&n?.fields.length)if("startField"in e){const i=n.get(e.startField),t=n.get(e.endField);e.startField=i&&i.name||null,e.endField=t&&t.name||null}else{const i=n.get(e.startTimeField),t=n.get(e.endTimeField);e.startTimeField=i&&i.name||null,e.endTimeField=t&&t.name||null}}const p=new Set;function y(e,n){return e&&n?(p.clear(),g(p,e,n),Array.from(p).sort()):[]}function g(e,n,i){if(i)if(n?.fields?.length)if(i.includes("*"))for(const{name:t}of n.fields)e.add(t);else for(const t of i)F(e,n,t);else{if(i.includes("*"))return e.clear(),void e.add("*");for(const n of i)e.add(n)}}function F(e,n,i){if("string"==typeof i)if(n){const t=n.get(i);t&&e.add(t.name)}else e.add(i)}function I(e,i){return n(i)||n(e)?[]:i.includes("*")?e.fields.map((e=>e.name)):i}function x(e,n,i=1){if(!n||!e)return[];if(n.includes("*"))return["*"];const t=y(e,n);return t.length/e.fields.length>=i?["*"]:t}async function b(e,n,i){if(!i)return;const{arcadeUtils:t}=await a(),r=t.extractFieldNames(i,n?.fields?.map((e=>e.name)));for(const o of r)F(e,n,o)}async function T(n,i,t){if(t&&"1=1"!==t){const r=(await import("../../core/sql/WhereClause.js")).WhereClause.create(t,i);if(!r.isStandardized)throw new e("fieldUtils:collectFilterFields","Where clause is not standardized");g(n,i,r.fieldNames)}}function h({displayField:e,fields:n}){return e||(n&&n.length?S(n,"name-or-title")||S(n,"unique-identifier")||S(n,"type-or-category")||w(n):null)}function w(e){for(const n of e){if(!n||!n.name)continue;const e=n.name.toLowerCase();if(e.includes("name")||e.includes("title"))return n.name}return null}function S(e,n){for(const i of e)if(i&&i.valueType&&i.valueType===n)return i.name;return null}async function v(e){if(!e)return[];const n=new Set;return await A(n,e),Array.from(n).sort()}async function A(e,n){if(!n)return;const i=t("elevationInfo.featureExpressionInfo",n);return i?i.collectRequiredFields(e,n.fieldsIndex):void 0}async function E(e,n,i){i.outStatistic.onStatisticValueExpression?b(e,n,i.outStatistic.onStatisticValueExpression):e.add(i.outStatistic.onStatisticField)}async function N(e,n,i){if(!n||!i||!("fields"in i))return;const t=[];if(i.popupTemplate?.expressionInfos&&t.push(...i.popupTemplate.expressionInfos.map((i=>b(e,n.fieldsIndex,i.expression)))),Array.isArray(i.popupTemplate?.content)){const r=i.popupTemplate.content;for(const i of r)"expression"===i.type&&i.expressionInfo&&t.push(b(e,n.fieldsIndex,i.expressionInfo.expression))}i.fields&&t.push(...i.fields.map((i=>E(e,n.fieldsIndex,i)))),await Promise.all(t)}async function V(e,n,t){n&&(n.timeInfo&&i(t)&&t.timeExtent&&g(e,n.fieldsIndex,[n.timeInfo.startField,n.timeInfo.endField]),n.floorInfo&&g(e,n.fieldsIndex,[n.floorInfo.floorField]),i(t)&&i(t.where)&&await T(e,n.fieldsIndex,t.where))}async function _(e,n,i){n&&i&&await Promise.all(i.map((i=>D(e,n,i))))}async function D(e,n,i){n&&i&&(i.valueExpression?await b(e,n.fieldsIndex,i.valueExpression):i.field&&F(e,n.fieldsIndex,i.field))}async function $(e){if(!e)return[];const n="timeInfo"in e&&e.timeInfo;return n?y(e.fieldsIndex,[e.trackIdField,n.startField,n.endField]):[]}function L(e){if(!e)return[];const n="editFieldsInfo"in e&&e.editFieldsInfo;return n?y(e.fieldsIndex,[n&&n.creatorField,n&&n.creationDateField,n&&n.editorField,n&&n.editDateField]):[]}function O(e){if(!e)return[];const n=e.geometryFieldsInfo;return n?y(e.fieldsIndex,[n.shapeAreaField,n.shapeLengthField]):[]}async function U(e){if(!e)return[];const n=new Set;return await j(n,e),Array.from(n).sort()}async function j(e,n){const{labelingInfo:i,fieldsIndex:t}=n;i&&i.length&&await Promise.all(i.map((n=>z(e,t,n))))}async function z(e,n,i){if(!i)return;const t=i.getLabelExpression(),r=i.where;if("arcade"===t.type)await b(e,n,t.expression);else{const i=t.expression.match(/{[^}]*}/g);i&&i.forEach((i=>{F(e,n,i.slice(1,-1))}))}await T(e,n,r)}function P(e){const n=e.defaultValue;return void 0!==n&&Y(e,n)?n:e.nullable?null:void 0}function k(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}function C(e){return null===e||k(e)}const R="isInteger"in Number?Number.isInteger:e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e;function G(e){return null===e||R(e)}function W(e){return null!=e&&"string"==typeof e}function q(e){return null===e||W(e)}function M(){return!0}function Y(e,n){let i;switch(e.type){case"date":case"integer":case"long":case"small-integer":case"esriFieldTypeDate":case"esriFieldTypeInteger":case"esriFieldTypeLong":case"esriFieldTypeSmallInteger":i=e.nullable?G:R;break;case"double":case"single":case"esriFieldTypeSingle":case"esriFieldTypeDouble":i=e.nullable?C:k;break;case"string":case"esriFieldTypeString":i=e.nullable?q:W;break;default:i=M}return 1===arguments.length?i:i(n)}const J=["integer","small-integer","single","double"],X=new Set([...J,"esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeSingle","esriFieldTypeDouble"]);function B(e){return null!=e&&X.has(e.type)}function H(e){return null!=e&&("string"===e.type||"esriFieldTypeString"===e.type)}function K(e){return null!=e&&("date"===e.type||"esriFieldTypeDate"===e.type)}function Q(e,n){return null===ie(e,n)}var Z,ee;function ne(e){return null==e||"number"==typeof e&&isNaN(e)?null:e}function ie(e,n){return e.nullable&&null===n?null:B(e)&&!te(e.type,Number(n))?Z.OUT_OF_RANGE:Y(e,n)?e.domain?o(e.domain,n):null:ee.INVALID_TYPE}function te(e,n){const i="string"==typeof e?oe(e):e;return!!i&&(i.isInteger?R(n)&&n>=i.min&&n<=i.max:n>=i.min&&n<=i.max)}function re(e){const n=l(e.domain);return n||(B(e)?oe(e.type):void 0)}function oe(e){switch(e){case"esriFieldTypeSmallInteger":case"small-integer":return se;case"esriFieldTypeInteger":case"integer":return ae;case"esriFieldTypeSingle":case"single":return ue;case"esriFieldTypeDouble":case"double":return fe}}function le(e){if(!k(e))return null;if(R(e)){if(e>=se.min&&e<=se.max)return"esriFieldTypeSmallInteger";if(e>=ae.min&&e<=ae.max)return"esriFieldTypeInteger"}return e>=ue.min&&e<=ue.max?"esriFieldTypeSingle":"esriFieldTypeDouble"}!function(e){e.OUT_OF_RANGE="numeric-range-validation-error::out-of-range"}(Z||(Z={})),function(e){e.INVALID_TYPE="type-validation-error::invalid-type"}(ee||(ee={}));const se={min:-32768,max:32767,isInteger:!0},ae={min:-2147483648,max:2147483647,isInteger:!0},ue={min:-34e37,max:12e37,isInteger:!1},fe={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1};function ce(e,n,i){switch(e){case s.INVALID_CODED_VALUE:return`Value ${i} is not in the coded domain - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case s.VALUE_OUT_OF_RANGE:return`Value ${i} is out of the range of valid values - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case ee.INVALID_TYPE:return`Value ${i} is not a valid value for the field type - field: ${n.name}, type: ${n.type}, nullable: ${n.nullable}`;case Z.OUT_OF_RANGE:{const{min:e,max:t}=oe(n.type);return`Value ${i} is out of range for the number type - field: ${n.name}, type: ${n.type}, value range is ${e} to ${t}`}}}function de(e,n){return!me(e,n,null)}function me(e,n,t){if(!n||!n.attributes||!e){if(i(t))for(const n of e)t.add(n);return!0}const r=n.attributes;let o=!1;for(const l of e)if(!(l in r)){if(o=!0,!i(t))break;t.add(l)}return o}async function pe(e,n){const i=new Set;for(const t of n)await b(i,e.fieldsIndex,t);return Array.from(i).sort()}function ye(e){return["raster.itempixelvalue","raster.servicepixelvalue"].some((n=>e.toLowerCase().startsWith(n)))}export{Z as NumericRangeValidationError,ee as TypeValidationError,b as collectArcadeFieldNames,A as collectElevationFields,N as collectFeatureReductionFields,F as collectField,g as collectFields,V as collectFilterFields,j as collectLabelingFields,_ as collectOrderByInfos,fe as doubleRange,de as featureHasFields,y as fixFields,c as fixRendererFields,m as fixTimeInfoFields,h as getDisplayFieldName,v as getElevationFields,pe as getExpressionFields,L as getFeatureEditFields,O as getFeatureGeometryFields,P as getFieldDefaultValue,re as getFieldRange,U as getLabelingFields,le as getNumericTypeForValue,$ as getTimeFields,ae as integerRange,K as isDateField,te as isNumberInRange,B as isNumericField,ye as isRasterPixelValueField,H as isStringField,Q as isValidFieldValue,Y as isValueMatchingFieldType,J as numericTypes,x as packFields,me as populateMissingFields,u as rendererFields,ne as sanitizeNullFieldValue,ue as singleRange,se as smallIntegerRange,I as unpackFieldNames,ie as validateFieldValue,ce as validationErrorToString,f as visualVariableFields};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import{getAssetUrl as e}from"../../../assets.js";const t=[{pixelType:"S8",size:1,ctor:Int8Array,range:[-128,128]},{pixelType:"U8",size:1,ctor:Uint8Array,range:[0,255]},{pixelType:"S16",size:2,ctor:Int16Array,range:[-32768,32767]},{pixelType:"U16",size:2,ctor:Uint16Array,range:[0,65536]},{pixelType:"S32",size:4,ctor:Int32Array,range:[-2147483648,2147483647]},{pixelType:"U32",size:4,ctor:Uint32Array,range:[0,4294967296]},{pixelType:"F32",size:4,ctor:Float32Array,range:[-34027999387901484e22,34027999387901484e22]},{pixelType:"F64",size:8,ctor:Float64Array,range:[-17976931348623157e292,17976931348623157e292]}];let n=null,r=!1;function a(){return n||(n=import("../../../chunks/lerc-wasm.js").then((e=>e.l)).then((({default:t})=>t({locateFile:t=>e(`esri/layers/support/rasterFormats/${t}`)}))).then((e=>{o(e),r=!0})),n)}function s(){return r}const l={getBlobInfo:null,decode:null};function i(e){return 16+(e>>3<<3)}function o(e){const{_malloc:n,_free:r,_lerc_getBlobInfo:a,_lerc_getDataRanges:s,_lerc_decode_4D:o,asm:u}=e;let c;const f=Object.values(u).find((t=>t&&"buffer"in t&&t.buffer===e.HEAPU8.buffer)),y=e=>{const t=e.map((e=>i(e))),r=t.reduce(((e,t)=>e+t)),a=n(r);c=new Uint8Array(f.buffer);let s=t[0];t[0]=a;for(let n=1;n<t.length;n++){const e=t[n];t[n]=t[n-1]+s,s=e}return t};l.getBlobInfo=e=>{const t=12,n=3,l=new Uint8Array(4*t),i=new Uint8Array(8*n),[o,u,h]=y([e.length,l.length,i.length]);c.set(e,o),c.set(l,u),c.set(i,h);let p=a(o,e.length,u,h,t,n);if(p)throw r(o),`lerc-getBlobInfo: error code is ${p}`;c=new Uint8Array(f.buffer),l.set(c.slice(u,u+l.length)),i.set(c.slice(h,h+i.length));const g=new Uint32Array(l.buffer),d=new Float64Array(i.buffer),[b,m,A,w,U,x,T,C,V,,D]=g,z={version:b,dimCount:A,width:w,height:U,validPixelCount:T,bandCount:x,blobSize:C,maskCount:V,dataType:m,minValue:d[0],maxValue:d[1],maxZerror:d[2],statistics:[],bandCountWithNoData:D};if(D)return z;if(1===A&&1===x)return r(o),z.statistics.push({minValue:d[0],maxValue:d[1]}),z;const I=A*x*8,F=new Uint8Array(I),_=new Uint8Array(I);let k,B=o,v=0,S=!1;if(c.byteLength<o+2*I?(r(o),S=!0,[B,v,k]=y([e.length,I,I]),c.set(e,B)):[v,k]=y([I,I]),c.set(F,v),c.set(_,k),p=s(o,e.length,A,x,v,k),p)throw r(B),S||r(v),`lerc-getDataRanges: error code is ${p}`;c=new Uint8Array(f.buffer),F.set(c.slice(v,v+I)),_.set(c.slice(k,k+I));const O=new Float64Array(F.buffer),$=new Float64Array(_.buffer),j=z.statistics;for(let r=0;r<x;r++)if(A>1){const e=O.slice(r*A,(r+1)*A),t=$.slice(r*A,(r+1)*A),n=Math.min.apply(null,e),a=Math.max.apply(null,t);j.push({minValue:n,maxValue:a,dimStats:{minValues:e,maxValues:t}})}else j.push({minValue:O[r],maxValue:$[r]});return r(B),S||r(v),z},l.decode=(e,n)=>{const{maskCount:a,dimCount:s,bandCount:l,width:i,height:u,dataType:h,bandCountWithNoData:p}=n,g=t[h],d=i*u,b=new Uint8Array(d*l),m=d*s*l*g.size,A=new Uint8Array(m),w=new Uint8Array(l),U=8*l,x=new Uint8Array(U),[T,C,V,D,z]=y([e.length,b.length,A.length,w.length,x.length]);c.set(e,T),c.set(b,C),c.set(A,V),c.set(w,D),c.set(x,z);const I=o(T,e.length,a,C,s,i,u,l,h,V,D,z);if(I)throw r(T),`lerc-decode: error code is ${I}`;c=new Uint8Array(f.buffer),A.set(c.slice(V,V+m)),b.set(c.slice(C,C+b.length));let F=null;if(p){w.set(c.slice(D,D+l)),x.set(c.slice(z,z+U)),F=[];for(let e=0;e<w.length;e++)F.push(w[e]?x[e]:null)}return r(T),{data:A,maskData:b,noDataValues:F}}}function u(e,t,n,r,a){if(n<2)return e;const s=new r(t*n);if(a)for(let l=0,i=0;l<t;l++)for(let r=0,a=l;r<n;r++,a+=t)s[a]=e[i++];else for(let l=0,i=0;l<t;l++)for(let r=0,a=l;r<n;r++,a+=t)s[i++]=e[a];return s}function c(e,n={}){const r=n.inputOffset??0,a=e instanceof Uint8Array?e.subarray(r):new Uint8Array(e,r),s=l.getBlobInfo(a),{data:i,maskData:o}=l.decode(a,s),{width:c,height:f,bandCount:y,dimCount:h,dataType:p,maskCount:g,statistics:d}=s,b=t[p],m=new b.ctor(i.buffer),A=[],w=[],U=c*f,x=U*h;for(let t=0;t<y;t++){const e=m.subarray(t*x,(t+1)*x);if(n.returnPixelInterleavedDims)A.push(e);else{const t=u(e,U,h,b.ctor,!0);A.push(t)}w.push(o.subarray(t*x,(t+1)*x))}const T=0===g?null:1===g?w[0]:new Uint8Array(U);if(g>1){T.set(w[0]);for(let e=1;e<w.length;e++){const t=w[e];for(let e=0;e<U;e++)T[e]=T[e]&t[e]}}const{noDataValue:C}=n,V=null!=C&&b.range[0]<=C&&b.range[1]>=C;if(g>0&&V){const{noDataValue:e}=n;for(let t=0;t<y;t++){const n=A[t],r=w[t]||T;for(let t=0;t<U;t++)0===r[t]&&(n[t]=e)}}const D=g===y&&y>1?w:null;return{width:c,height:f,bandCount:y,pixelType:n.pixelType&&0===s.version?n.pixelType:b.pixelType,dimCount:h,statistics:d,pixels:A,mask:T,bandMasks:D}}function f(e,t={}){const n=e instanceof Uint8Array?e.subarray(t.inputOffset??0):new Uint8Array(e,t.inputOffset??0);return l.getBlobInfo(n)}export{c as decode,f as getBlobInfo,s as isLoaded,a as load};
5
+ import{getAssetUrl as e}from"../../../assets.js";const t=[{pixelType:"S8",size:1,ctor:Int8Array,range:[-128,128]},{pixelType:"U8",size:1,ctor:Uint8Array,range:[0,255]},{pixelType:"S16",size:2,ctor:Int16Array,range:[-32768,32767]},{pixelType:"U16",size:2,ctor:Uint16Array,range:[0,65536]},{pixelType:"S32",size:4,ctor:Int32Array,range:[-2147483648,2147483647]},{pixelType:"U32",size:4,ctor:Uint32Array,range:[0,4294967296]},{pixelType:"F32",size:4,ctor:Float32Array,range:[-34027999387901484e22,34027999387901484e22]},{pixelType:"F64",size:8,ctor:Float64Array,range:[-17976931348623157e292,17976931348623157e292]}];let n=null,r=!1;function a(){return n||(n=import("../../../chunks/lerc-wasm.js").then((e=>e.l)).then((({default:t})=>t({locateFile:t=>e(`esri/layers/support/rasterFormats/${t}`)}))).then((e=>{u(e),r=!0})),n)}function l(){return r}const i={getBlobInfo:null,decode:null};function o(e){return 16+(e>>3<<3)}function s(e,t,n){n.set(e.slice(t,t+n.length))}function u(e){const{_malloc:n,_free:r,_lerc_getBlobInfo:a,_lerc_getDataRanges:l,_lerc_decode_4D:u,asm:f}=e;let c;const y=Object.values(f).find((t=>t&&"buffer"in t&&t.buffer===e.HEAPU8.buffer)),p=e=>{const t=e.map((e=>o(e))),r=t.reduce(((e,t)=>e+t)),a=n(r);c=new Uint8Array(y.buffer);let l=t[0];t[0]=a;for(let n=1;n<t.length;n++){const e=t[n];t[n]=t[n-1]+l,l=e}return t};i.getBlobInfo=e=>{const t=12,n=3,i=new Uint8Array(4*t),o=new Uint8Array(8*n),[u,f,h]=p([e.length,i.length,o.length]);c.set(e,u),c.set(i,f),c.set(o,h);let g=a(u,e.length,f,h,t,n);if(g)throw r(u),`lerc-getBlobInfo: error code is ${g}`;c=new Uint8Array(y.buffer),s(c,f,i),s(c,h,o);const d=new Uint32Array(i.buffer),b=new Float64Array(o.buffer),[m,A,w,U,x,T,C,V,z,,D]=d,F={version:m,dimCount:w,width:U,height:x,validPixelCount:C,bandCount:T,blobSize:V,maskCount:z,dataType:A,minValue:b[0],maxValue:b[1],maxZerror:b[2],statistics:[],bandCountWithNoData:D};if(D)return F;if(1===w&&1===T)return r(u),F.statistics.push({minValue:b[0],maxValue:b[1]}),F;const I=w*T*8,_=new Uint8Array(I),k=new Uint8Array(I);let B=u,v=0,S=0,O=!1;if(c.byteLength<u+2*I?(r(u),O=!0,[B,v,S]=p([e.length,I,I]),c.set(e,B)):[v,S]=p([I,I]),c.set(_,v),c.set(k,S),g=l(B,e.length,w,T,v,S),g)throw r(B),O||r(v),`lerc-getDataRanges: error code is ${g}`;c=new Uint8Array(y.buffer),s(c,v,_),s(c,S,k);const $=new Float64Array(_.buffer),j=new Float64Array(k.buffer),M=F.statistics;for(let r=0;r<T;r++)if(w>1){const e=$.slice(r*w,(r+1)*w),t=j.slice(r*w,(r+1)*w),n=Math.min.apply(null,e),a=Math.max.apply(null,t);M.push({minValue:n,maxValue:a,dimStats:{minValues:e,maxValues:t}})}else M.push({minValue:$[r],maxValue:j[r]});return r(B),O||r(v),F},i.decode=(e,n)=>{const{maskCount:a,dimCount:l,bandCount:i,width:o,height:f,dataType:h,bandCountWithNoData:g}=n,d=t[h],b=o*f,m=new Uint8Array(b*i),A=b*l*i*d.size,w=new Uint8Array(A),U=new Uint8Array(i),x=new Uint8Array(8*i),[T,C,V,z,D]=p([e.length,m.length,w.length,U.length,x.length]);c.set(e,T),c.set(m,C),c.set(w,V),c.set(U,z),c.set(x,D);const F=u(T,e.length,a,C,l,o,f,i,h,V,z,D);if(F)throw r(T),`lerc-decode: error code is ${F}`;c=new Uint8Array(y.buffer),s(c,V,w),s(c,C,m);let I=null;if(g){s(c,z,U),s(c,D,x),I=[];const e=new Float64Array(x.buffer);for(let t=0;t<U.length;t++)I.push(U[t]?e[t]:null)}return r(T),{data:w,maskData:m,noDataValues:I}}}function f(e,t,n,r,a){if(n<2)return e;const l=new r(t*n);if(a)for(let i=0,o=0;i<t;i++)for(let r=0,a=i;r<n;r++,a+=t)l[a]=e[o++];else for(let i=0,o=0;i<t;i++)for(let r=0,a=i;r<n;r++,a+=t)l[o++]=e[a];return l}function c(e,n={}){const r=n.inputOffset??0,a=e instanceof Uint8Array?e.subarray(r):new Uint8Array(e,r),l=i.getBlobInfo(a),{data:o,maskData:s}=i.decode(a,l),{width:u,height:c,bandCount:y,dimCount:p,dataType:h,maskCount:g,statistics:d}=l,b=t[h],m=new b.ctor(o.buffer),A=[],w=[],U=u*c,x=U*p;for(let t=0;t<y;t++){const e=m.subarray(t*x,(t+1)*x);if(n.returnPixelInterleavedDims)A.push(e);else{const t=f(e,U,p,b.ctor,!0);A.push(t)}w.push(s.subarray(t*x,(t+1)*x))}const T=0===g?null:1===g?w[0]:new Uint8Array(U);if(g>1){T.set(w[0]);for(let e=1;e<w.length;e++){const t=w[e];for(let e=0;e<U;e++)T[e]=T[e]&t[e]}}const{noDataValue:C}=n,V=null!=C&&b.range[0]<=C&&b.range[1]>=C;if(g>0&&V)for(let t=0;t<y;t++){const e=A[t],n=w[t]||T;for(let t=0;t<U;t++)0===n[t]&&(e[t]=C)}const z=g===y&&y>1?w:null;return{width:u,height:c,bandCount:y,pixelType:n.pixelType&&0===l.version?n.pixelType:b.pixelType,dimCount:p,statistics:d,pixels:A,mask:T,bandMasks:z}}function y(e,t={}){const n=e instanceof Uint8Array?e.subarray(t.inputOffset??0):new Uint8Array(e,t.inputOffset??0);return i.getBlobInfo(n)}export{c as decode,y as getBlobInfo,l as isLoaded,a as load};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcgis/core",
3
- "version": "4.24.0-next.20220508",
3
+ "version": "4.24.0-next.20220511",
4
4
  "homepage": "https://js.arcgis.com",
5
5
  "description": "ArcGIS API for JavaScript: A complete 2D and 3D mapping and data visualization API",
6
6
  "keywords": [
@@ -29,8 +29,8 @@
29
29
  "@esri/calcite-colors": "~6.0.1",
30
30
  "@esri/calcite-components": "1.0.0-beta.81",
31
31
  "@popperjs/core": "~2.11.5",
32
- "focus-trap": "~6.9.0",
33
- "luxon": "~2.3.2",
32
+ "focus-trap": "~6.9.1",
33
+ "luxon": "~2.4.0",
34
34
  "sortablejs": "~1.15.0"
35
35
  },
36
36
  "type": "module"
package/request.js CHANGED
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import e from"./config.js";import{id as t}from"./kernel.js";import r from"./core/Error.js";import s from"./core/has.js";import{clone as o}from"./core/lang.js";import{unwrap as n}from"./core/maybe.js";import{onAbort as a,isAbortError as i,createAbortError as l,isAborted as u}from"./core/promiseUtils.js";import{isDataProtocol as c,isBlobProtocol as d,normalize as p,getInterceptor as m,isTrustedServer as h,getOrigin as f,toHTTPS as y,addQueryParameter as w,objectToQuery as g,getProxyRule as b,getProxyUrl as q,addQueryParameters as T,hasSameOrigin as k,getAppUrl as S,addProxyRule as O}from"./core/urlUtils.js";import{supportsApiKey as x}from"./support/apiKeyUtils.js";import{loadImageAsync as C}from"./support/requestUtils.js";async function v(e,t){const r=c(e),o=d(e);o||r||(e=p(e));const i={url:e,requestOptions:{...n(t)}};let l=m(e);if(l){const e=await K(l,i);if(null!=e)return{data:e,getHeader:_,requestOptions:i.requestOptions,url:i.url};l.after||l.error||(l=null)}if(e=i.url,"image"===(t=i.requestOptions).responseType){if(s("host-webworker")||s("host-node"))throw R("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),i)}else if(r)throw R("request:invalid-parameters",new Error("Data URLs are not supported for responseType = "+t.responseType),i);if("head"===t.method){if(t.body)throw R("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),i);if(r||o)throw R("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),i)}if(await H(),E)return E.execute(e,t);const u=new AbortController;a(t,(()=>u.abort()));const h={controller:u,credential:null,credentialToken:null,fetchOptions:null,hasToken:!1,interceptor:l,params:i,redoRequest:!1,useIdentity:L.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},f=await z(h);return l?.after?.(f),f}let E;const L=e.request,U="FormData"in globalThis,j=[499,498,403,401],P=["COM_0056","COM_0057","SB_0008"],D=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],_=()=>null,F=Symbol();function I(e){const t=f(e);t&&!v._corsServers.includes(t)&&v._corsServers.push(t)}function M(e){const t=f(e);return!t||t.endsWith(".arcgis.com")||v._corsServers.includes(t)||h(t)}function R(e,t,s,n){let a="Error";const u={url:s.url,requestOptions:s.requestOptions,getHeader:_,ssl:!1};if(t instanceof r)return t.details?(t.details=o(t.details),t.details.url=s.url,t.details.requestOptions=s.requestOptions):t.details=u,t;if(t){const e=n&&(e=>n.headers.get(e)),r=n&&n.status,s=t.message;s&&(a=s),e&&(u.getHeader=e),u.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,u.subCode=t.subcode,u.messageCode=t.messageCode,"string"==typeof t.details?u.messages=[t.details]:u.messages=t.details,u.raw=F in t?t[F]:t}return i(t)?l():new r(e,a,u)}async function H(){s("host-webworker")?E||(E=await import("./core/workers/request.js")):v._abortableFetch||(v._abortableFetch=globalThis.fetch.bind(globalThis))}async function A(){t||await import("./identity/IdentityManager.js")}async function B(r){const s=r.params.url,o=r.params.requestOptions,n=r.controller.signal,a=o.body;let i=null,l=null,c=null;if(U&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(l=a,i=new FormData(l))),"string"==typeof a&&(c=a),r.fetchOptions={cache:o.cacheBust&&!v._abortableFetch.polyfill?"no-cache":"default",credentials:"same-origin",headers:o.headers||{},method:"head"===o.method?"HEAD":"GET",mode:"cors",priority:L.priority,redirect:"follow",signal:n},(i||c)&&(r.fetchOptions.body=i||c),"anonymous"===o.authMode&&(r.useIdentity=!1),r.hasToken=!!(/token=/i.test(s)||o.query&&o.query.token||i&&i.get&&i.get("token")||l&&l.elements.token),!r.hasToken&&e.apiKey&&x(s)&&(o.query||(o.query={}),o.query.token=e.apiKey,r.hasToken=!0),r.useIdentity&&!r.hasToken&&!r.credentialToken&&!N(s)&&!u(n)){let e;"immediate"===o.authMode?(await A(),e=await t.getCredential(s,{signal:n}),r.credential=e):"no-prompt"===o.authMode?(await A(),e=await t.getCredential(s,{prompt:!1,signal:n}).catch((()=>{})),r.credential=e):t&&(e=t.findCredential(s)),e&&(r.credentialToken=e.token,r.useSSL=!!e.ssl)}}function N(e){return D.some((t=>t.test(e)))}async function $(e){let r=e.params.url;const o=e.params.requestOptions,n=e.fetchOptions,a=d(r)||c(r),i=o.responseType||"json",u=a?0:null!=o.timeout?o.timeout:L.timeout;let p=!1;if(!a){e.useSSL&&(r=y(r)),o.cacheBust&&"default"===n.cache&&(r=w(r,"request.preventCache",Date.now()));let a={...o.query};e.credentialToken&&(a.token=e.credentialToken);let i=g(a);s("esri-url-encodes-apostrophe")&&(i=i.replace(/'/g,"%27"));const l=r.length+1+i.length;let u;p="delete"===o.method||"post"===o.method||"put"===o.method||!!o.body||l>L.maxUrlLength;const c=o.useProxy||!!b(r);if(c){const e=q(r);u=e.path,!p&&u.length+1+l>L.maxUrlLength&&(p=!0),e.query&&(a={...e.query,...a})}if("HEAD"===n.method&&(p||c)){if(p){if(l>L.maxUrlLength)throw R("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw R("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(c)throw R("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(p?(n.method="delete"===o.method?"DELETE":"put"===o.method?"PUT":"POST",o.body?r=T(r,a):(n.body=g(a),n.headers["Content-Type"]="application/x-www-form-urlencoded")):r=T(r,a),c&&(e.useProxy=!0,r=`${u}?${r}`),a.token&&U&&n.body instanceof FormData){const e=n.body;e.set?e.set("token",a.token):e.append("token",a.token)}if(o.hasOwnProperty("withCredentials"))e.withCredentials=o.withCredentials;else if(!k(r,S()))if(h(r))e.withCredentials=!0;else if(t){const s=t.findServerInfo(r);s&&s.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(n.credentials="include")}let m,x,C=0,E=!1;u>0&&(C=setTimeout((()=>{E=!0,e.controller.abort()}),u));try{if("native-request-init"===o.responseType)x=n,x.url=r;else if("image"!==o.responseType||"default"!==n.cache||"GET"!==n.method||p||W(o.headers)||!a&&!e.useProxy&&L.proxyUrl&&!M(r)){if(m=await v._abortableFetch(r,n),e.useProxy||I(r),"native"===o.responseType)x=m;else if("HEAD"!==n.method)if(m.ok){switch(i){case"array-buffer":x=await m.arrayBuffer();break;case"blob":case"image":x=await m.blob();break;default:x=await m.text()}if(C&&(clearTimeout(C),C=0),"json"===i||"xml"===i||"document"===i)if(x)switch(i){case"json":x=JSON.parse(x);break;case"xml":x=G(x,"application/xml");break;case"document":x=G(x,"text/html")}else x=null;if(x){if("array-buffer"===i||"blob"===i){const e=m.headers.get("Content-Type");if(/application\/json|text\/plain/i.test(e)&&x["blob"===i?"size":"byteLength"]<=750)try{const e=await new Response(x).json();e.error&&(x=e)}catch{}}"image"===i&&x instanceof Blob&&(x=await X(URL.createObjectURL(x),e,!0))}}else x=await m.text()}else x=await X(r,e)}catch(j){if("AbortError"===j.name){if(E)throw new Error("Timeout exceeded");throw l("Request canceled")}if(!(!m&&j instanceof TypeError&&L.proxyUrl)||o.body||"delete"===o.method||"head"===o.method||"post"===o.method||"put"===o.method||e.useProxy||M(r))throw j;e.redoRequest=!0,O({proxyUrl:L.proxyUrl,urlPrefix:f(r)})}finally{C&&clearTimeout(C)}return[m,x]}async function K(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let o,n;try{n=await e.before(t)}catch(s){o=R("request:interceptor",s,t)}if((n instanceof Error||n instanceof r)&&(o=R("request:interceptor",n,t)),o)throw e.error&&e.error(o),o;return n}}function W(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}function G(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function z(e){let r,s;await B(e);try{do{[r,s]=await $(e)}while(!await J(e,r,s))}catch(a){const t=R("request:server",a,e.params,r);throw t.details.ssl=e.useSSL,e.interceptor&&e.interceptor.error&&e.interceptor.error(t),t}const o=e.params.url;if(/\/sharing\/rest\/(accounts|portals)\/self/i.test(o)&&!e.hasToken&&!e.credentialToken&&s?.user?.username&&!h(o)){const e=f(o,!0);e&&L.trustedServers.push(e)}const n=e.credential;if(n&&t){const e=t.findServerInfo(n.server);let r=e&&e.owningSystemUrl;if(r){r=r.replace(/\/?$/,"/sharing");const e=t.findCredential(r,n.userId);e&&-1===t._getIdenticalSvcIdx(r,e)&&e.resources.unshift(r)}}return{data:s,getHeader:r?e=>r.headers.get(e):_,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}async function J(e,r,s){if(e.redoRequest)return e.redoRequest=!1,!1;const o=e.params.requestOptions;if(!r||"native"===o.responseType||"native-request-init"===o.responseType)return!0;let n,a,i,l;if(!r.ok)throw n=new Error(`Unable to load ${r.url} status: ${r.status}`),n[F]=s,n;s?.error&&(n=s.error),n&&(a=Number(n.code),i=n.hasOwnProperty("subcode")?Number(n.subcode):null,l=n.messageCode,l=l&&l.toUpperCase());const u=o.authMode;if(403===a&&(4===i||n.message&&n.message.toLowerCase().includes("ssl")&&!n.message.toLowerCase().includes("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==u||498===a)&&j.includes(a)&&!N(e.params.url)&&(403!==a||!P.includes(l)&&(null==i||2===i&&e.credentialToken))){await A();try{const r=await t.getCredential(e.params.url,{error:R("request:server",n,e.params),prompt:"no-prompt"!==u,signal:e.controller.signal,token:e.credentialToken});return e.credential=r,e.credentialToken=r.token,e.useSSL=e.useSSL||r.ssl,!1}catch(c){if("no-prompt"===u)return e.credential=null,e.credentialToken=null,!1;n=c}}if(n)throw n;return!0}function X(e,t,r=!1){const s=t.controller.signal,o=new Image;return t.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchpriority=L.priority,o.src=e,C(o,e,r,s)}v._abortableFetch=null,v._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"];export{v as default};
5
+ import e from"./config.js";import{id as t}from"./kernel.js";import r from"./core/Error.js";import s from"./core/has.js";import{clone as o}from"./core/lang.js";import{unwrap as n}from"./core/maybe.js";import{onAbort as a,isAbortError as i,createAbortError as l,isAborted as u}from"./core/promiseUtils.js";import{isDataProtocol as c,isBlobProtocol as d,normalize as p,getInterceptor as m,isTrustedServer as h,getOrigin as f,toHTTPS as y,addQueryParameter as w,objectToQuery as g,getProxyRule as b,getProxyUrl as q,addQueryParameters as T,hasSameOrigin as k,getAppUrl as O,addProxyRule as S}from"./core/urlUtils.js";import{supportsApiKey as C}from"./support/apiKeyUtils.js";import{registerNoCorsDomains as x,isNoCorsRequestRequired as v,sendNoCorsRequest as E,loadImageAsync as L}from"./support/requestUtils.js";async function U(e,t){const r=c(e),o=d(e);o||r||(e=p(e));const i={url:e,requestOptions:{...n(t)}};let l=m(e);if(l){const e=await G(l,i);if(null!=e)return{data:e,getHeader:M,requestOptions:i.requestOptions,url:i.url};l.after||l.error||(l=null)}if(e=i.url,"image"===(t=i.requestOptions).responseType){if(s("host-webworker")||s("host-node"))throw N("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),i)}else if(r)throw N("request:invalid-parameters",new Error("Data URLs are not supported for responseType = "+t.responseType),i);if("head"===t.method){if(t.body)throw N("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),i);if(r||o)throw N("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),i)}if(await B(),j)return j.execute(e,t);const u=new AbortController;a(t,(()=>u.abort()));const h={controller:u,credential:null,credentialToken:null,fetchOptions:null,hasToken:!1,interceptor:l,params:i,redoRequest:!1,useIdentity:D.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},f=await Q(h);return l?.after?.(f),f}let j;const D=e.request,P="FormData"in globalThis,_=[499,498,403,401],F=["COM_0056","COM_0057","SB_0008"],I=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],M=()=>null,R=Symbol();function H(e){const t=f(e);t&&!U._corsServers.includes(t)&&U._corsServers.push(t)}function A(e){const t=f(e);return!t||t.endsWith(".arcgis.com")||U._corsServers.includes(t)||h(t)}function N(e,t,s,n){let a="Error";const u={url:s.url,requestOptions:s.requestOptions,getHeader:M,ssl:!1};if(t instanceof r)return t.details?(t.details=o(t.details),t.details.url=s.url,t.details.requestOptions=s.requestOptions):t.details=u,t;if(t){const e=n&&(e=>n.headers.get(e)),r=n&&n.status,s=t.message;s&&(a=s),e&&(u.getHeader=e),u.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,u.subCode=t.subcode,u.messageCode=t.messageCode,"string"==typeof t.details?u.messages=[t.details]:u.messages=t.details,u.raw=R in t?t[R]:t}return i(t)?l():new r(e,a,u)}async function B(){s("host-webworker")?j||(j=await import("./core/workers/request.js")):U._abortableFetch||(U._abortableFetch=globalThis.fetch.bind(globalThis))}async function $(){t||await import("./identity/IdentityManager.js")}async function z(r){const s=r.params.url,o=r.params.requestOptions,n=r.controller.signal,a=o.body;let i=null,l=null,c=null;if(P&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(l=a,i=new FormData(l))),"string"==typeof a&&(c=a),r.fetchOptions={cache:o.cacheBust&&!U._abortableFetch.polyfill?"no-cache":"default",credentials:"same-origin",headers:o.headers||{},method:"head"===o.method?"HEAD":"GET",mode:"cors",priority:D.priority,redirect:"follow",signal:n},(i||c)&&(r.fetchOptions.body=i||c),"anonymous"===o.authMode&&(r.useIdentity=!1),r.hasToken=!!(/token=/i.test(s)||o.query&&o.query.token||i&&i.get&&i.get("token")||l&&l.elements.token),!r.hasToken&&e.apiKey&&C(s)&&(o.query||(o.query={}),o.query.token=e.apiKey,r.hasToken=!0),r.useIdentity&&!r.hasToken&&!r.credentialToken&&!K(s)&&!u(n)){let e;"immediate"===o.authMode?(await $(),e=await t.getCredential(s,{signal:n}),r.credential=e):"no-prompt"===o.authMode?(await $(),e=await t.getCredential(s,{prompt:!1,signal:n}).catch((()=>{})),r.credential=e):t&&(e=t.findCredential(s)),e&&(r.credentialToken=e.token,r.useSSL=!!e.ssl)}}function K(e){return I.some((t=>t.test(e)))}async function W(e){let r=e.params.url;const o=e.params.requestOptions,n=e.fetchOptions,a=d(r)||c(r),i=o.responseType||"json",u=a?0:null!=o.timeout?o.timeout:D.timeout;let p=!1;if(!a){e.useSSL&&(r=y(r)),o.cacheBust&&"default"===n.cache&&(r=w(r,"request.preventCache",Date.now()));let a={...o.query};e.credentialToken&&(a.token=e.credentialToken);let i=g(a);s("esri-url-encodes-apostrophe")&&(i=i.replace(/'/g,"%27"));const l=r.length+1+i.length;let u;p="delete"===o.method||"post"===o.method||"put"===o.method||!!o.body||l>D.maxUrlLength;const c=o.useProxy||!!b(r);if(c){const e=q(r);u=e.path,!p&&u.length+1+l>D.maxUrlLength&&(p=!0),e.query&&(a={...e.query,...a})}if("HEAD"===n.method&&(p||c)){if(p){if(l>D.maxUrlLength)throw N("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw N("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(c)throw N("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(p?(n.method="delete"===o.method?"DELETE":"put"===o.method?"PUT":"POST",o.body?r=T(r,a):(n.body=g(a),n.headers["Content-Type"]="application/x-www-form-urlencoded")):r=T(r,a),c&&(e.useProxy=!0,r=`${u}?${r}`),a.token&&P&&n.body instanceof FormData){const e=n.body;e.set?e.set("token",a.token):e.append("token",a.token)}if(o.hasOwnProperty("withCredentials"))e.withCredentials=o.withCredentials;else if(!k(r,O()))if(h(r))e.withCredentials=!0;else if(t){const s=t.findServerInfo(r);s&&s.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(n.credentials="include",v(r)&&await E(p?T(r,a):r))}let m,C,x=0,L=!1;u>0&&(x=setTimeout((()=>{L=!0,e.controller.abort()}),u));try{if("native-request-init"===o.responseType)C=n,C.url=r;else if("image"!==o.responseType||"default"!==n.cache||"GET"!==n.method||p||J(o.headers)||!a&&!e.useProxy&&D.proxyUrl&&!A(r)){if(m=await U._abortableFetch(r,n),e.useProxy||H(r),"native"===o.responseType)C=m;else if("HEAD"!==n.method)if(m.ok){switch(i){case"array-buffer":C=await m.arrayBuffer();break;case"blob":case"image":C=await m.blob();break;default:C=await m.text()}if(x&&(clearTimeout(x),x=0),"json"===i||"xml"===i||"document"===i)if(C)switch(i){case"json":C=JSON.parse(C);break;case"xml":C=X(C,"application/xml");break;case"document":C=X(C,"text/html")}else C=null;if(C){if("array-buffer"===i||"blob"===i){const e=m.headers.get("Content-Type");if(/application\/json|text\/plain/i.test(e)&&C["blob"===i?"size":"byteLength"]<=750)try{const e=await new Response(C).json();e.error&&(C=e)}catch{}}"image"===i&&C instanceof Blob&&(C=await Y(URL.createObjectURL(C),e,!0))}}else C=await m.text()}else C=await Y(r,e)}catch(j){if("AbortError"===j.name){if(L)throw new Error("Timeout exceeded");throw l("Request canceled")}if(!(!m&&j instanceof TypeError&&D.proxyUrl)||o.body||"delete"===o.method||"head"===o.method||"post"===o.method||"put"===o.method||e.useProxy||A(r))throw j;e.redoRequest=!0,S({proxyUrl:D.proxyUrl,urlPrefix:f(r)})}finally{x&&clearTimeout(x)}return[m,C]}async function G(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let o,n;try{n=await e.before(t)}catch(s){o=N("request:interceptor",s,t)}if((n instanceof Error||n instanceof r)&&(o=N("request:interceptor",n,t)),o)throw e.error&&e.error(o),o;return n}}function J(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}function X(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function Q(e){let r,s;await z(e);try{do{[r,s]=await W(e)}while(!await V(e,r,s))}catch(a){const t=N("request:server",a,e.params,r);throw t.details.ssl=e.useSSL,e.interceptor&&e.interceptor.error&&e.interceptor.error(t),t}const o=e.params.url;if(s&&/\/sharing\/rest\/(accounts|portals)\/self/i.test(o)){if(!e.hasToken&&!e.credentialToken&&s.user?.username&&!h(o)){const e=f(o,!0);e&&D.trustedServers.push(e)}Array.isArray(s.authorizedCrossOriginNoCorsDomains)&&x(s.authorizedCrossOriginNoCorsDomains)}const n=e.credential;if(n&&t){const e=t.findServerInfo(n.server);let r=e&&e.owningSystemUrl;if(r){r=r.replace(/\/?$/,"/sharing");const e=t.findCredential(r,n.userId);e&&-1===t._getIdenticalSvcIdx(r,e)&&e.resources.unshift(r)}}return{data:s,getHeader:r?e=>r.headers.get(e):M,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}async function V(e,r,s){if(e.redoRequest)return e.redoRequest=!1,!1;const o=e.params.requestOptions;if(!r||"native"===o.responseType||"native-request-init"===o.responseType)return!0;let n,a,i,l;if(!r.ok)throw n=new Error(`Unable to load ${r.url} status: ${r.status}`),n[R]=s,n;s?.error&&(n=s.error),n&&(a=Number(n.code),i=n.hasOwnProperty("subcode")?Number(n.subcode):null,l=n.messageCode,l=l&&l.toUpperCase());const u=o.authMode;if(403===a&&(4===i||n.message&&n.message.toLowerCase().includes("ssl")&&!n.message.toLowerCase().includes("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==u||498===a)&&_.includes(a)&&!K(e.params.url)&&(403!==a||!F.includes(l)&&(null==i||2===i&&e.credentialToken))){await $();try{const r=await t.getCredential(e.params.url,{error:N("request:server",n,e.params),prompt:"no-prompt"!==u,signal:e.controller.signal,token:e.credentialToken});return e.credential=r,e.credentialToken=r.token,e.useSSL=e.useSSL||r.ssl,!1}catch(c){if("no-prompt"===u)return e.credential=null,e.credentialToken=null,!1;n=c}}if(n)throw n;return!0}function Y(e,t,r=!1){const s=t.controller.signal,o=new Image;return t.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchpriority=D.priority,o.src=e,L(o,e,r,s)}U._abortableFetch=null,U._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"];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.24/esri/copyright.txt for details.
4
4
  */
5
- import e from"../core/has.js";import{isSome as r}from"../core/maybe.js";import{isAborted as o}from"../core/promiseUtils.js";function t(t,i,s=!1,c){return new Promise(((d,a)=>{if(o(c))return void a(n());let m=()=>{v(),a(new Error(`Unable to load ${i}`))},l=()=>{const e=t;v(),d(e)},u=()=>{if(!t)return;const e=t;v(),e.src="",a(n())};const v=()=>{e("esri-image-decode")||(t.removeEventListener("error",m),t.removeEventListener("load",l)),m=null,l=null,t=null,r(c)&&c.removeEventListener("abort",u),u=null,s&&URL.revokeObjectURL(i)};r(c)&&c.addEventListener("abort",u),e("esri-image-decode")?t.decode().then(l,m):(t.addEventListener("error",m),t.addEventListener("load",l))}))}function n(){try{return new DOMException("Aborted","AbortError")}catch{const e=new Error;return e.name="AbortError",e}}export{t as loadImageAsync};
5
+ import r from"../config.js";import e from"../core/has.js";import{isSome as o}from"../core/maybe.js";import{isAborted as t}from"../core/promiseUtils.js";import{getOrigin as n,hasSameOrigin as s,urlToObject as i,getAppUrl as c}from"../core/urlUtils.js";function a(r,n,s=!1,i){return new Promise(((c,a)=>{if(t(i))return void a(m());let u=()=>{l(),a(new Error(`Unable to load ${n}`))},d=()=>{const e=r;l(),c(e)},f=()=>{if(!r)return;const e=r;l(),e.src="",a(m())};const l=()=>{e("esri-image-decode")||(r.removeEventListener("error",u),r.removeEventListener("load",d)),u=null,d=null,r=null,o(i)&&i.removeEventListener("abort",f),f=null,s&&URL.revokeObjectURL(n)};o(i)&&i.addEventListener("abort",f),e("esri-image-decode")?r.decode().then(d,u):(r.addEventListener("error",u),r.addEventListener("load",d))}))}function m(){try{return new DOMException("Aborted","AbortError")}catch{const r=new Error;return r.name="AbortError",r}}function u(e){r.request.crossOriginNoCorsDomains||(r.request.crossOriginNoCorsDomains={});const o=r.request.crossOriginNoCorsDomains;for(let r of e)r=r.toLowerCase(),/^https?:\/\//.test(r)?o[n(r)]=0:(o[n("http://"+r)]=0,o[n("https://"+r)]=0)}function d(e){const o=r.request.crossOriginNoCorsDomains;if(o){let r=n(e);if(r)return r=r.toLowerCase(),!s(r,c())&&o[r]<Date.now()-36e5}return!1}async function f(e){const o=r.request.crossOriginNoCorsDomains;o&&(o[n(e).toLowerCase()]=Date.now());const t=i(e);e=t.path,"json"===t.query?.f&&(e+="?f=json");try{await fetch(e,{mode:"no-cors",credentials:"include"})}catch{}}export{d as isNoCorsRequestRequired,a as loadImageAsync,u as registerNoCorsDomains,f as sendNoCorsRequest};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- const e="20220508",b="a01670284557b2ce31ed4fd6b5fd634b1e56f303";export{e as buildDate,b as commitHash};
5
+ const a="20220511",b="a13be4bc9b31395a622720bcf52d19f4ad859a87";export{a as buildDate,b as commitHash};
package/symbols/Font.js CHANGED
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.24/esri/copyright.txt for details.
4
4
  */
5
- import{_ as t}from"../chunks/tslib.es6.js";import{JSONSupport as o}from"../core/JSONSupport.js";import{toPt as e}from"../core/screenUtils.js";import{property as r}from"../core/accessorSupport/decorators/property.js";import"../core/arrayUtils.js";import"../core/has.js";import{cast as s}from"../core/accessorSupport/decorators/cast.js";import{subclass as i}from"../core/accessorSupport/decorators/subclass.js";import{FONT_DECORATIONS as p,FONT_STYLES as a,FONT_WEIGHTS as c}from"./support/textUtils.js";var n;let l=n=class extends o{constructor(t){super(t),this.decoration="none",this.family="sans-serif",this.size=9,this.style="normal",this.weight="normal"}castSize(t){return e(t)}clone(){return new n({decoration:this.decoration,family:this.family,size:this.size,style:this.style,weight:this.weight})}hash(){return`${this.decoration}.${this.family}.${this.size}.${this.style}.${this.weight}`}};t([r({type:p,json:{default:"none",write:!0}})],l.prototype,"decoration",void 0),t([r({type:String,json:{write:!0}})],l.prototype,"family",void 0),t([r({type:Number,json:{write:{overridePolicy:(t,o,e)=>({enabled:!e||!e.textSymbol3D})}}})],l.prototype,"size",void 0),t([s("size")],l.prototype,"castSize",null),t([r({type:a,json:{default:"normal",write:!0}})],l.prototype,"style",void 0),t([r({type:c,json:{default:"normal",write:!0}})],l.prototype,"weight",void 0),l=n=t([i("esri.symbols.Font")],l);const m=l;export{m as default};
5
+ import{_ as t}from"../chunks/tslib.es6.js";import{JSONSupport as o}from"../core/JSONSupport.js";import{toPt as e}from"../core/screenUtils.js";import{property as r}from"../core/accessorSupport/decorators/property.js";import"../core/arrayUtils.js";import"../core/has.js";import{cast as s}from"../core/accessorSupport/decorators/cast.js";import{subclass as i}from"../core/accessorSupport/decorators/subclass.js";import{fontDecorations as p,fontStyles as a,fontWeights as c}from"./support/textUtils.js";var n;let l=n=class extends o{constructor(t){super(t),this.decoration="none",this.family="sans-serif",this.size=9,this.style="normal",this.weight="normal"}castSize(t){return e(t)}clone(){return new n({decoration:this.decoration,family:this.family,size:this.size,style:this.style,weight:this.weight})}hash(){return`${this.decoration}.${this.family}.${this.size}.${this.style}.${this.weight}`}};t([r({type:p,json:{default:"none",write:!0}})],l.prototype,"decoration",void 0),t([r({type:String,json:{write:!0}})],l.prototype,"family",void 0),t([r({type:Number,json:{write:{overridePolicy:(t,o,e)=>({enabled:!e||!e.textSymbol3D})}}})],l.prototype,"size",void 0),t([s("size")],l.prototype,"castSize",null),t([r({type:a,json:{default:"normal",write:!0}})],l.prototype,"style",void 0),t([r({type:c,json:{default:"normal",write:!0}})],l.prototype,"weight",void 0),l=n=t([i("esri.symbols.Font")],l);const m=l;export{m 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.24/esri/copyright.txt for details.
4
4
  */
5
- import{clamp as e}from"../../core/mathUtils.js";import{ensureNumber as o}from"../../core/accessorSupport/ensureType.js";const l=["none","underline","line-through"],t=["normal","italic","oblique"],r=["normal","lighter","bold","bolder"],n={type:Number,cast:l=>{const t=o(l);return 0===t?1:e(t,.1,4)},nonNullable:!0},i=["left","right","center"],a=["baseline","top","middle","bottom"],m={type:i,nonNullable:!0},p={type:a,nonNullable:!0};export{l as FONT_DECORATIONS,t as FONT_STYLES,r as FONT_WEIGHTS,i as HORIZONTAL_ALIGNMENTS,a as VERTICAL_ALIGNMENTS,m as horizontalAlignmentProperty,n as lineHeightProperty,p as verticalAlignmentProperty};
5
+ import{clamp as e}from"../../core/mathUtils.js";import{ensureNumber as o}from"../../core/accessorSupport/ensureType.js";const l=["none","underline","line-through"],t=["normal","italic","oblique"],r=["normal","lighter","bold","bolder"],n={type:Number,cast:l=>{const t=o(l);return 0===t?1:e(t,.1,4)},nonNullable:!0},i=["left","right","center"],a=["baseline","top","middle","bottom"],m={type:i,nonNullable:!0},p={type:a,nonNullable:!0};export{l as fontDecorations,t as fontStyles,r as fontWeights,m as horizontalAlignmentProperty,i as horizontalAlignments,n as lineHeightProperty,p as verticalAlignmentProperty,a as verticalAlignments};