@arcgis/core 4.23.0-next.20220119 → 4.23.0-next.20220127
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.
- package/Graphic.js +1 -1
- package/arcade/featureset/sources/FeatureLayerDynamic.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/02fbc76dfdc20e628c61.js +1 -0
- package/assets/esri/core/workers/chunks/0317f37b6c8705b363fd.js +1 -0
- package/assets/esri/core/workers/chunks/0453fad5cb819797b4f6.js +1 -0
- package/assets/esri/core/workers/chunks/{d1454155ee1b8a421cbb.js → 0d02c6ad1f4688bfa374.js} +1 -1
- package/assets/esri/core/workers/chunks/0d684f16f37d5dc385dd.js +1 -0
- package/assets/esri/core/workers/chunks/0e17691520d890d34efb.js +1 -0
- package/assets/esri/core/workers/chunks/12c0cabb6c59e65d8546.js +1 -0
- package/assets/esri/core/workers/chunks/16b6d0f8378582c051c3.js +1 -0
- package/assets/esri/core/workers/chunks/{b313ab14a643273e7d09.js → 1877ab1b6a115dbba1c5.js} +1 -1
- package/assets/esri/core/workers/chunks/199670a3a564ebe3bd79.js +1 -0
- package/assets/esri/core/workers/chunks/1b2a961f776a0b57e57a.js +1 -0
- package/assets/esri/core/workers/chunks/1b3fd66577b19aa5f2b6.js +1 -0
- package/assets/esri/core/workers/chunks/1f8c6a179e39fd4c5e6f.js +1 -0
- package/assets/esri/core/workers/chunks/2076fcbae63f1bfb7143.js +1 -0
- package/assets/esri/core/workers/chunks/{b2ae5fc4f787ea568b88.js → 2460f3b6ada6ae900dec.js} +1 -1
- package/assets/esri/core/workers/chunks/{99f0d896c17dd09cd285.js → 2629adf79e7fd9f25f07.js} +1 -1
- package/assets/esri/core/workers/chunks/281b89dbf5574fc642ae.js +1 -0
- package/assets/esri/core/workers/chunks/{4d539878bfbd7c549e60.js → 2c8fe9bc988c3c5760a5.js} +1 -1
- package/assets/esri/core/workers/chunks/2e899ef5881b4ec6fa55.js +1 -0
- package/assets/esri/core/workers/chunks/322d917e8cb398816a93.js +1 -0
- package/assets/esri/core/workers/chunks/34b59d7099904dcb28b5.js +1 -0
- package/assets/esri/core/workers/chunks/391e96192d1ec4e55ce2.js +1 -0
- package/assets/esri/core/workers/chunks/{1b28042fdf3f4dbc8ea5.js → 392b6382e06652dd4c80.js} +1 -1
- package/assets/esri/core/workers/chunks/3aa73119b055e05bbbeb.js +1 -0
- package/assets/esri/core/workers/chunks/3f343f792fd9f44d6f25.js +1 -0
- package/assets/esri/core/workers/chunks/422537fc3df707bb62c9.js +1 -0
- package/assets/esri/core/workers/chunks/{573dc3064e84ca86844d.js → 48fa8aed6c24877b44c4.js} +1 -1
- package/assets/esri/core/workers/chunks/{44b01d42d4ec72913229.js → 4954fd86b48cc68b737c.js} +1 -1
- package/assets/esri/core/workers/chunks/4ba6de8aa7e2960bad49.js +1 -0
- package/assets/esri/core/workers/chunks/4c76146014dc15143ba3.js +1 -0
- package/assets/esri/core/workers/chunks/52ea678ba1da0e349919.js +1 -0
- package/assets/esri/core/workers/chunks/56274b37ff74ca0d68a6.js +1 -0
- package/assets/esri/core/workers/chunks/{b9c177524b3e7de1ffd1.js → 5790d171072b3c7d108f.js} +1 -1
- package/assets/esri/core/workers/chunks/57b349d1dbc0bed75b79.js +1 -0
- package/assets/esri/core/workers/chunks/5948923e07bd1662c24a.js +1 -0
- package/assets/esri/core/workers/chunks/5bcb3240b3c005e5fe72.js +1 -0
- package/assets/esri/core/workers/chunks/5dbe555a5a662ff3d9ce.js +1 -0
- package/assets/esri/core/workers/chunks/5ec98f4ddac707d0fbd1.js +1 -0
- package/assets/esri/core/workers/chunks/5ee497d5d7b0e580526a.js +1 -0
- package/assets/esri/core/workers/chunks/5f1dcb6556820cd0aa31.js +1 -0
- package/assets/esri/core/workers/chunks/601e697dc7414bda128a.js +1 -0
- package/assets/esri/core/workers/chunks/64b7e8d812ea8fcf269e.js +1 -0
- package/assets/esri/core/workers/chunks/663ad15b86936eb06b69.js +1 -0
- package/assets/esri/core/workers/chunks/68a59ce98177d8513337.js +1 -0
- package/assets/esri/core/workers/chunks/69fd99b7c76e9992ccf3.js +1 -0
- package/assets/esri/core/workers/chunks/{9cdaba126ac7fa5f33f0.js → 6cd5e4380d29b9a3c344.js} +1 -1
- package/assets/esri/core/workers/chunks/6e6a3c5866e8d8820457.js +1 -0
- package/assets/esri/core/workers/chunks/75d812955a473d0e8960.js +1 -0
- package/assets/esri/core/workers/chunks/{7aa543a97f055cddea99.js → 7a5f5acfbd4ca1a5c1f3.js} +1 -1
- package/assets/esri/core/workers/chunks/{64276aacaafa4c8a15bd.js → 7dcf52d3db3903c8eb9f.js} +1 -1
- package/assets/esri/core/workers/chunks/8001b0e514bfffe9d7f8.js +1 -0
- package/assets/esri/core/workers/chunks/83b8fec1650e061aaa56.js +1 -0
- package/assets/esri/core/workers/chunks/83d00afae4406ec78bc9.js +1 -0
- package/assets/esri/core/workers/chunks/842db82733635dbf25cb.js +1 -0
- package/assets/esri/core/workers/chunks/{625d2663daa8e0cf64b0.js → 85b1f36790df95b17659.js} +1 -1
- package/assets/esri/core/workers/chunks/89820b200ee44e678af5.js +1 -0
- package/assets/esri/core/workers/chunks/8fa0a14165d43ffe87a5.js +1 -0
- package/assets/esri/core/workers/chunks/929c9b7cdab7c4ca3d87.js +1 -0
- package/assets/esri/core/workers/chunks/94515fb3ef38067eeadd.js +1 -0
- package/assets/esri/core/workers/chunks/{010a71c2aa1b7681e191.js → 9d11f84e6c893b9d0019.js} +1 -1
- package/assets/esri/core/workers/chunks/a1930e4f035bc9aa1ae5.js +1 -0
- package/assets/esri/core/workers/chunks/a78757b9c7e8cbea08fa.js +1 -0
- package/assets/esri/core/workers/chunks/a8692bffb76444c34760.js +1 -0
- package/assets/esri/core/workers/chunks/aa04b90b82bf70caaae4.js +1 -0
- package/assets/esri/core/workers/chunks/aeaa1667c2d9f1b3366b.js +1 -0
- package/assets/esri/core/workers/chunks/b2d2de935487257c568b.js +1 -0
- package/assets/esri/core/workers/chunks/{a8b13fb804bb775e4967.js → b62e3dccd9f662c0afeb.js} +1 -1
- package/assets/esri/core/workers/chunks/b97953694f42bfec1b3c.js +1 -0
- package/assets/esri/core/workers/chunks/b9e9cb354822c6d995a4.js +1 -0
- package/assets/esri/core/workers/chunks/{4b69129c0557852d9b3d.js → ba5eb394f098968c22d2.js} +1 -1
- package/assets/esri/core/workers/chunks/ba762bcfd74af0bb8218.js +1 -0
- package/assets/esri/core/workers/chunks/bac9fc90e6756e211160.js +1 -0
- package/assets/esri/core/workers/chunks/bf6dda4a2af14c4b7716.js +1 -0
- package/assets/esri/core/workers/chunks/bf97a933ea3b220115e1.js +1 -0
- package/assets/esri/core/workers/chunks/bfedd6ebff817c9b31c0.js +1 -0
- package/assets/esri/core/workers/chunks/c093dff4592832ac0973.js +1 -0
- package/assets/esri/core/workers/chunks/c1135cb02ec46c491459.js +1 -0
- package/assets/esri/core/workers/chunks/c2253a9f29c1aabb2b75.js +1 -0
- package/assets/esri/core/workers/chunks/c9cbf8135e95f0f42cd9.js +1 -0
- package/assets/esri/core/workers/chunks/{d39b7983b68d6e5b404d.js → cdbc005eebec1503b99d.js} +1 -1
- package/assets/esri/core/workers/chunks/d04fca5d46cca02500b7.js +1 -0
- package/assets/esri/core/workers/chunks/d07440469fe7d181c4fd.js +1 -0
- package/assets/esri/core/workers/chunks/d08efbc349dd9f999497.js +1 -0
- package/assets/esri/core/workers/chunks/d72488db62fcf39447b6.js +1 -0
- package/assets/esri/core/workers/chunks/d835b2a683fcd8aeeed8.js +1 -0
- package/assets/esri/core/workers/chunks/dbf192b4ce7e608610f6.js +1 -0
- package/assets/esri/core/workers/chunks/dd13772a5e2eccc6a2bc.js +1 -0
- package/assets/esri/core/workers/chunks/de6cff7b6cbbf99b20d1.js +981 -0
- package/assets/esri/core/workers/chunks/dedc333a61081772ca7b.js +1 -0
- package/assets/esri/core/workers/chunks/{22b09e276c9b9f22f0f8.js → dee9929d95e9fe26929c.js} +1 -1
- package/assets/esri/core/workers/chunks/{a7b1b75643ed31489495.js → e0c8d61c7a85ce15499a.js} +1 -1
- package/assets/esri/core/workers/chunks/e12d91ef44d6f879a02a.js +1 -0
- package/assets/esri/core/workers/chunks/{0ce1dc14280d6f188468.js → e4896cf85fb2da8a9cc7.js} +1 -1
- package/assets/esri/core/workers/chunks/e657ba0cab29f05d02da.js +1 -0
- package/assets/esri/core/workers/chunks/e8741bf421f80213f1d3.js +1 -0
- package/assets/esri/core/workers/chunks/e8e775758b79c5a084c8.js +1 -0
- package/assets/esri/core/workers/chunks/e93dfdede0532a89ffa5.js +1 -0
- package/assets/esri/core/workers/chunks/e9e5196b44b6923be1a3.js +1 -0
- package/assets/esri/core/workers/chunks/ea595b0df5050eda2a13.js +1 -0
- package/assets/esri/core/workers/chunks/{1305ef8717da6e902a55.js → ec10151a2a95e95a0bb5.js} +1 -1
- package/assets/esri/core/workers/chunks/eccba071ced2d922bb85.js +1 -0
- package/assets/esri/core/workers/chunks/f2124f4d0f2b8a91f0ea.js +1 -0
- package/assets/esri/core/workers/chunks/f9ff3eaf4eb324429fbd.js +1 -0
- package/assets/esri/libs/vxl/vxlLayer.wasm +0 -0
- package/assets/esri/themes/base/_mixins.scss +4 -1
- package/assets/esri/themes/base/icons/style.scss +11 -2
- package/assets/esri/themes/base/widgets/_BasemapLayerList.scss +13 -10
- package/assets/esri/themes/base/widgets/_CoordinateConversion.scss +4 -2
- package/assets/esri/themes/base/widgets/_Directions.scss +5 -3
- package/assets/esri/themes/base/widgets/_Editor.scss +5 -2
- package/assets/esri/themes/base/widgets/_ElevationProfile.scss +6 -4
- package/assets/esri/themes/base/widgets/_FeatureTable.scss +6 -0
- package/assets/esri/themes/base/widgets/_ItemList.scss +1 -1
- package/assets/esri/themes/base/widgets/_LayerList.scss +13 -9
- package/assets/esri/themes/base/widgets/_Popup.scss +4 -2
- package/assets/esri/themes/base/widgets/_Print.scss +24 -11
- package/assets/esri/themes/base/widgets/_Search.scss +4 -2
- package/assets/esri/themes/base/widgets/_TableList.scss +9 -7
- package/assets/esri/themes/base/widgets/_Weather.scss +12 -0
- package/assets/esri/themes/base/widgets/_Widget.scss +18 -9
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/dark-blue/main.css +1 -1
- package/assets/esri/themes/dark-green/main.css +1 -1
- package/assets/esri/themes/dark-purple/main.css +1 -1
- package/assets/esri/themes/dark-red/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/assets/esri/themes/light-blue/main.css +1 -1
- package/assets/esri/themes/light-green/main.css +1 -1
- package/assets/esri/themes/light-purple/main.css +1 -1
- package/assets/esri/themes/light-red/main.css +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ar.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_bg.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_bs.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ca.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_cs.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_da.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_de.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_el.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_en.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_es.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_et.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_fi.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_fr.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_he.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_hr.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_hu.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_id.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_it.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ja.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ko.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_lt.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_lv.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_nb.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_nl.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_pl.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_pt-BR.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_pt-PT.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ro.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_ru.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_sk.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_sl.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_sr.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_sv.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_th.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_tr.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_uk.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_vi.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_zh-CN.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_zh-HK.json +1 -1
- package/assets/esri/widgets/Weather/t9n/Weather_zh-TW.json +1 -1
- package/chunks/CloudsComposition.glsl.js +4 -4
- package/chunks/ComponentShader.glsl.js +19 -19
- package/chunks/Precipitation.glsl.js +91 -0
- package/chunks/Terrain.glsl.js +11 -11
- package/chunks/WaterSurface.glsl.js +21 -21
- package/chunks/pe.js +1 -1
- package/chunks/vec3.js +1 -1
- package/chunks/vxlLayer.js +1 -1
- package/core/accessorSupport/ensureType.js +1 -1
- package/core/accessorSupport/get.js +1 -1
- package/core/accessorSupport/read.js +1 -1
- package/core/accessorSupport/set.js +1 -1
- package/core/accessorSupport/write.js +1 -1
- package/core/clock.js +1 -1
- package/core/has.js +1 -1
- package/core/jsonMap.js +1 -1
- package/core/libs/gl-matrix-2/math/vec3.js +1 -1
- package/core/promiseUtils.js +1 -1
- package/core/reactiveUtils.js +1 -1
- package/core/workers/workerFactory.js +1 -1
- package/form/ExpressionInfo.js +1 -1
- package/geometry/pe.js +1 -1
- package/geometry/support/axisAngleDegrees.js +1 -1
- package/geometry/support/heightModelInfoUtils.js +1 -1
- package/interfaces.d.ts +343 -106
- package/layers/RouteLayer.js +1 -1
- package/layers/VoxelLayer.js +1 -1
- package/layers/VoxelWasmPerScene.js +1 -1
- package/layers/support/RasterWorker.js +1 -1
- package/layers/support/rasterDatasets/BaseRaster.js +1 -1
- package/layers/support/rasterFunctions/rasterProjectionHelper.js +1 -1
- package/libs/vxl/enums.js +1 -1
- package/package.json +2 -2
- package/popup/content/AttachmentsContent.js +1 -1
- package/popup/content/support/mediaInfoTypes.js +1 -1
- package/portal/schemas/buildingSceneLayerItem.js +1 -1
- package/portal/schemas/definitions.js +1 -1
- package/portal/schemas/integratedMeshLayerItem.js +1 -1
- package/portal/schemas/pointCloudLayerItem.js +1 -1
- package/portal/schemas/sceneLayerItem.js +1 -1
- package/portal/schemas/webScene.js +1 -1
- package/rest/find.js +1 -1
- package/rest/geometryService/generalize.js +1 -1
- package/rest/geometryService/lengths.js +1 -1
- package/rest/geometryService/offset.js +1 -1
- package/rest/geometryService/relation.js +1 -1
- package/rest/geometryService/trimExtend.js +1 -1
- package/rest/identify.js +1 -1
- package/{tasks → rest}/operations/find.js +0 -0
- package/{tasks → rest}/operations/generalize.js +0 -0
- package/rest/operations/identify.js +5 -0
- package/{tasks → rest}/operations/lengths.js +0 -0
- package/{tasks → rest}/operations/offset.js +0 -0
- package/{tasks → rest}/operations/relation.js +0 -0
- package/{tasks → rest}/operations/trimExtend.js +0 -0
- package/{tasks → rest}/operations/urlUtils.js +0 -0
- package/rest/print.js +1 -1
- package/rest/query/operations/query.js +1 -1
- package/rest/query/operations/queryAttachments.js +1 -1
- package/rest/query/operations/queryRelatedRecords.js +1 -1
- package/rest/query/operations/queryTopFeatures.js +1 -1
- package/rest/route/utils.js +1 -1
- package/rest/support/NetworkServiceDescription.js +1 -1
- package/rest/support/RouteInfo.js +1 -1
- package/rest/support/RouteParameters.js +1 -1
- package/rest/support/RouteSettings.js +5 -0
- package/rest/support/Stop.js +1 -1
- package/rest/support/networkEnums.js +1 -1
- package/support/arcadeOnDemand.js +1 -1
- package/support/featureFlags.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/Font.js +1 -1
- package/symbols/LabelSymbol3D.js +1 -1
- package/symbols/PointSymbol3D.js +1 -1
- package/symbols/TextSymbol.js +1 -1
- package/symbols/TextSymbol3DLayer.js +1 -1
- package/symbols/cim/CIMSymbolHelper.js +1 -1
- package/symbols/cim/CIMSymbolRasterizer.js +1 -1
- package/symbols/cim/cimAnalyzer.js +1 -1
- package/symbols/cim/placements/PlacementAlongLineSameSize.js +1 -1
- package/symbols/support/Symbol3DVerticalOffset.js +1 -1
- package/symbols/support/cimSymbolUtils.js +1 -1
- package/symbols/support/previewCIMSymbol.js +1 -1
- package/symbols/support/previewSymbol2D.js +1 -1
- package/symbols/support/previewSymbol3D.js +1 -1
- package/symbols/support/previewWebStyleSymbol.js +1 -1
- package/symbols/support/svgUtils.js +1 -1
- package/symbols/support/textUtils.js +5 -0
- package/symbols.js +1 -1
- package/views/2d/MapViewConstraints.js +1 -1
- package/views/2d/engine/webgl/brushes/raster/BrushRasterBitmap.js +1 -1
- package/views/2d/engine/webgl/mesh/templates/WGLFillTemplate.js +1 -1
- package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
- package/views/2d/layers/features/sources/BaseFeatureSource.js +1 -1
- package/views/2d/layers/imagery/BaseImageryTileSubView2D.js +1 -1
- package/views/2d/support/engineHelpers.js +1 -1
- package/views/2d/viewpointUtils.js +1 -1
- package/views/3d/environment/CloudsComposition.glsl.js +1 -1
- package/views/3d/environment/CloudsComposition.js +1 -1
- package/views/3d/environment/CloudsGenerator.js +1 -1
- package/views/3d/environment/CloudsPresets.js +1 -1
- package/views/3d/environment/EnvironmentRenderer.js +1 -1
- package/views/3d/environment/Fog.js +1 -1
- package/views/3d/environment/Precipitation.glsl.js +5 -0
- package/views/3d/environment/Precipitation.js +5 -0
- package/views/3d/environment/PrecipitationTechnique.js +5 -0
- package/views/3d/environment/RainyWeather.js +1 -1
- package/views/3d/environment/SceneViewEnvironmentManager.js +1 -1
- package/views/3d/environment/SnowyWeather.js +5 -0
- package/views/3d/environment/weather.js +1 -1
- package/views/3d/interactive/analysisTools/slice/SliceTool.js +1 -1
- package/views/3d/interactive/editingTools/transformGraphic/ScaleRotateMeshAdapter.js +1 -1
- package/views/3d/layers/FeatureLayerViewBase3D.js +1 -1
- package/views/3d/layers/FeatureLikeLayerView3D.js +1 -1
- package/views/3d/layers/GraphicsLayerView3D.js +1 -1
- package/views/3d/layers/GraphicsView3D.js +1 -1
- package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
- package/views/3d/layers/VoxelLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/graphics/Graphics3DDrapedGraphicLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DElevationAlignment.js +1 -1
- package/views/3d/layers/graphics/Graphics3DFeatureProcessor.js +5 -0
- package/views/3d/layers/graphics/Graphics3DFrustumVisibility.js +1 -1
- package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DPolygonFillSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DScaleVisibility.js +1 -1
- package/views/3d/layers/graphics/Graphics3DSymbolCreationContext.js +1 -1
- package/views/3d/layers/graphics/Graphics3DSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DTextSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DWaterSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/GraphicsProcessor.js +5 -0
- package/views/3d/layers/graphics/QueryEngine.js +1 -1
- package/views/3d/support/pointsOfInterest/Focus.js +1 -1
- package/views/3d/support/sunUtils.js +1 -1
- package/views/3d/terrain/OverlayRenderer.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/shading/Water.glsl.js +21 -13
- package/views/3d/webgl-engine/core/shaderLibrary/terrain/Overlay.glsl.js +2 -2
- package/views/3d/webgl-engine/core/shaderLibrary/util/CloudsParallaxShading.glsl.js +12 -14
- package/views/3d/webgl-engine/lib/OffscreenRendering.js +1 -1
- package/views/3d/webgl-engine/lib/RenderGeometry.js +1 -1
- package/views/3d/webgl-engine/lib/RenderPluginManager.js +1 -1
- package/views/3d/webgl-engine/lib/Renderer.js +1 -1
- package/views/3d/webgl-engine/lib/ShadowAccumulator.js +1 -1
- package/views/3d/webgl-engine/lib/TextRenderParameters.js +1 -1
- package/views/3d/webgl-engine/lib/TextRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/intersectorUtilsConversions.js +1 -1
- package/views/3d/webgl-engine/lib/lodRendering/LodRenderer.js +1 -1
- package/views/3d/webgl-engine/materials/WaterTechnique.js +1 -1
- package/views/3d/webgl-engine/parts/Model.js +1 -1
- package/views/3d/webgl-engine/parts/ScreenshotManager.js +1 -1
- package/views/3d/webgl-engine/shaders/WaterSurface.glsl.js +1 -1
- package/views/MapView.js +1 -1
- package/views/SceneView.js +1 -1
- package/views/View.js +1 -1
- package/views/input/recognizers/DoubleTapDrag.js +1 -1
- package/views/input/recognizers/ImmediateDoubleClick.js +1 -1
- package/views/input/recognizers/PointerClickHoldAndDrag.js +1 -1
- package/views/input/recognizers/SingleAndDoubleClick.js +1 -1
- package/views/interactive/dragEventPipeline.js +1 -1
- package/views/interactive/editGeometry/operations/OffsetEdgeVertex.js +1 -1
- package/views/support/DefaultsFromMap.js +1 -1
- package/views/support/projectionUtils.js +5 -0
- package/views/webgl/ContextState.js +1 -1
- package/views/webgl/FramebufferObject.js +1 -1
- package/views/webgl/Renderbuffer.js +1 -1
- package/views/webgl/RenderingContext.js +1 -1
- package/views/webgl/Texture.js +1 -1
- package/views/webgl/Util.js +1 -1
- package/views/webgl/enums.js +1 -1
- package/views/webgl/rasterUtils.js +1 -1
- package/views/webgl/testFloatBufferBlend.js +1 -1
- package/widgets/AreaMeasurement3D/AreaMeasurement3DViewModel.js +1 -1
- package/widgets/Attachments.js +1 -1
- package/widgets/BasemapGallery/BasemapGalleryViewModel.js +1 -1
- package/widgets/BasemapGallery/support/BasemapGalleryItem.js +1 -1
- package/widgets/BasemapGallery/support/basemapCompatibilityUtils.js +1 -1
- package/widgets/BasemapGallery.js +1 -1
- package/widgets/DirectLineMeasurement3D/DirectLineMeasurement3DViewModel.js +1 -1
- package/widgets/Feature/FeatureExpression.js +1 -1
- package/widgets/Feature/FeatureMedia/FeatureMediaViewModel.js +1 -1
- package/widgets/Feature/FeatureMedia.js +1 -1
- package/widgets/Feature/FeatureViewModel.js +1 -1
- package/widgets/FeatureForm/InputField.js +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/Grid/Grid.js +1 -1
- package/widgets/FeatureTable.js +1 -1
- package/widgets/LayerList/LayerListViewModel.js +1 -1
- package/widgets/LineOfSight/LineOfSightViewModel.js +1 -1
- package/widgets/Popup/PopupViewModel.js +1 -1
- package/widgets/Popup/actionUtils.js +1 -1
- package/widgets/Slice/SliceViewModel.js +1 -1
- package/widgets/Slider/SliderViewModel.js +1 -1
- package/widgets/Slider.js +1 -1
- package/widgets/Weather/WeatherViewModel.js +1 -1
- package/widgets/Weather/css.js +1 -1
- package/widgets/Weather/enums.js +5 -0
- package/widgets/Weather.js +1 -1
- package/widgets/support/InteractiveAnalysisViewModel.js +1 -1
- package/widgets/support/InteractiveToolViewModel.js +1 -1
- package/widgets/support/geolocationUtils.js +1 -1
- package/assets/components/assets/calcite-icon/checkSquareF16.json +0 -1
- package/assets/components/assets/calcite-icon/checkSquareF24.json +0 -1
- package/assets/components/assets/calcite-icon/checkSquareF32.json +0 -1
- package/assets/components/assets/calcite-icon/lineSolid4.json +0 -1
- package/assets/components/assets/calcite-icon/squareF16.json +0 -1
- package/assets/components/assets/calcite-icon/squareF24.json +0 -1
- package/assets/components/assets/calcite-icon/squareF32.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagon16.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagon24.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagon32.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagonF16.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagonF24.json +0 -1
- package/assets/components/assets/calcite-icon/xHexagonF32.json +0 -1
- package/assets/components/assets/calcite-icon/xOctagonF16.json +0 -1
- package/assets/components/assets/calcite-icon/xOctagonF24.json +0 -1
- package/assets/components/assets/calcite-icon/xOctagonF32.json +0 -1
- package/assets/esri/core/workers/chunks/01ef8de7f76a8c61b464.js +0 -1
- package/assets/esri/core/workers/chunks/05db312a0ca6bd3f014a.js +0 -1
- package/assets/esri/core/workers/chunks/09da224052976e290828.js +0 -1
- package/assets/esri/core/workers/chunks/0c3e3a5baf54bd5e210c.js +0 -1
- package/assets/esri/core/workers/chunks/0f254c3e91e8fee55f28.js +0 -1
- package/assets/esri/core/workers/chunks/14bef72154b3a19561a7.js +0 -1
- package/assets/esri/core/workers/chunks/18668dc45eb9e35530df.js +0 -1
- package/assets/esri/core/workers/chunks/1fd48459afb58a6cf14f.js +0 -1
- package/assets/esri/core/workers/chunks/20411bb8e04703962ce6.js +0 -1
- package/assets/esri/core/workers/chunks/208a7e24e19fc5633dd7.js +0 -1
- package/assets/esri/core/workers/chunks/21a77eed1a4ef5b0ff08.js +0 -1
- package/assets/esri/core/workers/chunks/23745a5ab47c840dc452.js +0 -1
- package/assets/esri/core/workers/chunks/2416f8bf8bbd2ec786ab.js +0 -1
- package/assets/esri/core/workers/chunks/25a3e9bc0b4c7e0d3165.js +0 -1
- package/assets/esri/core/workers/chunks/2e445a8735ea2adb641a.js +0 -1
- package/assets/esri/core/workers/chunks/32f8c4af7e70ebdcb19e.js +0 -1
- package/assets/esri/core/workers/chunks/3564e14010953def6df9.js +0 -1
- package/assets/esri/core/workers/chunks/36a3f6fb4d1d18fcb642.js +0 -1
- package/assets/esri/core/workers/chunks/390d9021169e65c10eb8.js +0 -1
- package/assets/esri/core/workers/chunks/3a9740dccda6a733313c.js +0 -1
- package/assets/esri/core/workers/chunks/3aa4194dc5497c57647f.js +0 -1
- package/assets/esri/core/workers/chunks/403c7d64f12f00330d88.js +0 -1
- package/assets/esri/core/workers/chunks/43cdff2418325e163420.js +0 -1
- package/assets/esri/core/workers/chunks/4409d77c9734de4e82a7.js +0 -1
- package/assets/esri/core/workers/chunks/47395d225229d237f0ac.js +0 -1
- package/assets/esri/core/workers/chunks/4bfbf5a34c9207fdcf44.js +0 -1
- package/assets/esri/core/workers/chunks/5d4863a92b03bebc1b54.js +0 -1
- package/assets/esri/core/workers/chunks/60371c0f750cde87656d.js +0 -1
- package/assets/esri/core/workers/chunks/615aa2d3ecafe30c80c0.js +0 -1
- package/assets/esri/core/workers/chunks/618076e6de605873e433.js +0 -1
- package/assets/esri/core/workers/chunks/631c5b514bb73782c570.js +0 -1
- package/assets/esri/core/workers/chunks/634b5ccd7a3ac67f855d.js +0 -1
- package/assets/esri/core/workers/chunks/662d13f68cf3ec92439b.js +0 -1
- package/assets/esri/core/workers/chunks/67162b3e2cc1b5dc6818.js +0 -1
- package/assets/esri/core/workers/chunks/6c1e92ff4c732dfda756.js +0 -1
- package/assets/esri/core/workers/chunks/722a10c65456844d72b9.js +0 -1
- package/assets/esri/core/workers/chunks/75d53b28afe732c459b2.js +0 -1
- package/assets/esri/core/workers/chunks/76eef4799f6c5fff7e2d.js +0 -1
- package/assets/esri/core/workers/chunks/7e596478507466953e65.js +0 -1
- package/assets/esri/core/workers/chunks/85e27fd949475f9a6bbc.js +0 -1
- package/assets/esri/core/workers/chunks/8967288145f8fbd20e7d.js +0 -1
- package/assets/esri/core/workers/chunks/8a250ec51097f16feb66.js +0 -1
- package/assets/esri/core/workers/chunks/8b6ab6202a40fe622833.js +0 -1
- package/assets/esri/core/workers/chunks/8fdd5bca3716816d359b.js +0 -1
- package/assets/esri/core/workers/chunks/96ab518eb6ba11333dee.js +0 -1
- package/assets/esri/core/workers/chunks/99a777693e4539f0b03b.js +0 -1
- package/assets/esri/core/workers/chunks/9d9dffc8884d66a258e4.js +0 -1
- package/assets/esri/core/workers/chunks/a28b53c61bddefb6616e.js +0 -1
- package/assets/esri/core/workers/chunks/a6ff3db3493543df81bc.js +0 -1
- package/assets/esri/core/workers/chunks/a8c13529367c037cdd94.js +0 -1
- package/assets/esri/core/workers/chunks/a960074644c3722be71e.js +0 -1
- package/assets/esri/core/workers/chunks/ac8dca61ade28c542ae2.js +0 -1
- package/assets/esri/core/workers/chunks/ad081d8e49e7f90c3c26.js +0 -1
- package/assets/esri/core/workers/chunks/b10fcbe1393c812fc219.js +0 -1
- package/assets/esri/core/workers/chunks/b9de831ac379cf1d2969.js +0 -1
- package/assets/esri/core/workers/chunks/ba615f118a3a8970ef25.js +0 -1
- package/assets/esri/core/workers/chunks/ba6654a885be4b7a43f0.js +0 -1
- package/assets/esri/core/workers/chunks/be2b7cce79fd41627931.js +0 -1
- package/assets/esri/core/workers/chunks/c11474b702dfb94e8e87.js +0 -1
- package/assets/esri/core/workers/chunks/c13dfdd548dcb1bdb294.js +0 -1
- package/assets/esri/core/workers/chunks/c3eca92d02958732e141.js +0 -1
- package/assets/esri/core/workers/chunks/c6bd943fe8fd13bb4806.js +0 -1
- package/assets/esri/core/workers/chunks/c6f94b92e866b881d9b9.js +0 -1
- package/assets/esri/core/workers/chunks/c8f976e53e232e8da9cc.js +0 -981
- package/assets/esri/core/workers/chunks/cb68db7169b9dfd1c3ff.js +0 -1
- package/assets/esri/core/workers/chunks/cc96608b2802fbfe7a08.js +0 -1
- package/assets/esri/core/workers/chunks/cd02fe27eb07681cb366.js +0 -1
- package/assets/esri/core/workers/chunks/cfbffa429d88e7709c3f.js +0 -1
- package/assets/esri/core/workers/chunks/d24c4fbc567486b1188f.js +0 -1
- package/assets/esri/core/workers/chunks/d52108864136c5a8a618.js +0 -1
- package/assets/esri/core/workers/chunks/da1c2873bdbc0956dca0.js +0 -1
- package/assets/esri/core/workers/chunks/dd433c160f7a0c120b82.js +0 -1
- package/assets/esri/core/workers/chunks/de03439ca2c9782bf325.js +0 -1
- package/assets/esri/core/workers/chunks/e2d68bcd2f99a65387bf.js +0 -1
- package/assets/esri/core/workers/chunks/e6df9839b551569fbc62.js +0 -1
- package/assets/esri/core/workers/chunks/ed0297fc61014e848c18.js +0 -1
- package/assets/esri/core/workers/chunks/ef8b75b92cf549e0507e.js +0 -1
- package/assets/esri/core/workers/chunks/f467c8f1fce22f6f599c.js +0 -1
- package/assets/esri/core/workers/chunks/f678293de9a6d8f5b5db.js +0 -1
- package/assets/esri/core/workers/chunks/f7fc4c993536e62f7f3e.js +0 -1
- package/assets/esri/core/workers/chunks/fd3e5d823dc7917f4b8f.js +0 -1
- package/assets/esri/core/workers/chunks/ffaf091c6023225cf5aa.js +0 -1
- package/symbols/support/constants.js +0 -5
- package/tasks/operations/identify.js +0 -5
- package/views/3d/layers/graphics/Graphics3DFeatureLikeLayerView.js +0 -5
- package/views/3d/layers/graphics/Graphics3DGraphicLikeLayerView.js +0 -5
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7622,4889],{3920:(e,t,r)=>{r.d(t,{r:()=>u,p:()=>c});var n=r(43697),i=r(15923),s=r(61247),a=r(5600),o=r(52011),l=r(89749);const c=e=>{let t=class extends e{destroy(){var e,t;this.destroyed||(null==(e=this._get("handles"))||e.destroy(),null==(t=this._get("updatingHandles"))||t.destroy())}get handles(){return this._get("handles")||new s.Z}get updatingHandles(){return this._get("updatingHandles")||new l.t}};return(0,n._)([(0,a.Cb)({readOnly:!0})],t.prototype,"handles",null),(0,n._)([(0,a.Cb)({readOnly:!0})],t.prototype,"updatingHandles",null),t=(0,n._)([(0,o.j)("esri.core.HandleOwner")],t),t};let u=class extends(c(i.Z)){};u=(0,n._)([(0,o.j)("esri.core.HandleOwner")],u)},78346:(e,t,r)=>{r.d(t,{bA:()=>A});var n=r(20102),i=r(80442),s=r(95330),a=r(80903),o=r(25045),l=r(40330),c=r(92604),u=r(94362),f=r(99880),h=r(68773),d=(r(2587),r(17452));const p={};function m(e){var t;const r={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages&&e.packages.concat()||[],paths:{...e.paths}};return e.hasOwnProperty("async")||(r.async=!0),e.hasOwnProperty("isDebug")||(r.isDebug=!1),e.baseUrl||(r.baseUrl=p.baseUrl),null==(t=p.packages)||t.forEach((e=>{!function(e,t){for(const r of e)if(r.name===t.name)return;e.push(t)}(r.packages,e)})),r}var y=r(41213);class g{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class x{constructor(){this._dispatcher=new g,this._workerPostMessage({type:u.Cs.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,y.Y)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,y.Y)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,u.QM)(e);if(t&&t.type===u.Cs.OPEN){const{modulePath:e,jobId:r}=t;let n=await o.default.loadWorker(e);n||(n=await import(e));const i=o.default.connect(n);this._workerPostMessage({type:u.Cs.OPENED,jobId:r,data:i})}}}var w=r(70171),v=r(17202);const b=c.Z.getLogger("esri.core.workers"),{HANDSHAKE:I}=u.Cs;let _,C;const R="Failed to create Worker. Fallback to execute module in main thread";async function S(e){return new Promise((t=>{function r(i){const s=(0,u.QM)(i);s&&s.type===I&&(e.removeEventListener("message",r),e.removeEventListener("error",n),t(e))}function n(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",n),b.warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new x).addEventListener("message",r),e.addEventListener("error",n)}e.addEventListener("message",r),e.addEventListener("error",n)}))}let k=0;const T=c.Z.getLogger("esri.core.workers"),{ABORT:M,INVOKE:P,OPEN:O,OPENED:F,RESPONSE:E}=u.Cs;class N{constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),T.error(e)}))}static async create(e){const t=await async function(){if(!(0,i.Z)("esri-workers"))return S(new x);if(!_&&!C)try{const e='let globalId=0;const outgoing=new Map,configuration=JSON.parse("{CONFIGURATION}");self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());t.addEventListener("abort",(()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))}))}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,buildDate:r,version:t}=configuration.kernelInfo,{revision:n,buildDate:i,version:s}=e.kernelInfo;o!==n&&console.warn(`[esri.core.workers] Version mismatch detected between ArcGIS API for JavaScript and assets:\nAPI version: ${t} [Date: ${r}, Revision: ${o.slice(0,8)}]\nAssets version: ${s} [Date: ${i}, Revision: ${n.slice(0,8)}]`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let e;function t(o){const t=e.connect(o);self.postMessage({type:2,jobId:r,data:t},[t])}"function"==typeof define&&define.amd?require([workerPath],(r=>{e=r.default||r,checkWorkerRevision(e),e.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((r=>(e=r.default,checkWorkerRevision(e),e.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):(self.RemoteClient||importScripts(workerPath),e=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(e),e.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const e=outgoing.get(r);outgoing.delete(r),o.error?e.reject(JSON.parse(o.error)):e.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.replace('"{CONFIGURATION}"',`'${function(){let e;if(null!=h.Z.default){const t={...h.Z};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(h.Z));e.assetsPath=(0,d.hF)(e.assetsPath),e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,w.Kd)(),e.has={"esri-csp-restrictions":(0,i.Z)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,i.Z)("esri-2d-update-debug"),"esri-2d-query-centroid-enabled":(0,i.Z)("esri-2d-query-centroid-enabled"),"featurelayer-pbf":(0,i.Z)("featurelayer-pbf"),"featurelayer-simplify-thresholds":(0,i.Z)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,i.Z)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,i.Z)("featurelayer-simplify-mobile-factor"),"esri-atomics":(0,i.Z)("esri-atomics"),"esri-shared-array-buffer":(0,i.Z)("esri-shared-array-buffer"),"esri-tiles-debug":(0,i.Z)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,i.Z)("esri-workers-arraybuffer-transfer"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,d.hF)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,d.hF)(e.workers.workerPath):e.workers.workerPath=(0,d.hF)((0,f.V)("esri/core/workers/RemoteClient.js"));const t=h.Z.workers.loaderConfig,r=m({baseUrl:null==t?void 0:t.baseUrl,locale:(0,w.Kd)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...null==t?void 0:t.has},map:{...null==t?void 0:t.map},paths:{...null==t?void 0:t.paths},packages:(null==t?void 0:t.packages)||[]}),n={version:l.i8,buildDate:v.r,revision:v.$};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:n})}()}'`);_=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){C=e||{}}let e;if(_)try{e=new Worker(_,{name:"esri-worker-"+k++})}catch(t){b.warn(R,C),e=new x}else b.warn(R,C),e=new x;return S(e)}();return new N(t,e)}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,n=(0,u.jt)();return new Promise(((t,i)=>{const a={resolve:t,reject:i,abortHandle:(0,s.$F)(r,(()=>{this._outJobs.delete(n),this._post({type:M,jobId:n})}))};this._outJobs.set(n,a),this._post({type:O,jobId:n,modulePath:e})}))}_onMessage(e){const t=(0,u.QM)(e);if(t)switch(t.type){case F:this._onOpenedMessage(t);break;case E:this._onResponseMessage(t);break;case M:this._onAbortMessage(t);break;case P:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,n=t.get(r);n&&(n.controller&&n.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:n,abortable:i}=e,a=i?new AbortController:null,o=this._inJobs,c=l.Nv[t];let f;try{if("function"!=typeof c)throw new TypeError(`${t} is not a function`);f=c.call(null,n,{signal:a?a.signal:null})}catch(e){return void this._post({type:E,jobId:r,error:(0,u.AB)(e)})}(0,s.y8)(f)?(o.set(r,{controller:a,promise:f}),f.then((e=>{o.has(r)&&(o.delete(r),this._post({type:E,jobId:r},e))}),(e=>{o.has(r)&&(o.delete(r),e||(e={message:"Error encountered at method"+t}),(0,s.D_)(e)||this._post({type:E,jobId:r,error:(0,u.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:E,jobId:r},f)}_onOpenedMessage(e){var t;const{jobId:r,data:n}=e,i=this._outJobs.get(r);i&&(this._outJobs.delete(r),null==(t=i.abortHandle)||t.remove(),i.resolve(n))}_onResponseMessage(e){var t;const{jobId:r,error:i,data:s}=e,a=this._outJobs.get(r);a&&(this._outJobs.delete(r),null==(t=a.abortHandle)||t.remove(),i?a.reject(n.Z.fromJSON(JSON.parse(i))):a.resolve(s))}_post(e,t,r){return(0,u.oi)(this.worker,e,t,r)}}let Z=(0,i.Z)("esri-workers-debug")?1:(0,i.Z)("host-browser")?navigator.hardwareConcurrency-1:0;Z||(Z=(0,i.Z)("safari")&&(0,i.Z)("mac")||(0,i.Z)("trident")?7:2);let B=0;const D=[];async function z(e,t){const r=new a.Z;return await r.open(e,t),r}async function A(e,t={}){if("string"!=typeof e)throw new n.Z("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,i.Z)("host-webworker")&&!(0,i.Z)("esri-workers")&&(r="local"),"local"===r){let r=await o.default.loadWorker(e);r||(r=await import(e)),(0,s.k_)(t.signal);const n=t.client||r;return z([o.default.connect(r)],{...t,client:n})}if(await async function(){if(L)return L;H=new AbortController;const e=[];for(let t=0;t<Z;t++){const r=N.create(t).then((e=>(D[t]=e,e)));e.push(r)}return L=Promise.all(e),L}(),(0,s.k_)(t.signal),"dedicated"===r){const r=B++%Z;return z([await D[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,Z);if(r<Z){const n=new Array(r);for(let i=0;i<r;++i){const r=B++%Z;n[i]=D[r].open(e,t)}return z(n,t)}}return z(D.map((r=>r.open(e,t))),t)}let H,L=null},2587:(e,t,r)=>{r(90344),r(18848),r(940),r(70171);var n=r(94443),i=r(3172),s=r(20102),a=r(70586);async function o(e){if((0,a.pC)(c.fetchBundleAsset))return c.fetchBundleAsset(e);const t=await(0,i.default)(e,{responseType:"text"});return JSON.parse(t.data)}class l{constructor({base:e="",pattern:t,location:r=new URL(window.location.href)}){let n;n="string"==typeof r?e=>new URL(e,new URL(r,window.location.href)).href:r instanceof URL?e=>new URL(e,r).href:r,this.pattern="string"==typeof t?new RegExp(`^${t}`):t,this.getAssetUrl=n,e=e?e.endsWith("/")?e:e+"/":"",this.matcher=new RegExp(`^${e}(?:(.*)/)?(.*)$`)}fetchMessageBundle(e,t){return async function(e,t,r,i){const a=t.exec(r);if(!a)throw new s.Z("esri-intl:invalid-bundle",`Bundle id "${r}" is not compatible with the pattern "${t}"`);const l=a[1]?`${a[1]}/`:"",c=a[2],u=(0,n.Su)(i),f=`${l}${c}.json`,h=u?`${l}${c}_${u}.json`:f;let d;try{d=await o(e(h))}catch(t){if(h===f)throw new s.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:t});try{d=await o(e(f))}catch(e){throw new s.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:e})}}return d}(this.getAssetUrl,this.matcher,e,t)}}const c={};var u,f=r(99880);(0,n.tz)((u={pattern:"esri/",location:f.V},new l(u)))},94443:(e,t,r)=>{r.d(t,{ME:()=>d,Su:()=>p,tz:()=>h});var n=r(20102),i=r(95330),s=r(70171);const a=/^([a-z]{2})(?:[-_]([A-Za-z]{2}))?$/,o={ar:!0,bg:!0,bs:!0,ca:!0,cs:!0,da:!0,de:!0,el:!0,en:!0,es:!0,et:!0,fi:!0,fr:!0,he:!0,hr:!0,hu:!0,id:!0,it:!0,ja:!0,ko:!0,lt:!0,lv:!0,nb:!0,nl:!0,pl:!0,"pt-BR":!0,"pt-PT":!0,ro:!0,ru:!0,sk:!0,sl:!0,sr:!0,sv:!0,th:!0,tr:!0,uk:!0,vi:!0,"zh-CN":!0,"zh-HK":!0,"zh-TW":!0};function l(e){var t;return null!=(t=o[e])&&t}const c=[],u=new Map;function f(e){for(const t of u.keys())m(e.pattern,t)&&u.delete(t)}function h(e){return c.includes(e)||(f(e),c.unshift(e)),{remove(){const t=c.indexOf(e);t>-1&&(c.splice(t,1),f(e))}}}async function d(e){const t=(0,s.Kd)();u.has(e)||u.set(e,async function(e,t){const r=[];for(const n of c)if(m(n.pattern,e))try{return await n.fetchMessageBundle(e,t)}catch(e){r.push(e)}if(r.length)throw new n.Z("intl:message-bundle-error",`Errors occurred while loading "${e}"`,{errors:r});throw new n.Z("intl:no-message-bundle-loader",`No loader found for message bundle "${e}"`)}(e,t));const r=u.get(e);return await y.add(r),r}function p(e){if(!a.test(e))return null;const[,t,r]=a.exec(e),n=t+(r?"-"+r.toUpperCase():"");return l(n)?n:l(t)?t:null}function m(e,t){return"string"==typeof e?t.startsWith(e):e.test(t)}(0,s.Ze)((()=>{u.clear()}));const y=new class{constructor(){this._numLoading=0}async waitForAll(){this._dfd&&await this._dfd.promise}add(e){return this._increase(),e.then((()=>this._decrease()),(()=>this._decrease())),this.waitForAll()}_increase(){this._numLoading++,this._dfd||(this._dfd=(0,i.dD)())}_decrease(){this._numLoading=Math.max(this._numLoading-1,0),this._dfd&&0===this._numLoading&&(this._dfd.resolve(),this._dfd=null)}}},940:(e,t,r)=>{r.d(t,{n:()=>c});var n=r(92604),i=r(78286),s=r(19153),a=r(90344),o=r(18848);const l=n.Z.getLogger("esri.intl");function c(e,t,r={}){const{format:n={}}=r;return(0,s.gx)(e,(e=>function(e,t,r){let n,s;const a=e.indexOf(":");if(-1===a?n=e.trim():(n=e.slice(0,a).trim(),s=e.slice(a+1).trim()),!n)return"";const o=(0,i.hS)(n,t);if(null==o)return"";const l=r[s]||r[n];return l?u(o,l):s?f(o,s):h(o)}(e,t,n)))}function u(e,t){switch(t.type){case"date":return(0,a.p6)(e,t.intlOptions);case"number":return(0,o.uf)(e,t.intlOptions);default:return l.warn("missing format descriptor for key {key}"),h(e)}}function f(e,t){switch(t.toLowerCase()){case"dateformat":return(0,a.p6)(e);case"numberformat":return(0,o.uf)(e);default:return l.warn(`inline format is unsupported since 4.12: ${t}`),/^(dateformat|datestring)/i.test(t)?(0,a.p6)(e):/^numberformat/i.test(t)?(0,o.uf)(e):h(e)}}function h(e){switch(typeof e){case"string":return e;case"number":return(0,o.uf)(e);case"boolean":return""+e;default:return e instanceof Date?(0,a.p6)(e):""}}},52294:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Ve});var n=r(43697),i=r(51773),s=r(14746),a=r(20102),o=r(70586),l=r(16453),c=r(95330),u=r(5600),f=(r(67676),r(80442),r(75215)),h=r(36030),d=r(71715),p=r(52011),m=r(29600),y=r(71612),g=r(17017),x=(r(66577),r(3172)),w=r(92604),v=r(44422),b=r(8744),I=r(66677),_=r(21506),C=r(35956),R=r(88281),S=r(11145),k=r(80676),T=r(67058),M=r(91219),P=r(23808),O=r(6570),F=r(82971);const E=w.Z.getLogger("esri.layers.mixins.ImageryTileMixin"),N=e=>{let t=class extends e{constructor(){super(...arguments),this._rasterJobHandler={instance:null,refCount:0,connectionPromise:null},this.bandIds=null,this.copyright=null,this.fullExtent=null,this.interpolation="nearest",this.multidimensionalDefinition=null,this.raster=null,this.rasterInfo=null,this.sourceJSON=null,this.spatialReference=null,this.tileInfo=null,this.symbolizer=null}set url(e){this._set("url",(0,I.Nm)(e,E))}set renderer(e){this._set("renderer",e),this.updateRenderer()}async convertVectorFieldData(e,t){if((0,o.Wi)(e))return null;const r=this._rasterJobHandler.instance,n=this.rasterInfo.dataType;return r?r.convertVectorFieldData({pixelBlock:e,dataType:n},t):(0,k.KC)(e,n)}async createStreamlinesMesh(e,t){const r=this._rasterJobHandler.instance;return r?r.createStreamlinesMesh(e,t):(0,P.z_)(e.rendererSettings,e.flowData,(0,o.pC)(t.signal)?t.signal:(new AbortController).signal)}normalizeRasterFetchOptions(e){const{multidimensionalInfo:t}=this.rasterInfo;if((0,o.Wi)(t))return e;let r=e.multidimensionalDefinition||this.multidimensionalDefinition;!(0,o.Wi)(r)&&r.length||(r=this._getDefaultSlice());const n=e.timeExtent||this.timeExtent;if((0,o.pC)(r)&&(0,o.pC)(n)&&((0,o.pC)(n.start)||(0,o.pC)(n.end))){var i,s;r=r.map((e=>e.clone()));const a=null==(i=t.variables.find((({name:e})=>e===r[0].variableName)))||null==(s=i.dimensions)?void 0:s.find((({name:e})=>"StdTime"===e)),l=r.find((({dimensionName:e})=>"StdTime"===e));if(!a||!l)return{...e,multidimensionalDefinition:null};const{start:c,end:u}=n,f=(0,o.Wi)(c)?null:c.getTime(),h=(0,o.Wi)(u)?null:u.getTime(),d=null!=f?f:h,p=null!=h?h:f;if((0,o.pC)(a.values)){const e=a.values.filter((e=>{if(Array.isArray(e)){if(d===p)return e[0]<=d&&e[1]>=d;const t=e[0]<=d&&e[1]>d||e[0]<p&&e[1]>=p,r=e[0]>=d&&e[1]<=p||e[0]<d&&e[1]>p;return t||r}return d===p?e===d:e>=d&&e<=p}));if(e.length){const t=e.sort(((e,t)=>{var r,n,i,s;return d===p?(null!=(i=e[0])?i:e)-(null!=(s=t[0])?s:t):Math.abs((null!=(r=e[1])?r:e)-p)-Math.abs((null!=(n=t[1])?n:t)-p)}))[0];l.values=[t]}else r=null}else if(a.hasRegularIntervals&&a.extent){const[e,t]=a.extent;d>t||p<e?r=null:l.values=d===p?[d]:[Math.max(e,d),Math.min(t,p)]}}return{...e,multidimensionalDefinition:r}}async updateRenderer(){if(!this.loaded)return;if(JSON.stringify(this._cachedRendererJson)===JSON.stringify(this.renderer))return;const e=this._rasterJobHandler.instance;e&&(this.symbolizer.rendererJSON=(0,T.ol)(this.renderer.toJSON()),this.symbolizer.bind(),await e.updateSymbolizer(this.symbolizer),this._cachedRendererJson=this.renderer.toJSON())}async applyRenderer(e,t){const r=e&&e.pixelBlock;if(!((0,o.pC)(r)&&r.pixels&&r.pixels.length>0))return null;let n;await this.updateRenderer();const i=this._rasterJobHandler.instance,{bandIds:s}=this;return n=i?await i.symbolize({...e,simpleStretchParams:t,bandIds:s}):this.symbolizer.symbolize({...e,simpleStretchParams:t,bandIds:s}),n}getTileUrl(e,t,r){return"RasterTileServer"===this.raster.datasetFormat?`${this.url}/tile/${e}/${t}/${r}`:""}getCompatibleTileInfo(e,t,r=!1){if(!this.loaded||(0,o.Wi)(t))return null;if(r&&e.equals(this.spatialReference))return this.tileInfo;const n=(0,b.C5)(e);return S.Z.create({size:256,spatialReference:e,origin:n?{x:n.origin[0],y:n.origin[1]}:{x:t.xmin,y:t.ymax}})}getCompatibleFullExtent(e){return this.loaded?(this._compatibleFullExtent&&this._compatibleFullExtent.spatialReference.equals(e)||(this._compatibleFullExtent=this.raster.computeExtent(e)),this._compatibleFullExtent):null}async fetchTile(e,t,r,n={}){if(n.requestAsImageElement){const i=this.getTileUrl(e,t,r);return(0,x.default)(i,{responseType:"image",query:{...this.refreshParameters,...this.raster.ioConfig.customFetchParameters},signal:n.signal}).then((e=>e.data))}if((0,o.pC)(this.rasterInfo.multidimensionalInfo)&&(n=this.normalizeRasterFetchOptions(n),(0,o.Wi)(n.multidimensionalDefinition))){const i=n.tileInfo||this.rasterInfo.storageInfo.tileInfo;return{extent:this.raster.getTileExtentFromTileInfo(e,t,r,i),pixelBlock:null}}return await this._initJobHandler(),"raster-shaded-relief"===this.renderer.type&&(n={...n,buffer:{cols:1,rows:1}}),this.raster.fetchTile(e,t,r,n)}async fetchPixels(e,t,r,n={}){return(0,o.pC)(this.rasterInfo.multidimensionalInfo)&&(n=this.normalizeRasterFetchOptions(n),(0,o.Wi)(n.multidimensionalDefinition))?{extent:e,pixelBlock:null}:(await this._initJobHandler(),this.raster.fetchPixels(e,t,r,n))}async identify(e,t={}){return(0,o.pC)(this.rasterInfo.multidimensionalInfo)&&(t=this.normalizeRasterFetchOptions(t),(0,o.Wi)(t.multidimensionalDefinition))?{location:e,value:null}:this.raster.identify(e,t)}increaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount++}decreaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount--,this._rasterJobHandler.refCount<=0&&this._shutdownJobHandler()}hasStandardTime(){var e;const t=this.rasterInfo.multidimensionalInfo;if(!(0,o.pC)(t)||"standard-time"!==this.rasterInfo.dataType)return!1;const r=null==(e=this.multidimensionalDefinition[0])?void 0:e.variableName;return t.variables.some((e=>e.name===r&&e.dimensions.some((e=>"StdTime"===e.name))))}getStandardTimeValue(e){return new Date(24*(e-25569)*3600*1e3).toString()}_configDefaultSettings(){this._configDefaultInterpolation(),this.multidimensionalDefinition||(this.multidimensionalDefinition=this._getDefaultSlice()),this._configDefaultRenderer()}_initJobHandler(){if(null!=this._rasterJobHandler.connectionPromise)return this._rasterJobHandler.connectionPromise;const e=new R.Z;return this._rasterJobHandler.connectionPromise=e.initialize().then((()=>{this._rasterJobHandler.instance=e,this.raster.rasterJobHandler=e,this.renderer&&this.updateRenderer()})).catch((()=>null)),this._rasterJobHandler.connectionPromise}_shutdownJobHandler(){this._rasterJobHandler.instance&&this._rasterJobHandler.instance.destroy(),this._rasterJobHandler.instance=null,this._rasterJobHandler.connectionPromise=null,this._rasterJobHandler.refCount=0,this.raster.rasterJobHandler=null}_configDefaultInterpolation(){if(null==this.interpolation){var e;const t=(0,T.In)(this.rasterInfo,this.raster.tileType,null==(e=this.sourceJSON)?void 0:e.defaultResamplingMethod);this._set("interpolation",t)}}_getDefaultSlice(){const{multidimensionalInfo:e}=this.raster.rasterInfo;if(!(0,o.pC)(e))return null;const t=e.variables[0];return t.dimensions.map((e=>{var r,n;return new C.Z({variableName:t.name,dimensionName:e.name,values:[null!=(r=null==(n=e.values)?void 0:n[0])?r:e.extent[0]],isSlice:!0})}))}_configDefaultRenderer(){const e=this.raster.rasterInfo;var t;this.bandIds||(this.bandIds=(0,T.YD)(e)),this.renderer||(this.renderer=(0,T.Ob)(e,{bandIds:this.bandIds,variableName:(0,o.pC)(this.multidimensionalDefinition)?null==(t=this.multidimensionalDefinition[0])?void 0:t.variableName:null})),this.symbolizer?(this.symbolizer.rendererJSON=(0,T.ol)(this.renderer.toJSON()),this.symbolizer.rasterInfo=e):this.symbolizer=new M.Z({rendererJSON:this.renderer.toJSON(),rasterInfo:e});const r=this.symbolizer.bind();r.success||E.warn("imagery-tile-mixin",r.error||"The given renderer is not supported by the layer.")}};return(0,n._)([(0,u.Cb)()],t.prototype,"_cachedRendererJson",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"_compatibleFullExtent",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"_rasterJobHandler",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"bandIds",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"copyright",void 0),(0,n._)([(0,u.Cb)({type:O.Z}),(0,v.B)("rasterInfo.extent")],t.prototype,"fullExtent",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"interpolation",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"ioConfig",void 0),(0,n._)([(0,u.Cb)({type:[C.Z]})],t.prototype,"multidimensionalDefinition",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"raster",void 0),(0,n._)([(0,u.Cb)({readOnly:!0}),(0,v.B)("raster.rasterInfo")],t.prototype,"rasterInfo",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"sourceJSON",void 0),(0,n._)([(0,u.Cb)({type:F.Z}),(0,v.B)("rasterInfo.spatialReference")],t.prototype,"spatialReference",void 0),(0,n._)([(0,u.Cb)({type:S.Z}),(0,v.B)("rasterInfo.storageInfo.tileInfo")],t.prototype,"tileInfo",void 0),(0,n._)([(0,u.Cb)(_.HQ)],t.prototype,"url",null),(0,n._)([(0,u.Cb)({types:s.dr})],t.prototype,"renderer",null),(0,n._)([(0,u.Cb)()],t.prototype,"symbolizer",void 0),t=(0,n._)([(0,p.j)("esri.layers.ImageryTileMixin")],t),t};var Z=r(38009),B=r(16859),D=r(34760),z=r(72965),A=r(28294),H=r(1231),L=r(69608),J=r(30547),W=r(48526),j=r(36679),q=r(96674),U=r(609),$=r(73506),G=r(13473);const V=new Map,Y=new class{constructor(e=15e3,t=5e3){this._timer=null,this._cachedBlocks=new Map,this._size=-1,this._duration=e,this._interval=Math.min(e,t)}decreaseRefCount(e,t){const r=e+"/"+t,n=this._cachedBlocks;if(n.has(r)){const e=n.get(r);return e.refCount--,e.refCount<=0&&(n.delete(r),e.controller&&e.controller.abort()),e.refCount}return 0}getBlock(e,t){const r=e+"/"+t,n=this._cachedBlocks;if(n.has(r)){const e=n.get(r);return e.ts=Date.now(),e.refCount++,n.delete(r),n.set(r,e),e.block}return null}putBlock(e,t,r,n=null){const i=this._cachedBlocks,s=e+"/"+t;if(i.has(s)){const e=i.get(s);e.ts=Date.now(),e.refCount++}else i.set(s,{block:r,ts:Date.now(),refCount:1,controller:n});this._trim(),this._updateTimer()}deleteBlock(e,t){const r=this._cachedBlocks,n=e+"/"+t;r.has(n)&&r.delete(n)}updateMaxSize(e){this._size=e,this._trim()}empty(){this._cachedBlocks.clear(),this._clearTimer()}getCurrentSize(){return this._cachedBlocks.size}_updateTimer(){if(null!=this._timer)return;const e=this._cachedBlocks;this._timer=setInterval((()=>{const t=Array.from(e),r=Date.now();for(let n=0;n<t.length&&t[n][1].ts<=r-this._duration;n++)e.delete(t[n][0]);0===e.size&&this._clearTimer()}),this._interval)}_trim(){const e=this._cachedBlocks;if(-1===this._size||this._size>=e.size)return;const t=Array.from(e);for(let r=0;r<t.length-this._size;r++)e.delete(t[r][0])}_clearTimer(){null!=this._timer&&(clearInterval(this._timer),this._timer=null)}};function X(e,t){return null==t?e:`${e}?sliceId=${t}`}function K(e,t,r){if(!V.has(e))return null==t?Y.decreaseRefCount(e,r):0;const n=V.get(e);if(null==n[t])return Y.decreaseRefCount(e,r);const i=n[t].cache;if(i.has(r)){const e=i.get(r);if(e.refCount--,0===e.refCount){i.delete(r);for(let e=0;e<n.length;e++)n[e]&&n[e].cache.has(r)&&n[e].cache.delete(r);e.controller&&e.controller.abort()}return e.refCount}return 0}function Q(e,t,r){if(!V.has(e))return null==t?Y.getBlock(e,r):null;const n=V.get(e);if(null==n[t]){for(let e=0;e<n.length;e++)if(n[e]&&n[e].cache.has(r)){const t=n[e].cache.get(r);return t.refCount++,t.block}return Y.getBlock(e,r)}const i=n[t].cache;if(i.has(r)){const e=i.get(r);return e.refCount++,e.block}for(let e=0;e<n.length;e++)if(e!==t&&n[e]&&n[e]&&n[e].cache.has(r)){const t=n[e].cache.get(r);return t.refCount++,i.set(r,t),t.block}return null}function ee(e,t,r,n,i=null){if(!V.has(e))return void(null==t&&Y.putBlock(e,r,n,i));const s=V.get(e);if(null==s[t])return void Y.putBlock(e,r,n,i);const a={refCount:1,block:n,isResolved:!1,isRejected:!1,controller:i};n.then((()=>a.isResolved=!0)).catch((()=>a.isRejected=!0)),s[t].cache.set(r,a)}function te(e,t,r){if(!V.has(e))return void(null==t&&Y.deleteBlock(e,r));const n=V.get(e);null!=n[t]?n[t].cache.delete(r):Y.deleteBlock(e,r)}var re=r(75993),ne=r(55914);let ie=class extends((0,U.v)(q.wq)){constructor(){super(...arguments),this.rasterJobHandler=null,this.datasetName=null,this.datasetFormat=null,this.rasterInfo=null,this.ioConfig={sampling:"closest"}}async init(){const e=(0,$.zD)();this.addResolvingPromise(e),await this.when()}normalizeCtorArgs(e){return e&&e.ioConfig&&(e={...e,ioConfig:{resolution:null,bandIds:null,sampling:"closest",tileInfo:S.Z.create(),...e.ioConfig}}),e}set url(e){this._set("url",(0,I.Nm)(e,w.Z.getLogger(this.declaredClass)))}async open(e){throw new a.Z("BaseRaster:open-not-implemented","open() is not implemented")}async fetchTile(e,t,r,n={}){const i=n.tileInfo||this.rasterInfo.storageInfo.tileInfo,s=this.getTileExtentFromTileInfo(e,t,r,i);return this.fetchPixels(s,i.size[0],i.size[1],n)}async identify(e,t={}){t=this._getRequestOptionsWithSliceId(t);const{spatialReference:r,extent:n}=this.rasterInfo,{datumTransformation:i}=t;let s=(0,$.nF)(e,r,i);if(!n.intersects(s))return{location:s,value:null};if((0,o.pC)(this.rasterInfo.transform)){const e=this.rasterInfo.transform.inverseTransform(s);if(!this.rasterInfo.nativeExtent.intersects(e))return{location:e,value:null};s=e}let a=0;if(t.srcResolution)a=(0,$.kr)(t.srcResolution,this.rasterInfo,this.ioConfig.sampling).pyramidLevel;else if(a=await this.computeBestPyramidLevelForLocation(e,t),null==a)return{location:s,value:null};const l=this.identifyPixelLocation(s,a,null);if(null===l)return{location:s,value:null};const{row:c,col:u,rowOffset:f,colOffset:h}=l,d=X(this.url,t.sliceId),p=`${a}/${c}/${u}`;let m=Q(d,null,p);(0,o.Wi)(m)&&(m=this.fetchRawTile(a,c,u,t),ee(d,null,p,m));const y=await m;if((0,o.Wi)(y)||!y.pixels||0===y.pixels.length)return{location:s,value:null};const g=f*this.rasterInfo.storageInfo.blockHeight+h,x=!y.mask||y.mask[g]?y.pixels.map((e=>e[g])):null,w=this.rasterInfo.dataType;return("vector-magdir"===w||"vector-uv"===w)&&(null==x?void 0:x.length)>1?{location:s,value:x,magdirValue:"vector-magdir"===w?[x[0],x[1]]:(0,k.Tg)([x[0],x[1]]),pyramidLevel:a}:{location:s,value:x,pyramidLevel:a}}async fetchPixels(e,t,r,n={}){e=(0,$.kZ)(e);const i=(0,$.ut)(e.spatialReference),s=(0,$.Hq)(e),a=(0,$.ut)(this.rasterInfo.spatialReference),l=(0,o.pC)(a)&&this.rasterInfo.extent.width>=a/2;if(n=this._getRequestOptionsWithSliceId(n),(0,o.Wi)(i)||0===s||1===s&&l)return this._fetchPixels(e,t,r,n);if(s>=3)return{extent:e,pixelBlock:null};const c=[],{xmin:u,xmax:f}=e,h=Math.round(i/(f-u)*t),d=h-Math.round((i/2-u)/(f-u)*t);let p=0;const m=[];for(let a=0;a<=s;a++){const o=new O.Z({xmin:0===a?u:-i/2,xmax:a===s?f-i*a:i/2,ymin:e.ymin,ymax:e.ymax,spatialReference:e.spatialReference}),l=0===a?h-d:a===s?t-p:h;p+=l,m.push(l);const y=this._fetchPixels(o,l,r,n);c.push(y)}const y=(await Promise.all(c)).map((e=>null==e?void 0:e.pixelBlock));let g=null;const x={width:t,height:r};return g=this.rasterJobHandler?await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:y,srcMosaicSize:x,destDimension:null,coefs:null,sampleSpacing:null,interpolation:"nearest",alignmentInfo:null,blockWidths:m},n):(0,ne.us)(y,x,{blockWidths:m}),{extent:e,srcExtent:(0,$.tB)(e,this.rasterInfo.spatialReference,n.datumTransformation),pixelBlock:g}}async fetchRawPixels(e,t,r,n={}){t={x:Math.floor(t.x),y:Math.floor(t.y)};const i=await this._fetchRawTiles(e,t,r,n),{nativeExtent:s,nativePixelSize:a,storageInfo:l}=this.rasterInfo,c=2**e,u=a.x*c,f=a.y*c,h=new O.Z({xmin:s.xmin+u*t.x,xmax:s.xmin+u*(t.x+r.width-1),ymin:s.ymax-f*(t.y+r.height-1),ymax:s.ymax-f*t.y,spatialReference:s.spatialReference});if(!i)return{extent:h,srcExtent:h,pixelBlock:null};const{pixelBlocks:d}=i;if(1===d.length&&(0,o.pC)(d[0])&&d[0].width===r.width&&d[0].height===r.height)return{extent:h,srcExtent:h,pixelBlock:i.pixelBlocks[0]};const p=e>0?l.pyramidBlockWidth:l.blockWidth,m=e>0?l.pyramidBlockHeight:l.blockHeight,y={width:Math.ceil(r.width/p)*p,height:Math.ceil(r.height/m)*m},g={x:t.x%p,y:t.y%m};let x;return x=this.rasterJobHandler?await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:d,srcMosaicSize:r,destDimension:r,clipOffset:g,clipSize:r,coefs:null,sampleSpacing:null,interpolation:n.interpolation,alignmentInfo:null,blockWidths:null},n):(0,ne.us)(d,y,{clipOffset:g,clipSize:r}),{extent:h,srcExtent:h,pixelBlock:x}}fetchRawTile(e,t,r,n){throw new a.Z("BaseRaster:read-not-implemented","fetchRawTile() is not implemented")}computeExtent(e){return(0,$.tB)(this.rasterInfo.extent,e)}decodePixelBlock(e,t){return!this.rasterJobHandler||t.useCanvas?(0,re.J)(e,t):this.rasterJobHandler.decode({data:e,options:t})}async request(e,t,r){var n,i;const{customFetchParameters:s}=this.ioConfig,{range:a,query:o,headers:l}=t;r=null!=(n=null!=(i=r)?i:t.retryCount)?n:this.ioConfig.retryCount;const c=a?{Range:`bytes=${a.from}-${a.to}`}:null;try{return await(0,x.default)(e,{...t,query:{...o,...s},headers:{...l,...c}})}catch(n){if(r>0)return r--,this.request(e,t,r);throw n}}getSliceIndex(e){const{multidimensionalInfo:t}=this.rasterInfo;if(!(0,o.pC)(t))return null;if(!(0,o.pC)(e)||0===e.length)return null;let r=0;const n=e[0].variableName;for(let i=0;i<t.variables.length;i++){const s=t.variables[i],a=s.dimensions;if(s.name!==n){r+=a.map((e=>this._getDimensionValuesCount(e))).reduce(((e,t)=>e+t));break}const o=a.map((e=>this._getDimensionValuesCount(e))),l=a.length;for(let t=0;t<l;t++){const n=e.filter((e=>e.dimensionName===a[t].name))[0];if(null==n)return null;const i=Array.isArray(n.values[0])?n.values[0][0]:n.values[0],s=this._getIndexFromDimensions(i,a[t]);if(-1===s)return null;o.shift(),r+=t===l-1?s:s*o.reduce(((e,t)=>e+t))}}return r}getTileExtentFromTileInfo(e,t,r,n){const i=n.lodAt(e);return this.getTileExtent({x:i.resolution,y:i.resolution},t,r,n.origin,n.spatialReference,n.size)}updateTileInfo(){const{storageInfo:e,spatialReference:t,extent:r,pixelSize:n}=this.rasterInfo;if(!e.tileInfo){const i=[],s=e.maximumPyramidLevel||0;let a=Math.max(n.x,n.y),o=1/.0254*96*a;for(let e=0;e<=s;e++)i.push({level:s-e,resolution:a,scale:o}),a*=2,o*=2;const l=new G.Z({x:r.xmin,y:r.ymax,spatialReference:t});e.tileInfo=new S.Z({origin:l,size:[e.blockWidth,e.blockHeight],spatialReference:t,lods:i}),e.isVirtualTileInfo=!0}}createRemoteDatasetStorageInfo(e,t=512,r=512,n){const{width:i,height:s,nativeExtent:a,pixelSize:o,spatialReference:l}=e,c=new G.Z({x:a.xmin,y:a.ymax,spatialReference:l});null==n&&(n=Math.max(0,Math.round(Math.log(Math.max(i,s))/Math.LN2-8)));const u=this.computeBlockBoundary(a,512,512,{x:a.xmin,y:a.ymax},[o],n);e.storageInfo=new j.Z({blockWidth:t,blockHeight:r,pyramidBlockWidth:t,pyramidBlockHeight:r,origin:c,firstPyramidLevel:1,maximumPyramidLevel:n,blockBoundary:u})}async computeBestPyramidLevelForLocation(e,t={}){return 0}computeBlockBoundary(e,t,r,n,i,s=0,a=2){if(1===i.length&&s>0){i=[...i];let{x:e,y:t}=i[0];for(let r=0;r<s;r++)e*=a,t*=a,i.push({x:e,y:t})}const o=[],{x:l,y:c}=n;for(let n=0;n<i.length;n++){const{x:s,y:a}=i[n];o.push({minCol:Math.floor((e.xmin-l+.1*s)/t/s),maxCol:Math.floor((e.xmax-l-.1*s)/t/s),minRow:Math.floor((c-e.ymax+.1*a)/r/a),maxRow:Math.floor((c-e.ymin-.1*a)/r/a)})}return o}getPyramidPixelSize(e){const{nativePixelSize:t}=this.rasterInfo,{pyramidResolutions:r,pyramidScalingFactor:n}=this.rasterInfo.storageInfo;if(0===e)return t;if((0,o.pC)(r)&&r.length)return r[e-1];const i=n**e;return{x:t.x*i,y:t.y*i}}identifyPixelLocation(e,t,r){const{spatialReference:n,nativeExtent:i}=this.rasterInfo,{blockWidth:s,blockHeight:a,maximumPyramidLevel:o,origin:l}=this.rasterInfo.storageInfo,c=(0,$.nF)(e,n,r);if(!i.intersects(c))return null;if(t<0||t>o)return null;const u=this.getPyramidPixelSize(t),{x:f,y:h}=u,d=(l.y-c.y)/h/a,p=(c.x-l.x)/f/s,m=Math.min(a-1,Math.floor((d-Math.floor(d))*a)),y=Math.min(s-1,Math.floor((p-Math.floor(p))*s));return{pyramidLevel:t,row:Math.floor(d),col:Math.floor(p),rowOffset:m,colOffset:y,srcLocation:c}}getTileExtent(e,t,r,n,i,s){const[a,o]=s,l=n.x+r*a*e.x,c=l+a*e.x,u=n.y-t*o*e.y,f=u-o*e.y;return new O.Z({xmin:l,xmax:c,ymin:f,ymax:u,spatialReference:i})}getBlockWidthHeight(e){return{blockWidth:e>0?this.rasterInfo.storageInfo.pyramidBlockWidth:this.rasterInfo.storageInfo.blockWidth,blockHeight:e>0?this.rasterInfo.storageInfo.pyramidBlockHeight:this.rasterInfo.storageInfo.blockHeight}}isBlockOutside(e,t,r){const n=this.rasterInfo.storageInfo.blockBoundary[e];return!n||n.maxRow<t||n.maxCol<r||n.minRow>t||n.minCol>r}async _fetchPixels(e,t,r,n={}){let i=(0,$.Hq)(e);if(i>=2)return{extent:e,pixelBlock:null};const s=this._getSourceDataInfo(e,t,r,n),{pyramidLevel:a,pyramidResolution:l,srcResolution:c,srcExtent:u,srcWidth:f,srcHeight:h}=s;if(0===f||0===h)return{extent:e,srcExtent:u,pixelBlock:null};const d=(0,o.Wg)(this.rasterInfo.transform);"gcs-shift"===(null==d?void 0:d.type)&&(i=(0,$.Hq)(s.srcExtent,!0));const p=this.rasterInfo.storageInfo,m={x:Math.floor((u.xmin-p.origin.x)/l.x+.1),y:Math.floor((p.origin.y-u.ymax)/l.y+.1)},y=await this._fetchRawTiles(a,m,{width:f,height:h,wrapCount:i},n);if(!y)return{extent:e,srcExtent:u,pixelBlock:null};const g=a>0?p.pyramidBlockWidth:p.blockWidth,x=a>0?p.pyramidBlockHeight:p.blockHeight,w=g===f&&x===h&&m.x%g==0&&m.y%x==0,v=new G.Z({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/r,spatialReference:e.spatialReference}),b=!e.spatialReference.equals(this.rasterInfo.spatialReference),{datumTransformation:I}=n;if(!b&&w&&1===y.pixelBlocks.length&&g===t&&x===r&&c.x===v.x&&c.y===v.y)return{extent:e,srcExtent:u,pixelBlock:y.pixelBlocks[0]};const _=this.rasterJobHandler?await this.rasterJobHandler.getProjectionOffsetGrid({projectedExtent:e,srcBufferExtent:y.extent,pixelSize:v.toJSON(),datumTransformation:I,rasterTransform:d,hasWrapAround:i>0,isAdaptive:!1!==this.ioConfig.optimizeProjectionAccuracy},n):(0,$.Qp)({projectedExtent:e,srcBufferExtent:y.extent,pixelSize:v,datumTransformation:I,rasterTransform:d,hasWrapAround:i>0,isAdaptive:!1});let C;const R=!n.requestRawData,S={rows:_.spacing[0],cols:_.spacing[1]},k=(0,o.Wg)(this._getRasterTileAlignmentInfo(a,y.extent.xmin)),{pixelBlocks:T,mosaicSize:M,isPartiallyFilled:P}=y;if(this.rasterJobHandler)C=await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:T,srcMosaicSize:M,destDimension:R?{width:t,height:r}:null,coefs:R?_.coefficients:null,sampleSpacing:R?S:null,interpolation:n.interpolation,alignmentInfo:k,blockWidths:null},n);else{const e=(0,ne.us)(T,M,{alignmentInfo:k});C=R?(0,ne.Uk)(e,{width:t,height:r},_.coefficients,S,n.interpolation):e}return n.requestRawData?{srcExtent:u,pixelBlock:C,transformGrid:_,extent:e,isPartiallyFilled:P}:{srcExtent:u,extent:e,pixelBlock:C}}async _fetchRawTiles(e,t,r,n){const{origin:i,blockBoundary:s}=this.rasterInfo.storageInfo,{blockWidth:a,blockHeight:l}=this.getBlockWidthHeight(e);let{x:c,y:u}=t,{width:f,height:h,wrapCount:d}=r;const p=(0,o.Wg)(this._getRasterTileAlignmentInfo(e,0));n.buffer&&(c-=n.buffer.cols,u-=n.buffer.rows,f+=2*n.buffer.cols,h+=2*n.buffer.rows);const m=Math.floor(c/a),y=Math.floor(u/l),g=Math.floor((c+f-1)/a),x=Math.floor((u+h-1)/l),w=s[e];if(!w)return null;const{minRow:v,minCol:b,maxCol:I,maxRow:_}=w;if(0===d&&(x<v||g<b||y>_||m>I))return null;const C=new Array;let R=!1;const S=null==this.ioConfig.allowPartialFill?n.allowPartialFill:this.ioConfig.allowPartialFill;for(let t=y;t<=x;t++)for(let r=m;r<=g;r++){const i=0===d||null==p||r<p.worldColumnCountFromOrigin?r:r%p.worldColumnCountFromOrigin-p.originColumnOffset;if(t>=v&&i>=b&&_>=t&&I>=i){const r=this._fetchRawTile(e,t,i,n);S?C.push(new Promise((e=>{r.then((t=>e(t))).catch((()=>{R=!0,e(null)}))}))):C.push(r)}else C.push(null)}if(0===C.length)return null;const k=await Promise.all(C),T={height:(x-y+1)*l,width:(g-m+1)*a},{spatialReference:M}=this.rasterInfo,P=this.getPyramidPixelSize(e),{x:F,y:E}=P;return{extent:new O.Z({xmin:i.x+m*a*F,xmax:i.x+(g+1)*a*F,ymin:i.y-(x+1)*l*E,ymax:i.y-y*l*E,spatialReference:M}),pixelBlocks:k,mosaicSize:T,isPartiallyFilled:R}}_fetchRawTile(e,t,r,n){const i=this.rasterInfo.storageInfo.blockBoundary[e];if(!i)return Promise.resolve(null);const{minRow:s,minCol:a,maxCol:l,maxRow:u}=i;if(t<s||r<a||t>u||r>l)return Promise.resolve(null);const f=X(this.url,n.sliceId),h=`${e}/${t}/${r}`;let d=Q(f,n.registryId,h);if((0,o.Wi)(d)){const i=new AbortController;d=this.fetchRawTile(e,t,r,{...n,signal:i.signal}),ee(f,n.registryId,h,d,i),d.catch((()=>te(f,n.registryId,h)))}return n.signal&&(0,c.fu)(n,(()=>{K(f,n.registryId,h)})),d}_getIndexFromDimensions(e,t){const{extent:r,interval:n,unit:i,values:s}=t;if(null!=s&&s.length)return Array.isArray(s[0])?s.findIndex((t=>t[0]<=e&&t[1]>=e)):s.indexOf(e);if(e>r[1])return-1;const a=r[0];let o=-1;if("ISO8601"===i){var l;switch((null==(l=t.intervalUnit)?void 0:l.toLowerCase())||"seconds"){case"seconds":o=Math.round((e-a)/1e3/n);break;case"minutes":o=Math.round((e-a)/6e4/n);break;case"hours":o=Math.round((e-a)/36e5/n);break;case"days":o=Math.round((e-a)/864e5/n);break;case"years":o=Math.round((new Date(e).getUTCFullYear()-new Date(a).getUTCFullYear())/n);break;case"decades":o=Math.round((new Date(e).getUTCFullYear()-new Date(a).getUTCFullYear())/10/n)}return o}return Math.round((e-a)/n)}_getDimensionValuesCount(e){const{extent:t,interval:r,unit:n,values:i}=e;let s=(null==i?void 0:i.length)||0;if(s)return s;const a=t[0];if(0===s&&"ISO8601"===n){var o;switch((null==(o=e.intervalUnit)?void 0:o.toLowerCase())||"seconds"){case"seconds":s=Math.round((t[1]-t[0])/1e3/r);break;case"minutes":s=Math.round((t[1]-t[0])/6e4/r);break;case"hours":s=Math.round((t[1]-t[0])/36e5/r);break;case"days":s=Math.round((t[1]-t[0])/864e5/r);break;case"years":s=Math.round((new Date(t[1]).getUTCFullYear()-new Date(a).getUTCFullYear())/r);break;case"decades":s=Math.round((new Date(t[1]).getUTCFullYear()-new Date(a).getUTCFullYear())/10/r)}return s}return Math.round((t[1]-t[0])/r)}_getRasterTileAlignmentInfo(e,t){return null==this._rasterTileAlighmentInfo&&(this._rasterTileAlighmentInfo=(0,$.P_)(this.rasterInfo)),(0,o.pC)(this._rasterTileAlighmentInfo.pyramidsInfo)?{startX:t,halfWorldWidth:this._rasterTileAlighmentInfo.halfWorldWidth,hasGCSSShiftTransform:this._rasterTileAlighmentInfo.hasGCSSShiftTransform,...this._rasterTileAlighmentInfo.pyramidsInfo[e]}:null}_getSourceDataInfo(e,t,r,n={}){const i={datumTransformation:n.datumTransformation,pyramidLevel:0,pyramidResolution:null,srcExtent:null,srcHeight:0,srcResolution:null,srcWidth:0};n.srcResolution&&(i.srcResolution=n.srcResolution,this._updateSourceDataInfo(e,i));const s=this.rasterInfo.storageInfo.maximumPyramidLevel||0,{srcWidth:a,srcHeight:o,pyramidLevel:l}=i,c=a/t,u=o/r,f=l<s&&c*u>=16;if(f||l===s&&(c>8||u>8)||0===a||0===o){const a=new G.Z({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/r,spatialReference:e.spatialReference});let o=(0,$.VO)(a,this.rasterInfo.spatialReference,e,i.datumTransformation);const h=!o||n.srcResolution&&o.x+o.y<n.srcResolution.x+n.srcResolution.y;if(f&&n.srcResolution&&h){const e=Math.round(Math.log(Math.max(c,u))/Math.LN2)-1;if(s-l+3>=e){const t=2**e;o={x:n.srcResolution.x*t,y:n.srcResolution.y*t}}}o&&(i.srcResolution=o,this._updateSourceDataInfo(e,i))}return(i.srcWidth/t>8||i.srcHeight/r>8)&&(i.srcWidth=0,i.srcHeight=0),i}_updateSourceDataInfo(e,t){t.srcWidth=0,t.srcHeight=0;const r=this.rasterInfo.spatialReference,{srcResolution:n,datumTransformation:i}=t,{pyramidLevel:s,pyramidResolution:a,excessiveReading:l}=(0,$.kr)(n,this.rasterInfo,this.ioConfig.sampling);if(l)return;let c=t.srcExtent||(0,$.tB)(e,r,i);if(null==c)return;const u=(0,o.Wg)(this.rasterInfo.transform);u&&(c=u.inverseTransform(c)),t.srcExtent=c;const f=Math.ceil((c.xmax-c.xmin)/a.x-.1),h=Math.ceil((c.ymax-c.ymin)/a.y-.1);t.pyramidLevel=s,t.pyramidResolution=a,t.srcWidth=f,t.srcHeight=h}_getRequestOptionsWithSliceId(e){return(0,o.pC)(this.rasterInfo.multidimensionalInfo)&&null==e.sliceId&&(e={...e,sliceId:this.getSliceIndex(e.multidimensionalDefinition)}),e}};(0,n._)([(0,u.Cb)()],ie.prototype,"_rasterTileAlighmentInfo",void 0),(0,n._)([(0,u.Cb)(_.HQ)],ie.prototype,"url",null),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],ie.prototype,"datasetName",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],ie.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"rasterInfo",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"ioConfig",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"sourceJSON",void 0),ie=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.BaseRaster")],ie);const se=ie;var ae=r(20095);function oe(e){const t=e.fields,r=e.records,n=t.some((e=>"oid"===e.name.toLowerCase()))?"OBJECTID":"OID",i=[{name:n,type:"esriFieldTypeOID",alias:"OID"}].concat(t.map((e=>({name:e.name,type:"esriFieldType"+e.typeName,alias:e.name})))),s=i.map((e=>e.name)),a=[];let o=0,l=0;return r.forEach((e=>{const t={};for(t[n]=o++,l=1;l<s.length;l++)t[s[l]]=e[l-1];a.push({attributes:t})})),{displayFieldName:"",fields:i,features:a}}var le=r(87521),ce=r(74889);const ue=new Map;ue.set("int16","esriFieldTypeSmallInteger"),ue.set("int32","esriFieldTypeInteger"),ue.set("int64","esriFieldTypeInteger"),ue.set("float32","esriFieldTypeSingle"),ue.set("float64","esriFieldTypeDouble"),ue.set("text","esriFieldTypeString");let fe=class extends se{constructor(){super(...arguments),this.storageInfo=null,this.datasetFormat="CRF"}async open(e){await this.init();const{data:t}=await this.request(this.url+"/conf.json",{signal:null==e?void 0:e.signal});if(!this._validateHeader(t))throw new a.Z("cloudraster:open","Invalid or unsupported conf.json.");this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const{storageInfo:r,rasterInfo:n}=this._parseHeader(t);if("thematic"===n.dataType){const e=await this._fetchAuxiliaryInformation();n.attributeTable=e}this._set("storageInfo",r),this._set("rasterInfo",n),this.ioConfig.retryCount=this.ioConfig.retryCount||0}async fetchRawTile(e,t,r,n={}){const i=this.rasterInfo.storageInfo.maximumPyramidLevel-e;if(i<0)return null;const s=this._buildCacheFilePath(i,t,r,n.multidimensionalDefinition),a=this._getIndexRecordFromBundle(t,r),o=await this.request(s,{range:{from:0,to:this.storageInfo.headerSize-1},responseType:"array-buffer",signal:n.signal});if(!o)return null;const l=new Uint8Array(o.data),c=this._getTileEndAndContentType(l,a);if(0===c.recordSize)return null;const u=await this.request(s,{range:{from:c.position,to:c.position+c.recordSize},responseType:"array-buffer",signal:n.signal});return u?this.decodePixelBlock(u.data,{width:this.rasterInfo.storageInfo.tileInfo.size[0],height:this.rasterInfo.storageInfo.tileInfo.size[1],planes:null,pixelType:null}):null}_validateHeader(e){return e&&"RasterInfo"===e.type&&!["origin","extent","geodataXform","LODInfos","blockWidth","blockHeight","bandCount","pixelType","pixelSizeX","pixelSizeY","format","packetSize"].some((t=>!e[t]))}_parseHeader(e){var t,r;const n=["u1","u2","u4","u8","s8","u16","s16","u32","s32","f32","f64"][e.pixelType],{bandCount:i,histograms:s,colormap:a,blockWidth:o,blockHeight:l,firstPyramidLevel:c,maximumPyramidLevel:u}=e,f=e.statistics&&e.statistics.map((e=>({min:e.min,max:e.max,avg:e.mean,stddev:e.standardDeviation,median:e.median,mode:e.mode}))),h=e.extent.spatialReference,d=null==(t=e.geodataXform)?void 0:t.spatialReference,p=new F.Z(null!=h&&h.wkid||null!=h&&h.wkt?h:d);let m=new O.Z({xmin:e.extent.xmin,ymin:e.extent.ymin,xmax:e.extent.xmax,ymax:e.extent.ymax,spatialReference:p});const y=new G.Z({x:e.pixelSizeX,y:e.pixelSizeY,spatialReference:p}),g=Math.round((m.xmax-m.xmin)/y.x),x=Math.round((m.ymax-m.ymin)/y.y),w=this._parseTransform(e.geodataXform),v=w?m:null;w&&(m=w.forwardTransform(m),y.x=(m.xmax-m.xmin)/g,y.y=(m.ymax-m.ymin)/x);const b=null!=(r=e.properties)?r:{},I=e.format.toLowerCase().replace("cache/",""),_=new G.Z(e.origin.x,e.origin.y,p);let C,R,k,T;if(a&&a.colors)for(C=[],R=0;R<a.colors.length;R++)k=a.colors[R],T=a.values?a.values[R]:R,C.push([T,255&k,k<<16>>>24,k<<8>>>24,k>>>24]);const M=e.LODInfos,P=[];for(R=0;R<M.levels.length;R++)P.push({level:M.levels[R],resolution:M.resolutions[R],scale:96/.0254*M.resolutions[R]});const E=new S.Z({dpi:96,lods:P,format:I,origin:_,size:[o,l],spatialReference:p}),N={recordSize:8,packetSize:e.packetSize,headerSize:e.packetSize*e.packetSize*8+64},Z=[{maxCol:Math.ceil(g/o)-1,maxRow:Math.ceil(x/l)-1,minCol:0,minRow:0}];let B=2;if(u>0)for(R=0;R<u;R++)Z.push({maxCol:Math.ceil(g/B/o)-1,maxRow:Math.ceil(x/B/l)-1,minCol:0,minRow:0}),B*=2;const D=e.mdInfo;return{storageInfo:N,rasterInfo:new W.Z({width:g,height:x,pixelType:n,bandCount:i,extent:m,nativeExtent:v,transform:w,spatialReference:p,pixelSize:y,keyProperties:b,statistics:f,histograms:s,multidimensionalInfo:D,colormap:C,storageInfo:new j.Z({blockWidth:o,blockHeight:l,pyramidBlockWidth:o,pyramidBlockHeight:l,origin:_,tileInfo:E,firstPyramidLevel:c,maximumPyramidLevel:u,blockBoundary:Z})})}}_parseTransform(e){var t,r;if(!(0,le.j)(e))throw new a.Z("cloudraster:open","the data contains unsupported geodata transform types");const n=(0,le.c)(e);if("identity"===n.type)return null;if("polynomial"!==n.type||null==(t=n.forwardCoefficients)||!t.length||null==(r=n.inverseCoefficients)||!r.length)throw new a.Z("cloudraster:open","the data contains unsupported geodata transforms - both forward and inverse coefficients are required currently");return n}async _fetchAuxiliaryInformation(e){const t=this.request(this.url+"/conf.vat.json",{signal:e}).then((e=>e.data)).catch((()=>null)),r=this.request(this.url+"/conf.vat.dbf",{responseType:"array-buffer",signal:e}).then((e=>e.data)).catch((()=>null)),n=await Promise.all([t,r]);let i;if(n[0]){let e=n[0].fields;const t=n[0].values;if(e&&t){e=e.map((e=>({type:"OID"===e.name?"esriFieldTypeOID":ue.get(e.type),name:e.name,alias:e.alias||e.name})));const r=t.map((e=>({attributes:e})));e&&t&&(i={fields:e,features:r})}}return!i&&n[1]&&(i=class{static get supportedVersions(){return[5]}static parse(e){const t=new DataView(e),r=3&t.getUint8(0);if(3!==r)return{header:{version:r},recordSet:null};const n=t.getUint32(4,!0),i=t.getUint16(8,!0),s=t.getUint16(10,!0),a={version:r,recordCount:n,headerByteCount:i,recordByteCount:s};let o=32;const l=[],c=[];let u;if(3===r){for(;13!==t.getUint8(o);)u=String.fromCharCode(t.getUint8(o+11)).trim(),l.push({name:(0,ae.f)(new Uint8Array(e,o,11)),type:u,typeName:["String","Date","Double","Boolean","String","Integer"][["C","D","F","L","M","N"].indexOf(u)],length:t.getUint8(o+16)}),o+=32;if(o+=1,l.length>0)for(;c.length<n&&e.byteLength-o>s;){const r=[];32===t.getUint8(o)?(o+=1,l.forEach((t=>{if("C"===t.type)r.push((0,ae.f)(new Uint8Array(e,o,t.length)).trim());else if("N"===t.type)r.push(parseInt(String.fromCharCode.apply(null,new Uint8Array(e,o,t.length)).trim(),10));else if("F"===t.type)r.push(parseFloat(String.fromCharCode.apply(null,new Uint8Array(e,o,t.length)).trim()));else if("D"===t.type){const n=String.fromCharCode.apply(null,new Uint8Array(e,o,t.length)).trim();r.push(new Date(parseInt(n.substring(0,4),10),parseInt(n.substring(4,6),10)-1,parseInt(n.substring(6,8),10)))}o+=t.length})),c.push(r)):o+=s}}return{header:a,fields:l,records:c,recordSet:oe({fields:l,records:c})}}}.parse(n[1]).recordSet),ce.default.fromJSON(i)}_buildCacheFilePath(e,t,r,n){const i=this.storageInfo.packetSize,s=Math.floor(t/i)*i,a=Math.floor(r/i)*i,l="R"+this._toHexString4(s)+"C"+this._toHexString4(a);let c="L";c+=e>=10?e.toString():"0"+e.toString();const{multidimensionalInfo:u}=this.rasterInfo,f=null==n?void 0:n[0];if(!(0,o.pC)(u)||!f)return`${this.url}/_alllayers/${c}/${l}.bundle`;let h=u.variables.filter((e=>e.name===f.variableName))[0].dimensions[0].values.indexOf(f.values[0]).toString(16);const d=4-h.length;for(let e=0;e<d;e++)h="0"+h;return h="S"+h,`${this.url}/_alllayers/${f.variableName}/${h}/${c}/${l}.bundle`}_getIndexRecordFromBundle(e,t){const r=this.storageInfo.packetSize,n=r*(e%r)+t%r;if(n<0)throw"Invalid level / row / col";return 20+n*this.storageInfo.recordSize+44}_getTileEndAndContentType(e,t){const r=e.subarray(t,t+8);let n,i=0;for(n=0;n<5;n++)i|=(255&r[n])<<8*n;const s=0xffffffffff&i;for(i=0,n=5;n<8;n++)i|=(255&r[n])<<8*(n-5);return{position:s,recordSize:0xffffffffff&i}}_toHexString4(e){let t=e.toString(16);if(4!==t.length){let e=4-t.length;for(;e-- >0;)t="0"+t}return t}};(0,n._)([(0,u.Cb)({readOnly:!0})],fe.prototype,"storageInfo",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],fe.prototype,"datasetFormat",void 0),fe=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.CloudRaster")],fe);const he=fe;let de=class extends se{constructor(){super(...arguments),this.datasetFormat="MEMORY"}async open(e){var t;await this.init();const{pixelBlock:r,statistics:n,histograms:i,name:s,keyProperties:a,nativeExtent:o,transform:l}=this.data,{width:c,height:u,pixelType:f}=r,h=this.data.extent||new O.Z({xmin:-.5,ymin:.5,xmax:c-.5,ymax:u-.5,spatialReference:new F.Z({wkid:3857})}),d=null!=(t=this.data.isPseudoSpatialReference)?t:!this.data.extent,p={x:h.width/c,y:h.height/u},m=new W.Z({width:c,height:u,pixelType:f,extent:h,nativeExtent:o,transform:l,pixelSize:p,spatialReference:h.spatialReference,bandCount:3,keyProperties:a||{},statistics:n,isPseudoSpatialReference:d,histograms:i});this.createRemoteDatasetStorageInfo(m,512,512),this._set("rasterInfo",m),this.updateTileInfo(),await this._buildInMemoryRaster(r,{width:512,height:512},e),this.datasetName=s,this.url="/InMemory/"+s}fetchRawTile(e,t,r,n={}){const i=this._pixelBlockTiles.get(`${e}/${t}/${r}`);return Promise.resolve(i)}async _buildInMemoryRaster(e,t,r){const n=this.rasterInfo.storageInfo.maximumPyramidLevel,i=this.rasterJobHandler?this.rasterJobHandler.split({pixelBlock:e,tileSize:t,maximumPyramidLevel:n},r):Promise.resolve((0,ne.Vl)(e,t,n)),s=(0,o.pC)(this.rasterInfo.statistics),l=(0,o.pC)(this.rasterInfo.histograms),u=s&&l?Promise.resolve({statistics:null,histograms:null}):this.rasterJobHandler?this.rasterJobHandler.estimateStatisticsHistograms({pixelBlock:e},r):Promise.resolve((0,ne.Hv)(e)),f=await(0,c.as)([i,u]);if(!f[0].value&&f[1].value)throw new a.Z("inmemory-raster:open","failed to build in memory raster");var h,d;this._pixelBlockTiles=f[0].value,s||(this.rasterInfo.statistics=null==(h=f[1].value)?void 0:h.statistics),l&&(this.rasterInfo.histograms=null==(d=f[1].value)?void 0:d.histograms)}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],de.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],de.prototype,"data",void 0),de=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.InMemoryRaster")],de);const pe=de;function me(e,t){if(!e||!t)return[];let r=t;t.indexOf("/")>-1?(r=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const n=[];if(t){const i=me(e,r);for(let e=0;e<i.length;e++)me(i[e],t).forEach((e=>n.push(e)));return n}const i=e.getElementsByTagNameNS("*",r);if(!i||0===i.length)return[];for(let e=0;e<i.length;e++)n.push(i[e]||i.item[e]);return n}function ye(e,t){if(!e||!t)return null;let r=t;t.indexOf("/")>-1?(r=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const n=me(e,r);return n.length>0?t?ye(n[0],t):n[0]:null}function ge(e,t=null){const r=t?ye(e,t):e;let n;return r?(n=r.textContent||r.nodeValue,n?n.trim():null):null}function xe(e,t){return function(e,t){const r=me(e,t),n=[];let i;for(let e=0;e<r.length;e++)i=r[e].textContent||r[e].nodeValue,i&&(i=i.trim(),""!==i&&n.push(i));return n}(e,t).map((e=>Number(e)))}function we(e,t){const r=ge(e,t);return Number(r)}function ve(e,t){var r;const n=null==e||null==(r=e.nodeName)?void 0:r.toLowerCase(),i=t.toLowerCase();return n.slice(n.lastIndexOf(":")+1)===i}var be=r(87390);function Ie(e,t){if(!e||!t)return null;const r=[];for(let n=0;n<e.length;n++)r.push(e[n]),r.push(t[n]);return r}function _e(e){if(!e)return null;let t=Number(e);if(!isNaN(t)&&0!==t)return new F.Z({wkid:t});if((e=String(e)).startsWith("COMPD_CS")){if(!e.includes("VERTCS")||!e.includes("GEOGCS")&&!e.startsWith("PROJCS"))return null;const r=e.indexOf("VERTCS"),n=e.indexOf("PROJCS"),i=n>-1?n:e.indexOf("GEOGCS");if(-1===i)return null;const s=e.slice(i,e.lastIndexOf("]",r)+1).trim(),a=e.slice(r,e.lastIndexOf("]")).trim();t=Ce(s);const o=new F.Z(t?{wkid:t}:{wkt:s}),l=Ce(a);return l&&(o.vcsWkid=l),o}return e.startsWith("GEOGCS")||e.startsWith("PROJCS")?(t=Ce(e),new F.Z(0!==t?{wkid:t}:{wkt:e})):null}function Ce(e){var t;const r=e.replace(/\]/g,"[").replace(/\"/g,"").split("[").map((e=>e.trim())).filter((e=>""!==e)),n=r[r.length-1].split(","),i=null==(t=n[0])?void 0:t.toLowerCase();if(("epsg"===i||"esri"===i)&&e.endsWith('"]]')){const e=Number(n[1]);if(!isNaN(e)&&0!==e)return e}return 0}function Re(e){var t;if("pamdataset"!==(null==e||null==(t=e.documentElement.tagName)?void 0:t.toLowerCase()))return{};const r={spatialReference:null,transform:null,metadata:{},rasterBands:[],statistics:null,histograms:null};e.documentElement.childNodes.forEach((e=>{if(1===e.nodeType)if(ve(e,"SRS")){if(!r.spatialReference){const t=ge(e);r.spatialReference=_e(t)}}else if(ve(e,"Metadata"))if("xml:ESRI"===e.getAttribute("domain")){const{spatialReference:t,transform:n}=function(e){var t;const r=ye(e,"GeodataXform"),n=_e(we(r,"SpatialReference/WKID")||ge(r,"SpatialReference/WKT"));if("typens:PolynomialXform"!==r.getAttribute("xsi:type"))return{spatialReference:n,transform:null};const i=null!=(t=we(r,"PolynomialOrder"))?t:1,s=xe(r,"CoeffX/Double"),a=xe(r,"CoeffY/Double"),o=xe(r,"InverseCoeffX/Double"),l=xe(r,"InverseCoeffY/Double"),c=Ie(s,a),u=Ie(o,l);return{spatialReference:n,transform:new be.Z({spatialReference:n,polynomialOrder:i,forwardCoefficients:c,inverseCoefficients:u})}}(e);r.transform=n,r.spatialReference||(r.spatialReference=t)}else me(e,"MDI").forEach((e=>r.metadata[e.getAttribute("key")]=ge(e)));else if(ve(e,"PAMRasterBand")){const t=function(e){var t;const r=we(e,"NoDataValue"),n=ye(e,"Histograms/HistItem"),i=we(n,"HistMin"),s=we(n,"HistMax"),a=we(n,"BucketCount"),o=null==(t=ge(n,"HistCounts"))?void 0:t.split("|").map((e=>Number(e)));let l,c,u,f;me(e,"Metadata/MDI").forEach((e=>{var t;const r=Number(null!=(t=e.textContent)?t:e.nodeValue);switch(e.getAttribute("key").toUpperCase()){case"STATISTICS_MINIMUM":l=r;break;case"STATISTICS_MAXIMUM":c=r;break;case"STATISTICS_MEAN":u=r;break;case"STATISTICS_STDDEV":f=r}}));const h=we(e,"Metadata/SourceBandIndex");return{noDataValue:r,histogram:null!=o&&o.length&&null!=l&&null!=c?{min:i,max:s,size:a||o.length,counts:o}:null,sourceBandIndex:h,statistics:null!=l&&null!=c?{min:l,max:c,avg:u,stddev:f}:null}}(e);null!=t.sourceBandIndex&&null==r.rasterBands[t.sourceBandIndex]?r.rasterBands[t.sourceBandIndex]=t:r.rasterBands.push(t)}}));const n=r.rasterBands;if(n){const e=!!n[0].statistics;r.statistics=e?n.map((e=>e.statistics)):null;const t=!!n[0].histogram;r.histograms=t?n.map((e=>e.histogram)):null}return r}let Se=class extends se{async open(e){await this.init();const t=await this._fetchData(e);let{spatialReference:r,statistics:n,histograms:i,transform:s}=await this._fetchAuxiliaryData(e);const a=!r;a&&(r=new F.Z({wkid:3857})),null!=i&&i.length&&null==n&&(n=(0,ne.Oh)(i));const{width:o,height:l}=t;let c=new O.Z({xmin:-.5,ymin:.5-l,xmax:o-.5,ymax:.5,spatialReference:r});const u=s?s.forwardTransform(c):c;let f=!0;if(s){const e=s.forwardCoefficients;f=e&&0===e[1]&&0===e[2],f&&(s=null,c=u)}const h=new pe({data:{extent:u,nativeExtent:c,transform:s,pixelBlock:t,statistics:n,histograms:i,keyProperties:{DateType:"Processed"},isPseudoSpatialReference:a}});await h.open(),this._set("rasterInfo",h.rasterInfo),this._inMemoryRaster=h}fetchRawTile(e,t,r,n={}){return this._inMemoryRaster.fetchRawTile(e,t,r,n)}async _fetchData(e){const{data:t}=await this.request(this.url,{responseType:"array-buffer",signal:null==e?void 0:e.signal}),r=(0,re.y)(t).toUpperCase();if("JPG"!==r&&"PNG"!==r&&"GIF"!==r&&"BMP"!==r)throw new a.Z("image-aux-raster:open","the data is not a supported format");return this._set("datasetFormat",r),await this.decodePixelBlock(t,{format:"jpg",width:1,height:1,useCanvas:!0})}async _fetchAuxiliaryData(e){var t,r;const n=(0,o.Wg)(null==e?void 0:e.signal),i=null!=(t=this.ioConfig.skipExtensions)?t:[],s=i.indexOf("aux.xml")>-1?null:this.request(this.url+".aux.xml",{responseType:"xml",signal:n}),a=this.datasetFormat,l="JPG"===a?"jgw":"PNG"===a?"pgw":"BMP"===a?"bpw":null,u=i.indexOf(l)>-1?null:this.request(this.url.slice(0,this.url.lastIndexOf("."))+"."+l,{responseType:"text",signal:n}),f=await(0,c.as)([s,u]);if(null!=n&&n.aborted)throw(0,c.zE)();const h=Re(null==(r=f[0].value)?void 0:r.data);if(!h.transform){const e=f[1].value?f[1].value.data.split("\n").slice(0,6).map((e=>Number(e))):null;h.transform=6===(null==e?void 0:e.length)?new be.Z({forwardCoefficients:[e[4],e[5],e[0],-e[1],e[2],-e[3]]}):null}return h}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],Se.prototype,"datasetFormat",void 0),Se=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.ImageAuxRaster")],Se);const ke=Se;var Te=r(17452),Me=r(45322),Pe=r(56608),Oe=r(29680);let Fe=class extends se{constructor(){super(...arguments),this._levelOffset=0,this._slices=null,this._tilemapCache=null,this.datasetFormat="RasterTileServer"}async open(e){await this.init();const t=e&&e.signal,r=this.sourceJSON?{data:this.sourceJSON}:await this.request(this.url,{query:{f:"json"},signal:t});r.ssl&&(this.url=this.url.replace(/^http:/i,"https:"));const n=r.data;if(this.sourceJSON=n,!n)throw new a.Z("imageserverraster:open","cannot initialize tiled image service, missing service info");if(!n.tileInfo)throw new a.Z("imageserverraster:open","use ImageryLayer to open non-tiled image services");this._fixScaleInServiceInfo(),this.tileType=n.cacheType,null==this.tileType&&(["jpg","jpeg","png","png8","png24","png32","mixed"].indexOf(n.tileInfo.format.toLowerCase())>-1?this.tileType="Map":"lerc"===n.tileInfo.format.toLowerCase()?this.tileType="Elevation":this.tileType="Raster"),this.datasetName=n.name.slice(n.name.indexOf("/")+1);const i=await this._fetchRasterInfo({signal:t});if(!(0,o.pC)(i))throw new a.Z("image-server-raster:open","cannot initialize image service");{const e="Map"===this.tileType?(0,Me.d)(n.tileInfo,n):S.Z.fromJSON(n.tileInfo),{extent:t,pixelSize:r}=i,s=.5/i.width*r.x;let a,o;const l=e.lodAt(Math.max.apply(null,e.lods.map((e=>e.level))));"Map"!==this.tileType&&0!==n.maxScale&&("Raster"===this.tileType?(a=e.lods.filter((e=>e.resolution===r.x))[0],a||(a=e.lods[e.lods.length-1])):(a=e.lods.filter((e=>Math.abs(e.scale-n.maxScale)<s))[0],a||(a=e.lods.filter((e=>e.scale>n.maxScale)).sort(((e,t)=>e.scale>t.scale?1:-1))[0])),r.x=r.y=a.resolution,i.width=Math.ceil((t.xmax-t.xmin)/r.x-.1),i.height=Math.ceil((t.ymax-t.ymin)/r.y-.1)),a||(a=l);const c=e.lodAt(Math.min.apply(null,e.lods.map((e=>e.level))));"Map"===this.tileType?this._levelOffset=e.lods[0].level:0!==n.minScale&&"Elevation"===this.tileType&&(o=e.lods.filter((e=>Math.abs(e.scale-n.minScale)<s))[0],this._levelOffset=o.level-c.level),o||(o=c);const u=Math.max(r.x,r.y);(Math.abs(r.x-r.y)>s||!e.lods.some((e=>Math.abs(e.resolution-u)<s)))&&(r.x=r.y=a.resolution,i.width=Math.ceil((t.xmax-t.xmin)/r.x-.1),i.height=Math.ceil((t.ymax-t.ymin)/r.y-.1));const f=a.level-o.level,[h,d]=e.size,p=[];e.lods.forEach((e=>{e.level>=o.level&&e.level<=a.level&&p.push({x:e.resolution,y:e.resolution})})),p.sort(((e,t)=>e.x-t.x));const m=this.computeBlockBoundary(t,h,d,e.origin,p,f),y=p.length>1?p.slice(1):null;i.storageInfo=new j.Z({blockWidth:e.size[0],blockHeight:e.size[1],pyramidBlockWidth:e.size[0],pyramidBlockHeight:e.size[1],pyramidResolutions:y,compression:e.format,origin:e.origin,firstPyramidLevel:1,maximumPyramidLevel:f,tileInfo:e,blockBoundary:m}),this._fixGCSShift(i),this._set("rasterInfo",i)}if(n.capabilities.toLowerCase().indexOf("tilemap")>-1){const e={tileInfo:i.storageInfo.tileInfo,parsedUrl:(0,Te.mN)(this.url),url:this.url,tileServers:[],type:"tile"};this._tilemapCache=new Pe.y({layer:e})}}async fetchRawTile(e,t,r,n={}){if(this._slices&&null==n.sliceId)return null;const{storageInfo:i,extent:s}=this.rasterInfo,a=i.maximumPyramidLevel-e+this._levelOffset,o=`${this.url}/tile/${a}/${t}/${r}`,l=this._slices?{sliceId:n.sliceId||0}:null,{data:c}=await this.request(o,{query:l,responseType:"array-buffer",signal:n.signal});if(!c)return null;const u=await this.decodePixelBlock(c,{width:i.tileInfo.size[0],height:i.tileInfo.size[1],planes:null,pixelType:null,isPoint:"Elevation"===this.tileType}),f=i.blockBoundary[e];if("jpg"!==i.compression||r>f.minCol&&r<f.maxCol&&t>f.minRow&&t<f.maxRow)return u;const{origin:h,blockWidth:d,blockHeight:p}=i,{x:m,y}=this.getPyramidPixelSize(e),g=Math.round((s.xmin-h.x)/m)%d,x=Math.round((s.xmax-h.x)/m)%d,w=Math.round((h.y-s.ymax)/y)%p,v=Math.round((h.y-s.ymin)/y)%p,b=r===f.minCol?g:0,I=t===f.minRow?w:0,_=r===f.maxCol?x:d,C=t===f.maxRow?v:p;return(0,ne.pW)(u,{x:b,y:I},{width:_-b,height:C-I}),u}getSliceIndex(e){if(!this._slices||(0,o.Wi)(e)||0===e.length)return null;const t=e;for(let e=0;e<this._slices.length;e++){const r=this._slices[e].multidimensionalDefinition;if(r.length===t.length&&!r.some((e=>{const r=t.filter((t=>e.variableName===t.variableName&&t.dimensionName===e.dimensionName))[0];return!r||(Array.isArray(e.values[0])?`${e.values[0][0]}-${e.values[0][1]}`:e.values[0])!==(Array.isArray(r.values[0])?`${r.values[0][0]}-${r.values[0][1]}`:r.values[0])})))return e}return null}async fetchVariableStatisticsHistograms(e,t){const r=this.request(this.url+"/statistics",{query:{variable:e,f:"json"},signal:t}).then((e=>{var t;return null==(t=e.data)?void 0:t.statistics})),n=this.request(this.url+"/histograms",{query:{variable:e,f:"json"},signal:t}).then((e=>{var t;return null==(t=e.data)?void 0:t.histograms})),i=await Promise.all([r,n]);return i[0]&&i[0].forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:i[0]||null,histograms:i[1]||null}}async computeBestPyramidLevelForLocation(e,t={}){if(!this._tilemapCache)return 0;let r=this.identifyPixelLocation(e,0,(0,o.Wg)(t.datumTransformation));if(null===r)return null;let n=0;const{maximumPyramidLevel:i}=this.rasterInfo.storageInfo;let s=i-n+this._levelOffset;const a=r.srcLocation;for(;s>=0;){try{if("available"===await this._tilemapCache.fetchAvailability(s,r.row,r.col,t))break}catch{}if(s--,n++,r=this.identifyPixelLocation(a,n,(0,o.Wg)(t.datumTransformation)),null===r)return null}return-1===s||null==r?null:n}async _fetchRasterInfo(e){const t=this.sourceJSON,r=Math.ceil((t.extent.xmax-t.extent.xmin)/t.pixelSizeX-.1),n=Math.ceil((t.extent.ymax-t.extent.ymin)/t.pixelSizeY-.1),i=F.Z.fromJSON(t.spatialReference||t.extent.spatialReference);if("Map"===this.tileType)return new W.Z({width:r,height:n,bandCount:3,extent:O.Z.fromJSON(t.extent),spatialReference:i,pixelSize:new G.Z({x:t.pixelSizeX,y:t.pixelSizeY,spatialReference:i}),pixelType:"u8",statistics:null,keyProperties:{DataType:"processed"}});const{slice:s,signal:a}=e,o=!!t.hasRasterAttributeTable&&this.request(this.url+"/rasterAttributeTable",{query:{slice:s,f:"json"},signal:a}).then((e=>ce.default.fromJSON(e.data))).catch((()=>null)),l=!!t.hasColormap&&this.request(this.url+"/colormap",{query:{slice:s,f:"json"},signal:a}).then((e=>{var t;return null==(t=e.data)?void 0:t.colormap})),c=!!t.hasHistograms&&this.request(this.url+"/histograms",{query:{slice:s,f:"json"},signal:a}).then((e=>{var t;return null==(t=e.data)?void 0:t.histograms})),u=this.request(this.url+"/keyProperties",{query:{f:"json"},signal:a}).then((e=>e.data)).catch((()=>{})),f=!!t.hasMultidimensions&&this._fetchMultidimensionalInfo(),h=!!t.hasMultidimensions&&this.request(this.url+"/slices",{query:{f:"json"},signal:a}).then((e=>e.data&&e.data.slices)).catch((()=>{}));return Promise.all([o,l,c,u,f,h]).then((e=>{let s=null;if(t.minValues&&t.minValues.length===t.bandCount){s=[];for(let e=0;e<t.minValues.length;e++)s.push({min:t.minValues[e],max:t.maxValues[e],avg:t.meanValues[e],stddev:t.stdvValues[e]})}return this._slices=e[5]||null,new W.Z({width:r,height:n,bandCount:t.bandCount,extent:O.Z.fromJSON(t.extent),spatialReference:i,pixelSize:new G.Z({x:t.pixelSizeX,y:t.pixelSizeY,spatialReference:i}),pixelType:t.pixelType.toLowerCase(),statistics:s,attributeTable:e[0]||null,colormap:e[1]||null,histograms:e[2]||null,keyProperties:e[3]||{},multidimensionalInfo:e[4]||null})}))}async _fetchMultidimensionalInfo(e){var t;const r=await this.request(this.url+"/multidimensionalInfo",{query:{f:"json"},signal:e}).then((e=>{var t;return null==(t=e.data)?void 0:t.multidimensionalInfo}));return null!=(t=r.variables)&&t.length&&r.variables.forEach((e=>{var t;null!=(t=e.statistics)&&t.length&&e.statistics.forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation}))})),r}_fixScaleInServiceInfo(){const{sourceJSON:e}=this;e.minScale&&e.minScale<0&&(e.minScale=0),e.maxScale&&e.maxScale<0&&(e.maxScale=0)}_fixGCSShift(e){const{extent:t,spatialReference:r}=e;0===t.xmin&&360===t.xmax&&r.wkid&&r.isGeographic&&(e.nativeExtent=e.extent,e.transform=new Oe.Z,e.extent=e.transform.forwardTransform(t))}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],Fe.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],Fe.prototype,"tileType",void 0),Fe=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.ImageServerRaster")],Fe);const Ee=Fe;var Ne=r(54163),Ze=r(48279);const Be=new Map;Be.set("Int8","s8"),Be.set("UInt8","u8"),Be.set("Int16","s16"),Be.set("UInt16","u16"),Be.set("Int32","s32"),Be.set("UInt32","u32"),Be.set("Float32","f32"),Be.set("Float64","f32"),Be.set("Double64","f32");const De=new Map;De.set("none",{blobExtension:".til",isOneSegment:!0,decoderFormat:"bip"}),De.set("lerc",{blobExtension:".lrc",isOneSegment:!1,decoderFormat:"lerc"}),De.set("deflate",{blobExtension:".pzp",isOneSegment:!0,decoderFormat:"deflate"}),De.set("jpeg",{blobExtension:".pjg",isOneSegment:!0,decoderFormat:"jpg"});let ze=class extends se{constructor(){super(...arguments),this._files=null,this._storageIndex=null,this.datasetFormat="MRF"}async open(e){var t;await this.init(),this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const r=e?(0,o.Wg)(e.signal):null,n=await this.request(this.url,{responseType:"xml",signal:r}),{rasterInfo:i,files:s}=this._parseHeader(n.data);if(-1===(null==(t=this.ioConfig.skipExtensions)?void 0:t.indexOf("aux.xml"))){const t=await this._fetchAuxiliaryData(e);var a;null!=t&&(i.statistics=null!=(a=t.statistics)?a:i.statistics,i.histograms=t.histograms,t.histograms&&!(0,o.pC)(i.statistics)&&(i.statistics=(0,ne.Oh)(t.histograms)))}this._set("rasterInfo",i),this._files=s;const l=await this.request(s.index,{responseType:"array-buffer",signal:r});this._storageIndex=this._parseIndex(l.data);const{blockWidth:c,blockHeight:u}=this.rasterInfo.storageInfo,f=this.rasterInfo.storageInfo.pyramidScalingFactor,{width:h,height:d}=this.rasterInfo,p=[],m=this._getBandSegmentCount();let y=0,g=-1;for(;y<this._storageIndex.length;){g++;const e=Math.ceil(h/c/f**g)-1,t=Math.ceil(d/u/f**g)-1;y+=(e+1)*(t+1)*m*4,p.push({maxRow:t,maxCol:e,minCol:0,minRow:0})}this.rasterInfo.storageInfo.blockBoundary=p,g>0&&(this.rasterInfo.storageInfo.firstPyramidLevel=1,this.rasterInfo.storageInfo.maximumPyramidLevel=g),this.updateTileInfo()}async fetchRawTile(e,t,r,n={}){const{blockWidth:i,blockHeight:s,blockBoundary:a}=this.rasterInfo.storageInfo,l=a[e];if(!l||l.maxRow<t||l.maxCol<r||l.minRow>t||l.minCol>r)return null;const{bandCount:c,pixelType:u}=this.rasterInfo,{ranges:f,actualTileWidth:h,actualTileHeight:d}=this._getTileLocation(e,t,r);if(!f||0===f.length)return null;if(0===f[0].from&&0===f[0].to){const e=new Uint8Array(i*s);return new Ne.Z({width:i,height:s,pixels:null,mask:e,validPixelCount:0})}const{bandIds:p}=this.ioConfig,m=this._getBandSegmentCount(),y=[];let g=0;for(g=0;g<m;g++)(!p||p.indexOf[g]>-1)&&y.push(this.request(this._files.data,{range:{from:f[g].from,to:f[g].to},responseType:"array-buffer",signal:n.signal}));const x=await Promise.all(y),w=x.map((e=>e.data.byteLength)).reduce(((e,t)=>e+t)),v=new Uint8Array(w);let b=0;for(g=0;g<m;g++)v.set(new Uint8Array(x[g].data),b),b+=x[g].data.byteLength;const I=De.get(this.rasterInfo.storageInfo.compression).decoderFormat,_=await this.decodePixelBlock(v.buffer,{width:i,height:s,format:I,planes:(null==p?void 0:p.length)||c,pixelType:u});if((0,o.pC)(this.rasterInfo.noDataValue)&&"lerc"!==I&&!_.mask){const e=this.rasterInfo.noDataValue[0];if(null!=e){const t=_.width*_.height,r=new Uint8Array(t);if(Math.abs(e)>1e24)for(g=0;g<t;g++)Math.abs((_.pixels[0][g]-e)/e)>1e-6&&(r[g]=1);else for(g=0;g<t;g++)_.pixels[0][g]!==e&&(r[g]=1);_.mask=r}}let C=0,R=0;if(h!==i||d!==s){let e=_.mask;if(e)for(g=0;g<s;g++)if(R=g*i,g<d)for(C=h;C<i;C++)e[R+C]=0;else for(C=0;C<i;C++)e[R+C]=0;else for(e=new Uint8Array(i*s),_.mask=e,g=0;g<d;g++)for(R=g*i,C=0;C<h;C++)e[R+C]=1}return _}_parseIndex(e){if(e.byteLength%16>0)throw"invalid array buffer must be multiples of 16";let t,r,n,i,s,a;if(Ze.f){for(r=new Uint8Array(e),i=new ArrayBuffer(e.byteLength),n=new Uint8Array(i),s=0;s<e.byteLength/4;s++)for(a=0;a<4;a++)n[4*s+a]=r[4*s+3-a];t=new Uint32Array(i)}else t=new Uint32Array(e);return t}_getBandSegmentCount(){return De.get(this.rasterInfo.storageInfo.compression).isOneSegment?1:this.rasterInfo.bandCount}_getTileLocation(e,t,r){const{blockWidth:n,blockHeight:i,pyramidScalingFactor:s}=this.rasterInfo.storageInfo,{width:a,height:o}=this.rasterInfo,l=this._getBandSegmentCount();let c,u,f,h=0,d=0;for(f=0;f<e;f++)d=s**f,c=Math.ceil(a/n/d),u=Math.ceil(o/i/d),h+=c*u;d=s**e,c=Math.ceil(a/n/d),u=Math.ceil(o/i/d),h+=t*c+r,h*=4*l;const p=this._storageIndex.subarray(h,h+4*l);let m=0,y=0;const g=[];for(let e=0;e<l;e++)m=p[4*e+0]*2**32+p[4*e+1],y=m+p[4*e+2]*2**32+p[4*e+3],g.push({from:m,to:y});return{ranges:g,actualTileWidth:r<c-1?n:Math.ceil(a/d)-n*(c-1),actualTileHeight:t<u-1?i:Math.ceil(o/d)-i*(u-1)}}_parseHeader(e){const t=ye(e,"MRF_META/Raster");if(!t)throw new a.Z("mrf:open","not a valid MRF format");const r=ye(t,"Size"),n=parseInt(r.getAttribute("x"),10),i=parseInt(r.getAttribute("y"),10),s=parseInt(r.getAttribute("c"),10),o=(ge(t,"Compression")||"none").toLowerCase();if(!De.has(o))throw new a.Z("mrf:open","currently does not support compression "+o);const l=ge(t,"DataType")||"UInt8",c=Be.get(l);if(null==c)throw new a.Z("mrf:open","currently does not support pixel type "+l);const u=ye(t,"PageSize"),f=parseInt(u.getAttribute("x"),10),h=parseInt(u.getAttribute("y"),10),d=ye(t,"DataValues");let p,m;if(d&&(m=d.getAttribute("NoData"),null!=m&&(p=m.trim().split(" ").map((e=>parseFloat(e))))),ye(e,"MRF_META/CachedSource"))throw new a.Z("mrf:open","currently does not support MRF referencing other data files");const y=ye(e,"MRF_META/GeoTags"),g=ye(y,"BoundingBox");let x,w=!1;if(null!=g){const e=parseFloat(g.getAttribute("minx")),t=parseFloat(g.getAttribute("miny")),r=parseFloat(g.getAttribute("maxx")),n=parseFloat(g.getAttribute("maxy")),i=ge(y,"Projection")||"";let s;if("LOCAL_CS[]"!==i)if(i.toLowerCase().startsWith("epsg:")){const e=Number(i.slice(5));isNaN(e)||0===e||(s=new F.Z({wkid:e}))}else s=_e(i);else w=!0,s=new F.Z({wkid:3857});x=new O.Z(e,t,r,n),x.spatialReference=s}else w=!0,x=new O.Z({xmin:-.5,ymin:.5-i,xmax:n-.5,ymax:.5,spatialReference:new F.Z({wkid:3857})});const v=ye(e,"MRF_META/Rsets"),b=parseInt(v&&v.getAttribute("scale")||"2",10),I=x.spatialReference,_=new j.Z({origin:new G.Z({x:x.xmin,y:x.ymax,spatialReference:I}),blockWidth:f,blockHeight:h,pyramidBlockWidth:f,pyramidBlockHeight:h,compression:o,pyramidScalingFactor:b}),C=new G.Z({x:x.width/n,y:x.height/i,spatialReference:I}),R=new W.Z({width:n,height:i,extent:x,isPseudoSpatialReference:w,spatialReference:I,bandCount:s,pixelType:c,pixelSize:C,noDataValue:p,storageInfo:_}),S=ge(e,"datafile"),k=ge(e,"IndexFile");return{rasterInfo:R,files:{mrf:this.url,index:k||this.url.replace(".mrf",".idx"),data:S||this.url.replace(".mrf",De.get(o).blobExtension)}}}async _fetchAuxiliaryData(e){try{const{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:null==e?void 0:e.signal});return Re(t)}catch{return null}}};(0,n._)([(0,u.Cb)()],ze.prototype,"_files",void 0),(0,n._)([(0,u.Cb)()],ze.prototype,"_storageIndex",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],ze.prototype,"datasetFormat",void 0),ze=(0,n._)([(0,p.j)("esri.layers.support.rasterIO.MRFRaster")],ze);const Ae=ze;var He=r(94793),Le=r(9832);const Je=function(e,t){const r=e.get(t);return r&&r.values},We=function(e,t){const r=e.get(t);return r&&r.values[0]};let je=class extends se{constructor(){super(...arguments),this._files=null,this._headerInfo=null,this._bufferSize=1048576,this.datasetFormat="TIFF"}async open(e){var t,r,n;await this.init();const i=e?(0,o.Wg)(e.signal):null,{data:s}=await this.request(this.url,{range:{from:0,to:this._bufferSize},responseType:"array-buffer",signal:i});if(!s)throw new a.Z("tiffraster:open","failed to open url "+this.url);this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const{littleEndian:l,firstIFD:c,isBigTiff:u}=(0,He.cK)(s),f=[];await this._readIFDs(f,s,l,c,0,u?8:4,i);const h=(0,He.FI)(f),{width:d,height:p,tileWidth:m,tileHeight:y,planes:g,pixelType:x,compression:w,firstPyramidLevel:v,maximumPyramidLevel:b,pyramidBlockWidth:I,pyramidBlockHeight:_,tileBoundary:C,affine:R,metadata:S}=h;let k=_e((null==(t=h.extent.spatialReference)?void 0:t.wkt)||(null==(r=h.extent.spatialReference)?void 0:r.wkid)),T=!1;null==k&&(T=!0,k=new F.Z({wkid:3857}));const M=new O.Z({...h.extent,spatialReference:k}),P=new G.Z(M?{x:M.xmin,y:M.ymax,spatialReference:k}:{x:0,y:0}),E=new j.Z({blockWidth:m,blockHeight:y,pyramidBlockWidth:I,pyramidBlockHeight:_,compression:w,origin:P,firstPyramidLevel:v,maximumPyramidLevel:b,blockBoundary:C}),N=new G.Z({x:(M.xmax-M.xmin)/d,y:(M.ymax-M.ymin)/p,spatialReference:k}),Z=S?{BandProperties:S.bandProperties,DataType:S.dataType}:{},B=new W.Z({width:d,height:p,bandCount:g,pixelType:x,compression:w,pixelSize:N,storageInfo:E,spatialReference:k,isPseudoSpatialReference:T,keyProperties:Z,extent:M,statistics:S?S.statistics:null});if(null!=R&&R.length&&(B.nativeExtent=new O.Z({xmin:-.5,ymin:.5-p,xmax:d-.5,ymax:.5,spatialReference:k}),B.transform=new be.Z({polynomialOrder:1,forwardCoefficients:[R[2]+R[0]/2,R[5]-R[3]/2,R[0],R[3],-R[1],-R[4]]}),B.extent=B.transform.forwardTransform(B.nativeExtent),B.pixelSize=new G.Z({x:(M.xmax-M.xmin)/d,y:(M.ymax-M.ymin)/p,spatialReference:k}),E.origin.x=-.5,E.origin.y=.5),null==(n=this.ioConfig.skipExtensions)||!n.includes("aux.xml")){const t=await this._fetchAuxiliaryData(e);if(null!=t){var D;if(B.statistics=null!=(D=t.statistics)?D:B.statistics,B.histograms=t.histograms,t.histograms&&!(0,o.pC)(B.statistics)&&(B.statistics=(0,ne.Oh)(t.histograms)),t.transform&&!R){B.transform=t.transform,B.nativeExtent=B.extent;const e=B.transform.forwardTransform(B.nativeExtent);B.pixelSize=new G.Z({x:(e.xmax-e.xmin)/d,y:(e.ymax-e.ymin)/p,spatialReference:k}),B.extent=e}B.spatialReference||(B.spatialReference=t.spatialReference)}}if(this._set("rasterInfo",B),this._headerInfo={littleEndian:l,isBigTiff:u,ifds:f,...h},!this._headerInfo.isSupported)throw new a.Z("tiffraster:open","this tiff is not supported: "+this._headerInfo.message);this.updateTileInfo()}async fetchRawTile(e,t,r,n={}){var i;if(null==(i=this._headerInfo)||!i.isSupported||this.isBlockOutside(e,t,r))return null;const s=this._getTileLocation(e,t,r);if(!s)return null;const{ranges:a,actualTileWidth:o,actualTileHeight:l,ifd:c}=s,u=a.map((e=>this.request(this.url,{range:e,responseType:"array-buffer",signal:n.signal}))),f=await Promise.all(u),h=f.map((e=>e.data.byteLength)).reduce(((e,t)=>e+t)),d=1===f.length?f[0].data:new ArrayBuffer(h),p=[0],m=[0];if(f.length>1){const e=new Uint8Array(d);for(let t=0,r=0;t<f.length;t++){const n=f[t].data;e.set(new Uint8Array(n),r),p[t]=r,r+=n.byteLength,m[t]=n.byteLength}}const{blockWidth:y,blockHeight:g}=this.getBlockWidthHeight(e),x=await this.decodePixelBlock(d,{format:"tiff",customOptions:{headerInfo:this._headerInfo,ifd:c,offsets:p,sizes:m},width:y,height:g,planes:null,pixelType:null});let w,v,b;if(o!==y||l!==g){let e=x.mask;if(e)for(w=0;w<g;w++)if(b=w*y,w<l)for(v=o;v<y;v++)e[b+v]=0;else for(v=0;v<y;v++)e[b+v]=0;else for(e=new Uint8Array(y*g),x.mask=e,w=0;w<l;w++)for(b=w*y,v=0;v<o;v++)e[b+v]=1}return x}async _readIFDs(e,t,r,n,i,s=4,a){if(!n)return null;(n>=t.byteLength||n<0)&&(t=(await this.request(this.url,{range:{from:n+i,to:n+i+this._bufferSize},responseType:"array-buffer",signal:a})).data,i=n+i,n=0);const o=await this._readIFD(t,r,n,i,Le.Z.TIFF_TAGS,s,a);if(e.push(o.ifd),!o.nextIFD)return null;await this._readIFDs(e,t,r,o.nextIFD-i,i,s,a)}async _readIFD(e,t,r,n,i=Le.Z.TIFF_TAGS,s=4,a){if(!e)return null;const o=(0,He.vr)(e,t,r,n,i,s);if(o.success){const r=[];if(o.ifd.forEach((e=>{e.values||r.push(e)})),r.length>0){const i=r.map((e=>e.offlineOffsetSize)),s=Math.min.apply(null,i.map((e=>e[0])));if(Math.min.apply(null,i.map((e=>e[0]+e[1])))-s<=this._bufferSize){const{data:i}=await this.request(this.url,{range:{from:s,to:s+this._bufferSize},responseType:"array-buffer",signal:a});e=i,n=s,r.forEach((r=>(0,He.Dq)(e,t,r,n)))}}if(o.ifd.has("GEOKEYDIRECTORY")){const r=o.ifd.get("GEOKEYDIRECTORY"),i=r.values;if(i&&i.length>4){const s=i[0]+"."+i[1]+"."+i[2],o=await this._readIFD(e,t,r.valueOffset+6-n,n,Le.Z.GEO_KEYS,2,a);r.data=o.ifd,r.data&&r.data.set("GEOTIFFVersion",{id:0,type:2,valueCount:1,valueOffset:null,values:[s]})}}return o}if(o.requiredBufferSize&&o.requiredBufferSize!==e.byteLength){const r=await this.request(this.url,{range:{from:n,to:n+o.requiredBufferSize+4},responseType:"array-buffer",signal:a});return(e=r.data).byteLength<o.requiredBufferSize?null:this._readIFD(e,t,0,n,Le.Z.TIFF_TAGS,4,a)}}_getTileLocation(e,t,r){const{firstPyramidLevel:n,blockBoundary:i}=this.rasterInfo.storageInfo,s=0===e?0:e-(n-1),a=this._headerInfo.ifds[s];if(!a)return null;const o=(0,He.If)(a,this._headerInfo),l=Je(a,"TILEOFFSETS");if(void 0===l)return null;const c=Je(a,"TILEBYTECOUNTS"),{minRow:u,minCol:f,maxRow:h,maxCol:d}=i[s];if(t>h||r>d||t<u||r<f)return null;const p=We(a,"IMAGEWIDTH"),m=We(a,"IMAGELENGTH"),y=We(a,"TILEWIDTH"),g=We(a,"TILELENGTH"),x=o?this.rasterInfo.bandCount:1,w=x*t*(d+1)+r,v=[{from:l[w],to:l[w+x-1]+c[w+x-1]-1}];if(o){let e=!0;for(let t=0;t<x;t++)if(l[w+t]+c[w+t]!==l[w+t+1]){e=!1;break}if(!e)for(let e=0;e<x;e++)v[e]={from:l[w+e],to:l[w+e]+c[w+e]-1}}const b=l[w],I=c[w];return null==b||null==I?null:{ranges:v,ifd:a,actualTileWidth:r===d?p%y:y,actualTileHeight:t===h?m%g:g}}async _fetchAuxiliaryData(e){try{const{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:null==e?void 0:e.signal});return Re(t)}catch{return null}}};(0,n._)([(0,u.Cb)()],je.prototype,"_files",void 0),(0,n._)([(0,u.Cb)()],je.prototype,"_headerInfo",void 0),(0,n._)([(0,u.Cb)()],je.prototype,"_bufferSize",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],je.prototype,"datasetFormat",void 0),je=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.TIFFRaster")],je);const qe=je,Ue=new Map;Ue.set("CRF",{desc:"Cloud Raster Format",constructor:he}),Ue.set("MRF",{desc:"Meta Raster Format",constructor:Ae}),Ue.set("TIFF",{desc:"GeoTIFF",constructor:qe}),Ue.set("RasterTileServer",{desc:"Raster Tile Server",constructor:Ee}),Ue.set("JPG",{desc:"JPG Raster Format",constructor:ke}),Ue.set("PNG",{desc:"PNG Raster Format",constructor:ke}),Ue.set("GIF",{desc:"GIF Raster Format",constructor:ke}),Ue.set("BMP",{desc:"BMP Raster Format",constructor:ke});var $e=r(32163);let Ge=class extends((0,y.h)((0,z.M)((0,Z.q)((0,B.I)((0,g.N)(N((0,A.n)((0,D.Q)((0,l.R)(m.Z)))))))))){constructor(...e){super(...e),this.bandIds=null,this.interpolation=null,this.legendEnabled=!0,this.isReference=null,this.listMode="show",this.sourceJSON=null,this.version=null,this.title=null,this.type="imagery-tile",this.operationalLayerType="ArcGISTiledImageServiceLayer",this.popupEnabled=!0,this.popupTemplate=null,this.fields=null}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=(0,o.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"]},e).catch(c.r9).then((()=>this._openRaster(t)))),Promise.resolve(this)}get defaultPopupTemplate(){return this.createPopupTemplate()}get rasterFields(){var e,t;let r=[new H.Z({name:"Raster.ServicePixelValue",alias:"Pixel Value",domain:null,editable:!1,length:50,type:"string"})];const n=null==(e=this.rasterInfo)||null==(t=e.attributeTable)?void 0:t.fields;if(n){const e=n.filter((e=>"oid"!==e.type&&"value"!==e.name.toLowerCase())).map((e=>{const t=e.clone();return t.name="Raster."+e.name,t}));r=r.concat(e)}const i=this.rasterInfo.dataType;if(("vector-magdir"===i||"vector-uv"===i)&&(0,o.pC)(this.rasterInfo.multidimensionalInfo)){var s;const e=null==(s=this.rasterInfo.multidimensionalInfo.variables[0].unit)?void 0:s.trim(),t="Magnitude"+(e?` (${e})`:"");r.push(new H.Z({name:"Raster.Magnitude",alias:t,domain:null,editable:!1,type:"double"})),r.push(new H.Z({name:"Raster.Direction",alias:"Direction (°)",domain:null,editable:!1,type:"double"}))}return r}set renderer(e){this._set("renderer",e),this.updateRenderer()}readRenderer(e,t,r){const n=t&&t.layerDefinition&&t.layerDefinition.drawingInfo&&t.layerDefinition.drawingInfo.renderer,i=(0,s.ij)(n,r)||void 0;if(null!=i)return i}createPopupTemplate(e){return(0,$e.eZ)({fields:this.rasterFields,title:this.title},e)}write(e,t){const{raster:r}=this;if(this.loaded?"RasterTileServer"===r.datasetFormat&&("Raster"===r.tileType||"Map"===r.tileType):this.url&&/\/ImageServer(\/|\/?$)/i.test(this.url))return super.write(e,t);if(t&&t.messages){const e=`${t.origin}/${t.layerContainerType||"operational-layers"}`;t.messages.push(new a.Z("layer:unsupported",`Layers (${this.title}, ${this.id}) of type '${this.declaredClass}' are not supported in the context of '${e}'`,{layer:this}))}return null}async _openRaster(e){this.raster?(this.raster.rasterInfo||await this.raster.open(),this.url=this.raster.url):this.raster=await class{static get supportedFormats(){const e=new Set;return Ue.forEach(((t,r)=>e.add(r))),e}static async open(e){const{url:t,ioConfig:r,sourceJSON:n}=e;let i=e.datasetFormat;null==i&&t.lastIndexOf(".")&&(i=t.slice(t.lastIndexOf(".")+1).toUpperCase()),"OVR"===i||"TIF"===i?i="TIFF":"JPG"!==i&&"JPEG"!==i&&"JFIF"!==i||(i="JPG"),t.toLowerCase().indexOf("/imageserver")>-1&&-1===t.toLowerCase().indexOf("/wcsserver")&&(i="RasterTileServer");const s={url:t,sourceJSON:n,datasetFormat:i,ioConfig:r||{bandIds:null,sampling:null}};let o,l;if(this.supportedFormats.has(i))return o=Ue.get(i).constructor,l=new o(s),await l.open({signal:e.signal}),l;if(i)throw new a.Z("rasterfactory:open","not a supported format "+i);const c=Array.from(Ue.keys());let u=0;const f=function(){return i=c[u++],i?(o=Ue.get(i).constructor,l=new o(s),l.open({signal:e.signal}).then((()=>l)).catch((()=>f()))):null};return f()}static register(e,t,r){Ue.has(e.toUpperCase())||Ue.set(e.toUpperCase(),{desc:t,constructor:r})}}.open({url:this.url,sourceJSON:this.sourceJSON,ioConfig:{sampling:"closest",...this.ioConfig,customFetchParameters:this.customParameters},signal:e});const{rasterInfo:t}=this.raster;if(!t)throw new a.Z("imagery-tile-layer:load","cannot load resources on "+this.url);this.sourceJSON=this.sourceJSON||this.raster.sourceJSON,null!=this.sourceJSON&&(this._set("version",this.sourceJSON.currentVersion),this._set("copyright",this.sourceJSON.copyrightText),this.sourceJSON.timeInfo&&this._set("timeInfo",J.Z.fromJSON(this.sourceJSON.timeInfo))),null==this.title&&(this.title=this.raster.datasetName),"Map"===this.raster.tileType&&(this.popupEnabled=!1),this._configDefaultSettings(),this.watch("customParameters",(e=>this.raster.ioConfig.customFetchParameters=e))}};(0,n._)([(0,u.Cb)({type:[f.z8],json:{write:{overridePolicy(){var e;return{enabled:!this.loaded||"Raster"===this.raster.tileType||"0,1,2"!==(null==(e=this.bandIds)?void 0:e.join(","))}}}}})],Ge.prototype,"bandIds",void 0),(0,n._)([(0,u.Cb)({json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"bilinear"!==this.interpolation}}}}}),(0,h.J)(L.c)],Ge.prototype,"interpolation",void 0),(0,n._)([(0,u.Cb)({json:{write:!0}})],Ge.prototype,"multidimensionalDefinition",void 0),(0,n._)([(0,u.Cb)(_.rn)],Ge.prototype,"legendEnabled",void 0),(0,n._)([(0,u.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],Ge.prototype,"isReference",void 0),(0,n._)([(0,u.Cb)({type:["show","hide"]})],Ge.prototype,"listMode",void 0),(0,n._)([(0,u.Cb)()],Ge.prototype,"sourceJSON",void 0),(0,n._)([(0,u.Cb)({readOnly:!0})],Ge.prototype,"version",void 0),(0,n._)([(0,u.Cb)()],Ge.prototype,"title",void 0),(0,n._)([(0,u.Cb)({readOnly:!0,json:{read:!1}})],Ge.prototype,"type",void 0),(0,n._)([(0,u.Cb)({type:["ArcGISTiledImageServiceLayer"]})],Ge.prototype,"operationalLayerType",void 0),(0,n._)([(0,u.Cb)({type:Boolean,value:!0,json:{read:{source:"disablePopup",reader:(e,t)=>!t.disablePopup},write:{target:"disablePopup",overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType}},writer(e,t,r){t[r]=!e}}}})],Ge.prototype,"popupEnabled",void 0),(0,n._)([(0,u.Cb)({type:i.Z,json:{read:{source:"popupInfo"},write:{target:"popupInfo",overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType}}}}})],Ge.prototype,"popupTemplate",void 0),(0,n._)([(0,u.Cb)({readOnly:!0})],Ge.prototype,"defaultPopupTemplate",null),(0,n._)([(0,u.Cb)({readOnly:!0,type:[H.Z]})],Ge.prototype,"fields",void 0),(0,n._)([(0,u.Cb)({readOnly:!0,type:[H.Z]})],Ge.prototype,"rasterFields",null),(0,n._)([(0,u.Cb)({types:s.dr,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy(){var e;const t="raster-stretch"===(null==(e=this.renderer)?void 0:e.type)&&"none"===this.renderer.stretchType&&!this.renderer.useGamma;return{enabled:!this.loaded||"Raster"===this.raster.tileType||!t}}},origins:{"web-scene":{types:s.FK,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type&&"animated-flow"!==e.type})}}}}})],Ge.prototype,"renderer",null),(0,n._)([(0,d.r)("renderer")],Ge.prototype,"readRenderer",null),Ge=(0,n._)([(0,p.j)("esri.layers.ImageryTileLayer")],Ge);const Ve=Ge},73506:(e,t,r)=>{r.d(t,{Qp:()=>S,P_:()=>R,ut:()=>b,Hq:()=>C,zD:()=>p,tB:()=>w,nF:()=>g,VO:()=>m,Mk:()=>u,kZ:()=>T,kr:()=>M}),r(66577);var n=r(20102),i=r(70586),s=r(67900),a=r(90411),o=r(6570),l=r(13473);const c=5e-4;function u(e,t,r){return!(0,a.Up)(e,t,r)}function f(e,t,r){const i=u(e,t,r);if(i&&!(0,a.kR)())throw new n.Z("rasterprojectionhelper-project","projection engine is not loaded");return i}const h=function(e,t,r){const n=(e[0]+e[4]+e[4*t.cols]+e[4*t.cols+4])/4,i=(e[1]+e[5]+e[4*t.rows+1]+e[4*t.rows+5])/4,s=(e[4*t.cols]-e[0]+e[4*t.cols+4]-e[4])/r[0]*.5,a=(e[4*t.cols+1]-e[1]+e[4*t.cols+5]-e[5])/r[1]*.5;return[0===s||isNaN(s)?0:Math.abs(n-e[2*t.rows+2])/Math.abs(s),0===a||isNaN(a)?0:Math.abs(i-e[2*t.rows+3])/Math.abs(a)]},d={3395:20037508.342789244,3410:17334193.943686873,3857:20037508.342788905,3975:17367530.445161372,4087:20037508.342789244,4088:20015108.787169147,6933:17367530.445161372,32662:20037508.342789244,53001:20015086.79602057,53002:10007543.39801029,53003:20015086.79602057,53004:20015086.79602057,53016:14152803.599503474,53017:17333573.624304302,53034:20015086.79602057,53079:20015114.352186374,53080:20015114.352186374,54001:20037508.342789244,54002:10018754.171394624,54003:20037508.342789244,54004:20037508.342789244,54016:14168658.027268292,54017:17367530.44516137,54034:20037508.342789244,54079:20037508.342789244,54080:20037508.342789244,54100:20037508.342789244,54101:20037508.342789244};async function p(){if((0,a.kR)())return null;await(0,a.zD)()}function m(e,t,r,n=null){if(e.spatialReference.equals(t))return e;f(e.spatialReference,t,n);const s=r.center,l=new o.Z({xmin:s.x-e.x/2,xmax:s.x+e.x/2,ymin:s.y-e.y/2,ymax:s.y+e.y/2,spatialReference:e.spatialReference}),c=(0,a.iV)(l,t,n);return(0,i.Wi)(c)?null:{x:c.xmax-c.xmin,y:c.ymax-c.ymin}}function y(e,t=.01){return(0,s.c9)(e)?t/(0,s.c9)(e):0}function g(e,t,r=null,n=!0){const i=e.spatialReference;if(i.equals(t))return e;f(i,t,r);const s=(0,a.iV)(e,t,r);if(n&&t.isGeographic){const[t,r]=I(i,!0),n=y(i);n&&null!=t&&null!=r&&(Math.abs(e.x-t)<n&&Math.abs(180-s.x)<c?s.x-=360:Math.abs(e.x-r)<n&&Math.abs(180+s.x)<c&&(s.x+=360))}return s}function x(e){const t=b(e[0].spatialReference);if(e.length<2||!(0,i.pC)(t))return e[0];let{xmin:r,xmax:n,ymin:s,ymax:a}=e[0];for(let r=1;r<e.length;r++){const i=e[r];n=i.xmax+t*r,s=Math.min(s,i.ymin),a=Math.max(a,i.ymax)}return new o.Z({xmin:r,xmax:n,ymin:s,ymax:a,spatialReference:e[0].spatialReference})}function w(e,t,r=null,n=!0){if(e.spatialReference.equals(t))return e;const s=C(e),a=b(e.spatialReference,!0);return(0,i.pC)(a)&&0!==s?x(e.clone().normalize().map((e=>v(e,t,r,n)))):v(e,t,r,n)}function v(e,t,r=null,n=!0){const i=e.spatialReference;if(i.equals(t))return e;f(i,t,r);const s=(0,a.iV)(e,t,r);let[o,u]=I(i,!0);if(s&&n&&i.isWebMercator&&t.isGeographic&&null!=o&&null!=u){const n=.001,a=1e3;if(Math.abs(e.xmin-o)<n&&Math.abs(u-e.xmax)>a&&Math.abs(180-s.xmax)<c){s.xmin=-180;const n=[];n.push(new l.Z(e.xmax,e.ymin,i)),n.push(new l.Z(e.xmax,(e.ymin+e.ymax)/2,i)),n.push(new l.Z(e.xmax,e.ymax,i));const a=n.map((e=>g(e,t,r))).filter((e=>!isNaN(null==e?void 0:e.x))).map((e=>e.x));s.xmax=Math.max.apply(null,a)}if(Math.abs(e.xmax-u)<n&&Math.abs(o-e.xmin)>a&&Math.abs(180+s.xmin)<c){s.xmax=180;const n=[];n.push(new l.Z(e.xmin,e.ymin,i)),n.push(new l.Z(e.xmin,(e.ymin+e.ymax)/2,i)),n.push(new l.Z(e.xmin,e.ymax,i));const a=n.map((e=>g(e,t,r))).filter((e=>!isNaN(null==e?void 0:e.x))).map((e=>e.x));s.xmin=Math.min.apply(null,a)}}[o,u]=I(t,!0);const h=y(t);return h&&null!=o&&null!=u&&s&&(Math.abs(s.xmin-o)<h&&(s.xmin=o),Math.abs(s.xmax-u)<h&&(s.xmax=u)),s}function b(e,t=!1){const r=t?20037508.342787:20037508.342788905;return e.isWebMercator?2*r:e.wkid&&e.isGeographic?360:2*d[e.wkid]||null}function I(e,t=!1){const r=[],n=b(e,t);return(0,i.pC)(n)&&(r.push(-n/2),r.push(n/2)),r}function _(e,t,r,n){let i=(e-t)/r;return i-Math.floor(i)!=0?i=Math.floor(i):n&&(i-=1),i}function C(e,t=!1){const r=b(e.spatialReference);if(!(0,i.pC)(r))return 0;const n=t?0:-r/2;return _(e.xmax,n,r,!0)-_(e.xmin,n,r,!1)}function R(e){const t=e.storageInfo.origin.x,r=b(e.spatialReference,!0);if(!(0,i.pC)(r))return{originX:t,halfWorldWidth:null,pyramidsInfo:null};const n=r/2,{nativePixelSize:s,storageInfo:a,extent:o}=e,{maximumPyramidLevel:l,blockWidth:c,pyramidScalingFactor:u}=a;let f=s.x;const h=[],d=(0,i.pC)(e.transform)&&"gcs-shift"===e.transform.type,p=t+(d?0:n),m=d?r-t:n-t;for(let e=0;e<=l;e++){const e=(o.xmax-t)/f/c,r=e-Math.floor(e)==0?e:Math.ceil(e),n=m/f/c,i=n-Math.floor(n)==0?n:Math.ceil(n),s=Math.floor(p/f/c),a=Math.round(p/f)%c,l=(c-Math.round(m/f)%c)%c;h.push({resolutionX:f,blockWidth:c,datsetColumnCount:r,worldColumnCountFromOrigin:i,leftMargin:a,rightPadding:l,originColumnOffset:s}),f*=u}return{originX:t,halfWorldWidth:n,pyramidsInfo:h,hasGCSSShiftTransform:d}}function S(e){const t=e.isAdaptive&&null==e.spacing,r=e.spacing||[32,32];let n=k(e),i={cols:n.size[0]+1,rows:n.size[1]+1},s=h(n.offsets,i,r);const a=(s[0]+s[1])/2,o=n.outofBoundPointCount>0&&n.outofBoundPointCount<n.offsets.length/2;return t&&(o||a>4)&&(n=k({...e,spacing:[4,4]}),i={cols:n.size[0]+1,rows:n.size[1]+1},s=h(n.offsets,i,r)),n.error=s,n.coefficients=function(e,t,r){const{cols:n,rows:i}=t,s=new Float32Array((n-1)*(i-1)*2*6),a=new Float32Array([-0,-1,1,-1,1,-0,1,-0,-0]),o=new Float32Array([-1,1,0,0,-1,1,1,0,0]);for(let t=0;t<n-1;t++){for(let r=0;r<i-1;r++){let l=t*i*2+2*r;const c=e[l],u=e[l+1],f=e[l+2],h=e[l+3];l+=2*i;const d=e[l],p=e[l+1],m=e[l+2],y=e[l+3];let g=0,x=12*(r*(n-1)+t);for(let e=0;e<3;e++)s[x++]=a[g++]*c+a[g++]*f+a[g++]*m;g=0;for(let e=0;e<3;e++)s[x++]=a[g++]*u+a[g++]*h+a[g++]*y;g=0;for(let e=0;e<3;e++)s[x++]=o[g++]*c+o[g++]*d+o[g++]*m;g=0;for(let e=0;e<3;e++)s[x++]=o[g++]*u+o[g++]*p+o[g++]*y}if(r)for(let e=0;e<s.length;e++)isNaN(s[e])&&(s[e]=-1)}return s}(n.offsets,i,o),n}function k(e){const{projectedExtent:t,srcBufferExtent:r,pixelSize:n,datumTransformation:s,rasterTransform:o}=e,c=t.spatialReference,u=r.spatialReference;f(c,u);const{xmin:h,ymin:d,xmax:p,ymax:m}=t,y=b(u),g=e.hasWrapAround||"gcs-shift"===(null==o?void 0:o.type),x=e.spacing||[32,32],w={x:x[0]*n.x,y:x[1]*n.y},v=Math.ceil((p-h)/w.x-.1/x[0])+1,I=Math.ceil((m-d)/w.y-.1/x[1])+1,_=w.x,C=w.y,R=[];let S,k=0;const T=[];for(let e=0;e<v;e++)for(let t=0;t<I;t++)T.push(new l.Z({x:h+_*e,y:m-C*t,spatialReference:c}));const M=function(e,t,r=null){const n=e[0].spatialReference;return n.equals(t)?e:(f(n,t,r),(0,a.iV)(e,t,r))}(T,u,s);for(let e=0;e<v;e++){const t=[];for(let n=0;n<I;n++){let s=M[e*I+n];o&&(s=o.inverseTransform(s)),t.push(s),e>0&&g&&s&&S[n]&&(0,i.pC)(y)&&s.x<S[n].x&&(s.x+=y),s?(R.push((s.x-r.xmin)/(r.xmax-r.xmin)),R.push((r.ymax-s.y)/(r.ymax-r.ymin))):(R.push(NaN),R.push(NaN),k++)}S=t}return{offsets:R,error:null,coefficients:null,outofBoundPointCount:k,spacing:x,size:[v-1,I-1]}}function T(e){const t=e.clone().normalize();return 1===t.length?t[0]:x(t)}function M(e,t,r){const{storageInfo:n,pixelSize:s}=t;let a,o=!1;const{pyramidResolutions:c}=n;if((0,i.pC)(c)&&c.length){const n=(e.x+e.y)/2,i=c[c.length-1],u=(i.x+i.y)/2,f=(s.x+s.y)/2;if(n<=f)a=0;else if(n>=u)a=c.length,o=n/u>8;else{let e,t=f;for(let i=1;i<=c.length;i++){if(e=(c[i-1].x+c[i-1].y)/2,n<=e){n===e?a=i:"down"===r?(a=i-1,o=n/t>8):a="up"===r||n-t>e-n||n/t>2?i:i-1;break}t=e}}const h=0===a?s:c[a-1];return{pyramidLevel:a,pyramidResolution:new l.Z({x:h.x,y:h.y,spatialReference:t.spatialReference}),excessiveReading:o}}const u=Math.log(e.x/s.x)/Math.LN2,f=Math.log(e.y/s.y)/Math.LN2,h=t.storageInfo.maximumPyramidLevel||0;a="down"===r?Math.floor(Math.min(u,f)):"up"===r?Math.ceil(Math.max(u,f)):Math.round((u+f)/2),a<0?a=0:a>h&&(o=a>h+3,a=h);const d=2**a;return{pyramidLevel:a,pyramidResolution:new l.Z({x:d*t.nativePixelSize.x,y:d*t.nativePixelSize.y,spatialReference:t.spatialReference}),excessiveReading:o}}},48700:(e,t,r)=>{r.d(t,{Z:()=>l});var n=r(43697),i=r(96674),s=r(5600),a=(r(67676),r(80442),r(75215),r(52011));let o=class extends i.wq{get affectsPixelSize(){return!1}forwardTransform(e){return e}inverseTransform(e){return e}};(0,n._)([(0,s.Cb)()],o.prototype,"affectsPixelSize",null),(0,n._)([(0,s.Cb)({json:{write:!0}})],o.prototype,"spatialReference",void 0),o=(0,n._)([(0,a.j)("esri.layers.support.rasterTransforms.BaseRasterTransform")],o);const l=o},29680:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(43697),i=r(5600),s=(r(67676),r(80442),r(75215),r(36030)),a=r(52011),o=r(48700);let l=class extends o.Z{constructor(){super(...arguments),this.type="gcs-shift",this.tolerance=1e-8}forwardTransform(e){return"point"===(e=e.clone()).type?(e.x>180+this.tolerance&&(e.x-=360),e):(e.xmin>=180-this.tolerance?(e.xmax-=360,e.xmin-=360):e.xmax>180+this.tolerance&&(e.xmin=-180,e.xmax=180),e)}inverseTransform(e){return"point"===(e=e.clone()).type?(e.x<-this.tolerance&&(e.x+=360),e):(e.xmin<-this.tolerance&&(e.xmin+=360,e.xmax+=360),e)}};(0,n._)([(0,s.J)({GCSShiftXform:"gcs-shift"})],l.prototype,"type",void 0),(0,n._)([(0,i.Cb)()],l.prototype,"tolerance",void 0),l=(0,n._)([(0,a.j)("esri.layers.support.rasterTransforms.GCSShiftTransform")],l);const c=l},87390:(e,t,r)=>{r.d(t,{Z:()=>m});var n=r(43697),i=(r(66577),r(5600)),s=(r(67676),r(80442),r(75215),r(36030)),a=r(71715),o=r(52011),l=r(30556),c=r(48700),u=r(13473),f=r(6570);function h(e,t,r){const{x:n,y:i}=t;if(r<2)return{x:e[0]+n*e[2]+i*e[4],y:e[1]+n*e[3]+i*e[5]};if(2===r){const t=n*n,r=i*i,s=n*i;return{x:e[0]+n*e[2]+i*e[4]+t*e[6]+s*e[8]+r*e[10],y:e[1]+n*e[3]+i*e[5]+t*e[7]+s*e[9]+r*e[11]}}const s=n*n,a=i*i,o=n*i,l=s*n,c=s*i,u=n*a,f=i*a;return{x:e[0]+n*e[2]+i*e[4]+s*e[6]+o*e[8]+a*e[10]+l*e[12]+c*e[14]+u*e[16]+f*e[18],y:e[1]+n*e[3]+i*e[5]+s*e[7]+o*e[9]+a*e[11]+l*e[13]+c*e[15]+u*e[17]+f*e[19]}}function d(e,t,r){const{xmin:n,ymin:i,xmax:s,ymax:a,spatialReference:o}=t;let l=[];if(r<2)l.push({x:n,y:a}),l.push({x:s,y:a}),l.push({x:n,y:i}),l.push({x:s,y:i});else{let e=10;for(let t=0;t<e;t++)l.push({x:n,y:i+(a-i)*t/(e-1)}),l.push({x:s,y:i+(a-i)*t/(e-1)});e=8;for(let t=1;t<=e;t++)l.push({x:n+(s-n)*t/e,y:i}),l.push({x:n+(s-n)*t/e,y:a})}l=l.map((t=>h(e,t,r)));const c=l.map((e=>e.x)),u=l.map((e=>e.y));return new f.Z({xmin:Math.min.apply(null,c),xmax:Math.max.apply(null,c),ymin:Math.min.apply(null,u),ymax:Math.max.apply(null,u),spatialReference:o})}let p=class extends c.Z{constructor(){super(...arguments),this.polynomialOrder=1,this.type="polynomial"}readForwardCoefficients(e,t){const{coeffX:r,coeffY:n}=t;if(null==r||!r.length||null==n||!n.length||r.length!==n.length)return null;const i=[];for(let e=0;e<r.length;e++)i.push(r[e]),i.push(n[e]);return i}writeForwardCoefficients(e,t,r){const n=[],i=[];for(let t=0;t<(null==e?void 0:e.length);t++)t%2==0?n.push(e[t]):i.push(e[t]);t.coeffX=n,t.coeffY=i}get inverseCoefficients(){let e=this._get("inverseCoefficients");const t=this._get("forwardCoefficients");return!e&&t&&this.polynomialOrder<2&&(e=function(e){const[t,r,n,i,s,a]=e,o=n*a-s*i,l=s*i-n*a;return[(s*r-t*a)/o,(n*r-t*i)/l,a/o,i/l,-s/o,-n/l]}(t)),e}set inverseCoefficients(e){this._set("inverseCoefficients",e)}readInverseCoefficients(e,t){const{inverseCoeffX:r,inverseCoeffY:n}=t;if(null==r||!r.length||null==n||!n.length||r.length!==n.length)return null;const i=[];for(let e=0;e<r.length;e++)i.push(r[e]),i.push(n[e]);return i}writeInverseCoefficients(e,t,r){const n=[],i=[];for(let t=0;t<(null==e?void 0:e.length);t++)t%2==0?n.push(e[t]):i.push(e[t]);t.inverseCoeffX=n,t.inverseCoeffY=i}get affectsPixelSize(){return this.polynomialOrder>0}forwardTransform(e){if("point"===e.type){const t=h(this.forwardCoefficients,e,this.polynomialOrder);return new u.Z({x:t.x,y:t.y,spatialReference:e.spatialReference})}return d(this.forwardCoefficients,e,this.polynomialOrder)}inverseTransform(e){if("point"===e.type){const t=h(this.inverseCoefficients,e,this.polynomialOrder);return new u.Z({x:t.x,y:t.y,spatialReference:e.spatialReference})}return d(this.inverseCoefficients,e,this.polynomialOrder)}};(0,n._)([(0,i.Cb)({json:{write:!0}})],p.prototype,"polynomialOrder",void 0),(0,n._)([(0,i.Cb)()],p.prototype,"forwardCoefficients",void 0),(0,n._)([(0,a.r)("forwardCoefficients",["coeffX","coeffY"])],p.prototype,"readForwardCoefficients",null),(0,n._)([(0,l.c)("forwardCoefficients")],p.prototype,"writeForwardCoefficients",null),(0,n._)([(0,i.Cb)({json:{write:!0}})],p.prototype,"inverseCoefficients",null),(0,n._)([(0,a.r)("inverseCoefficients",["inverseCoeffX","inverseCoeffY"])],p.prototype,"readInverseCoefficients",null),(0,n._)([(0,l.c)("inverseCoefficients")],p.prototype,"writeInverseCoefficients",null),(0,n._)([(0,i.Cb)()],p.prototype,"affectsPixelSize",null),(0,n._)([(0,s.J)({PolynomialXform:"polynomial"})],p.prototype,"type",void 0),p=(0,n._)([(0,o.j)("esri.layers.support.rasterTransforms.PolynomialTransform")],p);const m=p},87521:(e,t,r)=>{r.d(t,{j:()=>d,c:()=>p});var n=r(29680),i=r(43697),s=(r(92604),r(75215),r(67676),r(80442),r(37697),r(36030)),a=r(52011),o=r(48700);let l=class extends o.Z{constructor(){super(...arguments),this.type="identity"}};(0,i._)([(0,s.J)({IdentityXform:"identity"})],l.prototype,"type",void 0),l=(0,i._)([(0,a.j)("esri.layers.support.rasterTransforms.IdentityTransform")],l);const c=l;var u=r(87390);const f={GCSShiftXform:n.Z,IdentityXform:c,PolynomialXform:u.Z},h=Object.keys(f);function d(e){const t=null==e?void 0:e.type;return!e||h.includes(t)}function p(e){if(!(null==e?void 0:e.type))return null;const t=f[null==e?void 0:e.type];if(t){const r=new t;return r.read(e),r}return null}},74889:(e,t,r)=>{r.r(t),r.d(t,{default:()=>v});var n,i=r(43697),s=r(66577),a=r(1692),o=r(35454),l=r(96674),c=r(22974),u=r(70586),f=r(5600),h=(r(75215),r(71715)),d=r(52011),p=r(30556),m=r(82971),y=r(33955),g=r(1231);const x=new o.Xn({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let w=n=class extends l.wq{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const r=m.Z.fromJSON(t.spatialReference),n=[];for(let t=0;t<e.length;t++){const i=e[t],s=a.Z.fromJSON(i),o=i.geometry&&i.geometry.spatialReference;(0,u.pC)(s.geometry)&&!o&&(s.geometry.spatialReference=r),n.push(s)}return n}writeGeometryType(e,t,r,n){if(e)return void x.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(e&&(0,u.pC)(e.geometry))return void x.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,y.im)(e);return!r&&t.spatialReference&&(n.spatialReference=m.Z.fromJSON(t.spatialReference)),n}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&(0,u.pC)(e.geometry)&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new n(this.cloneProperties())}cloneProperties(){return(0,c.d9)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const n=t.features[r];if(n.geometry){const t=e&&e[r];n.geometry=t&&t.toJSON()||n.geometry}}return t}quantize(e){const{scale:[t,r],translate:[n,i]}=e,s=this.features,a=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-n)/t)),(e=>Math.round((i-e)/r)));for(let e=0,t=s.length;e<t;e++)a((0,u.Wg)(s[e].geometry))||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[n,i],scale:[s,a]}=r,o=this._getHydrationFunction(e,(e=>e*s+n),(e=>i-e*a));for(const{geometry:e}of t)(0,u.pC)(e)&&o(e);return this.transform=null,this}_quantizePoints(e,t,r){let n,i;const s=[];for(let a=0,o=e.length;a<o;a++){const o=e[a];if(a>0){const e=t(o[0]),a=r(o[1]);e===n&&a===i||(s.push([e-n,a-i]),n=e,i=a)}else n=t(o[0]),i=r(o[1]),s.push([n,i])}return s.length>0?s:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const n=(0,y.oU)(e)?e.rings:e.paths,i=[];for(let e=0,s=n.length;e<s;e++){const s=n[e],a=this._quantizePoints(s,t,r);a&&i.push(a)}return i.length>0?((0,y.oU)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const n=this._quantizePoints(e.points,t,r);return n.length>0?(e.points=n,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y)}:"polyline"===e||"polygon"===e?e=>{const n=(0,y.oU)(e)?e.rings:e.paths;let i,s;for(let e=0,a=n.length;e<a;e++){const a=n[e];for(let e=0,n=a.length;e<n;e++){const n=a[e];e>0?(i+=n[0],s+=n[1]):(i=n[0],s=n[1]),n[0]=t(i),n[1]=r(s)}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax)}:"multipoint"===e?e=>{const n=e.points;let i,s;for(let e=0,a=n.length;e<a;e++){const a=n[e];e>0?(i+=a[0],s+=a[1]):(i=a[0],s=a[1]),a[0]=t(i),a[1]=r(s)}}:void 0}};(0,i._)([(0,f.Cb)({type:String,json:{write:!0}})],w.prototype,"displayFieldName",void 0),(0,i._)([(0,f.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"exceededTransferLimit",void 0),(0,i._)([(0,f.Cb)({type:[a.Z],json:{write:!0}})],w.prototype,"features",void 0),(0,i._)([(0,h.r)("features")],w.prototype,"readFeatures",null),(0,i._)([(0,f.Cb)({type:[g.Z],json:{write:!0}})],w.prototype,"fields",void 0),(0,i._)([(0,f.Cb)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:x.read}}})],w.prototype,"geometryType",void 0),(0,i._)([(0,p.c)("geometryType")],w.prototype,"writeGeometryType",null),(0,i._)([(0,f.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasM",void 0),(0,i._)([(0,f.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasZ",void 0),(0,i._)([(0,f.Cb)({types:s.qM,json:{write:!0}})],w.prototype,"queryGeometry",void 0),(0,i._)([(0,h.r)("queryGeometry")],w.prototype,"readQueryGeometry",null),(0,i._)([(0,f.Cb)({type:m.Z,json:{write:!0}})],w.prototype,"spatialReference",void 0),(0,i._)([(0,p.c)("spatialReference")],w.prototype,"writeSpatialReference",null),(0,i._)([(0,f.Cb)({json:{write:!0}})],w.prototype,"transform",void 0),w=n=(0,i._)([(0,d.j)("esri.rest.support.FeatureSet")],w),w.prototype.toJSON.isDefaultToJSON=!0;const v=w},89749:(e,t,r)=>{r.d(t,{t:()=>f});var n=r(43697),i=r(15923),s=r(61247),a=r(70586),o=r(17445),l=r(1654),c=r(5600),u=r(52011);let f=class extends i.Z{constructor(){super(...arguments),this.updating=!1,this.handleId=0,this.handles=new s.Z,this.scheduleHandleId=0,this.pendingPromises=new Set}destroy(){this.removeAll(),this.handles.destroy()}add(e,t,r={}){const n=++this.handleId;r.sync||this._installSyncUpdatingWatch(e,n);const i=(0,o.YP)(e,t,r);return this.handles.add(i,n),{remove:()=>this.handles.remove(n)}}addOnCollectionChange(e,t,{initial:r=!1}={}){const n=++this.handleId;return this.handles.add([(0,o.on)(e,"after-changes",this._createSyncUpdatingCallback(),o.Z_),(0,o.on)(e,"change",t,{onListenerAdd:r?e=>t({added:e.items,removed:[],moved:[],target:e}):void 0})],n),{remove:()=>this.handles.remove(n)}}addPromise(e){if((0,a.Wi)(e))return e;const t=++this.handleId;this.handles.add({remove:()=>{this.pendingPromises.delete(e)&&(0!==this.pendingPromises.size||this.handles.has(h)||this._set("updating",!1))}},t),this.pendingPromises.add(e),this._set("updating",!0);const r=()=>this.handles.remove(t);return e.then(r,r),e}removeAll(){this.pendingPromises.clear(),this.handles.removeAll(),this._set("updating",!1)}_installSyncUpdatingWatch(e,t){const r=this._createSyncUpdatingCallback(),n=(0,o.YP)(e,r,{sync:!0,equals:()=>!1});return this.handles.add(n,t),n}_createSyncUpdatingCallback(){return()=>{this.handles.remove(h),++this.scheduleHandleId;const e=this.scheduleHandleId;this._get("updating")||this._set("updating",!0),this.handles.add((0,l.Os)((()=>{e===this.scheduleHandleId&&(this._set("updating",this.pendingPromises.size>0),this.handles.remove(h))})),h)}}};(0,n._)([(0,c.Cb)({readOnly:!0})],f.prototype,"updating",void 0),f=(0,n._)([(0,u.j)("esri.views.support.WatchUpdatingTracking")],f);const h=-42;var d,p;(p=d||(d={}))[p.NONE=0]="NONE",p[p.SYNC=1]="SYNC",p[p.INIT=2]="INIT"}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5410],{92835:(e,t,r)=>{r.d(t,{Z:()=>y});var i,s=r(43697),n=r(96674),o=r(70586),a=r(35463),l=r(5600),_=(r(67676),r(80442),r(75215),r(71715)),u=r(52011),d=r(30556);let c=i=class extends n.wq{constructor(e){super(e),this.end=null,this.start=null}static get allTime(){return p}static get empty(){return h}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?e.getTime():null}get isAllTime(){return this.equals(i.allTime)}get isEmpty(){return this.equals(i.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?e.getTime():null}clone(){return new i({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=(0,o.pC)(this.start)?this.start.getTime():this.start,r=(0,o.pC)(this.end)?this.end.getTime():this.end,i=(0,o.pC)(e.start)?e.start.getTime():e.start,s=(0,o.pC)(e.end)?e.end.getTime():e.end;return t===i&&r===s}expandTo(e){if(this.isEmpty||this.isAllTime)return this.clone();const t=(0,o.Po)(this.start,(t=>(0,a.JE)(t,e))),r=(0,o.Po)(this.end,(t=>(0,a.Nm)((0,a.JE)(t,e),1,e)));return new i({start:t,end:r})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return i.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=(0,o.R2)(this.start,-1/0,(e=>e.getTime())),r=(0,o.R2)(this.end,1/0,(e=>e.getTime())),s=(0,o.R2)(e.start,-1/0,(e=>e.getTime())),n=(0,o.R2)(e.end,1/0,(e=>e.getTime()));let a,l;if(s>=t&&s<=r?a=s:t>=s&&t<=n&&(a=t),r>=s&&r<=n?l=r:n>=t&&n<=r&&(l=n),!isNaN(a)&&!isNaN(l)){const e=new i;return e.start=a===-1/0?null:new Date(a),e.end=l===1/0?null:new Date(l),e}return i.empty}offset(e,t){if(this.isEmpty||this.isAllTime)return this.clone();const r=new i,{start:s,end:n}=this;return(0,o.pC)(s)&&(r.start=(0,a.Nm)(s,e,t)),(0,o.pC)(n)&&(r.end=(0,a.Nm)(n,e,t)),r}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return p.clone();const t=(0,o.pC)(this.start)&&(0,o.pC)(e.start)?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,r=(0,o.pC)(this.end)&&(0,o.pC)(e.end)?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new i({start:t,end:r})}};(0,s._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],c.prototype,"end",void 0),(0,s._)([(0,_.r)("end")],c.prototype,"readEnd",null),(0,s._)([(0,d.c)("end")],c.prototype,"writeEnd",null),(0,s._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],c.prototype,"isAllTime",null),(0,s._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],c.prototype,"isEmpty",null),(0,s._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],c.prototype,"start",void 0),(0,s._)([(0,_.r)("start")],c.prototype,"readStart",null),(0,s._)([(0,d.c)("start")],c.prototype,"writeStart",null),c=i=(0,s._)([(0,u.j)("esri.TimeExtent")],c);const p=new c,h=new c({start:void 0,end:void 0}),y=c},99880:(e,t,r)=>{r.d(t,{V:()=>l});var i=r(68773),s=(r(3172),r(20102)),n=r(92604),o=r(17452);const a=n.Z.getLogger("esri.assets");function l(e){if(!i.Z.assetsPath)throw a.errorOnce("The API assets location needs to be set using config.assetsPath. More information: https://arcg.is/1OzLe50"),new s.Z("assets:path-not-set","config.assetsPath is not set");return(0,o.v_)(i.Z.assetsPath,e)}},25929:(e,t,r)=>{r.d(t,{M:()=>p,f:()=>n,i:()=>d,p:()=>y,r:()=>a,t:()=>o,w:()=>l});var i=r(70586),s=r(17452);function n(e,t){const r=t&&t.url&&t.url.path;if(e&&r&&(e=(0,s.hF)(e,r,{preserveProtocolRelative:!0}),t.portalItem&&t.readResourcePaths)){const r=(0,s.PF)(e,t.portalItem.itemUrl);u.test(r)&&t.readResourcePaths.push(t.portalItem.resourceFromPath(r).path)}return c(e,t&&t.portal)}function o(e,t,r=p.YES){if(!e)return e;!(0,s.YP)(e)&&t&&t.blockedRelativeUrls&&t.blockedRelativeUrls.push(e);let i=(0,s.hF)(e);if(t){const r=t.verifyItemRelativeUrls&&t.verifyItemRelativeUrls.rootPath||t.url&&t.url.path;if(r){const n=c(r,t.portal);i=(0,s.PF)(c(i,t.portal),n,n),i!==e&&t.verifyItemRelativeUrls&&t.verifyItemRelativeUrls.writtenUrls.push(i)}}return i=function(e,t){return t&&!t.isPortal&&t.urlKey&&t.customBaseUrl?(0,s.Ie)(e,`${t.urlKey}.${t.customBaseUrl}`,t.portalHostname):e}(i,t&&t.portal),(0,s.YP)(i)&&(i=(0,s.Fv)(i)),null!=t&&t.resources&&null!=t&&t.portalItem&&!(0,s.YP)(i)&&!(0,s.HK)(i)&&r===p.YES&&t.resources.toKeep.push({resource:t.portalItem.resourceFromPath(i)}),i}function a(e,t,r){return n(e,r)}function l(e,t,r,i){const s=o(e,i);void 0!==s&&(t[r]=s)}const _=/\/items\/([^\/]+)\/resources\//,u=/^\.\/resources\//;function d(e){const t=(0,i.pC)(e)?e.match(_):null;return(0,i.pC)(t)?t[1]:null}function c(e,t){if(!t||t.isPortal||!t.urlKey||!t.customBaseUrl)return e;const r=`${t.urlKey}.${t.customBaseUrl}`,i=(0,s.TI)();return(0,s.D6)(i,`${i.scheme}://${r}`)?(0,s.Ie)(e,t.portalHostname,r):(0,s.Ie)(e,r,t.portalHostname)}var p,h;(h=p||(p={}))[h.YES=0]="YES",h[h.NO=1]="NO";const y=Object.freeze({__proto__:null,fromJSON:n,toJSON:o,read:a,write:l,itemIdFromResourceUrl:d,get MarkKeep(){return p}})},10699:(e,t,r)=>{r.d(t,{I:()=>o});var i=r(43697),s=r(52011);let n=0;const o=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+n++})}};return t=(0,i._)([(0,s.j)("esri.core.Identifiable")],t),t};let a=class extends(o(class{})){};a=(0,i._)([(0,s.j)("esri.core.Identifiable")],a)},16453:(e,t,r)=>{r.d(t,{R:()=>A,w:()=>R});var i=r(43697),s=r(15923),n=r(70586),o=r(41103),a=r(22974),l=r(31263);class _{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(l.kk),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new _,r=this._originStores[l.s3.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,a.d9)(e),l.s3.DEFAULTS)}));for(let r=l.s3.SERVICE;r<l.kk;r++){const i=this._originStores[r];i&&i.forEach(((i,s)=>{e&&e.has(s)||t.set(s,(0,a.d9)(i),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=l.s3.USER){let i=this._originStores[r];if(i||(i=new Map,this._originStores[r]=i),i.set(e,t),!this._values.has(e)||(0,n.j0)(this._propertyOriginMap.get(e))<=r){const i=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),i!==t}return!1}delete(e,t=l.s3.USER){const r=this._originStores[t];if(!r)return;const i=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return i}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],i=r&&r.get(e),s=this._values.get(e);return this._values.set(e,i),this._propertyOriginMap.set(e,t),s!==i}originOf(e){return this._propertyOriginMap.get(e)||l.s3.DEFAULTS}forEach(e){this._values.forEach(e)}}var u=r(50549),d=r(1153),c=r(52011);const p=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,n.j0)((0,d.vw)(this)),r=t.store,i=new _;t.store=i,(0,o.M)(t,r,i)}read(e,t){(0,u.ij)(this,e,t)}getAtOrigin(e,t){const r=h(this),i=(0,l.M9)(t);if("string"==typeof e)return r.get(e,i);const s={};return e.forEach((e=>{s[e]=r.get(e,i)})),s}originOf(e){return(0,l.x3)(this.originIdOf(e))}originIdOf(e){return h(this).originOf(e)}revert(e,t){const r=h(this),i=(0,l.M9)(t),s=(0,d.vw)(this);let n;n="string"==typeof e?"*"===e?r.keys(i):[e]:e,n.forEach((e=>{s.invalidate(e),r.revert(e,i),s.commit(e)}))}};return t=(0,i._)([(0,c.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function h(e){return(0,d.vw)(e).store}let y=class extends(p(s.Z)){};y=(0,i._)([(0,c.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],y);var E=r(76169);const S=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return T(this).delete(e,(0,l.M9)(t))}write(e={},t){return(0,E.cW)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,d.vw)(this).setAtOrigin(e,t,(0,l.M9)(r))}removeOrigin(e){const t=T(this),r=(0,l.M9)(e),i=t.keys(r);for(const e of i)t.originOf(e)===r&&t.set(e,t.get(e,r),l.s3.USER)}updateOrigin(e,t){const r=T(this),i=(0,l.M9)(t),s=this.get(e);for(let t=i+1;t<l.kk;++t)r.delete(e,t);r.set(e,s,i)}toJSON(e){return this.write({},e)}};return t=(0,i._)([(0,c.j)("esri.core.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function T(e){return(0,d.vw)(e).store}const A=e=>{let t=class extends(S(p(e))){constructor(...e){super(...e)}};return t=(0,i._)([(0,c.j)("esri.core.MultiOriginJSONSupport")],t),t};let R=class extends(A(s.Z)){};R=(0,i._)([(0,c.j)("esri.core.MultiOriginJSONSupport")],R)},70921:(e,t,r)=>{r.d(t,{R:()=>n,Z:()=>s});var i=r(80539);function s(e,t,r=i.Z){return t||(t=new r),t===e||(t.removeAll(),(s=e)&&(Array.isArray(s)||"items"in s&&Array.isArray(s.items))?t.addMany(e):e&&t.add(e)),t;var s}function n(e){return e}},35463:(e,t,r)=>{r.d(t,{rJ:()=>a,Nm:()=>n,JE:()=>o}),r(80442);const i={milliseconds:1,seconds:1e3,minutes:6e4,hours:36e5,days:864e5,weeks:6048e5,months:26784e5,years:31536e6,decades:31536e7,centuries:31536e8},s={milliseconds:{getter:"getMilliseconds",setter:"setMilliseconds",multiplier:1},seconds:{getter:"getSeconds",setter:"setSeconds",multiplier:1},minutes:{getter:"getMinutes",setter:"setMinutes",multiplier:1},hours:{getter:"getHours",setter:"setHours",multiplier:1},days:{getter:"getDate",setter:"setDate",multiplier:1},weeks:{getter:"getDate",setter:"setDate",multiplier:7},months:{getter:"getMonth",setter:"setMonth",multiplier:1},years:{getter:"getFullYear",setter:"setFullYear",multiplier:1},decades:{getter:"getFullYear",setter:"setFullYear",multiplier:10},centuries:{getter:"getFullYear",setter:"setFullYear",multiplier:100}};function n(e,t,r){const i=new Date(e.getTime());if(t&&r){const e=s[r],{getter:n,setter:o,multiplier:a}=e;if("months"===r){const e=function(e,t){const r=new Date(e,t+1,1);return r.setDate(0),r.getDate()}(i.getFullYear(),i.getMonth()+t);i.getDate()>e&&i.setDate(e)}i[o](i[n]()+t*a)}return i}function o(e,t){switch(t){case"milliseconds":return new Date(e.getTime());case"seconds":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds());case"minutes":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes());case"hours":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours());case"days":return new Date(e.getFullYear(),e.getMonth(),e.getDate());case"weeks":return new Date(e.getFullYear(),e.getMonth(),e.getDate()-e.getDay());case"months":return new Date(e.getFullYear(),e.getMonth(),1);case"years":return new Date(e.getFullYear(),0,1);case"decades":return new Date(e.getFullYear()-e.getFullYear()%10,0,1);case"centuries":return new Date(e.getFullYear()-e.getFullYear()%100,0,1);default:return new Date}}function a(e,t,r){return 0===e?0:e*i[t]/i[r]}},79235:(e,t,r)=>{r.d(t,{Z:()=>A});var i,s=r(43697),n=r(67676),o=r(35454),a=r(96674),l=r(67900),_=r(20941),u=r(5600),d=(r(80442),r(75215),r(71715)),c=r(52011),p=r(30556);const h=(0,o.wY)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),y=h.jsonValues.slice();(0,n.e$)(y,"orthometric");const E=(0,o.wY)()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet","clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});let S=i=class extends a.wq{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,r){return h.write(e,t,r)}readHeightModel(e,t,r){return h.read(e)||(r&&r.messages&&r.messages.push(function(e,t){return new _.Z("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:r})),null)}readHeightUnit(e,t,r){return E.read(e)||(r&&r.messages&&r.messages.push(T(e,{context:r})),null)}readHeightUnitService(e,t,r){return(0,l.$C)(e)||E.read(e)||(r&&r.messages&&r.messages.push(T(e,{context:r})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new i({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const r=(0,l.cM)(t);return new i({heightModel:e.heightModel,heightUnit:r,vertCRS:e.vertCRS})}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new i;return t.read(e,{origin:"web-scene"}),t}};function T(e,t){return new _.Z("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,s._)([(0,u.Cb)({type:h.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:y,default:"ellipsoidal"}}}})],S.prototype,"heightModel",void 0),(0,s._)([(0,p.c)("web-scene","heightModel")],S.prototype,"writeHeightModel",null),(0,s._)([(0,d.r)(["web-scene","service"],"heightModel")],S.prototype,"readHeightModel",null),(0,s._)([(0,u.Cb)({type:E.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:E.jsonValues,write:E.write}}}})],S.prototype,"heightUnit",void 0),(0,s._)([(0,d.r)("web-scene","heightUnit")],S.prototype,"readHeightUnit",null),(0,s._)([(0,d.r)("service","heightUnit")],S.prototype,"readHeightUnitService",null),(0,s._)([(0,u.Cb)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],S.prototype,"vertCRS",void 0),(0,s._)([(0,d.r)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],S.prototype,"readVertCRS",null),S=i=(0,s._)([(0,c.j)("esri.geometry.HeightModelInfo")],S);const A=S},29600:(e,t,r)=>{r.d(t,{Z:()=>R});var i=r(43697),s=r(68773),n=(r(66577),r(3172)),o=r(20102),a=r(32448),l=r(10699),_=r(83379),u=r(92604),d=r(95330),c=r(17452),p=r(5600),h=(r(67676),r(80442),r(75215),r(52011)),y=r(6570),E=r(82971);let S=0;const T=u.Z.getLogger("esri.layers.Layer");let A=class extends(a.Z.EventedMixin((0,l.I)(_.Z))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new y.Z(-180,-90,180,90,E.Z.WGS84),this.id=Date.now().toString(16)+"-layer-"+S++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=E.Z.WGS84,this.title=null,this.type=null,this.url=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e,i=await r.e(3529).then(r.bind(r,63529));try{return await i.fromUrl(t)}catch(e){throw T.error("#fromArcGISServerUrl({ url: '"+t.url+"'})","Failed to create layer from arcgis server url",e),e}}static async fromPortalItem(e){const t="portalItem"in e?e:{portalItem:e},i=await r.e(4579).then(r.bind(r,44579));try{return await i.fromItem(t)}catch(e){const r=t&&t.portalItem,i=r&&r.id||"unset",n=r&&r.portal&&r.portal.url||s.Z.portalUrl;throw T.error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+n+"', id: '"+i+"')",e),e}}initialize(){this.when().catch((e=>{var t,r;(0,d.D_)(e)||u.Z.getLogger(this.declaredClass).error("#load()",`Failed to load layer (title: '${null!=(t=this.title)?t:"no title"}', id: '${null!=(r=this.id)?r:"no id"}')`,{error:e})}))}destroy(){if(this.parent){const e=this,t=this.parent;"layers"in t&&t.layers.includes(e)?t.layers.remove(e):"tables"in t&&t.tables.includes(e)?t.tables.remove(e):"baseLayers"in t&&t.baseLayers.includes(e)?t.baseLayers.remove(e):"baseLayers"in t&&t.referenceLayers.includes(e)&&t.referenceLayers.remove(e)}}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){const e=this.url;return e?(0,c.mN)(e):null}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,n.default)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.Z("layer:no-attribution-data","Layer does not have attribution data")}};(0,i._)([(0,p.Cb)({type:String})],A.prototype,"attributionDataUrl",void 0),(0,i._)([(0,p.Cb)({type:y.Z})],A.prototype,"fullExtent",void 0),(0,i._)([(0,p.Cb)({readOnly:!0})],A.prototype,"hasAttributionData",null),(0,i._)([(0,p.Cb)({type:String})],A.prototype,"id",void 0),(0,i._)([(0,p.Cb)({type:Boolean,nonNullable:!0})],A.prototype,"legendEnabled",void 0),(0,i._)([(0,p.Cb)({type:["show","hide","hide-children"]})],A.prototype,"listMode",void 0),(0,i._)([(0,p.Cb)({type:Number,range:{min:0,max:1},nonNullable:!0})],A.prototype,"opacity",void 0),(0,i._)([(0,p.Cb)()],A.prototype,"parent",void 0),(0,i._)([(0,p.Cb)({readOnly:!0})],A.prototype,"parsedUrl",null),(0,i._)([(0,p.Cb)({type:Boolean})],A.prototype,"popupEnabled",void 0),(0,i._)([(0,p.Cb)({type:Boolean})],A.prototype,"attributionVisible",void 0),(0,i._)([(0,p.Cb)({type:E.Z})],A.prototype,"spatialReference",void 0),(0,i._)([(0,p.Cb)({type:String})],A.prototype,"title",void 0),(0,i._)([(0,p.Cb)({type:String,readOnly:!0,json:{read:!1}})],A.prototype,"type",void 0),(0,i._)([(0,p.Cb)()],A.prototype,"url",void 0),(0,i._)([(0,p.Cb)({type:Boolean,nonNullable:!0})],A.prototype,"visible",void 0),A=(0,i._)([(0,h.j)("esri.layers.Layer")],A);const R=A},58092:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Ue});var i,s,n,o,a=r(43697),l=r(80539),_=r(61247),u=r(92604),d=r(70586),c=r(16453),p=r(95330),h=r(17445),y=r(5600),E=(r(67676),r(80442),r(75215)),S=r(71715),T=r(52011),A=r(17896),R=r(65617),g=r(29600),m=r(3172);!function(e){e[e.Binary=0]="Binary",e[e.JSON=1]="JSON"}(i||(i={})),function(e){e[e.None=1]="None",e[e.Front=2]="Front",e[e.Back=3]="Back"}(s||(s={})),function(e){e[e.Low=0]="Low",e[e.Medium=1]="Medium",e[e.High=2]="High"}(n||(n={})),function(e){e[e.None=0]="None",e[e.StaticSections=1]="StaticSections",e[e.Slices=2]="Slices",e[e.DynamicSections=4]="DynamicSections",e[e.GhostShell=8]="GhostShell",e[e.Isosurface=16]="Isosurface",e[e.Quality=32]="Quality",e[e.SunLocation=64]="SunLocation",e[e.StaticSectionSelection=128]="StaticSectionSelection",e[e.ExaggerationAndOffset=256]="ExaggerationAndOffset",e[e.CurrentTime=512]="CurrentTime",e[e.CurrentVariable=1024]="CurrentVariable",e[e.DeleteIsosurface=2048]="DeleteIsosurface",e[e.ContainerVisibility=4096]="ContainerVisibility",e[e.RenderMode=8192]="RenderMode",e[e.Optimization=16384]="Optimization"}(o||(o={}));var b=r(99880);function C(e){return(0,b.V)(`esri/libs/vxl/${e}`)}var v=r(50173),f=r(97995),N=r(54738),L=r(35371);const w=u.Z.getLogger("esri.layers.VoxelWasmPerScene");var I,O;(O=I||(I={}))[O.Lifetime=1]="Lifetime",O[O.RequestResponse=2]="RequestResponse",O[O.Rendering=3]="Rendering",O[O.Error=4]="Error";class M{constructor(e){this._halfIntTexturesAvailable=!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=v.C.MATERIAL,this._renderSlot=f.r.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===I.Error?w.error(t):w.warn(t))}_removeRenderPlugin(){this._pluginIsActive&&this._view._stage&&(this._dbg(I.Lifetime,"--removeRenderPlugin--"),this._view._stage.removeRenderPlugin(this)),this._pluginIsActive=!1}_initialize(){this._dbg(I.Lifetime,"--initialize--");for(const e of this._wasmMemBlockSizes)this._wasmMemBlocks.set(e,0);this._readyWatchHandle=(0,h.YP)((()=>this._view.ready),(e=>{e&&"local"===this._view.viewingMode?(this._dbg(I.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(I.Lifetime,"view ready status changed, not ready or not a local view!"),this._removeRenderPlugin())}),{initial:!0}),this._qualityWatchHandle=(0,h.YP)((()=>{var e;return null==(e=this._view)?void 0:e.qualityProfile}),(e=>{this._dbg(I.Rendering,"qualityProfile changed to "+e),this._vxl&&this._vxl.set_quality(this._toWasmQuality(e))}),{initial:!0}),this._timeExtentWatchHandle=(0,h.YP)((()=>{var e;return null==(e=this._view)?void 0:e.timeExtent}),(()=>{if(this._vxl){var e;const t=this._getTimeArgs(null==(e=this._view)?void 0:e.timeExtent);this._dbg(I.Rendering,"sceneView timeExtent changed to useTime="+t.useTime+" st="+t.startTime+" et="+t.endTime),this._vxl.set_scene_time_extent(t.startTime,t.endTime,t.useTime),this._renderPluginContext.requestRender()}}),{initial:!0}),this._stationaryWatchHandle=(0,h.YP)((()=>{var e;return null==(e=this._view)?void 0:e.stationary}),(e=>{this._vxl&&e&&!this._lastFrameWasStationary&&this._renderPluginContext.requestRender()}))}initializeRenderContext(e){this._dbg(I.Lifetime,"--initializeRenderContext--");const t=e.renderContext.rctx;t.type===N.zO.WEBGL2?(this._renderPluginContext=e,this._rctx=e.renderContext.rctx,this._halfIntTexturesAvailable=!!this._rctx.capabilities.textureNorm16,this._initializeWasm(t.gl)):this._dbg(I.Error,"WebGL 1 context only!")}uninitializeRenderContext(){this._renderPluginContext=null,this._rctx=null,this._dbg(I.Lifetime,"--uninitializeRenderContext--")}_restoreFramebuffer(){if(!this._renderTargetToRestore)return;const e=this._renderTargetToRestore.fbo;if(!this._rctx)return void this._dbg(I.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 r=!!this._rctx,i=!!this._renderTargetToRestore;if(!r||!i)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(I.Error,"no depth/stencil texture exists!"),0)}_setBlendState(e,t,r,i){this._rctx?(this._rctx.setBlendingEnabled(1===e),this._rctx.setBlendFunction(t,r),this._rctx.setBlendEquation(i)):this._dbg(I.Error,"setBlendState callback has no rendering context!")}_setFrontFace(e){this._rctx?this._rctx.setFrontFace(e):this._dbg(I.Error,"setFrontFace callback has no rendering context!")}_setDepthStencilStateFunction(e,t,r){this._rctx?(this._rctx.setDepthFunction(r),this._rctx.setDepthTestEnabled(1===e),this._rctx.setDepthWriteEnabled(1===t),this._rctx.setStencilTestEnabled(!1),this._rctx.setStencilFunction(L.wb.ALWAYS,0,255),this._rctx.setStencilOpSeparate(L.LR.FRONT,L.xS.KEEP,L.xS.INCR,L.xS.KEEP),this._rctx.setStencilOpSeparate(L.LR.BACK,L.xS.KEEP,L.xS.DECR,L.xS.KEEP)):this._dbg(I.Error,"setDepthStencilStateFunction callback has no rendering context!")}_setRasterizerState(e){if(this._rctx)switch(e){case s.None:this._rctx.setFaceCullingEnabled(!1);break;case s.Back:this._rctx.setCullFace(L.LR.BACK),this._rctx.setFaceCullingEnabled(!0);break;case s.Front:this._rctx.setCullFace(L.LR.FRONT),this._rctx.setFaceCullingEnabled(!0)}else this._dbg(I.Error,"setRasterizerState callback has no rendering context!")}_setViewport(e,t,r,i){this._rctx?this._rctx.setViewport(e,t,r,i):this._dbg(I.Error,"setViewport callback has no rendering context!")}_syncRequestsResponses(){this._layers.forEach(((e,t)=>{const r=[];e.responses.forEach(((e,i)=>{r.push(i),this._dbg(I.RequestResponse,"responding for requestID:"+i+" size:"+e.size),this._vxl.respond(t,i,e)}));const i=e.responses;for(const e of r)i.delete(e);const s=this._vxl.get_new_requests(t),n=e.abortController.signal;for(const t in s){e.outstandingRequestCount+=1,1===e.outstandingRequestCount&&e.layerView.updatingFlagChanged();const r=s[t],o={responseType:"array-buffer",signal:n};this._dbg(I.RequestResponse,"making requestID:"+t+" url:"+r.url),(0,m.default)(r.url,o).then((s=>{e.outstandingRequestCount-=1,0===e.outstandingRequestCount&&e.layerView.updatingFlagChanged(),this._dbg(I.RequestResponse,"have response for requestID:"+t);let n=0;if(s.data.byteLength>0){n=this._vxl._malloc(s.data.byteLength);const e=new Uint8Array(this._vxl.HEAPU8.buffer,n,s.data.byteLength),t=new Uint8Array(s.data);for(let r=0;r<s.data.byteLength;++r)e[r]=t[r]}i.set(+t,{type:r.type,ptr:n,size:s.data.byteLength,success:!0})})).catch((s=>{e.outstandingRequestCount-=1,0===e.outstandingRequestCount&&e.layerView.updatingFlagChanged(),(0,p.D_)(s)||(this._dbg(I.Error,`requestID:${t} failed, error=${s.toString()}`),i.set(+t,{type:r.type,ptr:0,size:0,success:!1}))}))}}))}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(((r,i)=>{r.layerView===e&&(this._vxl.set_enabled(i,t),this._renderPluginContext.requestRender())}))}setSlices(e,t){const r={mask:o.Slices,slices:{planes:t,currentEditPlane:-1}};return this._doMaskedUIUpdate(e,r,!0)}setDynamicSections(e,t){const r={mask:o.DynamicSections,dynamicSections:{planes:t,currentEditPlane:-1}};return this._doMaskedUIUpdate(e,r,!0)}setStaticSections(e,t){const r={mask:o.StaticSections,staticSections:t};return this._doMaskedUIUpdate(e,r,!0)}setCurrentVariable(e,t){const r={mask:o.CurrentVariable,currentVariable:t};return this._doMaskedUIUpdate(e,r,!0)}setRenderMode(e,t){const r={mask:o.RenderMode,renderMode:t};return this._doMaskedUIUpdate(e,r,!0)}_doMaskedUIUpdate(e,t,r){if(!this._vxl)return!1;let i=!1;return this._layers.forEach(((r,s)=>{if(r.layerView===e){const e={str:JSON.stringify(t),byteCount:0,ptr:0,isReusable:!1};this._allocateBlock(e)&&(i=1===this._vxl.handle_masked_ui_update(s,e.ptr,e.byteCount),e.isReusable||this._vxl._free(e.ptr))}})),i&&r&&this._renderPluginContext.requestRender(),i}addVoxelLayer(e){if(!this._vxl){const t={layerView:e,resolveCallback:null,rejectCallback:null},r=new Promise(((e,r)=>{t.resolveCallback=e,t.rejectCallback=r}));return this._newLayers.push(t),r}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===t.layerView));t>=0&&(this._newLayers[t].resolveCallback(-1),this._newLayers.splice(t,1));const r=this._newLayers.length;return 0===r&&(this._dbg(I.Lifetime," no voxel layers left after removing a layer, removing RenderPlugin and destroying"),this.destroy()),r}let t=-1;this._layers.forEach(((r,i)=>{r.layerView===e&&(t=i,r.abortController.abort(),this._vxl.remove_layer(t))})),t>=0&&this._layers.delete(t);const r=this._layers.size;return 0===r&&(this._dbg(I.Lifetime," no voxel layers left after removing a layer, removing RenderPlugin and destroying"),this.destroy()),r}_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,r=Number.MAX_VALUE,i=!1;return(0,d.pC)(e)&&(e.isAllTime?i=!0:((0,d.pC)(e.start)&&(i=!0,t=e.start.getTime()/1e3),(0,d.pC)(e.end)&&(i=!0,r=e.end.getTime()/1e3))),{startTime:t,endTime:r,useTime:i}}_addVoxelLayer(e){var t;const r=e.layer;let i=-1;const s=r.getConfiguration();if(s.length<1)return-1;const n={str:s,byteCount:0,ptr:0,isReusable:!1};if(!this._allocateBlock(n))return-1;const o=this._getTimeArgs(null==(t=this._view)?void 0:t.timeExtent),a=this._view.spatialReference.isWGS84&&r.spatialReference.isWGS84?111319.49079327357:1;if(i=this._vxl.add_layer(r.serviceRoot,n.ptr,n.byteCount,a,a,o.startTime,o.endTime,o.useTime,this._toWasmQuality(this._view.qualityProfile)),n.isReusable||this._vxl._free(n.ptr),i>=0){const t=new AbortController;if(this._layers.set(i,{layerView:e,responses:new Map,outstandingRequestCount:0,abortController:t}),!this._halfIntTexturesAvailable){const t=[];let r="";for(const i of e.layer.variables)"Int16"!==i.renderingFormat.type&&"UInt16"!==i.renderingFormat.type||(t.push(i.name),i.id===e.layer.style.currentVariableId&&(r=i.name));""!==r&&w.error("#addVoxelLayer_error()",e.layer,`The voxel layer '${e.layer.title}' cannot render the current variable '${r}' in this browser`),t.length>0&&w.warn("#addVoxelLayer_warning()",e.layer,`The voxel layer '${e.layer.title}' cannot render the variables '${t.toString()}' in this browser`)}return i}return-1}prepareRender(e){if(!this._vxl)return;const t=e.viewForward,r=e.eye;this._vxl.update_camera_pos_and_direction(r[0],r[1],r[2],t[0],t[1],t[2]);const i=this._vxl.cull();this._dbg(I.RequestResponse,"missingResourceCount="+i),this._moreToLoad=i>0,this._havePreparedWithAllLayers=0===this._newLayers.length}render(e){if(!this._vxl||e.pass!==this._renderPass||e.slot!==this._renderSlot)return;for(const e of this._newLayers){const t=this._addVoxelLayer(e.layerView);-1===t?e.rejectCallback(-1):e.resolveCallback(t)}if(this._newLayers=[],0===this._layers.size)return void this._dbg(I.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._vxl.begin_color_frame(!this._view.stationary||this._moreToLoad,e.scenelightingData.lightingMainDirection[0],e.scenelightingData.lightingMainDirection[1],e.scenelightingData.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)),0===t.x&&0===t.y||this._dbg(I.Error,"Unsupported viewport parameters detected!"),this.updateWasmCamera(e.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(I.Lifetime,"--destroy--"),this._removeRenderPlugin(),this._readyWatchHandle=(0,d.hw)(this._readyWatchHandle),this._qualityWatchHandle=(0,d.hw)(this._qualityWatchHandle),this._timeExtentWatchHandle=(0,d.hw)(this._timeExtentWatchHandle),this._stationaryWatchHandle=(0,d.hw)(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=function(e){return new Promise((t=>r.e(6550).then(r.bind(r,6550)).then((e=>e.v)).then((({default:r})=>{const i=r({locateFile:C,preinitializedWebGLContext:e,onRuntimeInitialized:()=>t(i)})})))).catch((e=>Promise.reject(e)))}(e).then((e=>{var t;if(this._vxl=e,this._vxlPromise=null,this._newLayers.length<=0)return this._dbg(I.Lifetime," no voxel layers left after WASM downloaded, removing RenderPlugin and destroying"),void this.destroy();const r=this._getTimeArgs(null==(t=this._view)?void 0:t.timeExtent),i=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"),o=this._vxl.addFunction(this._setRasterizerState.bind(this),"vi"),a=this._vxl.addFunction(this._setDepthStencilStateFunction.bind(this),"viii"),l=this._vxl.addFunction(this._setViewport.bind(this),"viiii"),_=this._vxl.addFunction(this._bindPreviousDepthToSlot.bind(this),"iii");this._vxl.initialize_voxel_wasm(i,s,n,o,a,l,_,r.startTime,r.endTime,r.useTime),this._renderPluginContext&&this._renderPluginContext.requestRender()})).catch((()=>{for(const e of this._newLayers)e.rejectCallback(-2);this._dbg(I.Error," WASM failed to download, removing RenderPlugin and destroying"),this.destroy()}))),this._vxlPromise)}pickDepth(e,t,r){if(!this._vxl||!this._rctx||0===this._layers.size)return null;const i=r.viewport[3]-t;if(e<0||e>r.viewport[2]||t<0||t>r.viewport[3])return this._dbg(I.Error,`pickDepth: outOfRange, screenXY=[${e}, ${i}], vp=[${r.viewport.toString()}]`),null;this._renderTargetToRestore={fbo:this._rctx.getBoundFramebufferObject(),viewport:this._rctx.getViewport()};const s=r.viewForward,n=r.eye;this._vxl.update_camera_pos_and_direction(n[0],n[1],n[2],s[0],s[1],s[2]),this.updateWasmCamera(r),this._vxl.begin_frame();const o=this._vxl.pick_depth(e,i);return 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(),o.success?o.distanceToCamera:null}_toWasmQuality(e){switch(e){case"low":return 0;case"medium":return 1;case"high":return 2}}}class x{constructor(){this.view2WASM=new Map}static getInstance(){return x.instance||(x.instance=new x),x.instance}getVoxelWasmPerSceneView(e){return this.view2WASM.has(e)?this.view2WASM.get(e):null}isUpdating(e,t){return!!this.view2WASM.has(e)&&this.view2WASM.get(e).isUpdating(t)}addLayer(e,t){return this.view2WASM.has(e)||this.view2WASM.set(e,new M(e)),this.view2WASM.get(e).addVoxelLayer(t)}removeLayer(e,t){this.view2WASM.has(e)&&this.view2WASM.get(e).removeVoxelLayer(t)<1&&this.view2WASM.delete(e)}setLayerEnabled(e,t,r){this.view2WASM.has(e)&&this.view2WASM.get(e).setEnabled(t,r)}setLayerSlices(e,t){let r=!1;return this.view2WASM.forEach(((i,s)=>{s.allLayerViews.filter((e=>"voxel-3d"===e.type)).forEach((s=>{s.layer===e&&(r=i.setSlices(s,t))}))})),r}setLayerDynamicSections(e,t){let r=!1;return this.view2WASM.forEach(((i,s)=>{s.allLayerViews.filter((e=>"voxel-3d"===e.type)).forEach((s=>{s.layer===e&&(r=i.setDynamicSections(s,t))}))})),r}setLayerCurrentVariable(e,t){let r=!1;return this.view2WASM.forEach(((i,s)=>{s.allLayerViews.filter((e=>"voxel-3d"===e.type)).forEach((s=>{s.layer===e&&(r=i.setCurrentVariable(s,t))}))})),r}setLayerRenderMode(e,t){let r=!1;return this.view2WASM.forEach(((i,s)=>{s.allLayerViews.filter((e=>"voxel-3d"===e.type)).forEach((s=>{s.layer===e&&(r=i.setRenderMode(s,t))}))})),r}setLayerStaticSections(e,t){let r=!1;return this.view2WASM.forEach(((i,s)=>{s.allLayerViews.filter((e=>"voxel-3d"===e.type)).forEach((s=>{s.layer===e&&(r=i.setStaticSections(s,t))}))})),r}}var P=r(54295),D=r(17287),U=r(38009),F=r(16859),V=r(72965),B=r(13496),j=r(66677),H=r(21506),G=r(96674);let W=class extends G.wq{constructor(){super(...arguments),this.enabled=!0,this.label="",this.normal=null,this.point=null}};(0,a._)([(0,y.Cb)({type:Boolean,json:{default:!0,write:!0}})],W.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],W.prototype,"label",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],W.prototype,"normal",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],W.prototype,"point",void 0),W=(0,a._)([(0,T.j)("esri.layers.support.VoxelDynamicSection")],W);const q=W;let k=class extends G.wq{constructor(){super(...arguments),this.enabled=!0,this.label="",this.normal=null,this.point=null}};(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],k.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],k.prototype,"label",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],k.prototype,"normal",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],k.prototype,"point",void 0),k=(0,a._)([(0,T.j)("esri.layers.support.VoxelSlice")],k);const Y=k;var Z=r(25929);let z=class extends G.wq{constructor(){super(...arguments),this.enabled=!0,this.href=null,this.id=null,this.label="",this.normal=null,this.point=null,this.sizeInPixel=null,this.slices=null,this.timeId=0,this.variableId=null}readHref(e,t,r){return(0,Z.f)(e,r)}};(0,a._)([(0,y.Cb)({type:Boolean,json:{default:!0,write:!0}})],z.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"href",void 0),(0,a._)([(0,S.r)(["service","web-scene"],"href")],z.prototype,"readHref",null),(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"id",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],z.prototype,"label",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"normal",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"point",void 0),(0,a._)([(0,y.Cb)({type:[E.z8],json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"sizeInPixel",void 0),(0,a._)([(0,y.Cb)({type:[Y],json:{write:!0}})],z.prototype,"slices",void 0),(0,a._)([(0,y.Cb)({type:E.z8,json:{default:0,write:!0}})],z.prototype,"timeId",void 0),(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],z.prototype,"variableId",void 0),z=(0,a._)([(0,T.j)("esri.layers.support.VoxelSection")],z);const X=z;var $=r(70921);let J=class extends G.wq{constructor(){super(...arguments),this.diffuseFactor=.5,this.specularFactor=.5}};(0,a._)([(0,y.Cb)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],J.prototype,"diffuseFactor",void 0),(0,a._)([(0,y.Cb)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],J.prototype,"specularFactor",void 0),J=(0,a._)([(0,T.j)("esri.layers.support.VoxelSimpleShading")],J);const K=J;var Q=r(22303);let ee=class extends G.wq{constructor(){super(...arguments),this.color=null,this.value=null,this.enabled=!0,this.label=null}};(0,a._)([(0,y.Cb)({type:Q.Z,json:{type:[E.z8],write:{enabled:!0,isRequired:!0}}})],ee.prototype,"color",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],ee.prototype,"value",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{default:!0,write:!0}})],ee.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],ee.prototype,"label",void 0),ee=(0,a._)([(0,T.j)("esri.layers.support.VoxelIsosurface")],ee);const te=ee;let re=class extends G.wq{constructor(){super(...arguments),this.alpha=0,this.position=0}};(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],re.prototype,"alpha",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],re.prototype,"position",void 0),re=(0,a._)([(0,T.j)("esri.layers.support.VoxelAlphaStop")],re);const ie=re;let se=class extends G.wq{constructor(){super(...arguments),this.color=null,this.position=0}};(0,a._)([(0,y.Cb)({type:Q.Z,json:{type:[E.z8],write:{enabled:!0,isRequired:!0}}})],se.prototype,"color",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],se.prototype,"position",void 0),se=(0,a._)([(0,T.j)("esri.layers.support.VoxelColorStop")],se);const ne=se;let oe=class extends G.wq{constructor(){super(...arguments),this.enabled=!1,this.range=null}};(0,a._)([(0,y.Cb)({type:Boolean,json:{default:!1,write:!0}})],oe.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],oe.prototype,"range",void 0),oe=(0,a._)([(0,T.j)("esri.layers.support.VoxelRangeFilter")],oe);const ae=oe;let le=class extends G.wq{constructor(e){super(e),this.interpolation=null,this.stretchRange=null,this.rangeFilter=null,this.colorStops=new l.Z,this.alphaStops=new l.Z}set colorStops(e){this._set("colorStops",(0,$.Z)(e,this._get("colorStops"),l.Z.ofType(ne)))}set alphaStops(e){this._set("alphaStops",(0,$.Z)(e,this._get("alphaStops"),l.Z.ofType(ie)))}};(0,a._)([(0,y.Cb)({type:["linear","nearest"],json:{write:!0}})],le.prototype,"interpolation",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],le.prototype,"stretchRange",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(ne),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.colorStops&&this.colorStops.length>0}}}}})],le.prototype,"colorStops",null),(0,a._)([(0,y.Cb)({type:l.Z.ofType(ie),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.alphaStops&&this.alphaStops.length>0}}}}})],le.prototype,"alphaStops",null),(0,a._)([(0,y.Cb)({type:ae,json:{write:!0}})],le.prototype,"rangeFilter",void 0),le=(0,a._)([(0,T.j)("esri.layers.support.VoxelTransferFunctionStyle")],le);const _e=le;let ue=class extends G.wq{constructor(){super(...arguments),this.color=null,this.value=0,this.enabled=!0,this.label=null}};(0,a._)([(0,y.Cb)({type:Q.Z,json:{type:[E.z8],write:{enabled:!0,isRequired:!0}}})],ue.prototype,"color",void 0),(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],ue.prototype,"value",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{default:!0,write:!0}})],ue.prototype,"enabled",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],ue.prototype,"label",void 0),ue=(0,a._)([(0,T.j)("esri.layers.support.VoxelUniqueValue")],ue);const de=ue;let ce=class extends G.wq{constructor(e){super(e),this.variableId=0,this.label=null,this.transferFunction=null,this.uniqueValues=new l.Z,this.isosurfaces=new l.Z}set uniqueValues(e){this._set("uniqueValues",(0,$.Z)(e,this._get("uniqueValues"),l.Z.ofType(de)))}set isosurfaces(e){this._set("isosurfaces",(0,$.Z)(e,this._get("isosurfaces"),l.Z.ofType(te)))}};(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],ce.prototype,"variableId",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],ce.prototype,"label",void 0),(0,a._)([(0,y.Cb)({type:_e,json:{write:{enabled:!0,overridePolicy(){return{enabled:!this.uniqueValues||this.uniqueValues.length<1}}}}})],ce.prototype,"transferFunction",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(de),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.uniqueValues&&this.uniqueValues.length>0}}}}})],ce.prototype,"uniqueValues",null),(0,a._)([(0,y.Cb)({type:l.Z.ofType(te),json:{write:{enabled:!0,overridePolicy(){const e=!this.uniqueValues||this.uniqueValues.length<1,t=!!this.isosurfaces&&this.isosurfaces.length>0;return{enabled:e&&t}}}}})],ce.prototype,"isosurfaces",null),ce=(0,a._)([(0,T.j)("esri.layers.support.VoxelVariableStyle")],ce);const pe=ce;let he=class extends G.wq{constructor(e){super(e),this.volumeId=0,this.verticalExaggeration=1,this.exaggerationMode="scale-height",this.verticalOffset=0,this.slices=new l.Z,this.dynamicSections=new l.Z}set slices(e){this._set("slices",(0,$.Z)(e,this._get("slices"),l.Z.ofType(Y)))}set dynamicSections(e){this._set("dynamicSections",(0,$.Z)(e,this._get("dynamicSections"),l.Z.ofType(q)))}};(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],he.prototype,"volumeId",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{default:1,write:!0}})],he.prototype,"verticalExaggeration",void 0),(0,a._)([(0,y.Cb)({type:["scale-position","scale-height"],json:{default:"scale-height",write:!0}})],he.prototype,"exaggerationMode",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{default:0,write:!0}})],he.prototype,"verticalOffset",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(Y),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.slices&&this.slices.length>0}}}}})],he.prototype,"slices",null),(0,a._)([(0,y.Cb)({type:l.Z.ofType(q),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.dynamicSections&&this.dynamicSections.length>0}}}}})],he.prototype,"dynamicSections",null),he=(0,a._)([(0,T.j)("esri.layers.support.VoxelVolumeStyle")],he);const ye=he;let Ee=class extends G.wq{constructor(e){super(e),this.currentVariableId=0,this.renderMode="volume",this.enableSlices=!0,this.enableSections=!0,this.enableDynamicSections=!0,this.enableIsosurfaces=!0,this.shading=new K,this.volumeStyles=new l.Z,this.variableStyles=new l.Z}set volumeStyles(e){this._set("volumeStyles",(0,$.Z)(e,this._get("volumeStyles"),l.Z.ofType(ye)))}set variableStyles(e){this._set("variableStyles",(0,$.Z)(e,this._get("variableStyles"),l.Z.ofType(pe)))}};(0,a._)([(0,y.Cb)({type:l.Z.ofType(ye),json:{write:!0}})],Ee.prototype,"volumeStyles",null),(0,a._)([(0,y.Cb)({type:E.z8,json:{write:{enabled:!0,isRequired:!0}}})],Ee.prototype,"currentVariableId",void 0),(0,a._)([(0,y.Cb)({type:["volume","surfaces"],json:{write:!0}})],Ee.prototype,"renderMode",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(pe),json:{write:!0}})],Ee.prototype,"variableStyles",null),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],Ee.prototype,"enableSlices",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],Ee.prototype,"enableSections",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],Ee.prototype,"enableDynamicSections",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],Ee.prototype,"enableIsosurfaces",void 0),(0,a._)([(0,y.Cb)({type:K,json:{write:!0}})],Ee.prototype,"shading",void 0),Ee=(0,a._)([(0,T.j)("esri.layers.support.VoxelStyle")],Ee);const Se=Ee;let Te=class extends G.wq{constructor(){super(...arguments),this.continuity=null,this.hasNoData=!1,this.noData=0,this.offset=0,this.scale=1,this.type=null}};(0,a._)([(0,y.Cb)({type:["discrete","continuous"],json:{write:!0}})],Te.prototype,"continuity",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],Te.prototype,"hasNoData",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Te.prototype,"noData",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Te.prototype,"offset",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Te.prototype,"scale",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Te.prototype,"type",void 0),Te=(0,a._)([(0,T.j)("esri.layers.support.VoxelFormat")],Te);const Ae=Te;let Re=class extends G.wq{constructor(){super(...arguments),this.id=null,this.description="",this.name=null,this.originalFormat=null,this.renderingFormat=null,this.unit="",this.volumeId=0,this.type=null}};(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],Re.prototype,"id",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],Re.prototype,"description",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Re.prototype,"name",void 0),(0,a._)([(0,y.Cb)({type:Ae,json:{write:!0}})],Re.prototype,"originalFormat",void 0),(0,a._)([(0,y.Cb)({type:Ae,json:{write:{enabled:!0,isRequired:!0}}})],Re.prototype,"renderingFormat",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],Re.prototype,"unit",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Re.prototype,"volumeId",void 0),(0,a._)([(0,y.Cb)({type:["stc-hot-spot-results","stc-cluster-outlier-results","stc-estimated-bin","generic-nearest-interpolated"],json:{write:!0}})],Re.prototype,"type",void 0),Re=(0,a._)([(0,T.j)("esri.layers.support.VoxelVariable")],Re);const ge=Re;let me=class extends G.wq{constructor(){super(...arguments),this.values=null}};(0,a._)([(0,y.Cb)({type:[Number],json:{write:!0}})],me.prototype,"values",void 0),me=(0,a._)([(0,T.j)("esri.layers.support.VoxelIrregularSpacing")],me);const be=me;let Ce=class extends G.wq{constructor(){super(...arguments),this.scale=1,this.offset=0}};(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Ce.prototype,"scale",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],Ce.prototype,"offset",void 0),Ce=(0,a._)([(0,T.j)("esri.layers.support.VoxelRegularSpacing")],Ce);const ve=Ce;let fe=class extends G.wq{constructor(){super(...arguments),this.irregularSpacing=null,this.isPositiveUp=null,this.isWrappedDateLine=null,this.label=null,this.name=null,this.quantity=null,this.regularSpacing=null,this.size=0,this.unit=null}};(0,a._)([(0,y.Cb)({type:be,json:{write:!0}})],fe.prototype,"irregularSpacing",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],fe.prototype,"isPositiveUp",void 0),(0,a._)([(0,y.Cb)({type:Boolean,json:{write:!0}})],fe.prototype,"isWrappedDateLine",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],fe.prototype,"label",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],fe.prototype,"name",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],fe.prototype,"quantity",void 0),(0,a._)([(0,y.Cb)({type:ve,json:{write:!0}})],fe.prototype,"regularSpacing",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:!0}})],fe.prototype,"size",void 0),(0,a._)([(0,y.Cb)({type:String,json:{write:!0}})],fe.prototype,"unit",void 0),fe=(0,a._)([(0,T.j)("esri.layers.support.VoxelDimension")],fe);const Ne=fe;let Le=class extends G.wq{constructor(){super(...arguments),this.id=0,this.dimensions=null}getZDimension(){if(!this.dimensions)return-1;if(!Array.isArray(this.dimensions))return-1;if(4!==this.dimensions.length)return-1;for(let e=2;e<4;++e)if(this.dimensions[e].size>0)return e;return-1}isVolumeValid(){return!!this.dimensions&&!!Array.isArray(this.dimensions)&&4===this.dimensions.length&&!(this.dimensions[0].size<1||this.dimensions[1].size<1)&&-1!==this.getZDimension()}};(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],Le.prototype,"id",void 0),(0,a._)([(0,y.Cb)({type:[Ne],json:{write:{enabled:!0,isRequired:!0}}})],Le.prototype,"dimensions",void 0),Le=(0,a._)([(0,T.j)("esri.layers.support.VoxelVolume")],Le);const we=Le;var Ie;let Oe=Ie=class extends G.wq{constructor(){super(...arguments),this.apronWidth=1,this.brickSize=[32,32,32],this.maxLodLevel=0,this.nodeSize=[4,4,4]}isValid(){const e=new Ie;return e.apronWidth===this.apronWidth&&e.maxLodLevel===this.maxLodLevel&&!!this.brickSize&&!!this.nodeSize&&!(!Array.isArray(this.brickSize)||!Array.isArray(this.nodeSize))&&3===this.brickSize.length&&3===this.nodeSize.length&&32===this.brickSize[0]&&32===this.brickSize[1]&&32===this.brickSize[2]&&4===this.nodeSize[0]&&4===this.nodeSize[1]&&4===this.nodeSize[2]}};(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],Oe.prototype,"apronWidth",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],Oe.prototype,"brickSize",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],Oe.prototype,"maxLodLevel",void 0),(0,a._)([(0,y.Cb)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],Oe.prototype,"nodeSize",void 0),Oe=Ie=(0,a._)([(0,T.j)("esri.layers.support.VoxelVolumeIndex")],Oe);const Me=Oe,xe=u.Z.getLogger(" esri.layers.VoxelLayer");var Pe;!function(e){e[e.API=1]="API",e[e.VerboseAPI=2]="VerboseAPI",e[e.Error=3]="Error"}(Pe||(Pe={}));let De=class extends((0,B.Vt)((0,D.Y)((0,U.q)((0,F.I)((0,V.M)((0,c.R)((0,P.V)(g.Z)))))))){constructor(e){super(e),this.serviceRoot="",this.popupEnabled=!0,this.operationalLayerType="Voxel",this.legendEnabled=!0,this.title=null,this.sections=new l.Z,this.style=null,this.opacity=1,this.variables=new l.Z,this.volumes=new l.Z,this.index=null,this.minScale=0,this.maxScale=0,this.type="voxel",this._dbgFlags=new Set,this._handles=new _.Z,this.version={major:Number.NaN,minor:Number.NaN,versionString:""}}set url(e){this._set("url",(0,j.Nm)(e,xe))}destroy(){this._handles=(0,d.SC)(this._handles)}_dbg(e,t){this._dbgFlags.has(e)&&(e===Pe.Error?xe.error(t):xe.warn(t))}load(e){const t=(0,d.pC)(e)?e.signal:null,r=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(p.r9).then((()=>this._fetchService(t))).then((()=>this.serviceRoot=this.url));return this.addResolvingPromise(r),Promise.resolve(this)}getConfiguration(){this._handles.add([(0,h.YP)((()=>this._getRenderMode()),(e=>this._pushRenderModeToWasm(e))),(0,h.YP)((()=>this._getCurrentVariableId()),(e=>this._pushCurrentVariableIdToWasm(e))),(0,h.YP)((()=>this._getDynamicSections()),(e=>this._pushDynamicSectionsToWasm(e))),(0,h.YP)((()=>this._getSlices()),(e=>this._pushSlicesToWasm(e))),(0,h.YP)((()=>this._getSections()),(e=>this._pushSectionsToWasm(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,t){return super.parseVersionString(e)}_getSections(){const e=[];for(const t of this.sections)e.push(new X({enabled:t.enabled,href:t.href,id:t.id,label:t.label,normal:t.normal,point:t.point,sizeInPixel:t.sizeInPixel,slices:t.slices,timeId:t.timeId,variableId:t.variableId}));return e}_pushSectionsToWasm(e){this._dbg(Pe.VerboseAPI,"VoxelLayer._pushSectionsToWasm() called"),x.getInstance().setLayerStaticSections(this,e)||this._dbg(Pe.Error,"VoxelLayer._pushSectionsToWasm() failed!")}_isPlaneValid(e,t,r){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 i=0;i<3;++i){const s=e.point[i];if(s<0||s>=r[t[i]].size)return!1}const i=(0,R.f)(e.normal[0],e.normal[1],e.normal[2]);return(0,A.n)(i,i),!(Math.abs(i[0])+Math.abs(i[1])+Math.abs(i[2])<1e-6||(e.normal[0]=i[0],e.normal[1]=i[1],e.normal[2]=i[2],0))}getVariableStyle(e){let t=-1;if(t=(0,d.pC)(e)?e:this._getCurrentVariableId(),!(null==this?void 0:this.style.variableStyles)||-1===t)return null;const r=this.style.variableStyles.findIndex((e=>e.variableId===t));return r<0?null:this.style.variableStyles.getItemAt(r)}getVariable(e){let t=-1;if(t=(0,d.pC)(e)?e:this._getCurrentVariableId(),!this.variables||-1===t)return null;const r=this.variables.findIndex((e=>e.id===t));return r<0?null:this.variables.getItemAt(r)}_getVolume(e){const t=this.getVariable(e);return(0,d.pC)(t)?this.volumes.find((({id:e})=>e===t.volumeId)):null}_getVolumeStyle(e){const t=this.getVariable(e);return(0,d.pC)(t)?this.style.volumeStyles.find((({volumeId:e})=>e===t.volumeId)):null}_getSlices(){const e=[],t=this._getVolume(null);if(!(0,d.pC)(t)||!t.isVolumeValid())return e;const r=this._getVolumeStyle(null);if(!(0,d.pC)(r))return e;for(const i of r.slices)this._isPlaneValid(i,[0,1,t.getZDimension()],t.dimensions)?e.push(new Y({enabled:i.enabled,label:i.label,point:i.point,normal:i.normal})):e.push(new Y({enabled:!1,label:"invalid",point:i.point,normal:i.normal}));return e}_pushSlicesToWasm(e){this._dbg(Pe.VerboseAPI,"VoxelLayer._pushSlicesToWasm() called!"),x.getInstance().setLayerSlices(this,e)||this._dbg(Pe.Error,"VoxelLayer._pushSlicesToWasm() failed!")}_getDynamicSections(){const e=[],t=this._getVolume(null);if(!(0,d.pC)(t)||!t.isVolumeValid())return e;const r=this._getVolumeStyle(null);if(!(0,d.pC)(r))return e;for(const i of r.dynamicSections)this._isPlaneValid(i,[0,1,t.getZDimension()],t.dimensions)?e.push(new q({enabled:i.enabled,label:i.label,point:i.point,normal:i.normal})):e.push(new q({enabled:!1,label:"invalid",point:i.point,normal:i.normal}));return e}_pushDynamicSectionsToWasm(e){this._dbg(Pe.VerboseAPI,"VoxelLayer._pushDynamicSectionsToWasm() called!"),x.getInstance().setLayerDynamicSections(this,e)||this._dbg(Pe.Error,"VoxelLayer._updateDynamicSections() failed!")}_getCurrentVariableId(){return this.style?this.style.currentVariableId:-1}_pushCurrentVariableIdToWasm(e){this._dbg(Pe.VerboseAPI,"VoxelLayer._pushCurrentVariableIdToWasm() called!"),x.getInstance().setLayerCurrentVariable(this,e)||this._dbg(Pe.Error,"VoxelLayer._pushCurrentVariableIdToWasm() failed!")}_getRenderMode(){return this.style?this.style.renderMode:"volume"}_pushRenderModeToWasm(e){this._dbg(Pe.VerboseAPI,"VoxelLayer._pushRenderModeToWasm() called!"),x.getInstance().setLayerRenderMode(this,e)||this._dbg(Pe.Error,"VoxelLayer.setLayerRenderMode() failed!")}};(0,a._)([(0,y.Cb)(H.C_)],De.prototype,"popupEnabled",void 0),(0,a._)([(0,y.Cb)({type:["Voxel"]})],De.prototype,"operationalLayerType",void 0),(0,a._)([(0,y.Cb)(H.rn)],De.prototype,"legendEnabled",void 0),(0,a._)([(0,y.Cb)({json:{write:!0}})],De.prototype,"title",void 0),(0,a._)([(0,y.Cb)(H.HQ)],De.prototype,"url",null),(0,a._)([(0,y.Cb)({type:l.Z.ofType(X),json:{write:!0,origins:{"web-scene":{name:"layerDefinition.sections",write:!0},service:{write:!1}}}})],De.prototype,"sections",void 0),(0,a._)([(0,y.Cb)({type:Se,json:{write:!0,origins:{"web-scene":{name:"layerDefinition.style",write:!0},service:{write:!1}}}})],De.prototype,"style",void 0),(0,a._)([(0,y.Cb)({type:["show","hide"]})],De.prototype,"listMode",void 0),(0,a._)([(0,y.Cb)({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}}}})],De.prototype,"opacity",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(ge)})],De.prototype,"variables",void 0),(0,a._)([(0,y.Cb)({type:l.Z.ofType(we)})],De.prototype,"volumes",void 0),(0,a._)([(0,y.Cb)({type:Me})],De.prototype,"index",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{name:"layerDefinition.minScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],De.prototype,"minScale",void 0),(0,a._)([(0,y.Cb)({type:Number,json:{name:"layerDefinition.maxScale",read:!1,write:!1,origins:{service:{read:!1,write:!1}}}})],De.prototype,"maxScale",void 0),(0,a._)([(0,y.Cb)({json:{read:!1},readOnly:!0})],De.prototype,"type",void 0),(0,a._)([(0,y.Cb)({readOnly:!0,json:{name:"serviceVersion"}})],De.prototype,"version",void 0),(0,a._)([(0,S.r)("service","version")],De.prototype,"readVersion",null),De=(0,a._)([(0,T.j)("esri.layers.VoxelLayer")],De);const Ue=De},38009:(e,t,r)=>{r.d(t,{q:()=>p});var i=r(43697),s=r(20102),n=r(17452),o=r(5600),a=(r(67676),r(80442),r(75215),r(52011)),l=r(30556),_=r(50549),u=r(76169);const d={"web-scene/operational-layers":{ArcGISFeatureLayer:!0,ArcGISImageServiceLayer:!0,ArcGISMapServiceLayer:!0,ArcGISSceneServiceLayer:!0,ArcGISTiledElevationServiceLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,BuildingSceneLayer:!0,GroupLayer:!0,IntegratedMeshLayer:!0,OGCFeatureLayer:!0,PointCloudLayer:!0,WebTiledLayer:!0,CSV:!0,GeoJSON:!0,VectorTileLayer:!0,WFS:!0,WMS:!0,KML:!0,RasterDataLayer:!0,Voxel:!0},"web-scene/basemap":{ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,WebTiledLayer:!0,OpenStreetMap:!0,VectorTileLayer:!0,ArcGISImageServiceLayer:!0,WMS:!0,ArcGISMapServiceLayer:!0},"web-scene/ground":{ArcGISTiledElevationServiceLayer:!0,RasterDataElevationLayer:!0},"web-map/operational-layers":{ArcGISFeatureLayer:!0,ArcGISImageServiceLayer:!0,ArcGISImageServiceVectorLayer:!0,ArcGISMapServiceLayer:!0,ArcGISStreamLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,BingMapsAerial:!0,BingMapsHybrid:!0,BingMapsRoad:!0,CSV:!0,GeoRSS:!0,GeoJSON:!0,GroupLayer:!0,KML:!0,OGCFeatureLayer:!0,SubtypeGroupLayer:!0,VectorTileLayer:!0,WFS:!0,WMS:!0,WebTiledLayer:!0},"web-map/basemap":{ArcGISImageServiceLayer:!0,ArcGISImageServiceVectorLayer:!0,ArcGISMapServiceLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,OpenStreetMap:!0,VectorTileLayer:!0,WMS:!0,WebTiledLayer:!0,BingMapsAerial:!0,BingMapsRoad:!0,BingMapsHybrid:!0},"web-map/tables":{ArcGISFeatureLayer:!0},"portal-item/operational-layers":{ArcGISSceneServiceLayer:!0,PointCloudLayer:!0,BuildingSceneLayer:!0,IntegratedMeshLayer:!0}};var c=r(21506);const p=e=>{let t=class extends e{constructor(){super(...arguments),this.title=null}writeListMode(e,t,r,i){(i&&"ground"===i.layerContainerType||e&&(0,u.df)(this,r,{},i))&&(t[r]=e)}writeOperationalLayerType(e,t,r,i){!e||i&&"tables"===i.layerContainerType||(t.layerType=e)}writeTitle(e,t){t.title=e||"Layer"}read(e,t){t&&(t.layer=this),(0,_.$Z)(this,e,(t=>super.read(e,t)),t)}write(e,t){if(null!=t&&t.origin){const e=`${t.origin}/${t.layerContainerType||"operational-layers"}`,i=d[e];let n=i&&i[this.operationalLayerType];var r;if("ArcGISTiledElevationServiceLayer"===this.operationalLayerType&&"web-scene/operational-layers"===e&&(n=!1),!n)return null==(r=t.messages)||r.push(new s.Z("layer:unsupported",`Layers (${this.title}, ${this.id}) of type '${this.declaredClass}' are not supported in the context of '${e}'`,{layer:this})),null}const i=super.write(e,{...t,layer:this}),o=!!t&&!!t.messages&&!!t.messages.filter((e=>e instanceof s.Z&&"web-document-write:property-required"===e.name)).length;var a;return(0,n.jc)(null==i?void 0:i.url)?(null==t||null==(a=t.messages)||a.push(new s.Z("layer:invalid-url",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' using a Blob URL cannot be written to web scenes and web maps`,{layer:this})),null):!this.url&&o?null:i}beforeSave(){}};return(0,i._)([(0,o.Cb)({type:String,json:{write:{ignoreOrigin:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0}},"portal-item":{write:!1}}}})],t.prototype,"id",void 0),(0,i._)([(0,o.Cb)({json:{write:{ignoreOrigin:!0},origins:{"web-map":{read:!1,write:!1}}}})],t.prototype,"listMode",void 0),(0,i._)([(0,l.c)("listMode")],t.prototype,"writeListMode",null),(0,i._)([(0,o.Cb)({type:String,readOnly:!0,json:{read:!1,write:{target:"layerType",ignoreOrigin:!0},origins:{"portal-item":{write:!1}}}})],t.prototype,"operationalLayerType",void 0),(0,i._)([(0,l.c)("operationalLayerType")],t.prototype,"writeOperationalLayerType",null),(0,i._)([(0,o.Cb)(c.Oh)],t.prototype,"opacity",void 0),(0,i._)([(0,o.Cb)({type:String,json:{write:{ignoreOrigin:!0,writerEnsuresNonNull:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}},"portal-item":{write:!1}}},value:"Layer"})],t.prototype,"title",void 0),(0,i._)([(0,l.c)("title")],t.prototype,"writeTitle",null),(0,i._)([(0,o.Cb)({type:Boolean,json:{name:"visibility"}})],t.prototype,"visible",void 0),t=(0,i._)([(0,a.j)("esri.layers.mixins.OperationalLayer")],t),t}},72965:(e,t,r)=>{r.d(t,{M:()=>o});var i=r(43697),s=r(5600),n=(r(67676),r(80442),r(75215),r(52011));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;t&&"effectiveScaleRange"in t&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const r=this._get("effectiveScaleRange");return r&&r.minScale===e.minScale&&r.maxScale===e.maxScale?r:e}};return(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"minScale",void 0),(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"maxScale",void 0),(0,i._)([(0,s.Cb)({readOnly:!0})],t.prototype,"effectiveScaleRange",null),t=(0,i._)([(0,n.j)("esri.layers.mixins.ScaleRangeLayer")],t),t}},21506:(e,t,r)=>{r.d(t,{qG:()=>R,PV:()=>E,id:()=>m,iR:()=>p,rn:()=>y,u1:()=>C,rO:()=>b,Oh:()=>T,bT:()=>A,C_:()=>c,Lx:()=>S,vg:()=>g,YI:()=>d,HQ:()=>h});var i=r(92835),s=r(6570),n=r(82971),o=r(25929),a=r(70586),l=(r(95330),r(35463)),_=r(20682),u=r(65242);const d={type:Boolean,value:!0,json:{origins:{service:{read:!1,write:!1},"web-map":{read:!1,write:!1}},name:"screenSizePerspective",write:!0}},c={type:Boolean,value:!0,json:{name:"disablePopup",read:{reader:(e,t)=>!t.disablePopup},write:{enabled:!0,writer(e,t,r){t[r]=!e}}}},p={type:Boolean,value:!0,json:{name:"showLabels",write:!0}},h={type:String,json:{origins:{"portal-item":{write:!1}},write:{isRequired:!0,ignoreOrigin:!0,writer:o.w}}},y={type:Boolean,value:!0,json:{origins:{service:{read:{enabled:!1}}},name:"showLegend",write:!0}},E={value:null,type:_.Z,json:{origins:{service:{name:"elevationInfo",write:!0}},name:"layerDefinition.elevationInfo",write:!0}};function S(e){return{type:e,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}}}const T={type:Number,json:{origins:{"web-document":{write:!0,read:!0},"portal-item":{write:!0}}}},A={...T,json:{...T.json,origins:{"web-document":{...T.json.origins["web-document"],write:{enabled:!0,target:{opacity:{type:Number},"layerDefinition.drawingInfo.transparency":{type:Number}}}}},read:{source:["layerDefinition.drawingInfo.transparency","drawingInfo.transparency"],reader:(e,t,r)=>r&&"service"!==r.origin||!t.drawingInfo||void 0===t.drawingInfo.transparency?t.layerDefinition&&t.layerDefinition.drawingInfo&&void 0!==t.layerDefinition.drawingInfo.transparency?(0,u.b)(t.layerDefinition.drawingInfo.transparency):void 0:(0,u.b)(t.drawingInfo.transparency)}}},R={type:i.Z,readOnly:!0,get(){var e,t;if(null==(e=this.layer)||!e.timeInfo)return null;const{datesInUnknownTimezone:r,timeOffset:s,useViewTime:n}=this.layer,o=null==(t=this.view)?void 0:t.timeExtent;let _=this.layer.timeExtent;r&&(_=function(e){if(!e)return e;const{start:t,end:r}=e;return new i.Z({start:(0,a.pC)(t)?(0,l.Nm)(t,t.getTimezoneOffset(),"minutes"):t,end:(0,a.pC)(r)?(0,l.Nm)(r,r.getTimezoneOffset(),"minutes"):r})}(_));let u=n?o&&_?o.intersection(_):o||_:_;if(!u||u.isEmpty||u.isAllTime)return u;s&&(u=u.offset(-s.value,s.unit)),r&&(u=function(e){if(!e)return e;const{start:t,end:r}=e;return new i.Z({start:(0,a.pC)(t)?(0,l.Nm)(t,-t.getTimezoneOffset(),"minutes"):t,end:(0,a.pC)(r)?(0,l.Nm)(r,-r.getTimezoneOffset(),"minutes"):r})}(u));const d=this._get("timeExtent");return u.equals(d)?d:u}},g={type:s.Z,readOnly:!0,json:{origins:{service:{read:{source:["fullExtent","spatialReference"],reader:(e,t)=>{const r=s.Z.fromJSON(e);return null!=t.spatialReference&&"object"==typeof t.spatialReference&&(r.spatialReference=n.Z.fromJSON(t.spatialReference)),r}}}},read:!1}},m={type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}}}},b={type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.minScale"},write:{target:"layerDefinition.minScale"}}},C={type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.maxScale"},write:{target:"layerDefinition.maxScale"}}}},20682:(e,t,r)=>{r.d(t,{Z:()=>g});var i,s=r(43697),n=r(35454),o=r(96674),a=r(70586),l=r(5600),_=(r(67676),r(80442),r(75215),r(71715)),u=r(52011),d=r(30556),c=r(35671);let p=i=class extends o.wq{async collectRequiredFields(e,t){return(0,c.io)(e,t,this.expression)}clone(){return new i({expression:this.expression,title:this.title})}};(0,s._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"expression",void 0),(0,s._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"title",void 0),p=i=(0,s._)([(0,u.j)("esri.layers.support.FeatureExpressionInfo")],p);const h=p;var y=r(99282);const E=function(){const e=Object.keys(y.a);return e.sort(),e}();var S;const T=(0,n.wY)()({onTheGround:"on-the-ground",relativeToGround:"relative-to-ground",relativeToScene:"relative-to-scene",absoluteHeight:"absolute-height"}),A=new n.Xn({foot:"feet",kilometer:"kilometers",meter:"meters",mile:"miles","us-foot":"us-feet",yard:"yards"});let R=S=class extends o.wq{constructor(){super(...arguments),this.offset=null}readFeatureExpressionInfo(e,t){return null!=e?e:t.featureExpression&&0===t.featureExpression.value?{expression:"0"}:void 0}writeFeatureExpressionInfo(e,t,r,i){t[r]=e.write({},i),"0"===e.expression&&(t.featureExpression={value:0})}get mode(){const{offset:e,featureExpressionInfo:t}=this;return this._isOverridden("mode")?this._get("mode"):(0,a.pC)(e)||t?"relative-to-ground":"on-the-ground"}set mode(e){this._override("mode",e)}set unit(e){this._set("unit",e)}write(e,t){return this.offset||this.mode||this.featureExpressionInfo||this.unit?super.write(e,t):null}clone(){return new S({mode:this.mode,offset:this.offset,featureExpressionInfo:this.featureExpressionInfo?this.featureExpressionInfo.clone():void 0,unit:this.unit})}};(0,s._)([(0,l.Cb)({type:h,json:{write:!0}})],R.prototype,"featureExpressionInfo",void 0),(0,s._)([(0,_.r)("featureExpressionInfo",["featureExpressionInfo","featureExpression"])],R.prototype,"readFeatureExpressionInfo",null),(0,s._)([(0,d.c)("featureExpressionInfo",{featureExpressionInfo:{type:h},"featureExpression.value":{type:[0]}})],R.prototype,"writeFeatureExpressionInfo",null),(0,s._)([(0,l.Cb)({type:T.apiValues,nonNullable:!0,json:{type:T.jsonValues,read:T.read,write:{writer:T.write,isRequired:!0}}})],R.prototype,"mode",null),(0,s._)([(0,l.Cb)({type:Number,json:{write:!0}})],R.prototype,"offset",void 0),(0,s._)([(0,l.Cb)({type:E,json:{type:String,read:A.read,write:A.write}})],R.prototype,"unit",null),R=S=(0,s._)([(0,u.j)("esri.layers.support.ElevationInfo")],R);const g=R},50173:(e,t,r)=>{var i;r.d(t,{C:()=>i}),function(e){e[e.MATERIAL=0]="MATERIAL",e[e.MATERIAL_ALPHA=1]="MATERIAL_ALPHA",e[e.MATERIAL_DEPTH=2]="MATERIAL_DEPTH",e[e.MATERIAL_NORMAL=3]="MATERIAL_NORMAL",e[e.MATERIAL_DEPTH_SHADOWMAP_ALL=4]="MATERIAL_DEPTH_SHADOWMAP_ALL",e[e.MATERIAL_HIGHLIGHT=5]="MATERIAL_HIGHLIGHT",e[e.MATERIAL_DEPTH_SHADOWMAP_DEFAULT=6]="MATERIAL_DEPTH_SHADOWMAP_DEFAULT",e[e.MATERIAL_DEPTH_SHADOWMAP_HIGHLIGHT=7]="MATERIAL_DEPTH_SHADOWMAP_HIGHLIGHT",e[e.MAX_PASS=8]="MAX_PASS"}(i||(i={}))},97995:(e,t,r)=>{var i;r.d(t,{r:()=>i}),function(e){e[e.INTEGRATED_MESH=0]="INTEGRATED_MESH",e[e.OPAQUE_TERRAIN=1]="OPAQUE_TERRAIN",e[e.OPAQUE_MATERIAL=2]="OPAQUE_MATERIAL",e[e.OPAQUE_PLUGIN=3]="OPAQUE_PLUGIN",e[e.TRANSPARENT_MATERIAL=4]="TRANSPARENT_MATERIAL",e[e.TRANSPARENT_PLUGIN=5]="TRANSPARENT_PLUGIN",e[e.TRANSPARENT_TERRAIN=6]="TRANSPARENT_TERRAIN",e[e.TRANSPARENT_DEPTH_WRITE_DISABLED_MATERIAL=7]="TRANSPARENT_DEPTH_WRITE_DISABLED_MATERIAL",e[e.OCCLUDED_TERRAIN=8]="OCCLUDED_TERRAIN",e[e.OCCLUDER_MATERIAL=9]="OCCLUDER_MATERIAL",e[e.TRANSPARENT_OCCLUDER_MATERIAL=10]="TRANSPARENT_OCCLUDER_MATERIAL",e[e.OCCLUSION_PIXELS=11]="OCCLUSION_PIXELS",e[e.POSTPROCESSING_ENVIRONMENT_OPAQUE=12]="POSTPROCESSING_ENVIRONMENT_OPAQUE",e[e.POSTPROCESSING_ENVIRONMENT_TRANSPARENT=13]="POSTPROCESSING_ENVIRONMENT_TRANSPARENT",e[e.LASERLINES=14]="LASERLINES",e[e.LASERLINES_CONTRAST_CONTROL=15]="LASERLINES_CONTRAST_CONTROL",e[e.HUD_MATERIAL=16]="HUD_MATERIAL",e[e.LABEL_MATERIAL=17]="LABEL_MATERIAL",e[e.LINE_CALLOUTS=18]="LINE_CALLOUTS",e[e.LINE_CALLOUTS_HUD_DEPTH=19]="LINE_CALLOUTS_HUD_DEPTH",e[e.DRAPED_MATERIAL=20]="DRAPED_MATERIAL",e[e.DRAPED_WATER=21]="DRAPED_WATER",e[e.VOXEL=22]="VOXEL",e[e.MAX_SLOTS=23]="MAX_SLOTS"}(i||(i={}))},54738:(e,t,r)=>{var i,s;function n(e,t,r={}){const s=t===i.WEBGL1?["webgl","experimental-webgl","webkit-3d","moz-webgl"]:["webgl2"];let n=null;for(const t of s){try{n=e.getContext(t,r)}catch(e){}if(n)break}return n}r.d(t,{zO:()=>i,kr:()=>n}),r(80442),(s=i||(i={}))[s.WEBGL1=1]="WEBGL1",s[s.WEBGL2=2]="WEBGL2"},35371:(e,t,r)=>{var i,s,n,o,a,l,_,u,d,c,p,h,y,E,S,T,A,R,g,m,b,C,v;r.d(t,{zi:()=>n,db:()=>o,w0:()=>a,VY:()=>v,wb:()=>d,q_:()=>N,Wf:()=>_,g:()=>u,Lu:()=>f,OU:()=>b,LR:()=>l,VI:()=>E,Br:()=>S,MX:()=>s,Tg:()=>T,_g:()=>C,xS:()=>c,Lm:()=>m,cw:()=>p,No:()=>y,e8:()=>h,l1:()=>A}),function(e){e[e.DEPTH_BUFFER_BIT=256]="DEPTH_BUFFER_BIT",e[e.STENCIL_BUFFER_BIT=1024]="STENCIL_BUFFER_BIT",e[e.COLOR_BUFFER_BIT=16384]="COLOR_BUFFER_BIT"}(i||(i={})),function(e){e[e.POINTS=0]="POINTS",e[e.LINES=1]="LINES",e[e.LINE_LOOP=2]="LINE_LOOP",e[e.LINE_STRIP=3]="LINE_STRIP",e[e.TRIANGLES=4]="TRIANGLES",e[e.TRIANGLE_STRIP=5]="TRIANGLE_STRIP",e[e.TRIANGLE_FAN=6]="TRIANGLE_FAN"}(s||(s={})),function(e){e[e.ZERO=0]="ZERO",e[e.ONE=1]="ONE",e[e.SRC_COLOR=768]="SRC_COLOR",e[e.ONE_MINUS_SRC_COLOR=769]="ONE_MINUS_SRC_COLOR",e[e.SRC_ALPHA=770]="SRC_ALPHA",e[e.ONE_MINUS_SRC_ALPHA=771]="ONE_MINUS_SRC_ALPHA",e[e.DST_ALPHA=772]="DST_ALPHA",e[e.ONE_MINUS_DST_ALPHA=773]="ONE_MINUS_DST_ALPHA",e[e.DST_COLOR=774]="DST_COLOR",e[e.ONE_MINUS_DST_COLOR=775]="ONE_MINUS_DST_COLOR",e[e.SRC_ALPHA_SATURATE=776]="SRC_ALPHA_SATURATE",e[e.CONSTANT_COLOR=32769]="CONSTANT_COLOR",e[e.ONE_MINUS_CONSTANT_COLOR=32770]="ONE_MINUS_CONSTANT_COLOR",e[e.CONSTANT_ALPHA=32771]="CONSTANT_ALPHA",e[e.ONE_MINUS_CONSTANT_ALPHA=32772]="ONE_MINUS_CONSTANT_ALPHA"}(n||(n={})),function(e){e[e.ADD=32774]="ADD",e[e.SUBTRACT=32778]="SUBTRACT",e[e.REVERSE_SUBTRACT=32779]="REVERSE_SUBTRACT"}(o||(o={})),function(e){e[e.ARRAY_BUFFER=34962]="ARRAY_BUFFER",e[e.ELEMENT_ARRAY_BUFFER=34963]="ELEMENT_ARRAY_BUFFER",e[e.UNIFORM_BUFFER=35345]="UNIFORM_BUFFER",e[e.PIXEL_PACK_BUFFER=35051]="PIXEL_PACK_BUFFER",e[e.PIXEL_UNPACK_BUFFER=35052]="PIXEL_UNPACK_BUFFER",e[e.COPY_READ_BUFFER=36662]="COPY_READ_BUFFER",e[e.COPY_WRITE_BUFFER=36663]="COPY_WRITE_BUFFER"}(a||(a={})),function(e){e[e.FRONT=1028]="FRONT",e[e.BACK=1029]="BACK",e[e.FRONT_AND_BACK=1032]="FRONT_AND_BACK"}(l||(l={})),function(e){e[e.CW=2304]="CW",e[e.CCW=2305]="CCW"}(_||(_={})),function(e){e[e.BYTE=5120]="BYTE",e[e.UNSIGNED_BYTE=5121]="UNSIGNED_BYTE",e[e.SHORT=5122]="SHORT",e[e.UNSIGNED_SHORT=5123]="UNSIGNED_SHORT",e[e.INT=5124]="INT",e[e.UNSIGNED_INT=5125]="UNSIGNED_INT",e[e.FLOAT=5126]="FLOAT"}(u||(u={})),function(e){e[e.NEVER=512]="NEVER",e[e.LESS=513]="LESS",e[e.EQUAL=514]="EQUAL",e[e.LEQUAL=515]="LEQUAL",e[e.GREATER=516]="GREATER",e[e.NOTEQUAL=517]="NOTEQUAL",e[e.GEQUAL=518]="GEQUAL",e[e.ALWAYS=519]="ALWAYS"}(d||(d={})),function(e){e[e.ZERO=0]="ZERO",e[e.KEEP=7680]="KEEP",e[e.REPLACE=7681]="REPLACE",e[e.INCR=7682]="INCR",e[e.DECR=7683]="DECR",e[e.INVERT=5386]="INVERT",e[e.INCR_WRAP=34055]="INCR_WRAP",e[e.DECR_WRAP=34056]="DECR_WRAP"}(c||(c={})),function(e){e[e.NEAREST=9728]="NEAREST",e[e.LINEAR=9729]="LINEAR",e[e.NEAREST_MIPMAP_NEAREST=9984]="NEAREST_MIPMAP_NEAREST",e[e.LINEAR_MIPMAP_NEAREST=9985]="LINEAR_MIPMAP_NEAREST",e[e.NEAREST_MIPMAP_LINEAR=9986]="NEAREST_MIPMAP_LINEAR",e[e.LINEAR_MIPMAP_LINEAR=9987]="LINEAR_MIPMAP_LINEAR"}(p||(p={})),function(e){e[e.CLAMP_TO_EDGE=33071]="CLAMP_TO_EDGE",e[e.REPEAT=10497]="REPEAT",e[e.MIRRORED_REPEAT=33648]="MIRRORED_REPEAT"}(h||(h={})),function(e){e[e.TEXTURE_2D=3553]="TEXTURE_2D",e[e.TEXTURE_CUBE_MAP=34067]="TEXTURE_CUBE_MAP",e[e.TEXTURE_3D=32879]="TEXTURE_3D",e[e.TEXTURE_CUBE_MAP_POSITIVE_X=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",e[e.TEXTURE_CUBE_MAP_NEGATIVE_X=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",e[e.TEXTURE_CUBE_MAP_POSITIVE_Y=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Y=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",e[e.TEXTURE_CUBE_MAP_POSITIVE_Z=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Z=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(y||(y={})),function(e){e[e.DEPTH_COMPONENT=6402]="DEPTH_COMPONENT",e[e.ALPHA=6406]="ALPHA",e[e.RGB=6407]="RGB",e[e.RGBA=6408]="RGBA",e[e.LUMINANCE=6409]="LUMINANCE",e[e.LUMINANCE_ALPHA=6410]="LUMINANCE_ALPHA",e[e.RGBA4=32854]="RGBA4",e[e.DEPTH_STENCIL=34041]="DEPTH_STENCIL",e[e.R16F=33325]="R16F",e[e.RG16F=33327]="RG16F",e[e.RGB32F=34837]="RGB32F",e[e.RGBA16F=34842]="RGBA16F",e[e.R32F=33326]="R32F",e[e.RG32F=33328]="RG32F",e[e.RGBA32F=34836]="RGBA32F",e[e.R11F_G11F_B10F=35898]="R11F_G11F_B10F"}(E||(E={})),function(e){e[e.FLOAT=5126]="FLOAT",e[e.UNSIGNED_BYTE=5121]="UNSIGNED_BYTE",e[e.UNSIGNED_INT_24_8=34042]="UNSIGNED_INT_24_8",e[e.UNSIGNED_SHORT_4_4_4_4=32819]="UNSIGNED_SHORT_4_4_4_4",e[e.UNSIGNED_SHORT_5_5_5_1=32820]="UNSIGNED_SHORT_5_5_5_1",e[e.UNSIGNED_SHORT_5_6_5=33635]="UNSIGNED_SHORT_5_6_5"}(S||(S={})),function(e){e[e.DEPTH_COMPONENT16=33189]="DEPTH_COMPONENT16",e[e.STENCIL_INDEX8=36168]="STENCIL_INDEX8",e[e.DEPTH_STENCIL=34041]="DEPTH_STENCIL",e[e.RGBA4=32854]="RGBA4"}(T||(T={})),function(e){e[e.STATIC_DRAW=35044]="STATIC_DRAW",e[e.DYNAMIC_DRAW=35048]="DYNAMIC_DRAW",e[e.STREAM_DRAW=35040]="STREAM_DRAW",e[e.STATIC_READ=35045]="STATIC_READ",e[e.DYNAMIC_READ=35049]="DYNAMIC_READ",e[e.STREAM_READ=35041]="STREAM_READ",e[e.STATIC_COPY=35046]="STATIC_COPY",e[e.DYNAMIC_COPY=35050]="DYNAMIC_COPY",e[e.STREAM_COPY=35042]="STREAM_COPY"}(A||(A={})),function(e){e[e.FRAGMENT_SHADER=35632]="FRAGMENT_SHADER",e[e.VERTEX_SHADER=35633]="VERTEX_SHADER"}(R||(R={})),function(e){e[e.FRAMEBUFFER=36160]="FRAMEBUFFER",e[e.READ_FRAMEBUFFER=36008]="READ_FRAMEBUFFER",e[e.DRAW_FRAMEBUFFER=36009]="DRAW_FRAMEBUFFER"}(g||(g={})),function(e){e[e.TEXTURE=0]="TEXTURE",e[e.RENDER_BUFFER=1]="RENDER_BUFFER",e[e.CUBEMAP=2]="CUBEMAP"}(m||(m={})),function(e){e[e.NONE=0]="NONE",e[e.DEPTH_RENDER_BUFFER=1]="DEPTH_RENDER_BUFFER",e[e.STENCIL_RENDER_BUFFER=2]="STENCIL_RENDER_BUFFER",e[e.DEPTH_STENCIL_RENDER_BUFFER=3]="DEPTH_STENCIL_RENDER_BUFFER",e[e.DEPTH_STENCIL_TEXTURE=4]="DEPTH_STENCIL_TEXTURE"}(b||(b={})),function(e){e[e.Texture=0]="Texture",e[e.Buffer=1]="Buffer",e[e.VAO=2]="VAO",e[e.Shader=3]="Shader",e[e.Program=4]="Program",e[e.Framebuffer=5]="Framebuffer",e[e.Renderbuffer=6]="Renderbuffer",e[e.COUNT=7]="COUNT"}(C||(C={})),function(e){e[e.COLOR_ATTACHMENT0=36064]="COLOR_ATTACHMENT0",e[e.COLOR_ATTACHMENT1=36065]="COLOR_ATTACHMENT1",e[e.COLOR_ATTACHMENT2=36066]="COLOR_ATTACHMENT2",e[e.COLOR_ATTACHMENT3=36067]="COLOR_ATTACHMENT3",e[e.COLOR_ATTACHMENT4=36068]="COLOR_ATTACHMENT4",e[e.COLOR_ATTACHMENT5=36069]="COLOR_ATTACHMENT5",e[e.COLOR_ATTACHMENT6=36070]="COLOR_ATTACHMENT6",e[e.COLOR_ATTACHMENT7=36071]="COLOR_ATTACHMENT7",e[e.COLOR_ATTACHMENT8=36072]="COLOR_ATTACHMENT8",e[e.COLOR_ATTACHMENT9=36073]="COLOR_ATTACHMENT9",e[e.COLOR_ATTACHMENT10=36074]="COLOR_ATTACHMENT10",e[e.COLOR_ATTACHMENT11=36075]="COLOR_ATTACHMENT11",e[e.COLOR_ATTACHMENT12=36076]="COLOR_ATTACHMENT12",e[e.COLOR_ATTACHMENT13=36077]="COLOR_ATTACHMENT13",e[e.COLOR_ATTACHMENT14=36078]="COLOR_ATTACHMENT14",e[e.COLOR_ATTACHMENT15=36079]="COLOR_ATTACHMENT15"}(v||(v={}));const f=33306;var N,L,w,I,O,M,x;!function(e){e[e.COMPRESSED_RGB_S3TC_DXT1_EXT=33776]="COMPRESSED_RGB_S3TC_DXT1_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT1_EXT=33777]="COMPRESSED_RGBA_S3TC_DXT1_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT3_EXT=33778]="COMPRESSED_RGBA_S3TC_DXT3_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT5_EXT=33779]="COMPRESSED_RGBA_S3TC_DXT5_EXT",e[e.COMPRESSED_R11_EAC=37488]="COMPRESSED_R11_EAC",e[e.COMPRESSED_SIGNED_R11_EAC=37489]="COMPRESSED_SIGNED_R11_EAC",e[e.COMPRESSED_RG11_EAC=37490]="COMPRESSED_RG11_EAC",e[e.COMPRESSED_SIGNED_RG11_EAC=37491]="COMPRESSED_SIGNED_RG11_EAC",e[e.COMPRESSED_RGB8_ETC2=37492]="COMPRESSED_RGB8_ETC2",e[e.COMPRESSED_SRGB8_ETC2=37493]="COMPRESSED_SRGB8_ETC2",e[e.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2=37494]="COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2",e[e.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2=37495]="COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2",e[e.COMPRESSED_RGBA8_ETC2_EAC=37496]="COMPRESSED_RGBA8_ETC2_EAC",e[e.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC=37497]="COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"}(N||(N={})),function(e){e[e.FLOAT=5126]="FLOAT",e[e.FLOAT_VEC2=35664]="FLOAT_VEC2",e[e.FLOAT_VEC3=35665]="FLOAT_VEC3",e[e.FLOAT_VEC4=35666]="FLOAT_VEC4",e[e.INT=5124]="INT",e[e.INT_VEC2=35667]="INT_VEC2",e[e.INT_VEC3=35668]="INT_VEC3",e[e.INT_VEC4=35669]="INT_VEC4",e[e.BOOL=35670]="BOOL",e[e.BOOL_VEC2=35671]="BOOL_VEC2",e[e.BOOL_VEC3=35672]="BOOL_VEC3",e[e.BOOL_VEC4=35673]="BOOL_VEC4",e[e.FLOAT_MAT2=35674]="FLOAT_MAT2",e[e.FLOAT_MAT3=35675]="FLOAT_MAT3",e[e.FLOAT_MAT4=35676]="FLOAT_MAT4",e[e.SAMPLER_2D=35678]="SAMPLER_2D",e[e.SAMPLER_CUBE=35680]="SAMPLER_CUBE",e[e.UNSIGNED_INT=5125]="UNSIGNED_INT",e[e.UNSIGNED_INT_VEC2=36294]="UNSIGNED_INT_VEC2",e[e.UNSIGNED_INT_VEC3=36295]="UNSIGNED_INT_VEC3",e[e.UNSIGNED_INT_VEC4=36296]="UNSIGNED_INT_VEC4",e[e.FLOAT_MAT2x3=35685]="FLOAT_MAT2x3",e[e.FLOAT_MAT2x4=35686]="FLOAT_MAT2x4",e[e.FLOAT_MAT3x2=35687]="FLOAT_MAT3x2",e[e.FLOAT_MAT3x4=35688]="FLOAT_MAT3x4",e[e.FLOAT_MAT4x2=35689]="FLOAT_MAT4x2",e[e.FLOAT_MAT4x3=35690]="FLOAT_MAT4x3",e[e.SAMPLER_3D=35679]="SAMPLER_3D",e[e.SAMPLER_2D_SHADOW=35682]="SAMPLER_2D_SHADOW",e[e.SAMPLER_2D_ARRAY=36289]="SAMPLER_2D_ARRAY",e[e.SAMPLER_2D_ARRAY_SHADOW=36292]="SAMPLER_2D_ARRAY_SHADOW",e[e.SAMPLER_CUBE_SHADOW=36293]="SAMPLER_CUBE_SHADOW",e[e.INT_SAMPLER_2D=36298]="INT_SAMPLER_2D",e[e.INT_SAMPLER_3D=36299]="INT_SAMPLER_3D",e[e.INT_SAMPLER_CUBE=36300]="INT_SAMPLER_CUBE",e[e.INT_SAMPLER_2D_ARRAY=36303]="INT_SAMPLER_2D_ARRAY",e[e.UNSIGNED_INT_SAMPLER_2D=36306]="UNSIGNED_INT_SAMPLER_2D",e[e.UNSIGNED_INT_SAMPLER_3D=36307]="UNSIGNED_INT_SAMPLER_3D",e[e.UNSIGNED_INT_SAMPLER_CUBE=36308]="UNSIGNED_INT_SAMPLER_CUBE",e[e.UNSIGNED_INT_SAMPLER_2D_ARRAY=36311]="UNSIGNED_INT_SAMPLER_2D_ARRAY"}(L||(L={})),function(e){e[e.OBJECT_TYPE=37138]="OBJECT_TYPE",e[e.SYNC_CONDITION=37139]="SYNC_CONDITION",e[e.SYNC_STATUS=37140]="SYNC_STATUS",e[e.SYNC_FLAGS=37141]="SYNC_FLAGS"}(w||(w={})),function(e){e[e.UNSIGNALED=37144]="UNSIGNALED",e[e.SIGNALED=37145]="SIGNALED"}(I||(I={})),function(e){e[e.ALREADY_SIGNALED=37146]="ALREADY_SIGNALED",e[e.TIMEOUT_EXPIRED=37147]="TIMEOUT_EXPIRED",e[e.CONDITION_SATISFIED=37148]="CONDITION_SATISFIED",e[e.WAIT_FAILED=37149]="WAIT_FAILED"}(O||(O={})),function(e){e[e.SYNC_GPU_COMMANDS_COMPLETE=37143]="SYNC_GPU_COMMANDS_COMPLETE"}(M||(M={})),function(e){e[e.SYNC_FLUSH_COMMANDS_BIT=1]="SYNC_FLUSH_COMMANDS_BIT"}(x||(x={}))},65242:(e,t,r)=>{r.d(t,{a:()=>s,b:()=>n});var i=r(75215);function s(e){const t=(0,i.vU)(100*(1-e));return Math.max(0,Math.min(t,100))}function n(e){const t=1-e/100;return Math.max(0,Math.min(t,1))}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4273],{1692:(e,t,n)=>{n.d(t,{Z:()=>_});var r=n(43697),i=n(66577),o=n(51773),s=n(78223),l=n(15923),u=(n(80442),n(22974)),a=n(92604),c=n(70586),f=n(31263),p=n(1153),d=n(52011);a.Z.getLogger("esri.core.Clonable");const y=e=>{let t=class extends e{clone(){const e=(0,c.s3)((0,p.vw)(this),"unable to clone instance of non-accessor class"),t=e.metadatas,n=e.store,r={},i=new Map;for(const e in t){const o=t[e],s=null==n?void 0:n.originOf(e);if(o.readOnly||!1===o.clonable||s!==f.s3.USER&&s!==f.s3.DEFAULTS)continue;const l=this[e];let a=null;const c=o.clonable;a="function"==typeof c?c(l):"reference"===c?l:(0,u.Vo)(l),null!=l&&null==a||(s===f.s3.DEFAULTS?i.set(e,a):r[e]=a)}const o=new(0,Object.getPrototypeOf(this).constructor)(r);if(i.size){var s;const e=null==(s=(0,p.vw)(o))?void 0:s.store;if(e)for(const[t,n]of i)e.set(t,n,f.s3.DEFAULTS)}return o}};return t=(0,r._)([(0,d.j)("esri.core.Clonable")],t),t};let h=class extends(y(l.Z)){};h=(0,r._)([(0,d.j)("esri.core.Clonable")],h);var m=n(96674),g=n(99001),b=n(5600),v=(n(67676),n(75215),n(33955));let w=class extends(y(m.wq)){constructor(...e){super(...e),this.isAggregate=!1,this.layer=null,this.popupTemplate=null,this.sourceLayer=null,Object.defineProperty(this,"uid",{value:(0,g.D)(),configurable:!0})}normalizeCtorArgs(e,t,n,r){return e&&!e.declaredClass?e:{geometry:e,symbol:t,attributes:n,popupTemplate:r}}set attributes(e){const t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){const t=this._get("geometry");t!==e&&(this._set("geometry",e),this._notifyLayer("geometry",t,e))}set symbol(e){const t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}set visible(e){const t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;for(const t of[this.sourceLayer,this.layer])if(t){if("popupTemplate"in t&&t.popupTemplate)return t.popupTemplate;if(e&&"defaultPopupTemplate"in t&&(0,c.pC)(t.defaultPopupTemplate))return t.defaultPopupTemplate}return null}getAttribute(e){return this.attributes&&this.attributes[e]}setAttribute(e,t){if(this.attributes){const n=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",n,t,e)}else this.attributes={[e]:t},this._notifyLayer("attributes",void 0,t,e)}getObjectId(){return this.sourceLayer&&"objectIdField"in this.sourceLayer&&this.sourceLayer.objectIdField?this.getAttribute(this.sourceLayer.objectIdField):null}toJSON(){return{geometry:(0,c.pC)(this.geometry)?this.geometry.toJSON():null,symbol:(0,c.pC)(this.symbol)?this.symbol.toJSON():null,attributes:{...this.attributes},popupTemplate:this.popupTemplate&&this.popupTemplate.toJSON()}}notifyGeometryChanged(){this._notifyLayer("geometry",this.geometry,this.geometry)}_notifyLayer(e,t,n,r){if(!this.layer||!("graphicChanged"in this.layer))return;const i={graphic:this,property:e,oldValue:t,newValue:n};"attributes"===e&&(i.attributeName=r),this.layer.graphicChanged(i)}};(0,r._)([(0,b.Cb)({value:null})],w.prototype,"attributes",null),(0,r._)([(0,b.Cb)({value:null,types:i.qM,json:{read:v.im}})],w.prototype,"geometry",null),(0,r._)([(0,b.Cb)({type:Boolean})],w.prototype,"isAggregate",void 0),(0,r._)([(0,b.Cb)({clonable:"reference"})],w.prototype,"layer",void 0),(0,r._)([(0,b.Cb)({type:o.Z})],w.prototype,"popupTemplate",void 0),(0,r._)([(0,b.Cb)({clonable:"reference"})],w.prototype,"sourceLayer",void 0),(0,r._)([(0,b.Cb)({value:null,types:s.LB})],w.prototype,"symbol",null),(0,r._)([(0,b.Cb)({type:Boolean,value:!0})],w.prototype,"visible",null),w=(0,r._)([(0,d.j)("esri.Graphic")],w),(w||(w={})).generateUID=g.D;const _=w},36030:(e,t,n)=>{n.d(t,{J:()=>o});var r=n(35454),i=n(5600);function o(e,t={}){var n;const o=e instanceof r.Xn?e:new r.Xn(e,t),s={type:null==(n=null==t?void 0:t.ignoreUnknown)||n?o.apiValues:String,json:{type:o.jsonValues,read:(null==t||!t.readOnly)&&{reader:o.read},write:{writer:o.write}}};return void 0!==(null==t?void 0:t.readOnly)&&(s.readOnly=!!t.readOnly),void 0!==(null==t?void 0:t.default)&&(s.json.default=t.default),void 0!==(null==t?void 0:t.name)&&(s.json.name=t.name),(0,i.Cb)(s)}},91460:(e,t,n)=>{function r(e){return e&&("function"==typeof e.on||"function"==typeof e.addEventListener)}function i(e,t,n){if(!r(e))throw new TypeError("target is not a Evented or EventTarget object");if("on"in e)return e.on(t,n);if(Array.isArray(t)){const r=t.slice();for(const t of r)e.addEventListener(t,n);return{remove(){for(const t of r)e.removeEventListener(t,n)}}}return e.addEventListener(t,n),{remove(){e.removeEventListener(t,n)}}}function o(e,t,n){if(!r(e))throw new TypeError("target is not a Evented or EventTarget object");if("once"in e)return e.once(t,n);const o=i(e,t,(t=>{o.remove(),n.call(e,t)}));return{remove(){o.remove()}}}n.d(t,{vT:()=>r,on:()=>i,IH:()=>o})},95330:(e,t,n)=>{n.d(t,{e4:()=>F,$6:()=>u,Ue:()=>a,zE:()=>c,dD:()=>_,hh:()=>I,vr:()=>S,Ds:()=>L,as:()=>O,WW:()=>T,R8:()=>w,D_:()=>v,Hc:()=>d,y8:()=>C,fu:()=>m,$F:()=>g,d1:()=>x,DB:()=>$,r9:()=>y,k_:()=>f,H9:()=>h,Yn:()=>E,gx:()=>A,Hl:()=>b});const r=(i=globalThis,{setTimeout:(e,t)=>{const n=i.setTimeout(e,t);return{remove:()=>i.clearTimeout(n)}}});var i,o=n(20102),s=n(91460),l=(n(92604),n(70586));function u(e){return Promise.all(e)}function a(e){return new Promise(((t,n)=>{try{e(t,n)}catch(e){Promise.resolve().then((()=>n(e)))}}))}function c(e="Aborted"){return new o.Z("AbortError",e)}function f(e,t="Aborted"){if(d(e))throw c(t)}function p(e){return(0,l.pC)(e)?"aborted"in e?e:e.signal:e}function d(e){const t=p(e);return(0,l.pC)(t)&&t.aborted}function y(e){if(v(e))throw e}function h(e){if(!v(e))throw e}function m(e,t){const n=p(e);if(!(0,l.Wi)(n)){if(!n.aborted)return(0,s.IH)(n,"abort",(()=>t()));t()}}function g(e,t){const n=p(e);if(!(0,l.Wi)(n))return f(n),(0,s.IH)(n,"abort",(()=>t(c())))}function b(e,t){const n=p(t);return(0,l.Wi)(n)?e:new Promise(((n,r)=>{let i=m(t,(()=>r(c())));const o=()=>i=(0,l.hw)(i);e.then(o,o),e.then(n,r)}))}function v(e){return e&&"AbortError"===e.name}function w(e){return e.catch((e=>{if(!v(e))throw e}))}function _(){let e=null;const t=new Promise(((t,n)=>{e={promise:void 0,resolve:t,reject:n}}));return e.promise=t,e}function O(e){if(!e)return;if("function"!=typeof e.forEach){const t=Object.keys(e);return O(t.map((t=>e[t]))).then((e=>{const n={};return t.forEach(((t,r)=>n[t]=e[r])),n}))}const t=e;return a((e=>{const n=[];let r=t.length;0===r&&e(n),t.forEach((t=>{const i={promise:t||Promise.resolve(t)};n.push(i),i.promise.then((e=>{i.value=e})).catch((e=>{i.error=e})).then((()=>{--r,0===r&&e(n)}))}))}))}function T(e){return O(e).then((e=>e.filter((e=>!!e.value)).map((e=>e.value))))}function x(e){return Promise.reject(e)}function $(e){return Promise.resolve(e)}function F(e,t,n){const r=new AbortController;return m(n,(()=>r.abort())),new Promise(((n,i)=>{let o=setTimeout((()=>{o=0,n(t)}),e);m(r,(()=>{o&&(clearTimeout(o),i(c()))}))}))}function C(e){return e&&"function"==typeof e.then}function A(e){return C(e)?e:Promise.resolve(e)}function L(e,t=-1){let n,r,i,o,s=null;const u=(...a)=>{if(n){r=a,o&&o.reject(c()),o=_();const e=(0,l.j0)(o.promise);if(s){const e=s;s=null,e.abort()}return e}if(i=o||_(),o=null,t>0){const r=new AbortController;n=A(e(...a,r.signal));const i=n;F(t).then((()=>{n===i&&(o?r.abort():s=r)}))}else n=1,n=A(e(...a));const f=()=>{const e=r;r=i=n=s=null,null!=e&&u(...e)},p=n,d=i;return p.then(f,f),p.then(d.resolve,d.reject),(0,l.j0)(d.promise)};return u}function I(){let e,t;const n=new Promise(((n,r)=>{e=n,t=r})),i=t=>{e(t)};return i.resolve=t=>e(t),i.reject=e=>t(e),i.timeout=(e,t)=>r.setTimeout((()=>i.reject(t)),e),i.promise=n,i}function S(e,t){let n,r=new AbortController;const i=e(r.signal);let o={promise:i,finished:!1,abort:()=>{r&&(r.abort(),r=null)}};const s=()=>{o&&(o.finished=!0,o=null),(0,l.pC)(n)&&(n.remove(),n=null),r=null};return i.then(s,s),n=m(t,(()=>{(0,l.pC)(o)&&o.abort()})),o}function E(e){return Promise.resolve().then((()=>{f(e)}))}},17452:(e,t,n)=>{n.d(t,{R9:()=>b,qg:()=>L,tD:()=>P,ZN:()=>pe,fl:()=>de,Ie:()=>ae,sJ:()=>X,AH:()=>Y,io:()=>K,L:()=>T,TI:()=>O,vt:()=>le,oh:()=>R,P$:()=>k,Ml:()=>ye,ed:()=>U,b7:()=>A,D6:()=>D,tm:()=>N,YP:()=>W,jc:()=>z,HK:()=>B,$U:()=>ne,oC:()=>ee,kl:()=>G,v_:()=>M,hF:()=>V,_l:()=>Q,PF:()=>J,Fv:()=>Z,B7:()=>C,u0:()=>$,Yd:()=>se,Hu:()=>fe,Qj:()=>ue,hO:()=>re,mN:()=>x});var r=n(68773),i=n(20102),o=n(92604),s=n(70586);const l=o.Z.getLogger("esri.core.urlUtils"),u=r.Z.request,a="esri/config: esriConfig.request.proxyUrl is not set.",c=/^\s*[a-z][a-z0-9-+.]*:(?![0-9])/i,f=/^\s*http:/i,p=/^\s*https:/i,d=/^\s*file:/i,y=/:\d+$/,h=/^https?:\/\/[^/]+\.arcgis.com\/sharing(\/|$)/i,m=new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"),g=new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$");class b{constructor(e=""){this.uri=e,this.scheme=null,this.authority=null,this.path=null,this.query=null,this.fragment=null,this.user=null,this.password=null,this.host=null,this.port=null;let t=(0,s.j0)(this.uri.match(m));this.scheme=t[2]||(t[1]?"":null),this.authority=t[4]||(t[3]?"":null),this.path=t[5],this.query=t[7]||(t[6]?"":null),this.fragment=t[9]||(t[8]?"":null),null!=this.authority&&(t=(0,s.j0)(this.authority.match(g)),this.user=t[3]||null,this.password=t[4]||null,this.host=t[6]||t[7],this.port=t[9]||null)}toString(){return this.uri}}const v={};let w=new b(r.Z.applicationUrl);let _=function(){const e=(0,s.j0)(w.path),t=e.substring(0,e.lastIndexOf(e.split("/")[e.split("/").length-1]));return`${w.scheme}://${w.host}${null!=w.port?`:${w.port}`:""}${t}`}();const O=()=>w,T=()=>_;function x(e){const t={path:null,query:null},n=new b(e),r=e.indexOf("?");return null===n.query?t.path=e:(t.path=e.substring(0,r),t.query=$(n.query)),n.fragment&&(t.hash=n.fragment,null===n.query&&(t.path=t.path.substring(0,t.path.length-(n.fragment.length+1)))),t}function $(e){const t=e.split("&"),n={};for(const e of t){if(!e)continue;const t=e.indexOf("=");let r,i;t<0?(r=decodeURIComponent(e),i=""):(r=decodeURIComponent(e.slice(0,t)),i=decodeURIComponent(e.slice(t+1)));let o=n[r];"string"==typeof o&&(o=n[r]=[o]),Array.isArray(o)?o.push(i):n[r]=i}return n}function F(e){return e&&"object"==typeof e&&"toJSON"in e&&"function"==typeof e.toJSON}function C(e,t){return e?t&&"function"==typeof t?Object.keys(e).map((n=>encodeURIComponent(n)+"="+encodeURIComponent(t(n,e[n])))).join("&"):Object.keys(e).map((n=>{const r=e[n];if(null==r)return"";const i=encodeURIComponent(n)+"=",o=t&&t[n];return o?i+encodeURIComponent(o(r)):Array.isArray(r)?r.map((e=>F(e)?i+encodeURIComponent(JSON.stringify(e)):i+encodeURIComponent(e))).join("&"):F(r)?i+encodeURIComponent(JSON.stringify(r)):i+encodeURIComponent(r)})).filter((e=>e)).join("&"):""}function A(e=!1){let t,n=u.proxyUrl;if("string"==typeof e){t=ne(e);const r=U(e);r&&(n=r.proxyUrl)}else t=!!e;if(!n)throw l.warn(a),new i.Z("urlutils:proxy-not-set",a);return t&&ie()&&(n=re(n)),x(n)}function L(e){const t=U(e);let n,r;if(t){const e=S(t.proxyUrl);n=e.path,r=e.query?$(e.query):null}if(n){const t=x(e);e=n+"?"+t.path;const i=C({...r,...t.query});i&&(e=`${e}?${i}`)}return e}const I={path:"",query:""};function S(e){const t=e.indexOf("?");return-1!==t?(I.path=e.slice(0,t),I.query=e.slice(t+1)):(I.path=e,I.query=null),I}function E(e){return(e=oe(e=function(e){return e&&"/"===e[e.length-1]?e:`${e}/`}(e=S(e).path),!0)).toLowerCase()}function P(e){const t={proxyUrl:e.proxyUrl,urlPrefix:E(e.urlPrefix)},n=u.proxyRules,r=t.urlPrefix;let i=n.length;for(let e=0;e<n.length;e++){const t=n[e].urlPrefix;if(0===r.indexOf(t)){if(r.length===t.length)return-1;i=e;break}0===t.indexOf(r)&&(i=e+1)}return n.splice(i,0,t),i}function U(e){const t=u.proxyRules,n=E(e);for(let e=0;e<t.length;e++)if(0===n.indexOf(t[e].urlPrefix))return t[e]}function N(e,t){return e=j(e),t=j(t),oe(e)===oe(t)}function j(e){const t=(e=Z(e)).indexOf("/sharing");return t>0?e.substring(0,t):e.replace(/\/+$/,"")}function R(e){const t=t=>null==t||t instanceof RegExp&&t.test(e)||"string"==typeof t&&e.startsWith(t),n=u.interceptors;if(n)for(const e of n)if(Array.isArray(e.urls)){if(e.urls.some(t))return e}else if(t(e.urls))return e;return null}function D(e,t,n=!1){const r=ce(e),i=ce(t);return!(!n&&r.scheme!==i.scheme)&&null!=r.host&&null!=i.host&&r.host.toLowerCase()===i.host.toLowerCase()&&r.port===i.port}function G(e){if("string"==typeof e){if(!W(e))return!0;e=ce(e)}if(D(e,w))return!0;const t=u.trustedServers||[];for(let n=0;n<t.length;n++){const r=q(t[n]);for(let t=0;t<r.length;t++)if(D(e,r[t]))return!0}return!1}function q(e){return v[e]||(te(e)||ee(e)?v[e]=[new b(V(e))]:v[e]=[new b(`http://${e}`),new b(`https://${e}`)]),v[e]}function V(e,t=_,n){return ee(e)?n&&n.preserveProtocolRelative?e:"http"===w.scheme&&w.authority===k(e).slice(2)?`http:${e}`:`https:${e}`:te(e)?e:(0,s.j0)(M("/"===e[0]?function(e){const t=e.indexOf("//"),n=e.indexOf("/",t+2);return-1===n?e:e.slice(0,n)}(t):t,e))}function J(e,t=_,n){if(!W(e))return e;const r=Z(e),i=r.toLowerCase(),o=Z(t).toLowerCase().replace(/\/+$/,""),s=n?Z(n).toLowerCase().replace(/\/+$/,""):null;if(s&&0!==o.indexOf(s))return e;const l=(e,t,n)=>-1===(n=e.indexOf(t,n))?e.length:n;let u=l(i,"/",i.indexOf("//")+2),a=-1;for(;i.slice(0,u+1)===o.slice(0,u)+"/"&&(a=u+1,u!==i.length);)u=l(i,"/",u+1);if(-1===a)return e;if(s&&a<s.length)return e;e=r.slice(a);const c=o.slice(a-1).replace(/[^/]+/g,"").length;if(c>0)for(let t=0;t<c;t++)e=`../${e}`;else e=`./${e}`;return e}function Z(e){return function(e){const t=u.httpsDomains;if(!function(e){return f.test(e)||"http"===w.scheme&&ee(e)}(e))return e;const n=e.indexOf("/",7);let r;if(r=-1===n?e:e.slice(0,n),r=r.toLowerCase().slice(7),y.test(r)){if(!r.endsWith(":80"))return e;r=r.slice(0,-3),e=e.replace(":80","")}return"http"===w.scheme&&r===w.authority&&!h.test(e)||(ie()&&r===w.authority||t&&t.some((e=>r===e||r.endsWith(`.${e}`)))||ie()&&!U(e))&&(e=re(e)),e}(e=function(e){return e.replace(/^(https?:\/\/)(arcgis\.com)/i,"$1www.$2")}(e=function(e){if(/^https?:\/\//i.test(e)){const t=S(e);e=(e=t.path.replace(/\/{2,}/g,"/")).replace("/","//"),t.query&&(e+=`?${t.query}`)}return e}(e=V(e=e.trim()))))}function M(...e){const t=e.filter(s.pC);if(!t||!t.length)return;const n=[];if(W(t[0])){const e=t[0],r=e.indexOf("//");-1!==r&&(n.push(e.slice(0,r+1)),function(e){return d.test(e)}(t[0])&&(n[0]+="/"),t[0]=e.slice(r+2))}else"/"===t[0][0]&&n.push("");const r=t.reduce(((e,t)=>t?e.concat(t.split("/")):e),[]);for(let e=0;e<r.length;e++){const t=r[e];".."===t&&n.length>0&&".."!==n[n.length-1]?n.pop():(!t&&e===r.length-1||t&&("."!==t||0===n.length))&&n.push(t)}return n.join("/")}function k(e,t=!1){if(z(e)||B(e))return null;let n=e.indexOf("://");if(-1===n&&ee(e))n=2;else{if(-1===n)return null;n+=3}const r=e.indexOf("/",n);return-1!==r&&(e=e.slice(0,r)),t&&(e=oe(e,!0)),e}function W(e){return ee(e)||te(e)}function z(e){return null!=e&&"blob:"===e.slice(0,5)}function B(e){return"data:"===e.slice(0,5)}function Y(e){const t=X(e);if(!t||!t.isBase64)return null;const n=atob(t.data),r=new Uint8Array(n.length);for(let e=0;e<n.length;e++)r[e]=n.charCodeAt(e);return r.buffer}const H=/^data:(.*?)(;base64)?,(.*)$/;function X(e){const t=e.match(H);if(!t)return null;const[,n,r,i]=t;return{mediaType:n,isBase64:!!r,data:i}}function Q(e){return e.isBase64?`data:${e.mediaType};base64,${e.data}`:`data:${e.mediaType},${e.data}`}function K(e,t){(function(e,t){if(!e)return!1;const n=document.createElement("a");if(!("download"in n))return!1;const r=URL.createObjectURL(e);return n.download=t,n.href=r,n.style.display="none",document.body.appendChild(n),n.click(),document.body.removeChild(n),URL.revokeObjectURL(r),!0})(e,t)||function(e,t){!!window.navigator.msSaveOrOpenBlob&&window.navigator.msSaveOrOpenBlob(e,t)}(e,t)}function ee(e){return null!=e&&void 0!==e&&"/"===e[0]&&"/"===e[1]}function te(e){return c.test(e)}function ne(e){return p.test(e)||"https"===w.scheme&&ee(e)}function re(e){return ee(e)?`https:${e}`:e.replace(f,"https:")}function ie(){return"https"===w.scheme}function oe(e,t=!1){return ee(e)?e.slice(2):(e=e.replace(c,""),t&&e.length>1&&"/"===e[0]&&"/"===e[1]&&(e=e.slice(2)),e)}function se(e){let t=0;if(W(e)){const n=e.indexOf("//");-1!==n&&(t=n+2)}const n=e.lastIndexOf("/");return n<t?e:e.slice(0,n+1)}function le(e,t){if(!e)return"";const n=x(e).path.replace(/\/+$/,""),r=n.substring(n.lastIndexOf("/")+1);if(null==t||!t.length)return r;const i=new RegExp(`.(${t.join("|")})$`,"ig");return r.replace(i,"")}function ue(e){return e.replace(/\/+$/,"")}function ae(e,t,n){if(!(t&&n&&e&&W(e)))return e;const r=e.indexOf("//"),i=e.indexOf("/",r+2),o=e.indexOf(":",r+2),s=Math.min(i<0?e.length:i,o<0?e.length:o);return e.slice(r+2,s).toLowerCase()!==t.toLowerCase()?e:`${e.slice(0,r+2)}${n}${e.slice(s)}`}function ce(e){return"string"==typeof e?new b(V(e)):(e.scheme||(e.scheme=w.scheme),e)}function fe(e,t){const n=x(e),r=Object.keys(n.query||{});return r.length>0&&t&&t.warn("removeQueryParameters()",`Url query parameters are not supported, the following parameters have been removed: ${r.join(", ")}.`),n.path}function pe(e,t,n){const r=x(e),i=r.query||{};return i[t]=String(n),`${r.path}?${C(i)}`}function de(e,t){const n=x(e),r=n.query||{};for(const e in t)r[e]=t[e];const i=C(r);return i?`${n.path}?${i}`:n.path}function ye(e){if((0,s.Wi)(e))return null;const t=e.match(he);return t?t[1]:null}const he=/.*?\.([^\/]*)$/},66577:(e,t,n)=>{n.d(t,{qM:()=>c});var r=n(75215),i=n(6570),o=n(9361),s=n(65091),l=n(13473),u=n(17332),a=n(58901);n(82971),n(86973),n(33955);const c={base:o.Z,key:"type",typeMap:{extent:i.Z,multipoint:s.Z,point:l.Z,polyline:a.Z,polygon:u.Z}};(0,r.N7)(c)},33955:(e,t,n)=>{n.d(t,{im:()=>h,q9:()=>b,Ji:()=>m,YX:()=>c,aW:()=>f,wp:()=>p,oU:()=>y,l9:()=>d});var r=n(70586),i=n(6570),o=n(9361),s=n(65091),l=n(13473),u=n(17332),a=n(58901);function c(e){return void 0!==e.xmin&&void 0!==e.ymin&&void 0!==e.xmax&&void 0!==e.ymax}function f(e){return void 0!==e.points}function p(e){return void 0!==e.x&&void 0!==e.y}function d(e){return void 0!==e.paths}function y(e){return void 0!==e.rings}function h(e){return(0,r.Wi)(e)?null:e instanceof o.Z?e:p(e)?l.Z.fromJSON(e):d(e)?a.Z.fromJSON(e):y(e)?u.Z.fromJSON(e):f(e)?s.Z.fromJSON(e):c(e)?i.Z.fromJSON(e):null}function m(e){return e?p(e)?"esriGeometryPoint":d(e)?"esriGeometryPolyline":y(e)?"esriGeometryPolygon":c(e)?"esriGeometryEnvelope":f(e)?"esriGeometryMultipoint":null:null}const g={esriGeometryPoint:l.Z,esriGeometryPolyline:a.Z,esriGeometryPolygon:u.Z,esriGeometryEnvelope:i.Z,esriGeometryMultipoint:s.Z};function b(e){return e&&g[e]||null}},91040:(e,t,n)=>{n.d(t,{yZ:()=>i});var r=n(67900);function i(e,t){const n=t||e.extent,i=e.width,o=(0,r.c9)(n&&n.spatialReference);return n&&i?n.width/i*o*r.hd*96:0}},86973:(e,t,n)=>{n.d(t,{Mk:()=>i,P$:()=>o});var r=n(35454);const i=(0,r.wY)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),o=(0,r.wY)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"})},35671:(e,t,n)=>{n.d(t,{io:()=>g,AB:()=>m,gd:()=>h,Mu:()=>w,Q0:()=>y,YN:()=>c,UF:()=>p,O5:()=>b,os:()=>_,H7:()=>S,qN:()=>E,Pz:()=>N,Qc:()=>j,vP:()=>J});var r,i,o=n(20102),s=n(78286);(i=r||(r={})).VALUE_OUT_OF_RANGE="domain-validation-error::value-out-of-range",i.INVALID_CODED_VALUE="domain-validation-error::invalid-coded-value";var l=n(59266);const u=["field","field2","field3","normalizationField","rotationInfo.field","proportionalSymbolInfo.field","proportionalSymbolInfo.normalizationField","colorInfo.field","colorInfo.normalizationField"],a=["field","normalizationField"];function c(e,t){if(null!=e&&null!=t)for(const n of Array.isArray(e)?e:[e])if(f(u,n,t),"visualVariables"in n&&n.visualVariables)for(const e of n.visualVariables)f(a,e,t)}function f(e,t,n){if(e)for(const r of e){const e=(0,s.hS)(r,t),i=e&&"function"!=typeof e&&n.get(e);i&&(0,s.RB)(r,i.name,t)}}function p(e,t){if(null!=e&&null!=t&&t.fields.length)if("startField"in e){const n=t.get(e.startField),r=t.get(e.endField);e.startField=n&&n.name||null,e.endField=r&&r.name||null}else{const n=t.get(e.startTimeField),r=t.get(e.endTimeField);e.startTimeField=n&&n.name||null,e.endTimeField=r&&r.name||null}}const d=new Set;function y(e,t){return e&&t?(d.clear(),h(d,e,t),Array.from(d).sort()):[]}function h(e,t,n){var r;if(n)if(null!=t&&null!=(r=t.fields)&&r.length)if(n.includes("*"))for(const{name:n}of t.fields)e.add(n);else for(const r of n)m(e,t,r);else{if(n.includes("*"))return e.clear(),void e.add("*");for(const t of n)e.add(t)}}function m(e,t,n){if("string"==typeof n)if(t){const r=t.get(n);r&&e.add(r.name)}else e.add(n)}async function g(e,t,n){var r;if(!n)return;const{arcadeUtils:i}=await(0,l.LC)(),o=i.extractFieldNames(n,null==t||null==(r=t.fields)?void 0:r.map((e=>e.name)));for(const n of o)m(e,t,n)}function b({displayField:e,fields:t}){return e||(t&&t.length?v(t,"name-or-title")||v(t,"unique-identifier")||v(t,"type-or-category")||function(e){for(const t of e){if(!t||!t.name)continue;const e=t.name.toLowerCase();if(e.indexOf("name")>-1||e.indexOf("title")>-1)return t.name}return null}(t):null)}function v(e,t){for(const n of e)if(n&&n.valueType&&n.valueType===t)return n.name;return null}async function w(e,t){const{labelingInfo:r,fieldsIndex:i}=t;r&&r.length&&await Promise.all(r.map((t=>async function(e,t,r){if(!r)return;const i=r.getLabelExpression(),s=r.where;if("arcade"===i.type)await g(e,t,i.expression);else{const n=i.expression.match(/{[^}]*}/g);n&&n.forEach((n=>{m(e,t,n.slice(1,-1))}))}await async function(e,t,r){if(r&&"1=1"!==r){const i=(await Promise.all([n.e(1534),n.e(5732)]).then(n.bind(n,41534))).WhereClause.create(r,t);if(!i.isStandardized)throw new o.Z("fieldUtils:collectFilterFields","Where clause is not standardized");h(e,t,i.fieldNames)}}(e,t,s)}(e,i,t))))}function _(e){const t=e.defaultValue;return void 0!==t&&L(e,t)?t:e.nullable?null:void 0}function O(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}function T(e){return null===e||O(e)}const x="isInteger"in Number?Number.isInteger:e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e;function $(e){return null===e||x(e)}function F(e){return null!=e&&"string"==typeof e}function C(e){return null===e||F(e)}function A(){return!0}function L(e,t){let n;switch(e.type){case"date":case"integer":case"long":case"small-integer":case"esriFieldTypeDate":case"esriFieldTypeInteger":case"esriFieldTypeLong":case"esriFieldTypeSmallInteger":n=e.nullable?$:x;break;case"double":case"single":case"esriFieldTypeSingle":case"esriFieldTypeDouble":n=e.nullable?T:O;break;case"string":case"esriFieldTypeString":n=e.nullable?C:F;break;default:n=A}return 1===arguments.length?n:n(t)}const I=new Set(["integer","small-integer","single","double","esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeSingle","esriFieldTypeDouble"]);function S(e){return null!=e&&I.has(e.type)}function E(e){return null!=e&&("string"===e.type||"esriFieldTypeString"===e.type)}var P,U;function N(e){return null==e||"number"==typeof e&&isNaN(e)?null:e}function j(e,t){return e.nullable&&null===t?null:S(e)&&!function(e,t){const n="string"==typeof e?R(e):e;return!!n&&(n.isInteger?x(t)&&t>=n.min&&t<=n.max:t>=n.min&&t<=n.max)}(e.type,Number(t))?P.OUT_OF_RANGE:L(e,t)?e.domain?function(e,t){switch(e.type){case"range":{const n="range"in e?e.range[0]:e.minValue,i="range"in e?e.range[1]:e.maxValue;if(+t<n||+t>i)return r.VALUE_OUT_OF_RANGE;break}case"coded-value":case"codedValue":if(null==e.codedValues||e.codedValues.every((e=>null==e||e.code!==t)))return r.INVALID_CODED_VALUE}return null}(e.domain,t):null:U.INVALID_TYPE}function R(e){switch(e){case"esriFieldTypeSmallInteger":case"small-integer":return D;case"esriFieldTypeInteger":case"integer":return G;case"esriFieldTypeSingle":case"single":return q;case"esriFieldTypeDouble":case"double":return V}}!function(e){e.OUT_OF_RANGE="numeric-range-validation-error::out-of-range"}(P||(P={})),function(e){e.INVALID_TYPE="type-validation-error::invalid-type"}(U||(U={}));const D={min:-32768,max:32767,isInteger:!0},G={min:-2147483648,max:2147483647,isInteger:!0},q={min:-34e37,max:12e37,isInteger:!1},V={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1};function J(e,t,n){switch(e){case r.INVALID_CODED_VALUE:return`Value ${n} is not in the coded domain - field: ${t.name}, domain: ${JSON.stringify(t.domain)}`;case r.VALUE_OUT_OF_RANGE:return`Value ${n} is out of the range of valid values - field: ${t.name}, domain: ${JSON.stringify(t.domain)}`;case U.INVALID_TYPE:return`Value ${n} is not a valid value for the field type - field: ${t.name}, type: ${t.type}, nullable: ${t.nullable}`;case P.OUT_OF_RANGE:{const{min:e,max:r}=R(t.type);return`Value ${n} is out of range for the number type - field: ${t.name}, type: ${t.type}, value range is ${e} to ${r}`}}}},51623:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(43697),i=n(35454),o=n(96674),s=n(5600),l=(n(67676),n(80442),n(75215),n(52011));const u=new i.Xn({esriJobMessageTypeInformative:"informative",esriJobMessageTypeProcessDefinition:"process-definition",esriJobMessageTypeProcessStart:"process-start",esriJobMessageTypeProcessStop:"process-stop",esriJobMessageTypeWarning:"warning",esriJobMessageTypeError:"error",esriJobMessageTypeEmpty:"empty",esriJobMessageTypeAbort:"abort"});let a=class extends o.wq{constructor(e){super(e),this.description=null,this.type=null}};(0,r._)([(0,s.Cb)({type:String,json:{write:!0}})],a.prototype,"description",void 0),(0,r._)([(0,s.Cb)({type:String,json:{read:u.read,write:u.write}})],a.prototype,"type",void 0),a=(0,r._)([(0,l.j)("esri.rest.support.GPMessage")],a);const c=a},11282:(e,t,n)=>{n.d(t,{lA:()=>i,cv:()=>s,en:()=>o});var r=n(17452);function i(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,r.mN)(e):e}function s(e,t,n){const r={};for(const i in e){if("declaredClass"===i)continue;const o=e[i];if(null!=o&&"function"!=typeof o)if(Array.isArray(o)){r[i]=[];for(let e=0;e<o.length;e++)r[i][e]=s(o[e])}else if("object"==typeof o)if(o.toJSON){const e=o.toJSON(n&&n[i]);r[i]=t?e:JSON.stringify(e)}else r[i]=t?o:JSON.stringify(o);else r[i]=o}return r}n(91040)},59266:(e,t,n)=>{n.d(t,{mz:()=>c,pp:()=>a,WW:()=>l,Yi:()=>u,LC:()=>s}),n(66577);var r=n(70586),i=n(82971);let o;function s(){return o||(o=(async()=>{const e=await Promise.all([n.e(9490),n.e(6690)]).then(n.bind(n,96690));return{arcade:e.arcade,arcadeUtils:e,Dictionary:e.Dictionary,Feature:e.arcadeFeature}})()),o}const l=(e,t,n)=>c.create(e,t,n,null,["$feature"]),u=(e,t,n)=>c.create(e,t,n,null,["$feature","$view"]),a=(e,t,n,r)=>c.create(e,t,n,r,["$feature","$view"]);class c{constructor(e,t,n,r,i,o,s,l){this.script=e,this.evaluate=i;const u=Array.isArray(s)?s:s.fields;this.fields=u,this._syntaxTree=r,this._arcade=t,this._arcadeDictionary=n,this._arcadeFeature=o,this._spatialReference=l,this._referencesGeometry=t.scriptTouchesGeometry(this._syntaxTree),this._referencesScale=this._arcade.referencesMember(this._syntaxTree,"scale")}static async create(e,t,n,o,l,u){const{arcade:a,Feature:f,Dictionary:p}=await s(),d=i.Z.fromJSON(t),y=a.parseScript(e,u),h=l.reduce(((e,t)=>({...e,[t]:null})),{});let m=null;(0,r.pC)(o)&&(m=new p(o),m.immutable=!0,h.$config=null);const g=a.scriptUsesGeometryEngine(y)&&a.enableGeometrySupport(),b=a.scriptUsesFeatureSet(y)&&a.enableFeatureSetSupport(),v=a.scriptIsAsync(y)&&a.enableAsyncSupport(),w={vars:h,spatialReference:d,useAsync:!!v},_=new p;_.immutable=!1,_.setField("scale",0);const O=a.compileScript(y,w);return await Promise.all([g,b,v]),new c(e,a,p,y,(e=>("$view"in e&&e.$view&&(_.setField("scale",e.$view.scale),e.$view=_),m&&(e.$config=m),O({vars:e,spatialReference:d}))),new f,n,d)}repurposeFeature(e){return e.geometry&&!e.geometry.spatialReference&&(e.geometry.spatialReference=this._spatialReference),this._arcadeFeature.repurposeFromGraphicLikeObject(e.geometry,e.attributes,{fields:this.fields}),this._arcadeFeature}repurposeAdapter(e){return this._arcadeFeature.repurposeFromAdapter(e,{fields:this.fields}),this._arcadeFeature}createDictionary(){return new this._arcadeDictionary}referencesMember(e){return this._arcade.referencesMember(this._syntaxTree,e)}referencesFunction(e){return this._arcade.referencesFunction(this._syntaxTree,e)}referencesGeometry(){return this._referencesGeometry}referencesScale(){return this._referencesScale}extractFieldLiterals(){return this._arcade.extractExpectedFieldLiterals(this._syntaxTree)}}}}]);
|