@arcgis/core 5.0.0-next.55 → 5.0.0-next.57
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/Color.d.ts +12 -4
- package/Ground.js +1 -1
- package/applications/Components/SelectionOperation.d.ts +5 -0
- package/applications/Components/SketchTooltipControls.d.ts +5 -0
- package/applications/Components/actionUtils.d.ts +5 -0
- package/applications/Components/analysisUtils.d.ts +5 -0
- package/applications/Components/arcadeEditorUtils.d.ts +5 -0
- package/applications/Components/arcadeFeatureUtils.d.ts +5 -0
- package/applications/Components/basemapUtils.d.ts +5 -0
- package/applications/Components/drawUtils.d.ts +5 -0
- package/applications/Components/featureUtils.d.ts +5 -0
- package/applications/Components/fontUtils.d.ts +5 -0
- package/applications/Components/formatUtils.d.ts +5 -0
- package/applications/Components/getDefaultUnits.d.ts +5 -0
- package/applications/Components/gfxUtils.d.ts +5 -0
- package/applications/Components/imageryUtils.d.ts +5 -0
- package/applications/Components/layerOriginUtils.d.ts +5 -0
- package/applications/Components/layersEffectsJsonUtils.d.ts +5 -0
- package/applications/Components/previewSymbol2D.d.ts +5 -0
- package/applications/Components/reactiveUtils.d.ts +6 -0
- package/applications/Components/sanitizerUtils.d.ts +5 -0
- package/applications/Components/stringUtils.d.ts +6 -2
- package/applications/Components/styleUtils.d.ts +5 -0
- package/applications/Components/svgUtils.d.ts +5 -0
- package/applications/Components/testUtils.d.ts +5 -0
- package/applications/Components/viewUtils.d.ts +5 -0
- package/applications/Components/webStyleSymbolUtils.d.ts +5 -0
- package/applications/Excalibur/videoViewUtils.d.ts +5 -0
- package/applications/ExperienceBuilder/sketchUtils.d.ts +5 -0
- package/applications/KnowledgeStudio/generalSdkInternalAccess.d.ts +10 -0
- package/applications/KnowledgeStudio/generalSharedKgUtils.d.ts +10 -0
- package/applications/KnowledgeStudio/layerInternalAccessUtils.d.ts +11 -1
- package/applications/KnowledgeStudio/reshape.d.ts +5 -0
- package/applications/KnowledgeStudio/resourceSerializationUtils.d.ts +5 -0
- package/applications/MapViewer/layerUtils.d.ts +5 -0
- package/applications/MapViewer/mediaUtils.d.ts +5 -0
- package/applications/MapViewer/templateUtils.d.ts +5 -0
- package/applications/PortalApp/layerUtils.d.ts +5 -0
- package/applications/SceneViewer/colorUtils.d.ts +5 -0
- package/applications/SceneViewer/devEnvironmentUtils.d.ts +5 -0
- package/applications/SceneViewer/layerUtils.d.ts +5 -0
- package/applications/SceneViewer/sceneViewerUtils.d.ts +5 -0
- package/applications/SceneViewer/symbolUtils.d.ts +5 -0
- package/applications/Urban/meshUtils.d.ts +5 -0
- package/applications/WebEditor/sketchUtils.d.ts +5 -0
- package/arcade.d.ts +22 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/5340887a4a48bde3407a.js +1 -0
- package/assets/esri/core/workers/chunks/82ced9254b27707522ef.js +1 -0
- package/assets/esri/core/workers/chunks/8628bf45a33af786cd49.js +1 -0
- package/assets/esri/core/workers/chunks/{d63cf90d1356d1f10138.js → 8f4c480c418eba299c2b.js} +1 -1
- package/assets/esri/core/workers/chunks/{fa92a7c11befbad8739f.js → b4f944ef6c174b20b619.js} +1 -1
- package/assets/esri/core/workers/chunks/c531c0e3d420a1be0ad2.js +316 -0
- package/assets/esri/core/workers/chunks/{14765f98b8ea447498a1.js → da2c41ac0f82f32013c1.js} +4 -4
- package/assets/esri/libs/lyr3d/lyr3DMain.wasm +0 -0
- package/assets/esri/libs/lyr3d/lyr3DWorker.wasm +0 -0
- package/chunks/ChapmanAtmosphere.glsl.js +5 -7
- package/chunks/HUDMaterial.glsl.js +1 -1
- package/chunks/LineCallout.glsl.js +2 -2
- package/chunks/Precipitation.glsl.js +1 -1
- package/chunks/Terrain.glsl.js +1 -1
- package/chunks/lyr3DMain.js +1 -1
- package/chunks/vec32.js +1 -1
- package/config.d.ts +19 -1
- package/config.js +1 -1
- package/core/Error.d.ts +3 -4
- package/core/Error.js +1 -1
- package/core/Warning.js +1 -1
- package/core/accessorSupport/decorators.d.ts +11 -0
- package/core/accessorSupport/types.d.ts +2 -0
- package/core/has.js +1 -1
- package/core/lang.d.ts +6 -0
- package/core/libs/gl-matrix-2/math/vec3.js +1 -1
- package/core/libs/gl-matrix-2/vec3.js +1 -1
- package/core/promiseUtils.d.ts +5 -0
- package/core/quantity.d.ts +5 -0
- package/core/reactiveUtils.d.ts +142 -0
- package/core/scheduling.d.ts +26 -5
- package/core/scheduling.js +1 -1
- package/core/sql/WhereClause.d.ts +2 -13
- package/core/sql/{WhereGrammar.d.ts → types.d.ts} +22 -1
- package/core/sql.d.ts +8 -0
- package/core/string.js +1 -1
- package/core/types.d.ts +30 -1
- package/core/units.d.ts +8 -0
- package/core/urlUtils.d.ts +7 -0
- package/core/workers/loaderConfig.js +1 -1
- package/core/workers/workerFactory.js +1 -1
- package/core/workers.d.ts +26 -0
- package/form/elements/inputs.d.ts +55 -0
- package/form/elements.d.ts +43 -0
- package/geometry/coordinateFormatter.d.ts +33 -0
- package/geometry/geometryEngine.d.ts +16 -0
- package/geometry/operators/affineTransformOperator.d.ts +5 -0
- package/geometry/operators/alphaShapeOperator.d.ts +9 -0
- package/geometry/operators/areaOperator.d.ts +7 -0
- package/geometry/operators/autoCompleteOperator.d.ts +5 -0
- package/geometry/operators/boundaryOperator.d.ts +5 -0
- package/geometry/operators/bufferOperator.d.ts +11 -0
- package/geometry/operators/centroidOperator.d.ts +14 -0
- package/geometry/operators/clipOperator.d.ts +7 -0
- package/geometry/operators/containsOperator.d.ts +9 -0
- package/geometry/operators/convexHullOperator.d.ts +9 -0
- package/geometry/operators/crossesOperator.d.ts +7 -0
- package/geometry/operators/cutOperator.d.ts +18 -0
- package/geometry/operators/densifyOperator.d.ts +21 -0
- package/geometry/operators/differenceOperator.d.ts +7 -0
- package/geometry/operators/disjointOperator.d.ts +8 -0
- package/geometry/operators/distanceOperator.d.ts +8 -0
- package/geometry/operators/equalsOperator.d.ts +5 -0
- package/geometry/operators/extendOperator.d.ts +8 -0
- package/geometry/operators/generalizeOperator.d.ts +7 -0
- package/geometry/operators/geodesicBufferOperator.d.ts +13 -0
- package/geometry/operators/geodesicProximityOperator.d.ts +13 -0
- package/geometry/operators/geodeticAreaOperator.d.ts +11 -0
- package/geometry/operators/geodeticDensifyOperator.d.ts +12 -0
- package/geometry/operators/geodeticDistanceOperator.d.ts +14 -0
- package/geometry/operators/geodeticLengthOperator.d.ts +11 -0
- package/geometry/operators/geodeticUtilsOperator.d.ts +11 -0
- package/geometry/operators/graphicBufferOperator.d.ts +7 -0
- package/geometry/operators/integrateOperator.d.ts +9 -0
- package/geometry/operators/intersectionOperator.d.ts +7 -0
- package/geometry/operators/intersectsOperator.d.ts +9 -0
- package/geometry/operators/isNearOperator.d.ts +7 -0
- package/geometry/operators/labelPointOperator.d.ts +14 -0
- package/geometry/operators/lengthOperator.d.ts +7 -0
- package/geometry/operators/linesToPolygonsOperator.d.ts +5 -0
- package/geometry/operators/locateBetweenOperator.d.ts +10 -0
- package/geometry/operators/minimumBoundingCircleOperator.d.ts +13 -0
- package/geometry/operators/multiPartToSinglePartOperator.d.ts +7 -0
- package/geometry/operators/offsetOperator.d.ts +44 -0
- package/geometry/operators/overlapsOperator.d.ts +7 -0
- package/geometry/operators/polygonOverlayOperator.d.ts +6 -0
- package/geometry/operators/polygonSlicerOperator.d.ts +5 -0
- package/geometry/operators/projectOperator.d.ts +41 -0
- package/geometry/operators/proximityOperator.d.ts +8 -0
- package/geometry/operators/relateOperator.d.ts +7 -0
- package/geometry/operators/reshapeOperator.d.ts +5 -0
- package/geometry/operators/shapePreservingProjectOperator.d.ts +27 -0
- package/geometry/operators/simplifyOGCOperator.d.ts +8 -0
- package/geometry/operators/simplifyOperator.d.ts +9 -0
- package/geometry/operators/support/geographicTransformationUtils.d.ts +11 -0
- package/geometry/operators/symmetricDifferenceOperator.d.ts +12 -0
- package/geometry/operators/touchesOperator.d.ts +7 -0
- package/geometry/operators/unionOperator.d.ts +7 -0
- package/geometry/operators/withinOperator.d.ts +9 -0
- package/geometry/support/geodesicUtils.d.ts +8 -0
- package/geometry/support/jsonUtils.d.ts +7 -0
- package/geometry/support/meshUtils.d.ts +5 -0
- package/geometry/support/normalizeUtils.d.ts +7 -0
- package/geometry/support/webMercatorUtils.d.ts +12 -0
- package/geometry.d.ts +38 -0
- package/interfaces.d.ts +31 -32
- package/intl.d.ts +111 -0
- package/kernel.d.ts +5 -0
- package/kernel.js +1 -1
- package/layers/BaseDynamicLayer.d.ts +1 -1
- package/layers/CSVLayer.d.ts +2 -2
- package/layers/CatalogLayer.d.ts +2 -2
- package/layers/FeatureLayer.d.ts +2 -1
- package/layers/GeoJSONLayer.d.ts +2 -1
- package/layers/ILyr3DWasmPerSceneView.js +1 -1
- package/layers/Layer.d.ts +1 -1
- package/layers/Lyr3DWasmPerSceneView.js +1 -1
- package/layers/OGCFeatureLayer.d.ts +1 -1
- package/layers/ParquetLayer.d.ts +1 -1
- package/layers/RouteLayer.js +1 -1
- package/layers/SceneLayer.d.ts +2 -1
- package/layers/StreamLayer.d.ts +6 -5
- package/layers/SubtypeGroupLayer.d.ts +3 -4
- package/layers/VectorTileLayer.d.ts +1 -1
- package/layers/WFSLayer.d.ts +2 -1
- package/layers/WMSLayer.d.ts +2 -2
- package/layers/catalog/catalogUtils.d.ts +6 -0
- package/layers/ogc/wcsUtils.d.ts +6 -0
- package/layers/ogc/wfsUtils.d.ts +6 -0
- package/layers/orientedImagery/transformations/imageToWorld.d.ts +10 -0
- package/layers/orientedImagery/transformations/rectifyMapPoint.js +1 -1
- package/layers/orientedImagery/transformations/worldToImage.d.ts +10 -0
- package/layers/orientedImagery/types.d.ts +1 -1
- package/layers/support/arcadeUtils.d.ts +5 -0
- package/layers/support/csvUtils.d.ts +6 -0
- package/layers/support/fieldUtils.d.ts +9 -0
- package/layers/support/parquetUtils.d.ts +6 -0
- package/layers/support/rasterFunctionConstants.d.ts +9 -0
- package/layers/support/rasterFunctionUtils.d.ts +7 -0
- package/package.json +1 -1
- package/pointCloudRenderers.d.ts +44 -0
- package/popup/content.d.ts +48 -0
- package/rasterRenderers.d.ts +46 -0
- package/renderers/support/AuthoringInfo.d.ts +1 -1
- package/renderers/support/jsonUtils.d.ts +7 -0
- package/renderers/support/utils.d.ts +5 -0
- package/renderers/visualVariables/SizeVariable.d.ts +0 -3
- package/renderers/visualVariables/VisualVariable.d.ts +1 -1
- package/renderers/visualVariables/support/VisualVariableLegendOptions.d.ts +1 -1
- package/renderers.d.ts +46 -0
- package/request.d.ts +17 -0
- package/rest/closestFacility.d.ts +21 -0
- package/rest/featureService/utils.d.ts +5 -0
- package/rest/find.d.ts +21 -0
- package/rest/geometryService.d.ts +14 -0
- package/rest/geoprocessor.d.ts +16 -0
- package/rest/identify.d.ts +19 -0
- package/rest/imageService.d.ts +10 -0
- package/rest/knowledgeGraphService.d.ts +39 -0
- package/rest/lastMileDelivery.d.ts +12 -0
- package/rest/locator.d.ts +24 -0
- package/rest/networkService.d.ts +5 -0
- package/rest/networks/queryAssociations.d.ts +7 -0
- package/rest/networks/support/NetworkElement.d.ts +1 -1
- package/rest/networks/synthesizeAssociationGeometries.d.ts +7 -0
- package/rest/networks/trace.d.ts +6 -0
- package/rest/places.d.ts +34 -0
- package/rest/print.d.ts +74 -0
- package/rest/query.d.ts +33 -0
- package/rest/route.d.ts +18 -0
- package/rest/serviceArea.d.ts +18 -0
- package/rest/support/AreasAndLengthsParameters.d.ts +2 -2
- package/rest/support/AttachmentQuery.d.ts +0 -1
- package/rest/support/AttributeBinsQuery.d.ts +3 -3
- package/rest/support/AutoIntervalBinParameters.d.ts +4 -4
- package/rest/support/DateBinParameters.d.ts +2 -2
- package/rest/support/DateBinTimeInterval.d.ts +1 -1
- package/rest/support/DensifyParameters.d.ts +1 -1
- package/rest/support/DirectionsFeature.d.ts +1 -1
- package/rest/support/GPMessage.d.ts +1 -1
- package/rest/support/LastMileDeliveryParameters.d.ts +1 -1
- package/rest/support/QuantizationParameters.d.ts +3 -3
- package/rest/support/Query.d.ts +0 -1
- package/rest/support/QueryMixin.d.ts +1 -1
- package/rest/support/RelationshipQuery.d.ts +0 -1
- package/rest/support/interfaces.d.ts +1 -2
- package/rest/symbolService.d.ts +9 -0
- package/smartMapping/heuristics/binLevel.d.ts +12 -0
- package/smartMapping/heuristics/scaleRange.d.ts +15 -0
- package/smartMapping/heuristics/sizeRange.d.ts +12 -0
- package/smartMapping/labels/bins.d.ts +13 -0
- package/smartMapping/labels/clusters.d.ts +16 -0
- package/smartMapping/popup/clusters.d.ts +21 -0
- package/smartMapping/popup/templates.d.ts +18 -0
- package/smartMapping/raster/renderers/classBreaks.d.ts +7 -0
- package/smartMapping/raster/renderers/colormap.d.ts +7 -0
- package/smartMapping/raster/renderers/flow.d.ts +19 -0
- package/smartMapping/raster/renderers/rgb.d.ts +7 -0
- package/smartMapping/raster/renderers/shadedRelief.d.ts +7 -0
- package/smartMapping/raster/renderers/stretch.d.ts +7 -0
- package/smartMapping/raster/renderers/uniqueValue.d.ts +7 -0
- package/smartMapping/raster/renderers/vectorField.d.ts +20 -0
- package/smartMapping/raster/support/colorRamps.d.ts +7 -0
- package/smartMapping/raster/support/utils.d.ts +5 -0
- package/smartMapping/renderers/color.d.ts +17 -0
- package/smartMapping/renderers/dotDensity.d.ts +21 -0
- package/smartMapping/renderers/heatmap.d.ts +17 -0
- package/smartMapping/renderers/location.d.ts +10 -0
- package/smartMapping/renderers/opacity.d.ts +19 -0
- package/smartMapping/renderers/pieChart.d.ts +19 -0
- package/smartMapping/renderers/predominance.d.ts +27 -0
- package/smartMapping/renderers/relationship.d.ts +48 -0
- package/smartMapping/renderers/size.d.ts +18 -0
- package/smartMapping/renderers/support/rendererUtils.d.ts +8 -0
- package/smartMapping/renderers/support/spikeUtils.d.ts +6 -0
- package/smartMapping/renderers/type.d.ts +18 -0
- package/smartMapping/renderers/univariateColorSize.d.ts +29 -0
- package/smartMapping/statistics/classBreaks.d.ts +14 -0
- package/smartMapping/statistics/heatmapStatistics.d.ts +15 -0
- package/smartMapping/statistics/histogram.d.ts +17 -0
- package/smartMapping/statistics/predominantCategories.d.ts +6 -0
- package/smartMapping/statistics/summaryStatistics.d.ts +15 -0
- package/smartMapping/statistics/summaryStatisticsForAge.d.ts +8 -1
- package/smartMapping/statistics/support/ageUtils.d.ts +8 -0
- package/smartMapping/statistics/support/predominanceUtils.d.ts +8 -1
- package/smartMapping/statistics/types.d.ts +6 -1
- package/smartMapping/statistics/uniqueValues.d.ts +13 -0
- package/smartMapping/symbology/color.d.ts +8 -0
- package/smartMapping/symbology/dotDensity.d.ts +7 -0
- package/smartMapping/symbology/flow.d.ts +8 -0
- package/smartMapping/symbology/heatmap.d.ts +8 -0
- package/smartMapping/symbology/location.d.ts +8 -0
- package/smartMapping/symbology/pieChart.d.ts +7 -0
- package/smartMapping/symbology/predominance.d.ts +7 -0
- package/smartMapping/symbology/relationship.d.ts +7 -0
- package/smartMapping/symbology/size.d.ts +7 -0
- package/smartMapping/symbology/support/colorRamps.d.ts +7 -0
- package/smartMapping/symbology/type.d.ts +8 -0
- package/support/popupUtils.d.ts +5 -0
- package/support/revision.js +1 -1
- package/support/timeUtils.d.ts +9 -0
- package/symbols/CIMSymbol.d.ts +1 -1
- package/symbols/ExtrudeSymbol3DLayer.d.ts +2 -2
- package/symbols/FillSymbol3DLayer.d.ts +1 -1
- package/symbols/LineSymbol3DLayer.d.ts +2 -2
- package/symbols/ObjectSymbol3DLayer.d.ts +2 -2
- package/symbols/PathSymbol3DLayer.d.ts +2 -2
- package/symbols/TextSymbol.d.ts +2 -2
- package/symbols/support/Symbol3DFillMaterial.d.ts +1 -1
- package/symbols/support/Symbol3DFillMaterial.js +1 -1
- package/symbols/support/Symbol3DHalo.d.ts +8 -4
- package/symbols/support/Symbol3DHalo.js +1 -1
- package/symbols/support/cimConversionUtils.d.ts +9 -0
- package/symbols/support/cimSymbolUtils.d.ts +10 -0
- package/symbols/support/jsonUtils.d.ts +7 -0
- package/symbols/support/symbolUtils.d.ts +5 -0
- package/symbols.d.ts +59 -0
- package/tables/elements.d.ts +41 -0
- package/time/TimeExtent.d.ts +1 -1
- package/time/TimeInterval.d.ts +1 -1
- package/unionTypes.d.ts +5 -0
- package/versionManagement/utils.d.ts +5 -0
- package/versionManagement/versionAdapters/utils.d.ts +5 -0
- package/views/2d/MapViewConstraints.d.ts +18 -10
- package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
- package/views/2d/layers/RouteLayerView2D.js +1 -1
- package/views/2d/layers/TileLayerView2D.js +1 -1
- package/views/2d/layers/support/RouteLayerInteraction.js +1 -1
- package/views/2d/layers/support/RouteLayerWaypointVisualization.js +5 -0
- package/views/3d/analysis/DirectLineMeasurement/types.d.ts +5 -0
- package/views/3d/analysis/LineOfSight/types.d.ts +5 -0
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementError.d.ts +1 -1
- package/views/3d/analysis/VolumeMeasurement/types.d.ts +5 -0
- package/views/3d/environment/ChapmanRaymarching.glsl.js +2 -1
- package/views/3d/interactive/visualElements/PointVisualElement.js +1 -1
- package/views/3d/layers/graphics/Deconflictor.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DLineCalloutSymbolLayer.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/GraphicsDeconflictor.js +1 -1
- package/views/3d/layers/graphics/GraphicsProcessor.js +1 -1
- package/views/3d/layers/graphics/pipeline/symbolization/IconSymbolLayerRenderer.js +1 -1
- package/views/3d/state/helpers/SceneIntersectionHelper.js +1 -1
- package/views/3d/support/pointsOfInterest/StableSurfaceCenter.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/Slice.glsl.js +2 -2
- package/views/3d/webgl-engine/lib/GaussianSplatRenderNode.js +1 -1
- package/views/3d/webgl-engine/materials/HUDMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/LineCalloutMaterial.js +1 -1
- package/views/3d/webgl-engine/shaders/HUDMaterialTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/shaders/LineCalloutTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/shaders/OutputColorHighlightOLID.glsl.js +8 -8
- package/views/3d/webgl.d.ts +6 -0
- package/views/BreakpointsOwner.d.ts +16 -16
- package/views/IBreakpointsOwner.d.ts +15 -15
- package/views/MapView.d.ts +1 -1
- package/views/PopupView.d.ts +2 -2
- package/views/SelectionManager.d.ts +1 -0
- package/views/SelectionManager.js +1 -1
- package/views/VideoView.js +1 -1
- package/views/View.d.ts +6 -8
- package/views/analysis/AreaMeasurement/types.d.ts +6 -0
- package/views/analysis/DistanceMeasurement/types.d.ts +5 -0
- package/views/analysis/ElevationProfile/ElevationProfileError.d.ts +4 -4
- package/views/analysis/ElevationProfile/types.d.ts +6 -0
- package/views/analysis/types.d.ts +5 -0
- package/views/interactive/editGeometry/support/editPlaneUtils.js +1 -1
- package/views/interactive/snapping/GridSnappingEngine.js +1 -1
- package/views/layers/BuildingSceneLayerView.d.ts +1 -1
- package/views/layers/LayerView.d.ts +1 -1
- package/views/support/colorUtils.d.ts +5 -0
- package/views/support/selectionUtils.js +1 -1
- package/webscene/types.d.ts +5 -0
- package/widgets/FeatureForm/FeatureFormViewModel.d.ts +2 -2
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/Features/FeaturesViewModel.d.ts +1 -1
- package/widgets/Home/HomeViewModel.d.ts +1 -1
- package/widgets/Locate/LocateViewModel.d.ts +2 -2
- package/widgets/Search/types.d.ts +5 -0
- package/widgets/TimeSlider/TimeSliderViewModel.d.ts +1 -1
- package/widgets/UtilityNetworkValidateTopology.js +1 -1
- package/widgets/smartMapping/support/utils.d.ts +6 -0
- package/widgets/support/SelectionList/FeatureItem.js +1 -1
- package/widgets/support/SelectionList/LayerItem.js +1 -1
- package/widgets/support/SelectionList/SelectionListViewModel.js +1 -1
- package/widgets/support/SelectionList.js +1 -1
- package/widgets/support/Selector2D/selectorUtils.js +1 -1
- package/widgets/support/symbolPreviewUtils.js +1 -1
- package/widgets/support/widget.d.ts +11 -0
- package/assets/esri/core/workers/chunks/0d1e8d5d9abee38e275e.js +0 -316
- package/assets/esri/core/workers/chunks/73c3ee2697265b0f7208.js +0 -1
- package/assets/esri/core/workers/chunks/cd2ea924cb91cdb6dde9.js +0 -1
- package/assets/esri/core/workers/chunks/d57577c02fb2932e8305.js +0 -1
- package/colorUtils.d.ts +0 -13
- package/core/Logger.d.ts +0 -29
- package/core/Message.d.ts +0 -2
- package/core/Message.js +0 -5
- package/core/accessorSupport/PropertyOrigin.d.ts +0 -2
- package/core/sql/sql92grammar.d.ts +0 -12
- package/core/string.d.ts +0 -3
- package/core/time.d.ts +0 -2
- package/core/timeUtils.d.ts +0 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7136,9785],{159:(e,t,r)=>{r.d(t,{A:()=>l});var i,o=r(31635),n=r(69622),s=r(91429),a=r(99157);let l=i=class extends n.A{constructor(e){super(e),this.steps=[]}getInverse(){const e=new i;for(let t=this.steps.length-1;t>=0;t--){const r=this.steps[t];e.steps.push(r.getInverse())}return e}};(0,o.Cg)([(0,s.MZ)({type:[a.A],nonNullable:!0})],l.prototype,"steps",void 0),l=i=(0,o.Cg)([(0,s.$K)("esri.geometry.operators.support.GeographicTransformation")],l)},4197:(e,t,r)=>{r.d(t,{Vj:()=>u,cj:()=>l,jh:()=>n,l5:()=>a,xm:()=>s});var i=r(34275),o=r(9093);function n(e){return e<=i.y9?new Array(e).fill(0):new Float64Array(e)}function s(e){return((0,i.iu)(e)?e.byteLength/8:e.length)<=i.y9?Array.from(e):new Float64Array(e)}function a(e,t,r){return Array.isArray(e)?e.slice(t,t+r):e.subarray(t,t+r)}function l(e){return[...e]}function u(e){const t=(0,o.vt)();for(let r=0;r<16;++r)t[r]=e[r];return t}},6797:(e,t,r)=>{r.d(t,{Ui:()=>d});var i=r(69622),o=r(7762),n=r(88620);const s=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof i.A}function l(e){return e instanceof o.A?Object.keys(e.items):a(e)?(0,n.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof o.A?e.items[t]:e[t]}function p(e){return e?e.declaredClass:null}function c(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const i=l(e),o=l(t);if(0===i.length&&0===o.length)return;if(!i.length||!o.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const n=o.filter(e=>!i.includes(e)),d=i.filter(e=>!o.includes(e)),m=i.filter(r=>o.includes(r)&&u(e,r)!==u(t,r)).concat(n,d).sort(),y=p(e);if(y&&s.has(y)&&m.length)return{type:"complete",oldValue:e,newValue:t};let f;const h=a(e)&&a(t);for(const i of m){const o=u(e,i),n=u(t,i);let s;if((h||"function"!=typeof o&&"function"!=typeof n)&&o!==n&&(null!=o||null!=n)){if(r&&r[i]&&"function"==typeof r[i])s=r[i]?.(o,n);else if(o instanceof Date&&n instanceof Date){if(o.getTime()===n.getTime())continue;s={type:"complete",oldValue:o,newValue:n}}else s="object"==typeof o&&"object"==typeof n&&p(o)===p(n)?c(o,n):{type:"complete",oldValue:o,newValue:n};null!=s&&(null!=f?f.diff[i]=s:f={type:"partial",diff:{[i]:s}})}}return f}function d(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&p(e)!==p(t)?{type:"complete",oldValue:e,newValue:t}:c(e,t)}},8303:(e,t,r)=>{r.d(t,{A:()=>T});var i=r(31635),o=r(92602),n=r(70333),s=r(11254),a=r(60999),l=r(49186),u=r(53966),p=r(97768),c=r(74887),d=r(84952),m=r(91429),y=r(77548),f=r(20655),h=r(80812),g=r(41318),v=r(10407),b=r(36005),w=r(43937);const T=e=>{const t=e;let T=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new h.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:i}=await r.e(1204).then(r.bind(r,41204));return(0,c.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!o.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:i},content:{updateItem:o}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",o)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const i=!n.id?.findCredential(this.url),o=e===r.id;if(o&&r.portal.user)return this._getUserPrivileges(r,i);let s,a;if(o)s=r.portal.url;else try{s=await(0,y.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!s||!(0,d.b8)(s,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;a=await(n.id?.getCredential(`${s}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}const l=!0,u=!1,p=!1;if(!a)return{features:{edit:l,fullEdit:u},content:{updateItem:p}};try{if(o?await r.reload():(r=new h.default({id:e,portal:{url:s}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,i)}catch(e){(0,c.QP)(e)}return{features:{edit:l,fullEdit:u},content:{updateItem:p}}}_getUserPrivileges(e,t){const r=(0,v.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?n.id?.findCredential(this.url):null;if(!t)return!0;const r=C.credential===t?C.user:await this._fetchEditingUser(e);return C.credential=t,C.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=n.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const i=`${r.owningSystemUrl}/sharing/rest`,o=f.A.getDefault();if(o&&o.loaded&&(0,d.S8)(o.restUrl)===(0,d.S8)(i))return o.user;const l=`${i}/community/self`,u=null!=e?e.signal:null,p=await(0,a.Ke)((0,s.A)(l,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?g.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,i=this.portalItem?.id&&(this.portalItem.portal||f.A.getDefault());return r&&i&&!(0,d.ut)(i.restUrl,r.restUrl)?(t.messages&&t.messages.push(new l.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i.Cg)([(0,m.MZ)({type:h.default})],T.prototype,"portalItem",null),(0,i.Cg)([(0,b.w)("web-document","portalItem",["itemId"])],T.prototype,"readPortalItem",null),(0,i.Cg)([(0,w.K)("web-document","portalItem",{itemId:{type:String}})],T.prototype,"writePortalItem",null),(0,i.Cg)([(0,m.MZ)({clonable:!1})],T.prototype,"resourceReferences",void 0),(0,i.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],T.prototype,"userHasEditingPrivileges",void 0),(0,i.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],T.prototype,"userHasFullEditingPrivileges",void 0),(0,i.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],T.prototype,"userHasUpdateItemPrivileges",void 0),T=(0,i.Cg)([(0,m.$K)("esri.layers.mixins.PortalLayer")],T),T},C={credential:null,user:null}},9093:(e,t,r)=>{function i(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function o(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]]}r.d(t,{o8:()=>o,vt:()=>i,zK:()=>n});const n=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:n,clone:o,create:i,fromValues:function(e,t,r,i,o,n,s,a,l,u,p,c,d,m,y,f){return[e,t,r,i,o,n,s,a,l,u,p,c,d,m,y,f]}},Symbol.toStringTag,{value:"Module"}))},9762:(e,t,r)=>{r.r(t),r.d(t,{projectBuffer:()=>o});var i=r(37539);function o(e,t,r,o,n,s,a=Math.floor(e.length/3)){const l=(0,i.jd)(t,n);if(null==l)return!1;if(l===i.pO){if(e===o&&r===s)return!0;const t=r+3*a;for(let i=r,n=s;i<t;i++,n++)o[n]=e[i]??0;return!0}const u=r+3*a;for(let t=r,i=s;t<u;t+=3,i+=3)l(e,t,o,i);return!0}},10407:(e,t,r)=>{r.d(t,{It:()=>m,LG:()=>s,OM:()=>u,Sm:()=>p,Y:()=>a,bK:()=>l,mm:()=>d,sQ:()=>c});var i=r(91218),o=r(16930),n=r(28735);function s(e,t){if(!a(e,t)){const r=e.typeKeywords;r?r.push(t):e.typeKeywords=[t]}}function a(e,t){return!!e.typeKeywords?.includes(t)}function l(e){return a(e,d.HOSTED_SERVICE)}function u(e,t){const r=e.typeKeywords;if(r){const e=r.indexOf(t);e>-1&&r.splice(e,1)}}function p(e,t,r){r?s(e,t):u(e,t)}async function c(e){const t=e.clone().normalize();let r;if(t.length>1)for(const e of t)r?e.width>r.width&&(r=e):r=e;else r=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,n.ci)(e);const r=o.A.WGS84;return await(0,i.initializeProjection)(t,r),(0,i.project)(e,r)}(r)}const d={CHARTS:"Charts",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function m(e){const{portal:t,isOrgItem:r,itemControl:i}=e,o=t.user?.privileges;let n=!o||o.includes("features:user:edit"),s=!!r&&!!o?.includes("features:user:fullEdit");const a="update"===i||"admin"===i;return a?s=n=!0:s&&(n=!0),{features:{edit:n,fullEdit:s},content:{updateItem:a}}}},17136:(e,t,r)=>{r.d(t,{Y_:()=>N,O7:()=>I,el:()=>A});var i=r(92602),o=r(69052),n=r(49186),s=r(53966),a=r(39829),l=r(82799),u=r(16930),p=r(80754),c=r(21325),d=r(28735),m=r(11254),y=r(60408),f=r(65864),h=r(2272),g=r(84952),v=r(92300);const b=()=>s.A.getLogger("esri.geometry.support.normalizeUtils");function w(e){return"polygon"===e[0].type}function T(e){return"polyline"===e[0].type}function C(e,t,r){if(t){const t=function(e,t){if(!(e instanceof l.A||e instanceof a.A)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw b().error(e),new n.A("internal:geometry",e)}const r=(0,p.r8)(e),i=[];for(const e of r){const r=[];i.push(r),r.push([e[0][0],e[0][1]]);for(let i=0;i<e.length-1;i++){const o=e[i][0],n=e[i][1],s=e[i+1][0],a=e[i+1][1],l=Math.sqrt((s-o)*(s-o)+(a-n)*(a-n)),u=(a-n)/l,p=(s-o)/l,c=l/t;if(c>1){for(let e=1;e<=c-1;e++){const i=e*t,s=p*i+o,a=u*i+n;r.push([s,a])}const e=(l+Math.floor(c-1)*t)/2,i=p*e+o,s=u*e+n;r.push([i,s])}r.push([s,a])}}return function(e){return"polygon"===e.type}(e)?new a.A({rings:i,spatialReference:e.spatialReference}):new l.A({paths:i,spatialReference:e.spatialReference})}(e,1e6);e=(0,d.ci)(t,!0)}return r&&(e=(0,p.kS)(e,r)),e}function S(e,t,r){if(Array.isArray(e)){const i=e[0];if(i>t){const r=(0,p.kd)(i,t);e[0]=i+r*(-2*t)}else if(i<r){const t=(0,p.kd)(i,r);e[0]=i+t*(-2*r)}}else{const i=e.x;if(i>t){const r=(0,p.kd)(i,t);e=e.clone().offset(r*(-2*t),0)}else if(i<r){const t=(0,p.kd)(i,r);e=e.clone().offset(t*(-2*r),0)}}return e}function M(e,t){let r=-1;for(let i=0;i<t.cutIndexes.length;i++){const o=t.cutIndexes[i],n=t.geometries[i],s=(0,p.r8)(n);for(let e=0;e<s.length;e++){const t=s[e];t.some(r=>{if(r[0]<180)return!0;{let r=0;for(let e=0;e<t.length;e++){const i=t[e][0];r=i>r?i:r}r=Number(r.toFixed(9));const i=-360*(0,p.kd)(r,180);for(let r=0;r<t.length;r++){const t=n.getPoint(e,r);n.setPoint(e,r,t.clone().offset(i,0))}return!0}})}if(o===r){if(w(e))for(const t of(0,p.r8)(n))e[o]=e[o].addRing(t);else if(T(e))for(const t of(0,p.r8)(n))e[o]=e[o].addPath(t)}else r=o,e[o]=n}return e}async function A(e,t,r){if(!Array.isArray(e))return A([e],t);t&&"string"!=typeof t&&b().warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const o="string"==typeof t?t:t?.url??i.A.geometryServiceUrl;let n,s,u,w,T,I,O,N,Z=0;const j=[],D=[];for(const t of e)if(null!=t)if(n||(n=t.spatialReference,s=(0,c.Vp)(n),u=n.isWebMercator,I=u?102100:4326,w=p.j7[I].maxX,T=p.j7[I].minX,O=p.j7[I].plus180Line,N=p.j7[I].minus180Line),s)if("mesh"===t.type)D.push(t);else if("point"===t.type)D.push(S(t.clone(),w,T));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map(e=>S(e,w,T)),D.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,s);D.push(e.rings?new a.A(e):e)}else if(t.extent){const e=t.extent,r=(0,p.kd)(e.xmin,T)*(2*w);let i=0===r?t.clone():(0,p.kS)(t.clone(),r);e.offset(r,0);let{xmin:o,xmax:n}=e;o=Number(o.toFixed(9)),n=Number(n.toFixed(9)),e.intersects(O)&&n!==w?(Z=n>Z?n:Z,i=C(i,u),j.push(i),D.push("cut")):e.intersects(N)&&o!==T?(Z=n*(2*w)>Z?n*(2*w):Z,i=C(i,u,360),j.push(i),D.push("cut")):D.push(i)}else D.push(t.clone());else D.push(t);else D.push(t);let F=(0,p.kd)(Z,w),x=-90;const B=F,R=new l.A;for(;F>0;){const e=360*F-180;R.addPath([[e,x],[e,-1*x]]),x*=-1,F--}if(j.length>0&&B>0){const t=M(j,await async function(e,t,r,i){const o=(0,h.Dl)(e),n=t[0].spatialReference,s={...i,responseType:"json",query:{...o.query,f:"json",sr:(0,c.YX)(n),target:JSON.stringify({geometryType:(0,y.$B)(t[0]),geometries:t}),cutter:JSON.stringify(r)}},a=await(0,m.A)(o.path+"/cut",s),{cutIndexes:l,geometries:u=[]}=a.data;return{cutIndexes:l,geometries:u.map(e=>{const t=(0,f.rS)(e);return t.spatialReference=n,t})}}(o,j,R,r)),i=[],n=[];for(let r=0;r<D.length;r++){const o=D[r];if("cut"!==o)n.push(o);else{const o=t.shift(),s=e[r];null!=s&&"polygon"===s.type&&s.rings&&s.rings.length>1&&o.rings.length>=s.rings.length?(i.push(o),n.push("simplify")):n.push(u?(0,d.Gh)(o):o)}}if(!i.length)return n;const s=await async function(e,t,r){const i="string"==typeof e?(0,g.An)(e):e,o=t[0].spatialReference,n=(0,y.$B)(t[0]),s={...r,query:{...i.query,f:"json",sr:(0,c.YX)(o),geometries:JSON.stringify((0,v.X)(t))}},{data:a}=await(0,m.A)(i.path+"/simplify",s);return(0,v.V)(a.geometries,n,o)}(o,i,r),a=[];for(let e=0;e<n.length;e++){const t=n[e];"simplify"!==t?a.push(t):a.push(u?(0,d.Gh)(s.shift()):s.shift())}return a}const _=[];for(let e=0;e<D.length;e++){const t=D[e];if("cut"!==t)_.push(t);else{const e=j.shift();_.push(!0===u?(0,d.Gh)(e):e)}}return _}function I(e,t,r){const i=(0,c.Vp)(r);if(null==i)return e;const[o,n]=i.valid,s=2*n;let a=0,l=0;t>n?a=Math.ceil(Math.abs(t-n)/s):t<o&&(a=-Math.ceil(Math.abs(t-o)/s)),e>n?l=Math.ceil(Math.abs(e-n)/s):e<o&&(l=-Math.ceil(Math.abs(e-o)/s));let u=e+(a-l)*s;const p=u-t;return p>n?u-=s:p<o&&(u+=s),u}function O(e){const t=(0,c.Vp)(e);if(null==t)return null;const[r,i]=t.valid;return new o.hr(r,i)}const N=O(u.A.WGS84);O(u.A.WebMercator)},24097:(e,t,r)=>{r.d(t,{K:()=>i});const i={type:String,json:{read:{source:"token"},write:{target:"token"}}}},25036:(e,t,r)=>{r.d(t,{j:()=>n});var i=r(31635),o=r(91429);const n=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;void 0!==t?.effectiveScaleRange&&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.Cg)([(0,o.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],r.prototype,"minScale",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],r.prototype,"maxScale",void 0),(0,i.Cg)([(0,o.MZ)({readOnly:!0})],r.prototype,"effectiveScaleRange",null),r=(0,i.Cg)([(0,o.$K)("esri.layers.mixins.ScaleRangeLayer")],r),r}},34507:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Rt});var i=r(31635),o=r(92602),n=r(52106),s=r(37838),a=r(4576),l=r(7762),u=r(49186),p=r(53966),c=r(25728),d=r(93637),m=r(74887),y=r(36708),f=r(86211),h=r(84952),g=r(91429),v=r(46130),b=r(5443),w=r(48526),T=r(91218),C=r(16930),S=r(21325),M=r(4146),A=r(63074),I=r(16131),O=r(8303),N=r(25036),Z=r(60694),j=r(25482),D=r(53930),F=r(33910);let x=class extends j.o{constructor(e){super(e),this.break=new D.A({color:[255,255,255],size:12,outline:{color:[0,122,194],width:3}}),this.first=new D.A({color:[0,255,0],size:20,outline:{color:[255,255,255],width:4}}),this.unlocated=new D.A({color:[255,0,0],size:12,outline:{color:[255,255,255],width:3}}),this.last=new D.A({color:[255,0,0],size:20,outline:{color:[255,255,255],width:4}}),this.middle=new D.A({color:[51,51,51],size:12,outline:{color:[0,122,194],width:3}}),this.waypoint=new D.A({color:[255,255,255],size:12,outline:{color:[0,122,194],width:3}})}};(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"break",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"first",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"unlocated",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"last",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"middle",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],x.prototype,"waypoint",void 0),x=(0,i.Cg)([(0,g.$K)("esri.layers.support.RouteStopSymbols")],x);var B=r(94985),R=r(31593);let _=class extends j.o{constructor(e){super(e),this.directionLines=new R.A({color:[0,122,194],width:6}),this.directionPoints=new D.A({color:[255,255,255],size:6,outline:{color:[0,122,194],width:2}}),this.pointBarriers=new D.A({style:"x",size:10,outline:{color:[255,0,0],width:3}}),this.polygonBarriers=new B.A({color:[255,170,0,.6],outline:{width:7.5,color:[255,0,0,.6]}}),this.polylineBarriers=new R.A({width:7.5,color:[255,85,0,.7]}),this.routeInfo=new R.A({width:8,color:[20,89,127]}),this.stops=new x}};(0,i.Cg)([(0,g.MZ)({types:F.Y7})],_.prototype,"directionLines",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],_.prototype,"directionPoints",void 0),(0,i.Cg)([(0,g.MZ)({types:F.wC})],_.prototype,"pointBarriers",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Ac})],_.prototype,"polygonBarriers",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Y7})],_.prototype,"polylineBarriers",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Y7})],_.prototype,"routeInfo",void 0),(0,i.Cg)([(0,g.MZ)({type:x})],_.prototype,"stops",void 0),_=(0,i.Cg)([(0,g.$K)("esri.layers.support.RouteSymbols")],_);var P=r(20655),E=r(80812),L=r(10407),J=r(65494),U=r(11254),k=r(2272),$=r(2073),W=r(93223);let V=class extends j.o{constructor(e){super(e),this.dataType=null,this.name=null,this.parameterNames=null,this.restrictionUsageParameterName=null,this.timeNeutralAttributeName=null,this.trafficSupport=null,this.units=null,this.usageType=null}};(0,i.Cg)([(0,g.MZ)({type:String})],V.prototype,"dataType",void 0),(0,i.Cg)([(0,W.e)($.et,{ignoreUnknown:!1})],V.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({type:[String]})],V.prototype,"parameterNames",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],V.prototype,"restrictionUsageParameterName",void 0),(0,i.Cg)([(0,W.e)($.Mm,{ignoreUnknown:!1})],V.prototype,"timeNeutralAttributeName",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],V.prototype,"trafficSupport",void 0),(0,i.Cg)([(0,W.e)($.dn)],V.prototype,"units",void 0),(0,i.Cg)([(0,W.e)($.WU)],V.prototype,"usageType",void 0),V=(0,i.Cg)([(0,g.$K)("esri.rest.support.NetworkAttribute")],V);const q=V;let G=class extends j.o{constructor(e){super(e),this.buildTime=null,this.name=null,this.networkAttributes=null,this.networkSources=null,this.state=null}};(0,i.Cg)([(0,g.MZ)({type:Number})],G.prototype,"buildTime",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],G.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({type:[q]})],G.prototype,"networkAttributes",void 0),(0,i.Cg)([(0,g.MZ)()],G.prototype,"networkSources",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],G.prototype,"state",void 0),G=(0,i.Cg)([(0,g.$K)("esri.rest.support.NetworkDataset")],G);const K=G;var z=r(69540),Y=r(36005),H=r(43937);let X=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.attributeParameterValues=null,this.description=null,this.distanceAttributeName=null,this.id=null,this.impedanceAttributeName=null,this.name=null,this.restrictionAttributeNames=null,this.simplificationTolerance=null,this.simplificationToleranceUnits=null,this.timeAttributeName=null,this.type=null,this.useHierarchy=null,this.uturnAtJunctions=null}readId(e,t){return t.id??t.itemId??null}readRestrictionAttributes(e,t){const{restrictionAttributeNames:r}=t;return null==r?null:r.map(e=>$.OC.fromJSON(e))}writeRestrictionAttributes(e,t,r){null!=e&&(t[r]=e.map(e=>$.OC.toJSON(e)))}};(0,i.Cg)([(0,g.MZ)({type:[Object],json:{write:!0}})],X.prototype,"attributeParameterValues",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],X.prototype,"description",void 0),(0,i.Cg)([(0,W.e)($.dd,{ignoreUnknown:!1})],X.prototype,"distanceAttributeName",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],X.prototype,"id",void 0),(0,i.Cg)([(0,Y.w)("id",["id","itemId"])],X.prototype,"readId",null),(0,i.Cg)([(0,W.e)($.et,{ignoreUnknown:!1})],X.prototype,"impedanceAttributeName",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],X.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({type:[String],json:{write:!0}})],X.prototype,"restrictionAttributeNames",void 0),(0,i.Cg)([(0,Y.w)("restrictionAttributeNames")],X.prototype,"readRestrictionAttributes",null),(0,i.Cg)([(0,H.K)("restrictionAttributeNames")],X.prototype,"writeRestrictionAttributes",null),(0,i.Cg)([(0,g.MZ)({type:Number,json:{write:{allowNull:!0}}})],X.prototype,"simplificationTolerance",void 0),(0,i.Cg)([(0,W.e)($.hY)],X.prototype,"simplificationToleranceUnits",void 0),(0,i.Cg)([(0,W.e)($.Mm,{ignoreUnknown:!1})],X.prototype,"timeAttributeName",void 0),(0,i.Cg)([(0,W.e)($.ow)],X.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"useHierarchy",void 0),(0,i.Cg)([(0,W.e)($.hE)],X.prototype,"uturnAtJunctions",void 0),X=(0,i.Cg)([(0,g.$K)("esri.rest.support.TravelMode")],X);let Q=class extends j.o{constructor(e){super(e),this.accumulateAttributeNames=null,this.attributeParameterValues=null,this.currentVersion=null,this.defaultTravelMode=null,this.directionsLanguage=null,this.directionsLengthUnits=null,this.directionsSupportedLanguages=null,this.directionsTimeAttribute=null,this.hasZ=null,this.impedance=null,this.networkDataset=null,this.supportedTravelModes=null}readAccumulateAttributes(e){return null==e?null:e.map(e=>$.et.fromJSON(e))}writeAccumulateAttributes(e,t,r){e?.length&&(t[r]=e.map(e=>$.et.toJSON(e)))}get capabilities(){return{supportsNow:(this.currentVersion??10)>=10.81}}readDefaultTravelMode(e,t){const r=t.supportedTravelModes?.find(({id:e})=>e===t.defaultTravelMode)??t.supportedTravelModes?.find(({itemId:e})=>e===t.defaultTravelMode);return r?X.fromJSON(r):null}};function ee(e,t,r,i){i[r]=[t.length,t.length+e.length],e.forEach(e=>{t.push(e.geometry)})}async function te(e,t,r){if(!e)throw new u.A("network-service:missing-url","Url to Network service is missing");const i=(0,k.jV)({f:"json",token:t},r),{data:o}=await(0,U.A)(e,i),n=o.currentVersion>=10.4?async function(e,t,r){try{const i=(0,k.jV)({f:"json",token:t},r),o=(0,h.UC)(e)+"/retrieveTravelModes",{data:{supportedTravelModes:n,defaultTravelMode:s}}=await(0,U.A)(o,i);return{supportedTravelModes:n,defaultTravelMode:s}}catch(e){throw new u.A("network-service:retrieveTravelModes","Could not get to the NAServer's retrieveTravelModes.",{error:e})}}(e,t,r):async function(e,t){const r=(0,k.jV)({f:"json"},t),{data:i}=await(0,U.A)(e.replace(/\/rest\/.*$/i,"/info"),r);if(!i?.owningSystemUrl)return{supportedTravelModes:[],defaultTravelMode:null};const{owningSystemUrl:o}=i,n=(0,h.UC)(o)+"/sharing/rest/portals/self",{data:s}=await(0,U.A)(n,r),a=(0,d.wc)("helperServices.routingUtilities.url",s);if(!a)return{supportedTravelModes:[],defaultTravelMode:null};const l=(0,k.Dl)(o),u=/\/solve$/i.test(l.path)?"Route":/\/solveclosestfacility$/i.test(l.path)?"ClosestFacility":"ServiceAreas",p=(0,k.jV)({f:"json",serviceName:u},t),c=(0,h.UC)(a)+"/GetTravelModes/execute",m=await(0,U.A)(c,p),y=[];let f=null;if(m?.data?.results?.length){const e=m.data.results;for(const t of e)if("supportedTravelModes"===t.paramName){if(t.value?.features)for(const{attributes:e}of t.value.features)if(e){const t=JSON.parse(e.TravelMode);y.push(t)}}else"defaultTravelMode"===t.paramName&&(f=t.value)}return{supportedTravelModes:y,defaultTravelMode:f}}(e,r),{defaultTravelMode:s,supportedTravelModes:a}=await n;return o.defaultTravelMode=s,o.supportedTravelModes=a,Q.fromJSON(o)}(0,i.Cg)([(0,g.MZ)()],Q.prototype,"accumulateAttributeNames",void 0),(0,i.Cg)([(0,Y.w)("accumulateAttributeNames")],Q.prototype,"readAccumulateAttributes",null),(0,i.Cg)([(0,H.K)("accumulateAttributeNames")],Q.prototype,"writeAccumulateAttributes",null),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"attributeParameterValues",void 0),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"capabilities",null),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"currentVersion",void 0),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"defaultTravelMode",void 0),(0,i.Cg)([(0,Y.w)("defaultTravelMode",["defaultTravelMode","supportedTravelModes"])],Q.prototype,"readDefaultTravelMode",null),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"directionsLanguage",void 0),(0,i.Cg)([(0,W.e)($.Z7)],Q.prototype,"directionsLengthUnits",void 0),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"directionsSupportedLanguages",void 0),(0,i.Cg)([(0,W.e)($.Mm,{ignoreUnknown:!1})],Q.prototype,"directionsTimeAttribute",void 0),(0,i.Cg)([(0,g.MZ)()],Q.prototype,"hasZ",void 0),(0,i.Cg)([(0,W.e)($.et,{ignoreUnknown:!1})],Q.prototype,"impedance",void 0),(0,i.Cg)([(0,g.MZ)({type:K})],Q.prototype,"networkDataset",void 0),(0,i.Cg)([(0,g.MZ)({type:[X]})],Q.prototype,"supportedTravelModes",void 0),Q=(0,i.Cg)([(0,g.$K)("esri.rest.support.NetworkServiceDescription")],Q);var re=r(16649),ie=r(17136);function oe(e,t){if(null==e)return null;const r={},i=new RegExp(`^${t}`,"i");for(const o of Object.keys(e))if(i.test(o)){const i=o.slice(t.length);r[$.et.fromJSON(i)]=e[o]}return r}function ne(e,t,r){if(null!=e){t.attributes||(t.attributes={});for(const i in e){const o=$.et.toJSON(i);t.attributes[`${r}${o}`]=e[i]}}}function se(e){const t={};for(const r of Object.keys(e)){const i=r;t[$.et.fromJSON(i)]=e[r]}return t}function ae(e){const t={};for(const r of Object.keys(e)){const i=r;t[$.et.toJSON(i)]=e[r]}return t}function le(e,t){return null==e||null==t?null:Math.round((e-t)/6e4)}function ue(e){const t=e.toJSON(),r=t;return r.accumulateAttributeNames&&=t.accumulateAttributeNames?.join(),r.attributeParameterValues&&=JSON.stringify(t.attributeParameterValues),r.barriers&&=JSON.stringify(t.barriers),r.locateSettings&&=JSON.stringify(t.locateSettings),r.outSR&&=t.outSR?.wkid,r.overrides&&=JSON.stringify(t.overrides),r.polygonBarriers&&=JSON.stringify(t.polygonBarriers),r.polylineBarriers&&=JSON.stringify(t.polylineBarriers),r.restrictionAttributeNames&&=t.restrictionAttributeNames?.join(),r.stops&&=JSON.stringify(t.stops),r.travelMode&&=JSON.stringify(t.travelMode),r}var pe=r(22671),ce=r(66552),de=r(37807);const me=new ce.J({0:"informative",1:"process-definition",2:"process-start",3:"process-stop",50:"warning",100:"error",101:"empty",200:"abort"});let ye=class extends de.A{constructor(e){super(e),this.type=null}};(0,i.Cg)([(0,g.MZ)({type:String,json:{read:me.read,write:me.write}})],ye.prototype,"type",void 0),ye=(0,i.Cg)([(0,g.$K)("esri.rest.support.NAMessage")],ye);const fe=ye;var he=r(82799),ge=r(86738);let ve=class extends j.o{constructor(e){super(e)}};(0,i.Cg)([(0,g.MZ)({json:{read:{source:"string"}}})],ve.prototype,"text",void 0),(0,i.Cg)([(0,W.e)($.Ec,{name:"stringType"})],ve.prototype,"type",void 0),ve=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionsString")],ve);const be=ve;let we=class extends j.o{constructor(e){super(e),this.arriveTime=null,this.arriveTimeOffset=null,this.geometry=null,this.strings=null}readArriveTimeOffset(e,t){return le(t.ETA,t.arriveTimeUTC)}readGeometry(e,t){return ge.A.fromJSON(t.point)}};(0,i.Cg)([(0,g.MZ)({type:Date,json:{read:{source:"arriveTimeUTC"}}})],we.prototype,"arriveTime",void 0),(0,i.Cg)([(0,g.MZ)()],we.prototype,"arriveTimeOffset",void 0),(0,i.Cg)([(0,Y.w)("arriveTimeOffset",["arriveTimeUTC","ETA"])],we.prototype,"readArriveTimeOffset",null),(0,i.Cg)([(0,g.MZ)({type:ge.A})],we.prototype,"geometry",void 0),(0,i.Cg)([(0,Y.w)("geometry",["point"])],we.prototype,"readGeometry",null),(0,i.Cg)([(0,g.MZ)({type:[be]})],we.prototype,"strings",void 0),we=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionsEvent")],we);const Te=we;let Ce=class extends n.A{constructor(e){super(e),this.events=null,this.geometry=null,this.strings=null}set attributes(e){super.attributes=e}readGeometry(e,t){const r=function(e){if(null==e||""===e)return null;let t=0,r=0,i=0,o=0;const n=[];let s,a,l,u,p,c,d,m,y=0,f=0,h=0;if(p=e.match(/((\+|-)[^+\-|]+|\|)/g),p||(p=[]),0===parseInt(p[y],32)){y=2;const e=parseInt(p[y],32);y++,c=parseInt(p[y],32),y++,1&e&&(f=p.indexOf("|")+1,d=parseInt(p[f],32),f++),2&e&&(h=p.indexOf("|",f)+1,m=parseInt(p[h],32),h++)}else c=parseInt(p[y],32),y++;for(;y<p.length&&"|"!==p[y];){s=parseInt(p[y],32)+t,y++,t=s,a=parseInt(p[y],32)+r,y++,r=a;const e=[s/c,a/c];f&&(u=parseInt(p[f],32)+i,f++,i=u,e.push(u/d)),h&&(l=parseInt(p[h],32)+o,h++,o=l,e.push(l/m)),n.push(e)}return{paths:[n],hasZ:f>0,hasM:h>0}}(t.compressedGeometry);return null!=r?he.A.fromJSON(r):null}};(0,i.Cg)([(0,g.MZ)({type:[Te]})],Ce.prototype,"events",void 0),(0,i.Cg)([(0,g.MZ)({type:he.A})],Ce.prototype,"geometry",void 0),(0,i.Cg)([(0,Y.w)("geometry",["compressedGeometry"])],Ce.prototype,"readGeometry",null),(0,i.Cg)([(0,g.MZ)({type:[be]})],Ce.prototype,"strings",void 0),Ce=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionsFeature")],Ce);const Se=Ce;let Me=class extends pe.A{constructor(e){super(e),this.extent=null,this.features=[],this.geometryType="polyline",this.routeId=null,this.routeName=null,this.totalDriveTime=null,this.totalLength=null,this.totalTime=null}readFeatures(e,t){if(!e)return[];const r=t.summary.envelope.spatialReference??t.spatialReference,i=r&&C.A.fromJSON(r);return e.map(e=>{const t=Se.fromJSON(e);if(null!=t.geometry&&(t.geometry.spatialReference=i),null!=t.events)for(const e of t.events)null!=e.geometry&&(e.geometry.spatialReference=i);return t})}get mergedGeometry(){return this.features?function(e,t){if(0===e.length)return new he.A({spatialReference:t});const r=[];for(const t of e)for(const e of t.paths)r.push(...e);const i=[];r.forEach((e,t)=>{0!==t&&e[0]===r[t-1][0]&&e[1]===r[t-1][1]||i.push(e)});const{hasM:o,hasZ:n}=e[0];return new he.A({hasM:o,hasZ:n,paths:[i],spatialReference:t})}(this.features.map(({geometry:e})=>e),this.extent.spatialReference):null}get strings(){return this.features.flatMap(({strings:e})=>e).filter(a.Ru)}};(0,i.Cg)([(0,g.MZ)({type:b.A,json:{read:{source:"summary.envelope"}}})],Me.prototype,"extent",void 0),(0,i.Cg)([(0,g.MZ)({nonNullable:!0})],Me.prototype,"features",void 0),(0,i.Cg)([(0,Y.w)("features")],Me.prototype,"readFeatures",null),(0,i.Cg)([(0,g.MZ)()],Me.prototype,"geometryType",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],Me.prototype,"mergedGeometry",null),(0,i.Cg)([(0,g.MZ)()],Me.prototype,"routeId",void 0),(0,i.Cg)([(0,g.MZ)()],Me.prototype,"routeName",void 0),(0,i.Cg)([(0,g.MZ)({value:null,readOnly:!0})],Me.prototype,"strings",null),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"summary.totalDriveTime"}}})],Me.prototype,"totalDriveTime",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"summary.totalLength"}}})],Me.prototype,"totalLength",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"summary.totalTime"}}})],Me.prototype,"totalTime",void 0),Me=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionsFeatureSet")],Me);const Ae=Me;let Ie=class extends j.o{constructor(e){super(e),this.directionLines=null,this.directionPoints=null,this.directions=null,this.route=null,this.routeName=null,this.stops=null,this.traversedEdges=null,this.traversedJunctions=null,this.traversedTurns=null}};(0,i.Cg)([(0,g.MZ)({type:pe.A,json:{write:!0}})],Ie.prototype,"directionLines",void 0),(0,i.Cg)([(0,g.MZ)({type:pe.A,json:{write:!0}})],Ie.prototype,"directionPoints",void 0),(0,i.Cg)([(0,g.MZ)({type:Ae,json:{write:!0}})],Ie.prototype,"directions",void 0),(0,i.Cg)([(0,g.MZ)({type:n.A,json:{write:!0}})],Ie.prototype,"route",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],Ie.prototype,"routeName",void 0),(0,i.Cg)([(0,g.MZ)({type:[n.A],json:{write:!0}})],Ie.prototype,"stops",void 0),(0,i.Cg)([(0,g.MZ)({type:pe.A,json:{write:!0}})],Ie.prototype,"traversedEdges",void 0),(0,i.Cg)([(0,g.MZ)({type:pe.A,json:{write:!0}})],Ie.prototype,"traversedJunctions",void 0),(0,i.Cg)([(0,g.MZ)({type:pe.A,json:{write:!0}})],Ie.prototype,"traversedTurns",void 0),Ie=(0,i.Cg)([(0,g.$K)("esri.rest.support.RouteResult")],Ie);const Oe=Ie;function Ne(e){return e?pe.A.fromJSON(e).features.filter(a.Ru):[]}let Ze=class extends j.o{constructor(e){super(e),this.checksum=null,this.messages=null,this.pointBarriers=null,this.polylineBarriers=null,this.polygonBarriers=null,this.routeResults=null}readPointBarriers(e,t){return Ne(t.barriers)}readPolylineBarriers(e){return Ne(e)}readPolygonBarriers(e){return Ne(e)}};function je(e){return e instanceof pe.A}async function De(e,t,r){const i=[],o=[],n={},s={},a=(0,k.Dl)(e),{path:l}=a;je(t.stops)&&ee(t.stops.features,o,"stops.features",n),je(t.pointBarriers)&&ee(t.pointBarriers.features,o,"pointBarriers.features",n),je(t.polylineBarriers)&&ee(t.polylineBarriers.features,o,"polylineBarriers.features",n),je(t.polygonBarriers)&&ee(t.polygonBarriers.features,o,"polygonBarriers.features",n);const u=await(0,ie.el)(o);for(const e in n){const t=n[e];i.push(e),s[e]=u.slice(t[0],t[1])}if(function(e,t){for(let r=0;r<t.length;r++){const i=e[t[r]];if(i&&i.length)for(const e of i)if(null!=e&&e.hasZ)return!0}return!1}(s,i)){let e=null;try{e=await te(l,t.apiKey,r)}catch{}e&&!e.hasZ&&function(e,t){for(let r=0;r<t.length;r++){const i=e[t[r]];if(i&&i.length)for(const e of i)e.z=void 0}p.A.getLogger("esri.rest.networkService").warnOnce("The remote Network Analysis service is powered by a network dataset which is not Z-aware.\nZ-coordinates of the input geometry are ignored.")}(s,i)}for(const e in s)s[e].forEach((r,i)=>{(0,re.Jt)(t,e)[i].geometry=r});const c={...r,query:{...a.query,...ue(t),f:"json"}},d=l.endsWith("/solve")?l:`${l}/solve`,{data:m}=await(0,U.A)(d,c);return function(e){const{barriers:t,checksum:r,directionLines:i,directionPoints:o,directions:n,messages:s,polygonBarriers:a,polylineBarriers:l,routes:u,stops:p,traversedEdges:c,traversedJunctions:d,traversedTurns:m}=e,y=e=>{const t=h.find(t=>t.routeName===e);if(null!=t)return t;const r={routeId:h.length+1,routeName:e};return h.push(r),r},f=e=>{const t=h.find(t=>t.routeId===e);if(null!=t)return t;const r={routeId:e,routeName:null};return h.push(r),r},h=[];u?.features.forEach((e,t)=>{e.geometry.spatialReference=u.spatialReference??void 0;const r=e.attributes.Name,i=t+1;h.push({routeId:i,routeName:r,route:e})}),n?.forEach(e=>{const{routeName:t}=e;y(t).directions=e});const g=p?.features.every(e=>null==e.attributes.RouteName)&&h.length>0?h[0].routeName:null;return p?.features.forEach(e=>{e.geometry&&(e.geometry.spatialReference??=p.spatialReference??void 0);const t=g??e.attributes.RouteName,r=y(t);r.stops??=[],r.stops.push(e)}),i?.features.forEach(e=>{const t=e.attributes.RouteID,r=f(t),{geometryType:o,spatialReference:n}=i;r.directionLines??={features:[],geometryType:o,spatialReference:n},r.directionLines.features.push(e)}),o?.features.forEach(e=>{const t=e.attributes.RouteID,r=f(t),{geometryType:i,spatialReference:n}=o;r.directionPoints??={features:[],geometryType:i,spatialReference:n},r.directionPoints.features.push(e)}),c?.features.forEach(e=>{const t=e.attributes.RouteID,r=f(t),{geometryType:i,spatialReference:o}=c;r.traversedEdges??={features:[],geometryType:i,spatialReference:o},r.traversedEdges.features.push(e)}),d?.features.forEach(e=>{const t=e.attributes.RouteID,r=f(t),{geometryType:i,spatialReference:o}=d;r.traversedJunctions??={features:[],geometryType:i,spatialReference:o},r.traversedJunctions.features.push(e)}),m?.features.forEach(e=>{const t=e.attributes.RouteID,r=f(t);r.traversedTurns??={features:[]},r.traversedTurns.features.push(e)}),Ze.fromJSON({barriers:t,checksum:r,messages:s,polygonBarriers:a,polylineBarriers:l,routeResults:h})}(m)}var Fe;(0,i.Cg)([(0,g.MZ)({type:String})],Ze.prototype,"checksum",void 0),(0,i.Cg)([(0,g.MZ)({type:[fe]})],Ze.prototype,"messages",void 0),(0,i.Cg)([(0,g.MZ)({type:[n.A]})],Ze.prototype,"pointBarriers",void 0),(0,i.Cg)([(0,Y.w)("pointBarriers",["barriers"])],Ze.prototype,"readPointBarriers",null),(0,i.Cg)([(0,g.MZ)({type:[n.A]})],Ze.prototype,"polylineBarriers",void 0),(0,i.Cg)([(0,Y.w)("polylineBarriers")],Ze.prototype,"readPolylineBarriers",null),(0,i.Cg)([(0,g.MZ)({type:[n.A]})],Ze.prototype,"polygonBarriers",void 0),(0,i.Cg)([(0,Y.w)("polygonBarriers")],Ze.prototype,"readPolygonBarriers",null),(0,i.Cg)([(0,g.MZ)({type:[Oe]})],Ze.prototype,"routeResults",void 0),Ze=(0,i.Cg)([(0,g.$K)("esri.rest.support.RouteSolveResult")],Ze);let xe=class extends((0,z.OU)(j.o)){static{Fe=this}constructor(e){super(e),this.directionLineType=null,this.directionPointId=null,this.distance=null,this.duration=null,this.fromLevel=null,this.geometry=null,this.objectId=null,this.popupTemplate=null,this.symbol=null,this.toLevel=null,this.type="direction-line"}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"DirectionLineType",alias:"Line Type",type:"esriFieldTypeInteger"},{name:"DirectionPointID",alias:"Direction Point ID",type:"esriFieldTypeInteger"},{name:"FromLevel",alias:"From Level",type:"esriFieldTypeInteger"},{name:"Meters",alias:"Meters",type:"esriFieldTypeDouble"},{name:"Minutes",alias:"Minutes",type:"esriFieldTypeDouble"},{name:"ToLevel",alias:"To Level",type:"esriFieldTypeInteger"}]}static fromGraphic(e){return new Fe({directionLineType:$.gD.fromJSON(e.attributes.DirectionLineType),directionPointId:e.attributes.DirectionPointID,distance:e.attributes.Meters,duration:e.attributes.Minutes,fromLevel:e.attributes.FromLevel??null,geometry:e.geometry,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,symbol:e.symbol,toLevel:e.attributes.ToLevel??null})}toGraphic(){const e={ObjectID:this.objectId,DirectionLineType:this.directionLineType?$.gD.toJSON(this.directionLineType):null,DirectionPointID:this.directionPointId,Meters:this.distance,Minutes:this.duration};return null!=this.fromLevel&&(e.FromLevel=this.fromLevel),null!=this.toLevel&&(e.ToLevel=this.toLevel),new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};var Be;(0,i.Cg)([(0,g.MZ)({type:$.gD.apiValues,json:{read:{source:"attributes.DirectionLineType",reader:$.gD.read}}})],xe.prototype,"directionLineType",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.DirectionPointID"}}})],xe.prototype,"directionPointId",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Meters"}}})],xe.prototype,"distance",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Minutes"}}})],xe.prototype,"duration",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.FromLevel"}}})],xe.prototype,"fromLevel",void 0),(0,i.Cg)([(0,g.MZ)({type:he.A})],xe.prototype,"geometry",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ObjectID"}}})],xe.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],xe.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],xe.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ToLevel"}}})],xe.prototype,"toLevel",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],xe.prototype,"type",void 0),xe=Fe=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionLine")],xe);let Re=class extends((0,z.OU)(j.o)){static{Be=this}constructor(e){super(e),this.alternateName=null,this.arrivalTime=null,this.arrivalTimeOffset=null,this.azimuth=null,this.branchName=null,this.directionPointType=null,this.displayText=null,this.exitName=null,this.geometry=null,this.intersectingName=null,this.level=null,this.name=null,this.objectId=null,this.popupTemplate=null,this.sequence=null,this.shortVoiceInstruction=null,this.stopId=null,this.symbol=null,this.towardName=null,this.type="direction-point",this.voiceInstruction=null}readArrivalTime(e,t){return null!=t.attributes.ArrivalTime?new Date(t.attributes.ArrivalTime):null}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"AlternateName",alias:"Alternative Name",type:"esriFieldTypeString"},{name:"ArrivalTime",alias:"Arrival Time",type:"esriFieldTypeDate"},{name:"ArrivalUTCOffset",alias:"Arrival Time Offset",type:"esriFieldTypeInteger"},{name:"Azimuth",alias:"Azimuth",type:"esriFieldTypeDouble"},{name:"BranchName",alias:"Branch Name",type:"esriFieldTypeString"},{name:"DirectionPointType",alias:"Directions Point Type",type:"esriFieldTypeInteger"},{name:"DisplayText",alias:"Display Text",type:"esriFieldTypeString"},{name:"ExitName",alias:"Exit Name",type:"esriFieldTypeString"},{name:"IntersectingName",alias:"Intersecting Name",type:"esriFieldTypeString"},{name:"Level",alias:"Level",type:"esriFieldTypeInteger"},{name:"Name",alias:"Name",type:"esriFieldTypeString"},{name:"Sequence",alias:"Sequence",type:"esriFieldTypeInteger"},{name:"ShortVoiceInstruction",alias:"Short Voice Instruction",type:"esriFieldTypeString"},{name:"StopID",alias:"Stop ID",type:"esriFieldTypeInteger"},{name:"TowardName",alias:"Toward Name",type:"esriFieldTypeString"},{name:"VoiceInstruction",alias:"Voice Instruction",type:"esriFieldTypeString"}]}static fromGraphic(e){return new Be({alternateName:e.attributes.AlternateName??null,arrivalTime:null!=e.attributes.ArrivalTime?new Date(e.attributes.ArrivalTime):null,arrivalTimeOffset:e.attributes.ArrivalUTCOffset??null,azimuth:e.attributes.Azimuth??null,branchName:e.attributes.BranchName??null,directionPointType:$._6.fromJSON(e.attributes.DirectionPointType),displayText:e.attributes.DisplayText??null,exitName:e.attributes.ExitName??null,geometry:e.geometry,intersectingName:e.attributes.IntersectingName??null,level:e.attributes.Level??null,name:e.attributes.Name??null,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,sequence:e.attributes.Sequence,shortVoiceInstruction:e.attributes.ShortVoiceInstruction??null,stopId:e.attributes.StopID??null,symbol:e.symbol,towardName:e.attributes.TowardName??null,voiceInstruction:e.attributes.VoiceInstruction??null})}toGraphic(){const e={ObjectID:this.objectId,DirectionPointType:this.directionPointType?$._6.toJSON(this.directionPointType):null,Sequence:this.sequence,StopID:this.stopId};return null!=this.alternateName&&(e.AlternateName=this.alternateName),null!=this.arrivalTime&&(e.ArrivalTime=this.arrivalTime.getTime()),null!=this.arrivalTimeOffset&&(e.ArrivalUTCOffset=this.arrivalTimeOffset),null!=this.azimuth&&(e.Azimuth=this.azimuth),null!=this.branchName&&(e.BranchName=this.branchName),null!=this.displayText&&(e.DisplayText=this.displayText),null!=this.exitName&&(e.ExitName=this.exitName),null!=this.intersectingName&&(e.IntersectingName=this.intersectingName),null!=this.level&&(e.Level=this.level),null!=this.name&&(e.Name=this.name),null!=this.shortVoiceInstruction&&(e.ShortVoiceInstruction=this.shortVoiceInstruction),null!=this.towardName&&(e.TowardName=this.towardName),null!=this.voiceInstruction&&(e.VoiceInstruction=this.voiceInstruction),new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};var _e;(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.AlternateName"}}})],Re.prototype,"alternateName",void 0),(0,i.Cg)([(0,g.MZ)({type:Date})],Re.prototype,"arrivalTime",void 0),(0,i.Cg)([(0,Y.w)("arrivalTime",["attributes.ArrivalTime"])],Re.prototype,"readArrivalTime",null),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ArrivalUTCOffset"}}})],Re.prototype,"arrivalTimeOffset",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Azimuth"}}})],Re.prototype,"azimuth",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.BranchName"}}})],Re.prototype,"branchName",void 0),(0,i.Cg)([(0,g.MZ)({type:$._6.apiValues,json:{read:{source:"attributes.DirectionPointType",reader:$._6.read}}})],Re.prototype,"directionPointType",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.DisplayText"}}})],Re.prototype,"displayText",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ExitName"}}})],Re.prototype,"exitName",void 0),(0,i.Cg)([(0,g.MZ)({type:ge.A})],Re.prototype,"geometry",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.IntersectingName"}}})],Re.prototype,"intersectingName",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Level"}}})],Re.prototype,"level",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Name"}}})],Re.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ObjectID"}}})],Re.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],Re.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Sequence"}}})],Re.prototype,"sequence",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ShortVoiceInstruction"}}})],Re.prototype,"shortVoiceInstruction",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.StopID"}}})],Re.prototype,"stopId",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],Re.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.TowardName"}}})],Re.prototype,"towardName",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],Re.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.VoiceInstruction"}}})],Re.prototype,"voiceInstruction",void 0),Re=Be=(0,i.Cg)([(0,g.$K)("esri.rest.support.DirectionPoint")],Re);let Pe=class extends((0,z.OU)(j.o)){static{_e=this}constructor(e){super(e),this.addedCost=null,this.barrierType=null,this.costs=null,this.curbApproach=null,this.fullEdge=null,this.name=null,this.objectId=null,this.popupTemplate=null,this.positionAlong=null,this.sideOfEdge=null,this.sourceId=null,this.sourceOid=null,this.status=null,this.symbol=null,this.type="point-barrier"}readCosts(e,t){return oe(t.attributes,"Attr_")}writeCosts(e,t){ne(e,t,"Attr_")}set geometry(e){this._get("geometry")&&(this._set("positionAlong",null),this._set("sideOfEdge",null),this._set("sourceId",null),this._set("sourceOid",null),this._set("status",null)),this._set("geometry",e)}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"AddedCost",alias:"Added Cost",type:"esriFieldTypeDouble"},{name:"BarrierType",alias:"Barrier Type",type:"esriFieldTypeInteger"},{name:"Costs",alias:"Costs",type:"esriFieldTypeString"},{name:"CurbApproach",alias:"Curb Approach",type:"esriFieldTypeInteger"},{name:"FullEdge",alias:"Full Edge",type:"esriFieldTypeInteger"},{name:"Name",alias:"Name",type:"esriFieldTypeString"},{name:"Status",alias:"Status",type:"esriFieldTypeInteger"}]}static fromGraphic(e){return new _e({addedCost:e.attributes.AddedCost??null,barrierType:null!=e.attributes.BarrierType?$.iM.fromJSON(e.attributes.BarrierType):null,costs:null!=e.attributes.Costs?se(JSON.parse(e.attributes.Costs)):null,curbApproach:null!=e.attributes.CurbApproach?$.JJ.fromJSON(e.attributes.CurbApproach):null,fullEdge:null!=e.attributes.FullEdge?$.fe.fromJSON(e.attributes.FullEdge):null,geometry:e.geometry,name:e.attributes.Name??null,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,status:null!=e.attributes.Status?$.$r.fromJSON(e.attributes.Status):null,symbol:e.symbol})}toGraphic(){const e={ObjectID:this.objectId,AddedCost:this.addedCost,BarrierType:this.barrierType?$.iM.toJSON(this.barrierType):null,Costs:this.costs?JSON.stringify(ae(this.costs)):null,CurbApproach:this.curbApproach?$.JJ.toJSON(this.curbApproach):null,FullEdge:this.fullEdge?$.fe.toJSON(this.fullEdge):null,Name:this.name,Status:this.status?$.$r.toJSON(this.status):null};return new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};(0,i.Cg)([(0,g.MZ)()],Pe.prototype,"addedCost",void 0),(0,i.Cg)([(0,g.MZ)({type:$.iM.apiValues,json:{name:"attributes.BarrierType",read:{reader:$.iM.read},write:{writer:$.iM.write}}})],Pe.prototype,"barrierType",void 0),(0,i.Cg)([(0,g.MZ)()],Pe.prototype,"costs",void 0),(0,i.Cg)([(0,Y.w)("costs",["attributes"])],Pe.prototype,"readCosts",null),(0,i.Cg)([(0,H.K)("costs")],Pe.prototype,"writeCosts",null),(0,i.Cg)([(0,g.MZ)({type:$.JJ.apiValues,json:{read:{source:"attributes.CurbApproach",reader:$.JJ.read}}})],Pe.prototype,"curbApproach",void 0),(0,i.Cg)([(0,g.MZ)({type:$.fe.apiValues,json:{name:"attributes.FullEdge",read:{reader:$.fe.read},write:{writer:$.fe.write}}})],Pe.prototype,"fullEdge",void 0),(0,i.Cg)([(0,g.MZ)({type:ge.A,json:{write:!0},value:null})],Pe.prototype,"geometry",null),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Name"}})],Pe.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.ObjectID"}})],Pe.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],Pe.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.PosAlong"}})],Pe.prototype,"positionAlong",void 0),(0,i.Cg)([(0,g.MZ)({type:$.mt.apiValues,json:{name:"attributes.SideOfEdge",read:{reader:$.mt.read},write:{writer:$.mt.write}}})],Pe.prototype,"sideOfEdge",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.SourceID"}})],Pe.prototype,"sourceId",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.SourceOID"}})],Pe.prototype,"sourceOid",void 0),(0,i.Cg)([(0,g.MZ)({type:$.$r.apiValues,json:{read:{source:"attributes.Status",reader:$.$r.read}}})],Pe.prototype,"status",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],Pe.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],Pe.prototype,"type",void 0),Pe=_e=(0,i.Cg)([(0,g.$K)("esri.rest.support.PointBarrier")],Pe);var Ee,Le=r(39829);let Je=class extends((0,z.OU)(j.o)){static{Ee=this}constructor(e){super(e),this.barrierType=null,this.costs=null,this.geometry=null,this.name=null,this.objectId=null,this.popupTemplate=null,this.scaleFactor=null,this.symbol=null,this.type="polygon-barrier"}readCosts(e,t){return oe(t.attributes,"Attr_")}writeCosts(e,t){ne(e,t,"Attr_")}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"BarrierType",alias:"Barrier Type",type:"esriFieldTypeInteger"},{name:"Costs",alias:"Costs",type:"esriFieldTypeString"},{name:"Name",alias:"Name",type:"esriFieldTypeString"},{name:"ScaleFactor",alias:"Scale Factor",type:"esriFieldTypeDouble"}]}static fromGraphic(e){return new Ee({barrierType:null!=e.attributes.BarrierType?$.iM.fromJSON(e.attributes.BarrierType):null,costs:null!=e.attributes.Costs?se(JSON.parse(e.attributes.Costs)):null,geometry:e.geometry,name:e.attributes.Name??null,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,scaleFactor:e.attributes.ScaleFactor??null,symbol:e.symbol})}toGraphic(){const e={ObjectID:this.objectId,BarrierType:this.barrierType?$.iM.toJSON(this.barrierType):null,Costs:this.costs?JSON.stringify(ae(this.costs)):null,Name:this.name??null,ScaleFactor:this.scaleFactor??null};return new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};var Ue;(0,i.Cg)([(0,g.MZ)({type:$.iM.apiValues,json:{name:"attributes.BarrierType",read:{reader:$.iM.read},write:{writer:$.iM.write}}})],Je.prototype,"barrierType",void 0),(0,i.Cg)([(0,g.MZ)()],Je.prototype,"costs",void 0),(0,i.Cg)([(0,Y.w)("costs",["attributes"])],Je.prototype,"readCosts",null),(0,i.Cg)([(0,H.K)("costs")],Je.prototype,"writeCosts",null),(0,i.Cg)([(0,g.MZ)({type:Le.A,json:{write:!0}})],Je.prototype,"geometry",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Name"}})],Je.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.ObjectID"}})],Je.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],Je.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)()],Je.prototype,"scaleFactor",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],Je.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],Je.prototype,"type",void 0),Je=Ee=(0,i.Cg)([(0,g.$K)("esri.rest.support.PolygonBarrier")],Je);let ke=class extends((0,z.OU)(j.o)){static{Ue=this}constructor(e){super(e),this.barrierType=null,this.costs=null,this.geometry=null,this.name=null,this.objectId=null,this.popupTemplate=null,this.scaleFactor=null,this.symbol=null,this.type="polyline-barrier"}readCosts(e,t){return oe(t.attributes,"Attr_")}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"BarrierType",alias:"Barrier Type",type:"esriFieldTypeInteger"},{name:"Costs",alias:"Costs",type:"esriFieldTypeString"},{name:"Name",alias:"Name",type:"esriFieldTypeString"},{name:"ScaleFactor",alias:"Scale Factor",type:"esriFieldTypeDouble"}]}static fromGraphic(e){return new Ue({barrierType:null!=e.attributes.BarrierType?$.iM.fromJSON(e.attributes.BarrierType):null,costs:null!=e.attributes.Costs?se(JSON.parse(e.attributes.Costs)):null,geometry:e.geometry,name:e.attributes.Name??null,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,scaleFactor:e.attributes.ScaleFactor??null,symbol:e.symbol})}toGraphic(){const e={ObjectID:this.objectId,BarrierType:this.barrierType?$.iM.toJSON(this.barrierType):null,Costs:this.costs?JSON.stringify(ae(this.costs)):null,Name:this.name,ScaleFactor:this.scaleFactor};return new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};(0,i.Cg)([(0,g.MZ)({type:$.iM.apiValues,json:{read:{source:"attributes.BarrierType",reader:$.iM.read}}})],ke.prototype,"barrierType",void 0),(0,i.Cg)([(0,g.MZ)()],ke.prototype,"costs",void 0),(0,i.Cg)([(0,Y.w)("costs",["attributes"])],ke.prototype,"readCosts",null),(0,i.Cg)([(0,g.MZ)({type:he.A,json:{write:!0}})],ke.prototype,"geometry",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Name"}})],ke.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.ObjectID"}})],ke.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],ke.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)()],ke.prototype,"scaleFactor",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],ke.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],ke.prototype,"type",void 0),ke=Ue=(0,i.Cg)([(0,g.$K)("esri.rest.support.PolylineBarrier")],ke);let $e=class extends j.o{constructor(e){super(e),this.accumulateAttributes=null,this.directionsLanguage=null,this.findBestSequence=null,this.preserveFirstStop=null,this.preserveLastStop=null,this.startTimeIsUTC=null,this.timeWindowsAreUTC=null,this.travelMode=null}readAccumulateAttributes(e){return null==e?null:e.map(e=>$.et.fromJSON(e))}writeAccumulateAttributes(e,t,r){e?.length&&(t[r]=e.map(e=>$.et.toJSON(e)))}};var We;(0,i.Cg)([(0,g.MZ)({type:[String],json:{name:"accumulateAttributeNames",write:!0}})],$e.prototype,"accumulateAttributes",void 0),(0,i.Cg)([(0,Y.w)("accumulateAttributes")],$e.prototype,"readAccumulateAttributes",null),(0,i.Cg)([(0,H.K)("accumulateAttributes")],$e.prototype,"writeAccumulateAttributes",null),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],$e.prototype,"directionsLanguage",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],$e.prototype,"findBestSequence",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],$e.prototype,"preserveFirstStop",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],$e.prototype,"preserveLastStop",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],$e.prototype,"startTimeIsUTC",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],$e.prototype,"timeWindowsAreUTC",void 0),(0,i.Cg)([(0,g.MZ)({type:X,json:{write:!0}})],$e.prototype,"travelMode",void 0),$e=(0,i.Cg)([(0,g.$K)("esri.rest.support.RouteSettings")],$e);let Ve=class extends((0,z.OU)(j.o)){static{We=this}constructor(e){super(e),this.analysisSettings=null,this.endTime=null,this.endTimeOffset=null,this.firstStopId=null,this.geometry=null,this.lastStopId=null,this.messages=null,this.name=null,this.objectId=null,this.popupTemplate=null,this.startTime=null,this.startTimeOffset=null,this.stopCount=null,this.symbol=null,this.totalCosts=null,this.totalDistance=null,this.totalDuration=null,this.totalLateDuration=null,this.totalViolations=null,this.totalWait=null,this.totalWaitDuration=null,this.type="route-info",this.version="1.0.0"}readEndTime(e,t){return null!=t.attributes.EndTimeUTC?new Date(t.attributes.EndTimeUTC):null}readEndTimeOffset(e,t){return le(t.attributes.EndTime,t.attributes.EndTimeUTC)}readStartTime(e,t){return null!=t.attributes.StartTimeUTC?new Date(t.attributes.StartTimeUTC):null}readStartTimeOffset(e,t){return le(t.attributes.StartTime,t.attributes.StartTimeUTC)}readTotalCosts(e,t){return oe(t.attributes,"Total_")}readTotalViolations(e,t){return oe(t.attributes,"TotalViolation_")}readTotalWait(e,t){return oe(t.attributes,"TotalWait_")}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"AnalysisSettings",alias:"Analysis Settings",type:"esriFieldTypeString"},{name:"EndTime",alias:"End Time",type:"esriFieldTypeDate"},{name:"EndUTCOffset",alias:"End Time Offset",type:"esriFieldTypeInteger"},{name:"Messages",alias:"Messages",type:"esriFieldTypeString"},{name:"RouteName",alias:"Route Name",type:"esriFieldTypeString"},{name:"StartTime",alias:"Start Time",type:"esriFieldTypeDate"},{name:"StartUTCOffset",alias:"Start Time Offset",type:"esriFieldTypeInteger"},{name:"TotalCosts",alias:"Total Costs",type:"esriFieldTypeString"},{name:"TotalLateMinutes",alias:"Total Late Minutes",type:"esriFieldTypeDouble"},{name:"TotalMeters",alias:"Total Meters",type:"esriFieldTypeDouble"},{name:"TotalMinutes",alias:"Total Minutes",type:"esriFieldTypeDouble"},{name:"TotalWaitMinutes",alias:"Total Wait Minutes",type:"esriFieldTypeDouble"},{name:"Version",alias:"Version",type:"esriFieldTypeString"}]}static fromGraphic(e){return new We({analysisSettings:null!=e.attributes.AnalysisSettings?$e.fromJSON(JSON.parse(e.attributes.AnalysisSettings)):null,endTime:null!=e.attributes.EndTime?new Date(e.attributes.EndTime):null,endTimeOffset:e.attributes.EndUTCOffset??null,geometry:e.geometry,messages:null!=e.attributes.Messages?JSON.parse(e.attributes.Messages):null,name:e.attributes.RouteName,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,startTime:null!=e.attributes.StartTime?new Date(e.attributes.StartTime):null,startTimeOffset:e.attributes.StartUTCOffset??null,symbol:e.symbol,totalCosts:null!=e.attributes.TotalCosts?se(JSON.parse(e.attributes.TotalCosts)):null,totalDistance:e.attributes.TotalMeters??null,totalDuration:e.attributes.TotalMinutes??null,totalLateDuration:e.attributes.TotalLateMinutes??null,totalWaitDuration:e.attributes.TotalWaitMinutes??null,version:e.attributes.Version})}toGraphic(){const e={ObjectID:this.objectId,AnalysisSettings:this.analysisSettings?JSON.stringify(this.analysisSettings.toJSON()):null,EndTime:this.endTime?.getTime()??null,EndUTCOffset:this.endTimeOffset,Messages:this.messages?JSON.stringify(this.messages):null,RouteName:this.name,StartTime:this.startTime?.getTime()??null,StartUTCOffset:this.startTimeOffset,TotalCosts:this.totalCosts?JSON.stringify(ae(this.totalCosts)):null,TotalLateMinutes:this.totalLateDuration,TotalMeters:this.totalDistance,TotalMinutes:this.totalDuration,TotalWaitMinutes:this.totalWaitDuration,Version:this.version};return new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"analysisSettings",void 0),(0,i.Cg)([(0,g.MZ)({type:Date})],Ve.prototype,"endTime",void 0),(0,i.Cg)([(0,Y.w)("endTime",["attributes.EndTimeUTC"])],Ve.prototype,"readEndTime",null),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"endTimeOffset",void 0),(0,i.Cg)([(0,Y.w)("endTimeOffset",["attributes.EndTime","attributes.EndTimeUTC"])],Ve.prototype,"readEndTimeOffset",null),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.FirstStopID"}}})],Ve.prototype,"firstStopId",void 0),(0,i.Cg)([(0,g.MZ)({type:he.A})],Ve.prototype,"geometry",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.LastStopID"}}})],Ve.prototype,"lastStopId",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"messages",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.Name"}}})],Ve.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.ObjectID"}}})],Ve.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],Ve.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({type:Date})],Ve.prototype,"startTime",void 0),(0,i.Cg)([(0,Y.w)("startTime",["attributes.StartTimeUTC"])],Ve.prototype,"readStartTime",null),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"startTimeOffset",void 0),(0,i.Cg)([(0,Y.w)("startTimeOffset",["attributes.StartTime","attributes.StartTimeUTC"])],Ve.prototype,"readStartTimeOffset",null),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.StopCount"}}})],Ve.prototype,"stopCount",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],Ve.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalCosts",void 0),(0,i.Cg)([(0,Y.w)("totalCosts",["attributes"])],Ve.prototype,"readTotalCosts",null),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalDistance",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalDuration",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalLateDuration",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalViolations",void 0),(0,i.Cg)([(0,Y.w)("totalViolations",["attributes"])],Ve.prototype,"readTotalViolations",null),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalWait",void 0),(0,i.Cg)([(0,Y.w)("totalWait",["attributes"])],Ve.prototype,"readTotalWait",null),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"totalWaitDuration",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],Ve.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)()],Ve.prototype,"version",void 0),Ve=We=(0,i.Cg)([(0,g.$K)("esri.rest.support.RouteInfo")],Ve);var qe=r(56507),Ge=r(24097),Ke=r(65864),ze=r(50498);let Ye=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.doNotLocateOnRestrictedElements=null,this.geometry=null,this.geometryType=null,this.name=null,this.spatialRelationship=null,this.type="layer",this.where=null}};(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],Ye.prototype,"doNotLocateOnRestrictedElements",void 0),(0,i.Cg)([(0,g.MZ)({types:ze.yR,json:{read:Ke.rS,write:!0}})],Ye.prototype,"geometry",void 0),(0,i.Cg)([(0,W.e)($.Vj)],Ye.prototype,"geometryType",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{name:"layerName",write:!0}})],Ye.prototype,"name",void 0),(0,i.Cg)([(0,W.e)($.vS,{name:"spatialRel"})],Ye.prototype,"spatialRelationship",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],Ye.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],Ye.prototype,"where",void 0),Ye=(0,i.Cg)([(0,g.$K)("esri.rest.support.DataLayer")],Ye);var He=r(10107),Xe=r(64108);let Qe=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.name=null,this.where=null}};(0,i.Cg)([(0,He.MZ)({json:{write:!0}})],Qe.prototype,"name",void 0),(0,i.Cg)([(0,He.MZ)({json:{write:!0}})],Qe.prototype,"where",void 0),Qe=(0,i.Cg)([(0,Xe.$)("esri.rest.support.LocateSettingSource")],Qe);const et=Qe;let tt=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.allowAutoRelocate=null,this.sources=null}};(0,i.Cg)([(0,He.MZ)({type:Boolean,json:{write:!0}})],tt.prototype,"allowAutoRelocate",void 0),(0,i.Cg)([(0,He.MZ)({type:[et],json:{write:!0}})],tt.prototype,"sources",void 0),tt=(0,i.Cg)([(0,Xe.$)("esri.rest.support.LocateSettingBase")],tt);const rt=tt;let it=class extends rt{constructor(e){super(e),this.tolerance=null,this.toleranceUnits=null}};(0,i.Cg)([(0,He.MZ)({type:Number,json:{write:!0}})],it.prototype,"tolerance",void 0),(0,i.Cg)([(0,W.e)($.Y8)],it.prototype,"toleranceUnits",void 0),it=(0,i.Cg)([(0,Xe.$)("esri.rest.support.LocateSetting")],it);const ot=it;let nt=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.stops=null,this.pointBarriers=null,this.polylineBarriers=null,this.polygonBarriers=null}};(0,i.Cg)([(0,He.MZ)({type:ot,json:{write:!0}})],nt.prototype,"stops",void 0),(0,i.Cg)([(0,He.MZ)({type:ot,json:{name:"barriers",write:!0}})],nt.prototype,"pointBarriers",void 0),(0,i.Cg)([(0,He.MZ)({type:rt,json:{write:!0}})],nt.prototype,"polylineBarriers",void 0),(0,i.Cg)([(0,He.MZ)({type:rt,json:{write:!0}})],nt.prototype,"polygonBarriers",void 0),nt=(0,i.Cg)([(0,Xe.$)("esri.rest.support.LocateSettingsOverrides")],nt);const st=nt;let at=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.default=null,this.overrides=null}};(0,i.Cg)([(0,He.MZ)({type:ot,json:{write:!0}})],at.prototype,"default",void 0),(0,i.Cg)([(0,He.MZ)({type:st,json:{write:!0}})],at.prototype,"overrides",void 0),at=(0,i.Cg)([(0,Xe.$)("esri.rest.support.LocateSettings")],at);const lt=at;var ut;let pt=class extends pe.A{static{ut=this}constructor(e){super(e),this.doNotLocateOnRestrictedElements=null}clone(){return new ut({doNotLocateOnRestrictedElements:this.doNotLocateOnRestrictedElements,...this.cloneProperties()})}};(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],pt.prototype,"doNotLocateOnRestrictedElements",void 0),pt=ut=(0,i.Cg)([(0,g.$K)("esri.rest.support.NetworkFeatureSet")],pt);let ct=class extends((0,z.OU)(j.o)){constructor(e){super(e),this.doNotLocateOnRestrictedElements=null,this.url=null}};var dt;(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],ct.prototype,"doNotLocateOnRestrictedElements",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],ct.prototype,"url",void 0),ct=(0,i.Cg)([(0,g.$K)("esri.rest.support.NetworkUrl")],ct);let mt=class extends((0,z.OU)(j.o)){static{dt=this}constructor(e){super(e),this.accumulateAttributes=null,this.apiKey=null,this.attributeParameterValues=null,this.checksum=null,this.directionsLanguage=null,this.directionsLengthUnits=null,this.directionsOutputType=null,this.directionsStyleName=null,this.directionsTimeAttribute=null,this.findBestSequence=null,this.geometryPrecision=null,this.geometryPrecisionM=null,this.geometryPrecisionZ=null,this.ignoreInvalidLocations=null,this.impedanceAttribute=null,this.locateSettings=null,this.outputGeometryPrecision=null,this.outputGeometryPrecisionUnits=null,this.outputLines="true-shape",this.outSpatialReference=null,this.overrides=null,this.pointBarriers=null,this.polygonBarriers=null,this.polylineBarriers=null,this.preserveFirstStop=null,this.preserveLastStop=null,this.preserveObjectID=null,this.restrictionAttributes=null,this.restrictUTurns=null,this.returnBarriers=!1,this.returnDirections=!1,this.returnEmptyResults=null,this.returnPolygonBarriers=!1,this.returnPolylineBarriers=!1,this.returnRoutes=!0,this.returnStops=!1,this.returnTraversedEdges=null,this.returnTraversedJunctions=null,this.returnTraversedTurns=null,this.returnZ=!0,this.startTime=null,this.startTimeIsUTC=!0,this.stops=null,this.timeWindowsAreUTC=null,this.travelMode=null,this.useHierarchy=null,this.useTimeWindows=null}static from(e){return(0,qe.PZ)(dt,e)}readAccumulateAttributes(e){return null==e?null:e.map(e=>$.et.fromJSON(e))}writeAccumulateAttributes(e,t,r){e?.length&&(t[r]=e.map(e=>$.et.toJSON(e)))}writePointBarriers(e,t,r){yt(e,t,r)}writePolygonBarrier(e,t,r){yt(e,t,r)}writePolylineBarrier(e,t,r){yt(e,t,r)}readRestrictionAttributes(e){return null==e?null:e.map(e=>$.OC.fromJSON(e))}writeRestrictionAttributes(e,t,r){e?.length&&(t[r]=e.map(e=>$.OC.toJSON(e)))}readStartTime(e,t){const{startTime:r}=t;return null==r?null:"now"===r?"now":new Date(r)}writeStartTime(e,t){null!=e&&(t.startTime="now"===e?"now":e.getTime())}readStops(e,t){return function(e){return function(e){return e&&"type"in e}(e)?Ye.fromJSON(e):function(e){return e&&"url"in e}(e)?ct.fromJSON(e):function(e){return e&&"features"in e&&"doNotLocateOnRestrictedElements"in e}(e)?pt.fromJSON(e):function(e){return e&&"features"in e}(e)?pe.A.fromJSON(e):null}(t.stops)}writeStops(e,t,r){yt(e,t,r)}};function yt(e,t,r){null!=e&&(t[r]=l.A.isCollection(e)?{features:e.toArray().map(e=>e.toJSON())}:e.toJSON())}var ft;(0,i.Cg)([(0,g.MZ)({type:[String],json:{name:"accumulateAttributeNames",write:!0}})],mt.prototype,"accumulateAttributes",void 0),(0,i.Cg)([(0,Y.w)("accumulateAttributes")],mt.prototype,"readAccumulateAttributes",null),(0,i.Cg)([(0,H.K)("accumulateAttributes")],mt.prototype,"writeAccumulateAttributes",null),(0,i.Cg)([(0,g.MZ)(Ge.K)],mt.prototype,"apiKey",void 0),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"attributeParameterValues",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],mt.prototype,"checksum",void 0),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:!0}})],mt.prototype,"directionsLanguage",void 0),(0,i.Cg)([(0,W.e)($.Z7)],mt.prototype,"directionsLengthUnits",void 0),(0,i.Cg)([(0,W.e)($.aJ)],mt.prototype,"directionsOutputType",void 0),(0,i.Cg)([(0,W.e)($.$n)],mt.prototype,"directionsStyleName",void 0),(0,i.Cg)([(0,W.e)($.Mm,{name:"directionsTimeAttributeName",ignoreUnknown:!1})],mt.prototype,"directionsTimeAttribute",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"findBestSequence",void 0),(0,i.Cg)([(0,g.MZ)({type:Number,json:{write:!0}})],mt.prototype,"geometryPrecision",void 0),(0,i.Cg)([(0,g.MZ)({type:Number,json:{write:!0}})],mt.prototype,"geometryPrecisionM",void 0),(0,i.Cg)([(0,g.MZ)({type:Number,json:{write:!0}})],mt.prototype,"geometryPrecisionZ",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"ignoreInvalidLocations",void 0),(0,i.Cg)([(0,W.e)($.et,{name:"impedanceAttributeName",ignoreUnknown:!1})],mt.prototype,"impedanceAttribute",void 0),(0,i.Cg)([(0,g.MZ)({type:lt,json:{write:!0}})],mt.prototype,"locateSettings",void 0),(0,i.Cg)([(0,g.MZ)({type:Number,json:{write:!0}})],mt.prototype,"outputGeometryPrecision",void 0),(0,i.Cg)([(0,W.e)($.hY)],mt.prototype,"outputGeometryPrecisionUnits",void 0),(0,i.Cg)([(0,W.e)($.Sr)],mt.prototype,"outputLines",void 0),(0,i.Cg)([(0,g.MZ)({type:C.A,json:{name:"outSR",write:!0}})],mt.prototype,"outSpatialReference",void 0),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"overrides",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"barriers",write:!0}})],mt.prototype,"pointBarriers",void 0),(0,i.Cg)([(0,H.K)("pointBarriers")],mt.prototype,"writePointBarriers",null),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"polygonBarriers",void 0),(0,i.Cg)([(0,H.K)("polygonBarriers")],mt.prototype,"writePolygonBarrier",null),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"polylineBarriers",void 0),(0,i.Cg)([(0,H.K)("polylineBarriers")],mt.prototype,"writePolylineBarrier",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"preserveFirstStop",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"preserveLastStop",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"preserveObjectID",void 0),(0,i.Cg)([(0,g.MZ)({type:[String],json:{name:"restrictionAttributeNames",write:!0}})],mt.prototype,"restrictionAttributes",void 0),(0,i.Cg)([(0,Y.w)("restrictionAttributes")],mt.prototype,"readRestrictionAttributes",null),(0,i.Cg)([(0,H.K)("restrictionAttributes")],mt.prototype,"writeRestrictionAttributes",null),(0,i.Cg)([(0,W.e)($.hE)],mt.prototype,"restrictUTurns",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnBarriers",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnDirections",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnEmptyResults",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnPolygonBarriers",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnPolylineBarriers",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnRoutes",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnStops",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnTraversedEdges",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnTraversedJunctions",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnTraversedTurns",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"returnZ",void 0),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"startTime",void 0),(0,i.Cg)([(0,Y.w)("startTime")],mt.prototype,"readStartTime",null),(0,i.Cg)([(0,H.K)("startTime")],mt.prototype,"writeStartTime",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"startTimeIsUTC",void 0),(0,i.Cg)([(0,g.MZ)({json:{write:!0}})],mt.prototype,"stops",void 0),(0,i.Cg)([(0,Y.w)("stops")],mt.prototype,"readStops",null),(0,i.Cg)([(0,H.K)("stops")],mt.prototype,"writeStops",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"timeWindowsAreUTC",void 0),(0,i.Cg)([(0,g.MZ)({type:X,json:{write:!0}})],mt.prototype,"travelMode",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"useHierarchy",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],mt.prototype,"useTimeWindows",void 0),mt=dt=(0,i.Cg)([(0,g.$K)("esri.rest.support.RouteParameters")],mt);let ht=class extends((0,z.OU)(j.o)){static{ft=this}constructor(e){super(e),this.arriveCurbApproach=null,this.arriveTime=null,this.arriveTimeOffset=null,this.bearing=null,this.bearingTol=null,this.cumulativeCosts=null,this.cumulativeDistance=null,this.cumulativeDuration=null,this.curbApproach=null,this.departCurbApproach=null,this.departTime=null,this.departTimeOffset=null,this.distanceToNetworkInMeters=null,this.lateDuration=null,this.locationType=null,this.name=null,this.navLatency=null,this.objectId=null,this.popupTemplate=null,this.positionAlong=null,this.routeName=null,this.serviceCosts=null,this.serviceDistance=null,this.serviceDuration=null,this.sequence=null,this.sideOfEdge=null,this.snapX=null,this.snapY=null,this.snapZ=null,this.sourceId=null,this.sourceOid=null,this.status=null,this.symbol=null,this.timeWindowEnd=null,this.timeWindowEndOffset=null,this.timeWindowStart=null,this.timeWindowStartOffset=null,this.type="stop",this.violations=null,this.waitDuration=null,this.wait=null}readArriveTimeOffset(e,t){return le(t.attributes.ArriveTime,t.attributes.ArriveTimeUTC)}readCumulativeCosts(e,t){return oe(t.attributes,"Cumul_")}readDepartTimeOffset(e,t){return le(t.attributes.DepartTime,t.attributes.DepartTimeUTC)}set geometry(e){this._get("geometry")&&(this._set("positionAlong",null),this._set("sideOfEdge",null),this._set("sourceId",null),this._set("sourceOid",null),this._set("status",null)),this._set("geometry",e)}readServiceCosts(e,t){return oe(t.attributes,"Attr_")}writeServiceCosts(e,t){ne(e,t,"Attr_")}writeTimeWindowEnd(e,t){null!=e&&(t.attributes||(t.attributes={}),t.attributes.TimeWindowEnd=e.getTime())}writeTimeWindowStart(e,t){null!=e&&(t.attributes||(t.attributes={}),t.attributes.TimeWindowStart=e.getTime())}readViolations(e,t){return oe(t.attributes,"Violation_")}readWait(e,t){return oe(t.attributes,"Wait_")}static{this.fields=[{name:"ObjectID",alias:"ObjectID",type:"esriFieldTypeOID"},{name:"ArrivalCurbApproach",alias:"Arrival Curb Approach",type:"esriFieldTypeInteger"},{name:"ArrivalTime",alias:"Arrival Time",type:"esriFieldTypeDate"},{name:"ArrivalUTCOffset",alias:"Arrival Time",type:"esriFieldTypeInteger"},{name:"CumulativeCosts",alias:"Cumulative Costs",type:"esriFieldTypeString"},{name:"CumulativeMeters",alias:"Cumulative Meters",type:"esriFieldTypeDouble"},{name:"CumulativeMinutes",alias:"Cumulative Minutes",type:"esriFieldTypeDouble"},{name:"CurbApproach",alias:"Curb Approach",type:"esriFieldTypeInteger"},{name:"DepartureCurbApproach",alias:"Departure Curb Approach",type:"esriFieldTypeInteger"},{name:"DepartureTime",alias:"Departure Time",type:"esriFieldTypeDate"},{name:"DepartureUTCOffset",alias:"Departure Time",type:"esriFieldTypeInteger"},{name:"LateMinutes",alias:"Minutes Late",type:"esriFieldTypeDouble"},{name:"LocationType",alias:"Location Type",type:"esriFieldTypeInteger"},{name:"Name",alias:"Name",type:"esriFieldTypeString"},{name:"RouteName",alias:"Route Name",type:"esriFieldTypeString"},{name:"Sequence",alias:"Sequence",type:"esriFieldTypeInteger"},{name:"ServiceCosts",alias:"Service Costs",type:"esriFieldTypeString"},{name:"ServiceMeters",alias:"Service Meters",type:"esriFieldTypeDouble"},{name:"ServiceMinutes",alias:"Service Minutes",type:"esriFieldTypeDouble"},{name:"Status",alias:"Status",type:"esriFieldTypeInteger"},{name:"TimeWindowEnd",alias:"Time Window End",type:"esriFieldTypeDate"},{name:"TimeWindowEndUTCOffset",alias:"Time Window End Offset",type:"esriFieldTypeInteger"},{name:"TimeWindowStart",alias:"Time Window Start",type:"esriFieldTypeDate"},{name:"TimeWindowStartUTCOffset",alias:"Time Window Start Offset",type:"esriFieldTypeInteger"},{name:"WaitMinutes",alias:"Minutes Wait",type:"esriFieldTypeDouble"}]}static fromGraphic(e){return new ft({arriveCurbApproach:null!=e.attributes.ArrivalCurbApproach?$.JJ.fromJSON(e.attributes.ArrivalCurbApproach):null,arriveTime:null!=e.attributes.ArrivalTime?new Date(e.attributes.ArrivalTime):null,arriveTimeOffset:e.attributes.ArrivalUTCOffset,cumulativeCosts:null!=e.attributes.CumulativeCosts?se(JSON.parse(e.attributes.CumulativeCosts)):null,cumulativeDistance:e.attributes.CumulativeMeters??null,cumulativeDuration:e.attributes.CumulativeMinutes??null,curbApproach:null!=e.attributes.CurbApproach?$.JJ.fromJSON(e.attributes.CurbApproach):null,departCurbApproach:null!=e.attributes.DepartureCurbApproach?$.JJ.fromJSON(e.attributes.DepartureCurbApproach):null,departTime:null!=e.attributes.DepartureTime?new Date(e.attributes.DepartureTime):null,departTimeOffset:e.attributes.DepartureUTCOffset??null,geometry:e.geometry,lateDuration:e.attributes.LateMinutes??null,locationType:null!=e.attributes.LocationType?$.EM.fromJSON(e.attributes.LocationType):null,name:e.attributes.Name,objectId:e.attributes.ObjectID??e.attributes.__OBJECTID,popupTemplate:e.popupTemplate,routeName:e.attributes.RouteName,sequence:e.attributes.Sequence??null,serviceCosts:null!=e.attributes.ServiceCosts?se(JSON.parse(e.attributes.ServiceCosts)):null,serviceDistance:e.attributes.ServiceMeters??null,serviceDuration:e.attributes.ServiceMinutes??null,status:null!=e.attributes.Status?$.$r.fromJSON(e.attributes.Status):null,symbol:e.symbol,timeWindowEnd:null!=e.attributes.TimeWindowEnd?new Date(e.attributes.TimeWindowEnd):null,timeWindowEndOffset:e.attributes.TimeWindowEndUTCOffset??null,timeWindowStart:null!=e.attributes.TimeWindowStart?new Date(e.attributes.TimeWindowStart):null,timeWindowStartOffset:e.attributes.TimeWindowStartUTCOffset??null,waitDuration:e.attributes.WaitMinutes??null})}toGraphic(){const e={ObjectID:this.objectId,ArrivalCurbApproach:this.arriveCurbApproach?$.JJ.toJSON(this.arriveCurbApproach):null,ArrivalTime:this.arriveTime?.getTime()??null,ArrivalUTCOffset:this.arriveTimeOffset,CumulativeCosts:this.cumulativeCosts?JSON.stringify(ae(this.cumulativeCosts)):null,CumulativeMeters:this.cumulativeDistance,CumulativeMinutes:this.cumulativeDuration,CurbApproach:this.curbApproach?$.JJ.toJSON(this.curbApproach):null,DepartureCurbApproach:this.departCurbApproach?$.JJ.toJSON(this.departCurbApproach):null,DepartureTime:this.departTime?.getTime()??null,DepartureUTCOffset:this.departTimeOffset,LateMinutes:this.lateDuration,LocationType:this.locationType?$.EM.toJSON(this.locationType):null,Name:this.name,RouteName:this.routeName,Sequence:this.sequence,ServiceCosts:this.serviceCosts?JSON.stringify(ae(this.serviceCosts)):null,ServiceMeters:this.serviceDistance,ServiceMinutes:this.serviceDuration,Status:this.status?$.$r.toJSON(this.status):null,TimeWindowEnd:this.timeWindowEnd?.getTime()??null,TimeWindowEndUTCOffset:this.timeWindowEndOffset??this.arriveTimeOffset,TimeWindowStart:this.timeWindowStart?.getTime()??null,TimeWindowStartUTCOffset:this.timeWindowStartOffset??this.arriveTimeOffset,WaitMinutes:this.waitDuration};return new n.A({geometry:this.geometry,attributes:e,symbol:this.symbol,popupTemplate:this.popupTemplate})}};function gt(e){if(!e.length)return;const t=e.toArray(),r=t.map(({objectId:e})=>e).filter(e=>null!=e);let i=Math.max(...r,0);for(const e of t)e.objectId??=++i}function vt(e,t){return e.length===t.length&&bt(e)&&bt(t)}function bt(e){return e.every(({objectId:e})=>null!=e)}function wt(e,t){return!!e.length||!!t.length}function Tt(e){return e.length?e:null}function Ct(e){switch(e){case"esriGeometryPoint":return{type:"esriSMS",style:"esriSMSCircle",size:12,color:[0,0,0,0],outline:Ct("esriGeometryPolyline")};case"esriGeometryPolyline":return{type:"esriSLS",style:"esriSLSSolid",width:1,color:[0,0,0,0]};case"esriGeometryPolygon":return{type:"esriSFS",style:"esriSFSNull",outline:Ct("esriGeometryPolyline")}}}function St(e){return"layers"in e}async function Mt(e){const t=C.A.WGS84;return await(0,T.initializeProjection)(e.spatialReference,t),(0,T.project)(e,t)}function At(e,t){if(t&&e?.length&&!e.every(({symbol:e})=>!!e))for(const r of e)r.symbol=t}function It(e,t){switch(t){case"seconds":return e/60;case"hours":return 60*e;case"days":return 60*e*24;default:return e}}function Ot(e,t){return"decimal-degrees"===t||"points"===t||"unknown"===t?e:(0,f.oU)(e,t,"meters")}(0,i.Cg)([(0,g.MZ)({type:$.JJ.apiValues,json:{read:{source:"attributes.ArrivalCurbApproach",reader:$.JJ.read}}})],ht.prototype,"arriveCurbApproach",void 0),(0,i.Cg)([(0,g.MZ)({type:Date,json:{read:{source:"attributes.ArriveTimeUTC"}}})],ht.prototype,"arriveTime",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"arriveTimeOffset",void 0),(0,i.Cg)([(0,Y.w)("arriveTimeOffset",["attributes.ArriveTime","attributes.ArriveTimeUTC"])],ht.prototype,"readArriveTimeOffset",null),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Bearing",read:!1,write:!0}})],ht.prototype,"bearing",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.BearingTol",read:!1,write:!0}})],ht.prototype,"bearingTol",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"cumulativeCosts",void 0),(0,i.Cg)([(0,Y.w)("cumulativeCosts",["attributes"])],ht.prototype,"readCumulativeCosts",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"cumulativeDistance",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"cumulativeDuration",void 0),(0,i.Cg)([(0,g.MZ)({type:$.JJ.apiValues,json:{name:"attributes.CurbApproach",read:{reader:$.JJ.read},write:{writer:$.JJ.write}}})],ht.prototype,"curbApproach",void 0),(0,i.Cg)([(0,g.MZ)({type:$.JJ.apiValues,json:{read:{source:"attributes.DepartCurbApproach",reader:$.JJ.read}}})],ht.prototype,"departCurbApproach",void 0),(0,i.Cg)([(0,g.MZ)({type:Date,json:{read:{source:"attributes.DepartTimeUTC"}}})],ht.prototype,"departTime",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"departTimeOffset",void 0),(0,i.Cg)([(0,Y.w)("departTimeOffset",["attributes.DepartTime","attributes.DepartTimeUTC"])],ht.prototype,"readDepartTimeOffset",null),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.DistanceToNetworkInMeters"}}})],ht.prototype,"distanceToNetworkInMeters",void 0),(0,i.Cg)([(0,g.MZ)({type:ge.A,json:{write:!0},value:null})],ht.prototype,"geometry",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"lateDuration",void 0),(0,i.Cg)([(0,g.MZ)({type:$.EM.apiValues,json:{name:"attributes.LocationType",read:{reader:$.EM.read},write:{writer:$.EM.write}}})],ht.prototype,"locationType",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Name"}})],ht.prototype,"name",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.NavLatency",read:!1,write:!0}})],ht.prototype,"navLatency",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.ObjectID"}})],ht.prototype,"objectId",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A})],ht.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.PosAlong"}})],ht.prototype,"positionAlong",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.RouteName"}})],ht.prototype,"routeName",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"serviceCosts",void 0),(0,i.Cg)([(0,Y.w)("serviceCosts",["attributes"])],ht.prototype,"readServiceCosts",null),(0,i.Cg)([(0,H.K)("serviceCosts")],ht.prototype,"writeServiceCosts",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"serviceDistance",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"serviceDuration",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.Sequence"}})],ht.prototype,"sequence",void 0),(0,i.Cg)([(0,g.MZ)({type:$.mt.apiValues,json:{name:"attributes.SideOfEdge",read:{reader:$.mt.read},write:{writer:$.mt.write}}})],ht.prototype,"sideOfEdge",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.SnapX"}}})],ht.prototype,"snapX",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.SnapY"}}})],ht.prototype,"snapY",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:{source:"attributes.SnapZ"}}})],ht.prototype,"snapZ",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.SourceID"}})],ht.prototype,"sourceId",void 0),(0,i.Cg)([(0,g.MZ)({json:{name:"attributes.SourceOID"}})],ht.prototype,"sourceOid",void 0),(0,i.Cg)([(0,g.MZ)({type:$.$r.apiValues,json:{name:"attributes.Status",read:{reader:$.$r.read},write:{writer:$.$r.write}}})],ht.prototype,"status",void 0),(0,i.Cg)([(0,g.MZ)({types:F.Es})],ht.prototype,"symbol",void 0),(0,i.Cg)([(0,g.MZ)({type:Date,json:{name:"attributes.TimeWindowEnd"}})],ht.prototype,"timeWindowEnd",void 0),(0,i.Cg)([(0,H.K)("timeWindowEnd")],ht.prototype,"writeTimeWindowEnd",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"timeWindowEndOffset",void 0),(0,i.Cg)([(0,g.MZ)({type:Date,json:{name:"attributes.TimeWindowStart"}})],ht.prototype,"timeWindowStart",void 0),(0,i.Cg)([(0,H.K)("timeWindowStart")],ht.prototype,"writeTimeWindowStart",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"timeWindowStartOffset",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],ht.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"violations",void 0),(0,i.Cg)([(0,Y.w)("violations",["attributes"])],ht.prototype,"readViolations",null),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"waitDuration",void 0),(0,i.Cg)([(0,g.MZ)()],ht.prototype,"wait",void 0),(0,i.Cg)([(0,Y.w)("wait",["attributes"])],ht.prototype,"readWait",null),ht=ft=(0,i.Cg)([(0,g.$K)("esri.rest.support.Stop")],ht);const Nt=l.A.ofType(xe),Zt=l.A.ofType(Re),jt=l.A.ofType(Pe),Dt=l.A.ofType(Je),Ft=l.A.ofType(ke),xt=l.A.ofType(ht);let Bt=class extends((0,A.dM)((0,N.j)((0,I.q)((0,O.A)((0,c.P)(M.A)))))){constructor(e){super(e),this._cachedServiceDescription=null,this._featureCollection=null,this._type="Feature Collection",this.checksum=null,this.defaultSymbols=new _,this.directionLines=null,this.directionPoints=null,this.featureCollectionType="route",this.legendEnabled=!1,this.maxScale=0,this.minScale=0,this.pointBarriers=new jt,this.polygonBarriers=new Dt,this.polylineBarriers=new Ft,this.routeInfo=null,this.spatialReference=C.A.WGS84,this.stops=new xt,this.type="route"}initialize(){const e=()=>{this._setStopSymbol(this.stops)},t=()=>{At(this.pointBarriers,this.defaultSymbols.pointBarriers)},r=()=>{At(this.polylineBarriers,this.defaultSymbols.polylineBarriers)},i=()=>{At(this.polygonBarriers,this.defaultSymbols.polygonBarriers)};this.addHandles([(0,y.on)(()=>this.stops,"change",e,{sync:!0,onListenerAdd:e}),(0,y.on)(()=>this.pointBarriers,"change",t,{sync:!0,onListenerAdd:t}),(0,y.on)(()=>this.polylineBarriers,"change",r,{sync:!0,onListenerAdd:r}),(0,y.on)(()=>this.polygonBarriers,"change",i,{sync:!0,onListenerAdd:i})])}writeFeatureCollectionWebmap(e,t,r,i){const o=[this._writePolygonBarriers(),this._writePolylineBarriers(),this._writePointBarriers(),this._writeRouteInfo(),this._writeDirectionLines(),this._writeDirectionPoints(),this._writeStops()].filter(e=>!!e),n=o.map((e,t)=>t),s="web-map"===i.origin?"featureCollection.layers":"layers";(0,d.sM)(s,o,t),t.opacity=this.opacity,t.visibility=this.visible,t.visibleLayers=n}readDirectionLines(e,t){return this._getNetworkFeatures(t,"DirectionLines",e=>xe.fromGraphic(e))}readDirectionPoints(e,t){return this._getNetworkFeatures(t,"DirectionPoints",e=>Re.fromGraphic(e))}get fullExtent(){const e=new b.A({xmin:-180,ymin:-90,xmax:180,ymax:90,spatialReference:C.A.WGS84});if(null!=this.routeInfo?.geometry)return this.routeInfo.geometry.extent??e;if(null==this.stops)return e;const t=this.stops.filter(e=>null!=e.geometry);if(t.length<2)return e;const{spatialReference:r}=t.at(0).geometry;if(null==r)return e;const i=t.toArray().map(e=>{const t=e.geometry;return[t.x,t.y]});return new w.A({points:i,spatialReference:r}).extent}readMaxScale(e,t){const r=St(t)?t.layers:t.featureCollection?.layers,i=r?.find(e=>null!=e.layerDefinition.maxScale);return i?.layerDefinition.maxScale??0}readMinScale(e,t){const r=St(t)?t.layers:t.featureCollection?.layers,i=r?.find(e=>null!=e.layerDefinition.minScale);return i?.layerDefinition.minScale??0}readPointBarriers(e,t){return this._getNetworkFeatures(t,"Barriers",e=>Pe.fromGraphic(e))}readPolygonBarriers(e,t){return this._getNetworkFeatures(t,"PolygonBarriers",e=>Je.fromGraphic(e))}readPolylineBarriers(e,t){return this._getNetworkFeatures(t,"PolylineBarriers",e=>ke.fromGraphic(e))}readRouteInfo(e,t){return this._getNetworkFeatures(t,"RouteInfo",e=>Ve.fromGraphic(e)).at(0)??null}readSpatialReference(e,t){const r=St(t)?t.layers:t.featureCollection?.layers;if(!r?.length)return C.A.WGS84;const{layerDefinition:i,featureSet:o}=r[0],n=o.features[0],s=n?.geometry?.spatialReference??o.spatialReference??i.spatialReference??i.extent.spatialReference??S.KK;return C.A.fromJSON(s)}readStops(e,t){return this._getNetworkFeatures(t,"Stops",e=>ht.fromGraphic(e),e=>this._setStopSymbol(e))}get title(){return this.routeInfo?.name??"Route"}set title(e){this._overrideIfSome("title",e)}get url(){return o.A.routeServiceUrl}set url(e){null!=e?this._set("url",(0,Z.Jf)(e,p.A.getLogger(this))):this._set("url",o.A.routeServiceUrl)}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Feature Collection"]},e)),Promise.resolve(this)}removeAll(){this.removeResult(),this.pointBarriers.removeAll(),this.polygonBarriers.removeAll(),this.polylineBarriers.removeAll(),this.stops.removeAll()}removeResult(){null!=this.directionLines&&(this.directionLines.removeAll(),this._set("directionLines",null)),null!=this.directionPoints&&(this.directionPoints.removeAll(),this._set("directionPoints",null)),null!=this.routeInfo&&this._set("routeInfo",null)}async save(){await this.load();const{fullExtent:e,portalItem:t}=this;if(!t)throw new u.A("routelayer:portal-item-not-set","save() requires to the layer to have a portal item");if(!t.id)throw new u.A("routelayer:portal-item-not-saved","Please use saveAs() first to save the routelayer");if("Feature Collection"!==t.type)throw new u.A("routelayer:portal-item-wrong-type",'Portal item needs to have type "Feature Collection"');if(!this.routeInfo)throw new u.A("routelayer:route-unsolved","save() requires a solved route");const{portal:r}=t;await r.signIn(),r.user||await t.reload();const{itemUrl:i,itemControl:o}=t;if("admin"!==o&&"update"!==o)throw new u.A("routelayer:insufficient-permissions","To save this layer, you need to be the owner or an administrator of your organization");const n={messages:[],origin:"portal-item",portal:r,url:i?(0,h.An)(i):void 0,writtenProperties:[]},s=this.write(void 0,n);return t.extent=await Mt(e),t.title=this.title,await t.update({data:s}),t}async saveAs(e,t={}){if(await this.load(),null==this.routeInfo)throw new u.A("routelayer:route-unsolved","saveAs() requires a solved route");const r=E.default.from(e).clone();r.extent??=await Mt(this.fullExtent),r.id=null,r.portal??=P.A.getDefault(),r.title??=this.title,r.type="Feature Collection",r.typeKeywords=["Data","Feature Collection",L.mm.MULTI_LAYER,"Route Layer"];const{portal:i}=r,o={messages:[],origin:"portal-item",portal:i,url:null,writtenProperties:[]};await i.signIn();const n=t?.folder,s=this.write(void 0,o);return await i.user.addItem({item:r,folder:n,data:s}),this.portalItem=r,(0,v.v)(o),o.portalItem=r,r}async solve(e,t){gt(this.stops),gt(this.pointBarriers),gt(this.polylineBarriers),gt(this.polygonBarriers);const r=e?.stops??this.stops,i=e?.pointBarriers??Tt(this.pointBarriers),o=e?.polylineBarriers??Tt(this.polylineBarriers),n=e?.polygonBarriers??Tt(this.polygonBarriers);if(null==r)throw new u.A("routelayer:undefined-stops","the route layer must have stops defined in the route parameters.");if((function(e){return"esri.rest.support.FeatureSet"===e.declaredClass}(r)||function(e){return"esri.rest.support.NetworkFeatureSet"===e.declaredClass}(r))&&r.features.length<2||l.A.isCollection(r)&&r.length<2)throw new u.A("routelayer:insufficent-stops","the route layer must have two or more stops to solve a route.");if(l.A.isCollection(r))for(const e of r)e.routeName=null;const s=e?.apiKey,{checksum:a,url:p}=this,c=await this._getServiceDescription(p,s,t),d=e?.travelMode??c.defaultTravelMode,y=e?.accumulateAttributes??[];d&&(y.push(d.distanceAttributeName),d.timeAttributeName&&y.push(d.timeAttributeName));const f={accumulateAttributes:y,checksum:a,directionsOutputType:"featuresets",ignoreInvalidLocations:!0,pointBarriers:i,polylineBarriers:o,polygonBarriers:n,preserveObjectID:!0,returnBarriers:!!i,returnDirections:!0,returnPolygonBarriers:!!n,returnPolylineBarriers:!!o,returnRoutes:!0,returnStops:!0,stops:r},h=mt.from(e??{});let g;h.set(f);try{g=await De(p,h,t)}catch(e){throw(0,m.zf)(e)?e:new u.A("routelayer:failed-route-request","the routing request failed",{error:e})}const v=this._toRouteLayerSolution(g);return this._isOverridden("title")||(this.title=v.routeInfo.name??"Route"),this._populatePortalFields(v,c,h),v}update(e){const{checksum:t,directionLines:r,directionPoints:i,pointBarriers:o,polygonBarriers:n,polylineBarriers:s,routeInfo:a,stops:l}=e;vt(l,this.stops)?function(e,t){for(const r of e){const e=t.find(e=>e.objectId===r.objectId);e&&(e.arriveCurbApproach=r.arriveCurbApproach,e.arriveTime=r.arriveTime,e.arriveTimeOffset=r.arriveTimeOffset,e.cumulativeCosts=r.cumulativeCosts,e.cumulativeDistance=r.cumulativeDistance,e.cumulativeDuration=r.cumulativeDuration,e.curbApproach=r.curbApproach,e.departCurbApproach=r.departCurbApproach,e.departTime=r.departTime,e.departTimeOffset=r.departTimeOffset,e.distanceToNetworkInMeters=r.distanceToNetworkInMeters,e.geometry=r.geometry,e.lateDuration=r.lateDuration,e.name=r.name,e.navLatency=r.navLatency,e.positionAlong=r.positionAlong,e.routeName=r.routeName,e.serviceCosts=r.serviceCosts,e.serviceDistance=r.serviceDistance,e.serviceDuration=r.serviceDuration,e.sequence=r.sequence,e.sideOfEdge=r.sideOfEdge,e.snapX=r.snapX,e.snapY=r.snapY,e.snapZ=r.snapZ,e.sourceId=r.sourceId,e.sourceOid=r.sourceOid,e.status=r.status,e.symbol=r.symbol,e.timeWindowEnd=r.timeWindowEnd,e.timeWindowStart=r.timeWindowStart,e.violations=r.violations,e.waitDuration=r.waitDuration,e.wait=r.wait)}}(l,this.stops):this.set({stops:l}),wt(o,this.pointBarriers)&&(vt(o,this.pointBarriers)?function(e,t){for(const r of e){const e=t.find(e=>e.objectId===r.objectId);e&&(e.addedCost=r.addedCost,e.barrierType=r.barrierType,e.costs=r.costs,e.curbApproach=r.curbApproach,e.fullEdge=r.fullEdge,e.geometry=r.geometry,e.name=r.name,e.sideOfEdge=r.sideOfEdge,e.sourceId=r.sourceId,e.sourceOid=r.sourceOid,e.status=r.status,e.symbol=r.symbol)}}(o,this.pointBarriers):this.set({pointBarriers:o})),wt(s,this.polylineBarriers)&&(vt(s,this.polylineBarriers)?function(e,t){for(const r of e){const e=t.find(e=>e.objectId===r.objectId);e&&(e.barrierType=r.barrierType,e.costs=r.costs,e.geometry=r.geometry,e.name=r.name,e.scaleFactor=r.scaleFactor,e.symbol=r.symbol)}}(s,this.polylineBarriers):this.set({polylineBarriers:s})),wt(n,this.polygonBarriers)&&(vt(n,this.polygonBarriers)?function(e,t){for(const r of e){const e=t.find(e=>e.objectId===r.objectId);e&&(e.barrierType=r.barrierType,e.costs=r.costs,e.geometry=r.geometry,e.name=r.name,e.scaleFactor=r.scaleFactor,e.symbol=r.symbol)}}(n,this.polygonBarriers):this.set({polygonBarriers:n})),this.set({checksum:t}),this._set("directionLines",r),this._set("directionPoints",i),this._set("routeInfo",a),a.geometry&&(this.spatialReference=a.geometry.spatialReference)}_getNetworkFeatures(e,t,r,i){const o=St(e)?e.layers:e.featureCollection?.layers,a=o?.find(e=>e.layerDefinition.name===t);if(null==a)return new l.A;const{layerDefinition:u,popupInfo:p,featureSet:c}=a,d=u.drawingInfo.renderer,{features:m}=c,y=c.spatialReference??u.spatialReference??u.extent.spatialReference??S.KK,f=d&&(0,J.L)(d),h=C.A.fromJSON(y),g=m.map(e=>{const i=n.A.fromJSON(e);i.geometry&&e.geometry&&null==e.geometry.spatialReference&&(i.geometry.spatialReference=h);const o=r(i);return o.symbol??=f?.getSymbol(i)??this._getNetworkSymbol(t),o.popupTemplate??=p&&s.A.fromJSON(p),o});return i&&g.some(({symbol:e})=>!e)&&i(g),new l.A(g)}_getNetworkSymbol(e){switch(e){case"Barriers":return this.defaultSymbols.pointBarriers;case"DirectionPoints":return this.defaultSymbols.directionPoints;case"DirectionLines":return this.defaultSymbols.directionLines;case"PolylineBarriers":return this.defaultSymbols.polylineBarriers;case"PolygonBarriers":return this.defaultSymbols.polygonBarriers;case"RouteInfo":return this.defaultSymbols.routeInfo;case"Stops":return null}}async _getServiceDescription(e,t,r){if(null!=this._cachedServiceDescription&&this._cachedServiceDescription.url===e)return this._cachedServiceDescription.serviceDescription;const i=await te(e,t,r);return this._cachedServiceDescription={serviceDescription:i,url:e},i}_setStopSymbol(e){const t=l.A.isCollection(e)?e.toArray():e;if(!t||!t.length||!this.defaultSymbols.stops||t.every(({symbol:e})=>!!e))return;const{first:r,last:i,middle:o,unlocated:n,waypoint:s,break:u}=this.defaultSymbols.stops,p=t.map(({sequence:e})=>e).filter(a.Ru),c=t.length===p.length;if(!this.routeInfo&&!c||1===t.length)return void t.forEach((e,n)=>{switch(n){case 0:e.symbol=r;break;case t.length-1:e.symbol=i;break;default:e.symbol=o}});const d=Math.min(...p),m=Math.max(...p);for(const e of t)e.sequence!==d?e.sequence!==m?this.routeInfo&&"ok"!==e.status&&"not-located-on-closest"!==e.status?e.symbol=n:"waypoint"!==e.locationType?"break"!==e.locationType?e.symbol=o:e.symbol=u:e.symbol=s:e.symbol=i:e.symbol=r}_toRouteLayerSolution(e){const{checksum:t,routeResults:r}=e,i=r[0].stops?.map(e=>ht.fromJSON(e.toJSON()));this._setStopSymbol(i);const o=new xt(i),n=new Dt(e.polygonBarriers?.map(e=>Je.fromJSON(e.toJSON())));At(n,this.defaultSymbols.polygonBarriers);const s=new Ft(e.polylineBarriers?.map(e=>ke.fromJSON(e.toJSON())));At(s,this.defaultSymbols.polylineBarriers);const a=new jt(e.pointBarriers?.map(e=>Pe.fromJSON(e.toJSON())));At(a,this.defaultSymbols.pointBarriers);const l=r[0].route?.toJSON(),u=Ve.fromJSON(l);u.symbol=this.defaultSymbols.routeInfo;const p=new Zt(r[0].directionPoints?.features.map(e=>Re.fromJSON(e.toJSON())));At(p,this.defaultSymbols.directionPoints);const c=new Nt(r[0].directionLines?.features.map(e=>xe.fromJSON(e.toJSON())));return At(c,this.defaultSymbols.directionLines),{checksum:t,directionLines:c,directionPoints:p,pointBarriers:a,polygonBarriers:n,polylineBarriers:s,routeInfo:u,stops:o}}_writeDirectionLines(){return this._writeNetworkFeatures(this.directionLines,this.defaultSymbols.directionLines,"esriGeometryPolyline",xe.fields,"DirectionLines","Direction Lines")}_writeDirectionPoints(){return this._writeNetworkFeatures(this.directionPoints,this.defaultSymbols.directionPoints,"esriGeometryPoint",Re.fields,"DirectionPoints","Direction Points")}_writeNetworkFeatures(e,t,r,i,o,n){if(!e?.length)return null;const s=this.spatialReference.toJSON(),{fullExtent:a,maxScale:l,minScale:u}=this;return{featureSet:{features:e.toArray().map(e=>function(e){const{attributes:t,geometry:r,popupTemplate:i,symbol:o}=e.toGraphic().toJSON();return{attributes:t,geometry:r,popupInfo:i,symbol:o}}(e)),geometryType:r,spatialReference:s},layerDefinition:{capabilities:"Query,Update,Editing",drawingInfo:{renderer:{type:"simple",symbol:t?.toJSON()??Ct(r)}},extent:a.toJSON(),fields:i,geometryType:r,hasM:!1,hasZ:!1,maxScale:l,minScale:u,name:o,objectIdField:"ObjectID",spatialReference:s,title:n,type:"Feature Layer",typeIdField:""}}}_writePointBarriers(){return this._writeNetworkFeatures(this.pointBarriers,this.defaultSymbols.pointBarriers,"esriGeometryPoint",Pe.fields,"Barriers","Point Barriers")}_writePolygonBarriers(){return this._writeNetworkFeatures(this.polygonBarriers,this.defaultSymbols.polygonBarriers,"esriGeometryPolygon",Je.fields,"PolygonBarriers","Polygon Barriers")}_writePolylineBarriers(){return this._writeNetworkFeatures(this.polylineBarriers,this.defaultSymbols.polylineBarriers,"esriGeometryPolyline",ke.fields,"PolylineBarriers","Line Barriers")}_writeRouteInfo(){return this._writeNetworkFeatures(null!=this.routeInfo?new l.A([this.routeInfo]):null,this.defaultSymbols.routeInfo,"esriGeometryPolyline",Ve.fields,"RouteInfo","Route Details")}_writeStops(){const e=this._writeNetworkFeatures(this.stops,null,"esriGeometryPoint",ht.fields,"Stops","Stops");if(null==e)return null;const{stops:t}=this.defaultSymbols,r=t?.first?.toJSON(),i=t?.middle?.toJSON(),o=t?.last?.toJSON();return e.layerDefinition.drawingInfo.renderer={type:"uniqueValue",field1:"Sequence",defaultSymbol:i,uniqueValueInfos:[{value:"1",symbol:r,label:"First Stop"},{value:`${this.stops.length}`,symbol:o,label:"Last Stop"}]},e}_populatePortalFields(e,t,r){const i=t.networkDataset?.networkAttributes,o=i?.filter(({usageType:e})=>"cost"===e)??[],n=r.travelMode??t.defaultTravelMode;if(null==n)return void p.A.getLogger(this).warn("route-layer:missing-travel-mode","The routing service must have a default travel mode or one must be specified in the route parameter.");const{timeAttributeName:s,distanceAttributeName:a}=n,l=o.find(({name:e})=>e===s),c=o.find(({name:e})=>e===a),d=r.travelMode?.impedanceAttributeName??r.impedanceAttribute??t.impedance,m=l?.units,y=c?.units;if(!m||!y)throw new u.A("routelayer:unknown-impedance-units","the units of either the distance or time impedance are unknown");const f=r.directionsLanguage??t.directionsLanguage,h=r.accumulateAttributes??t.accumulateAttributeNames??[],g=new Set(o.filter(({name:e})=>e===s||e===a||e===d||null!=e&&h.includes(e)).map(({name:e})=>e)),v=e=>{for(const t in e)g.has(t)||delete e[t]};for(const t of e.pointBarriers)null!=t.costs&&(t.addedCost=t.costs[d]??0,v(t.costs));for(const t of e.polygonBarriers)null!=t.costs&&(t.scaleFactor=t.costs[d]??1,v(t.costs));for(const t of e.polylineBarriers)null!=t.costs&&(t.scaleFactor=t.costs[d]??1,v(t.costs));const{routeInfo:b}=e,{findBestSequence:w,preserveFirstStop:T,preserveLastStop:C,startTimeIsUTC:S,timeWindowsAreUTC:M}=r;b.analysisSettings=new $e({accumulateAttributes:h,directionsLanguage:f,findBestSequence:w,preserveFirstStop:T,preserveLastStop:C,startTimeIsUTC:S,timeWindowsAreUTC:M,travelMode:n}),b.totalDuration=It(b.totalCosts?.[s]??0,m),b.totalDistance=Ot(b.totalCosts?.[a]??0,y),b.totalLateDuration=It(b.totalViolations?.[s]??0,m),b.totalWaitDuration=It(b.totalWait?.[s]??0,m),null!=b.totalCosts&&v(b.totalCosts),null!=b.totalViolations&&v(b.totalViolations),null!=b.totalWait&&v(b.totalWait);for(const t of e.stops)null!=t.serviceCosts&&(t.serviceDuration=It(t.serviceCosts[s]??0,m),t.serviceDistance=Ot(t.serviceCosts[a]??0,y),v(t.serviceCosts)),null!=t.cumulativeCosts&&(t.cumulativeDuration=It(t.cumulativeCosts[s]??0,m),t.cumulativeDistance=Ot(t.cumulativeCosts[a]??0,y),v(t.cumulativeCosts)),null!=t.violations&&(t.lateDuration=It(t.violations[s]??0,m),v(t.violations)),null!=t.wait&&(t.waitDuration=It(t.wait[s]??0,m),v(t.wait))}};(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1,origins:{"portal-item":{write:{allowNull:!0,ignoreOrigin:!0}},"web-map":{write:{overridePolicy(){return{allowNull:!0,ignoreOrigin:null==this.portalItem}}}}}}})],Bt.prototype,"_featureCollection",void 0),(0,i.Cg)([(0,H.K)(["web-map","portal-item"],"_featureCollection")],Bt.prototype,"writeFeatureCollectionWebmap",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1,origins:{"web-map":{write:{target:"type",overridePolicy(){return{ignoreOrigin:null!=this.portalItem}}}}}}})],Bt.prototype,"_type",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],Bt.prototype,"checksum",void 0),(0,i.Cg)([(0,g.MZ)({nonNullable:!0,type:_})],Bt.prototype,"defaultSymbols",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],Bt.prototype,"directionLines",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"directionLines",["layers","featureCollection.layers"])],Bt.prototype,"readDirectionLines",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],Bt.prototype,"directionPoints",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"directionPoints",["layers","featureCollection.layers"])],Bt.prototype,"readDirectionPoints",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1,origins:{"web-map":{write:{ignoreOrigin:!0}}}}})],Bt.prototype,"featureCollectionType",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],Bt.prototype,"fullExtent",null),(0,i.Cg)([(0,g.MZ)({json:{origins:{"web-map":{name:"featureCollection.showLegend"}},write:!0}})],Bt.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,g.MZ)({type:["show","hide"]})],Bt.prototype,"listMode",void 0),(0,i.Cg)([(0,g.MZ)({type:Number,nonNullable:!0,json:{write:!1}})],Bt.prototype,"maxScale",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"maxScale",["layers","featureCollection.layers"])],Bt.prototype,"readMaxScale",null),(0,i.Cg)([(0,g.MZ)({type:Number,nonNullable:!0,json:{write:!1}})],Bt.prototype,"minScale",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"minScale",["layers","featureCollection.layers"])],Bt.prototype,"readMinScale",null),(0,i.Cg)([(0,g.MZ)({type:["ArcGISFeatureLayer"],value:"ArcGISFeatureLayer"})],Bt.prototype,"operationalLayerType",void 0),(0,i.Cg)([(0,g.MZ)({nonNullable:!0,type:l.A.ofType(Pe)})],Bt.prototype,"pointBarriers",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"pointBarriers",["layers","featureCollection.layers"])],Bt.prototype,"readPointBarriers",null),(0,i.Cg)([(0,g.MZ)({nonNullable:!0,type:l.A.ofType(Je)})],Bt.prototype,"polygonBarriers",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"polygonBarriers",["layers","featureCollection.layers"])],Bt.prototype,"readPolygonBarriers",null),(0,i.Cg)([(0,g.MZ)({nonNullable:!0,type:l.A.ofType(ke)})],Bt.prototype,"polylineBarriers",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"polylineBarriers",["layers","featureCollection.layers"])],Bt.prototype,"readPolylineBarriers",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],Bt.prototype,"routeInfo",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"routeInfo",["layers","featureCollection.layers"])],Bt.prototype,"readRouteInfo",null),(0,i.Cg)([(0,g.MZ)({type:C.A})],Bt.prototype,"spatialReference",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"spatialReference",["layers","featureCollection.layers"])],Bt.prototype,"readSpatialReference",null),(0,i.Cg)([(0,g.MZ)({nonNullable:!0,type:l.A.ofType(ht)})],Bt.prototype,"stops",void 0),(0,i.Cg)([(0,Y.w)(["web-map","portal-item"],"stops",["layers","featureCollection.layers"])],Bt.prototype,"readStops",null),(0,i.Cg)([(0,g.MZ)()],Bt.prototype,"title",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0,json:{read:!1}})],Bt.prototype,"type",void 0),(0,i.Cg)([(0,g.MZ)()],Bt.prototype,"url",null),Bt=(0,i.Cg)([(0,g.$K)("esri.layers.RouteLayer")],Bt);const Rt=Bt},37539:(e,t,r)=>{r.d(t,{pO:()=>f,jd:()=>d,Tp:()=>m,w5:()=>c});var i=r(34727),o=r(86211),n=r(73941),s=r(79258);Math.PI;const a=s.$O.radius,l=s.$O.eccentricitySquared,u={a1:a*l,a2:a*l*a*l,a3:a*l*l/2,a4:a*l*a*l*2.5,a5:a*l+a*l*l/2,a6:1-l};s.$O.radius,s.$O.flattening,s.Sw.radius,s.Sw.flattening,s.sH.radius,s.sH.flattening,s.sH.radius;var p=r(21325);const c={2:{5:f,7:null,9:null,10:f,1:S,6:null,8:null,0:null,3:g,11:v,2:f,4:N},5:{5:f,7:null,9:null,10:f,1:S,6:null,8:null,0:null,3:g,11:v,2:f,4:N},7:{5:null,7:f,9:null,10:f,1:null,6:C,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:f,10:f,1:null,6:null,8:T,0:null,3:null,11:null,2:null,4:null},3:{5:h,7:null,9:null,10:h,1:function(e,t,r,i){const o=e[t]/B,n=x-2*Math.atan(Math.exp(-e[t+1]/B)),s=B+(e[t+2]??0),a=Math.cos(n)*s;r[i]=Math.cos(o)*a,r[i+1]=Math.sin(o)*a,r[i+2]=Math.sin(n)*s},6:null,8:null,0:null,3:f,11:function(e,t,r,i){h(e,t,r,i),v(r,i,r,i)},2:h,4:function(e,t,r,i){h(e,t,r,i),N(r,i,r,i)}},4:{5:Z,7:null,9:null,10:Z,1:function(e,t,r,i){Z(e,t,r,i),S(r,i,r,i)},6:null,8:null,0:null,3:function(e,t,r,i){Z(e,t,r,i),g(r,i,r,i)},11:function(e,t,r,i){Z(e,t,r,i),v(r,i,r,i)},2:Z,4:f},1:{5:O,7:null,9:null,10:O,1:f,6:null,8:null,0:null,3:function(e,t,r,i){O(e,t,r,i),g(r,i,r,i)},11:function(e,t,r,i){O(e,t,r,i),v(r,i,r,i)},2:O,4:function(e,t,r,i){O(e,t,r,i),N(r,i,r,i)}},6:{5:null,7:I,9:null,10:I,1:null,6:f,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:A,10:A,1:null,6:null,8:f,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:f,3:null,11:null,2:null,4:null},10:{5:f,7:f,9:f,10:f,1:S,6:C,8:T,0:null,3:g,11:v,2:f,4:N},11:{5:b,7:null,9:null,10:b,1:function(e,t,r,i){b(e,t,r,i),S(r,i,r,i)},6:null,8:null,0:null,3:function(e,t,r,i){b(e,t,r,i),g(r,i,r,i)},11:f,2:b,4:function(e,t,r,i){b(e,t,r,i),N(r,i,r,i)}}};function d(e,t){return m(e,t)?.projector}function m(e,t){if(null==e||null==t)return null;if(j.source.spatialReference===e&&j.dest.spatialReference===t)return j;const r=y(e,j.source),i=y(t,j.dest);return 0===r&&0===i?(0,p.aI)(e,t)?j.projector=f:j.projector=null:j.projector=c[r][i],j}function y(e,t){return e?t.spatialReference===e?t.spatialReferenceId:(t.spatialReference=e,"metersPerUnit"in t&&(t.metersPerUnit=(0,o.GA)(e,1)),(0,n.jA)(e)?t.spatialReferenceId=1:(0,p.oT)(e)?t.spatialReferenceId=2:(0,p.K8)(e)?t.spatialReferenceId=3:(0,p.r1)(e)?t.spatialReferenceId=11:e.wkt===n.Ro.wkt?t.spatialReferenceId=4:4490===e.wkid?t.spatialReferenceId=5:e.wkt===n.FY.wkt?t.spatialReferenceId=6:e.wkt===n.LJ.wkt?t.spatialReferenceId=8:(0,p.q8)(e)?t.spatialReferenceId=7:(0,p.KQ)(e)?t.spatialReferenceId=9:t.spatialReferenceId=0):0}function f(e,t,r,i){e!==r&&(r[i++]=e[t++],r[i++]=e[t++],r[i]=e[t]??0)}function h(e,t,r,i){r[i]=F*(e[t]/B),r[i+1]=F*(x-2*Math.atan(Math.exp(-e[t+1]/B))),r[i+2]=e[t+2]??0}function g(e,t,r,o){!function(e,t,r,o,n){const s=.4999999*Math.PI,a=(0,i.qE)(D*e[t+1],-s,s),l=Math.sin(a);r[o++]=D*e[t]*n.radius,r[o++]=n.halfSemiMajorAxis*Math.log((1+l)/(1-l)),r[o]=e[t+2]??0}(e,t,r,o,s.$O)}function v(e,t,r,i){r[i]=e[t]*R,r[i+1]=e[t+1]*R,r[i+2]=e[t+2]??0}function b(e,t,r,i){r[i]=e[t]*_,r[i+1]=e[t+1]*_,r[i+2]=e[t+2]??0}function w(e,t,r,i,o){const n=o+(e[t+2]??0),s=D*e[t],a=D*e[t+1],l=Math.cos(a)*n;r[i]=Math.cos(s)*l,r[i+1]=Math.sin(s)*l,r[i+2]=Math.sin(a)*n}function T(e,t,r,i){w(e,t,r,i,s.Sw.radius)}function C(e,t,r,i){w(e,t,r,i,s.sH.radius)}function S(e,t,r,i){w(e,t,r,i,s.$O.radius)}function M(e,t,r,o,n){const s=e[t],a=e[t+1],l=e[t+2]??0,u=Math.sqrt(s*s+a*a+l*l),p=(0,i.YN)(l/(0===u?1:u)),c=Math.atan2(a,s);r[o++]=F*c,r[o++]=F*p,r[o]=u-n}function A(e,t,r,i){M(e,t,r,i,s.Sw.radius)}function I(e,t,r,i){M(e,t,r,i,s.sH.radius)}function O(e,t,r,i){M(e,t,r,i,s.$O.radius)}function N(e,t,r,i){!function(e,t,r,i,o){const n=D*e[t],s=D*e[t+1],a=e[t+2]??0,l=Math.sin(s),u=Math.cos(s),p=o.radius/Math.sqrt(1-o.eccentricitySquared*l*l);r[i++]=(p+a)*u*Math.cos(n),r[i++]=(p+a)*u*Math.sin(n),r[i++]=(p*(1-o.eccentricitySquared)+a)*l}(e,t,r,i,s.$O)}function Z(e,t,r,i){const o=u,n=e[t],a=e[t+1],l=e[t+2]??0;let p,c,d,m,y,f,h,g,v,b,w,T,C,S,M,A,I,O,N,Z,j;p=Math.abs(l),c=n*n+a*a,d=Math.sqrt(c),m=c+l*l,y=Math.sqrt(m),Z=Math.atan2(a,n),f=l*l/m,h=c/m,S=o.a2/y,M=o.a3-o.a4/y,h>.3?(g=p/y*(1+h*(o.a1+S+f*M)/y),N=Math.asin(g),b=g*g,v=Math.sqrt(1-b)):(v=d/y*(1-f*(o.a5-S-h*M)/y),N=Math.acos(v),b=1-v*v,g=Math.sqrt(b)),w=1-s.$O.eccentricitySquared*b,T=s.$O.radius/Math.sqrt(w),C=o.a6*T,S=d-T*v,M=p-C*g,I=v*S+g*M,A=v*M-g*S,O=A/(C/w+I),N+=O,j=I+A*O/2,l<0&&(N=-N),r[i++]=F*Z,r[i++]=F*N,r[i]=j}const j={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:f},D=(0,i.kU)(1),F=(0,i.KJ)(1),x=.5*Math.PI,B=s.$O.radius,R=B*Math.PI/180,_=180/(B*Math.PI)},46130:(e,t,r)=>{r.d(t,{v:()=>o});var i=r(76553);function o(e){e?.writtenProperties&&e.writtenProperties.forEach(({target:e,propName:t,newOrigin:r})=>{(0,i.H)(e)&&r&&e.originOf(t)!==r&&e.updateOrigin(t,r)})}},46140:(e,t,r)=>{r.d(t,{R:()=>o});var i=r(49186);let o=class e{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,r=""){const[o,n]=t.split("."),s=/^\s*\d+\s*$/;if(!o?.match||!s.test(o))throw new i.A((r&&r+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!n?.match||!s.test(n))throw new i.A((r&&r+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const a=parseInt(o,10),l=parseInt(n,10);return new e(a,l,r)}}},54339:(e,t,r)=>{function i(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{const r=[];for(const i of t.fieldNames)r.push(e.attributes[i]??null);return JSON.stringify(r)}}}function o(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];const r=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(r)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}r.d(t,{W:()=>i,r:()=>o})},55674:(e,t,r)=>{r.d(t,{Ad:()=>m,Gj:()=>h,QY:()=>d,lL:()=>g,xR:()=>y});var i=r(66131),o=r(49186),n=(r(44208),r(44729)),s=r(15032),a=r(65864),l=r(95466),u=r(43668),p=r(98623);const c=["geometry","scale","timeProperties"];function d(e,t){if(null!=t)for(const r of c)t.hasArcadeDependency(r)&&e.add(r);return e}function m(e,t){return f.create(e,t,null,["$feature","$view"])}function y(e,t,r){return f.create(e,t,r,["$feature","$view","$config"])}class f{static async create(e,t,r,i){const{arcade:n,Dictionary:s}=await(0,u.l)();let a;try{a=n.parseScript(e)}catch(t){throw new o.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=n.scriptUsesGeometryEngine(a);l&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,a,null,!1,l);const p={vars:i.reduce((e,t)=>({...e,[t]:null}),{}),spatialReference:t,useAsync:!1},c=n.compileScript(a,p);let d=null;null!=r&&(d=new s(r),d.immutable=!0);const m=new s;return m.immutable=!1,m.setField("scale",0),new f(e,n,a,c,t,m,d,s)}constructor(e,t,r,i,o,n,s,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=i,this._spatialReference=o,this._viewDict=n,this._configDict=s,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new h,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:o,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=o?null!=r?i.lY.epochToArcadeDate(o,r):i.lY.unknownEpochToArcadeDate(o):void 0,currentEnd:null!=n?null!=r?i.lY.epochToArcadeDate(n,r):i.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class h{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const i=t??new l.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=i.fields,this._boundSchema.fieldsIndex=i,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}_hasGeometry(){return null!=this._boundTarget.geometry}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===p.L5}field(e,t=!0){const r=this._getField(e);if(r){const t=this._boundTarget.attributes[r.name];if(null==t)return null;switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(t);case"time-only":case"esriFieldTypeTimeOnly":return s.k.fromReader(t);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return i.lY.fromReaderAsTimeStampOffset(t);case"date":case"esriFieldTypeDate":return this.isUnknownDateTimeField(e)?i.lY.unknownEpochToArcadeDate(t):i.lY.epochToArcadeDate(t,this.contextTimeZone??p.qU);default:return t}}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map(e=>e.name)}isEmpty(){return this._boundSchema.fields.length<=0&&!this._hasGeometry()}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}},63074:(e,t,r)=>{r.d(t,{LF:()=>u,dM:()=>p,sU:()=>a});var i=r(31635),o=r(91429),n=r(89317),s=r(76369);const a={type:["average","color-burn","color-dodge","color","darken","destination-atop","destination-in","destination-out","destination-over","difference","exclusion","hard-light","hue","invert","lighten","lighter","luminosity","minus","multiply","normal","overlay","plus","reflect","saturation","screen","soft-light","source-atop","source-in","source-out","vivid-light","xor"],nonNullable:!0,json:{read:!1,write:!1,origins:{"web-map":{read:!0,write:{layerContainerTypes:n.K}},"portal-item":{read:!0,write:{layerContainerTypes:n.K}}}}},l={read:{reader:s.LF},write:{allowNull:!0,writer:s.M9,layerContainerTypes:n.K}},u={json:{read:!1,write:!1,origins:{"web-map":l,"portal-item":l}}},p=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.blendMode="normal",this.effect=null}};return(0,i.Cg)([(0,o.MZ)(a)],r.prototype,"blendMode",void 0),(0,i.Cg)([(0,o.MZ)(u)],r.prototype,"effect",void 0),r=(0,i.Cg)([(0,o.$K)("esri.layers.mixins.BlendLayer")],r),r}},65494:(e,t,r)=>{r.d(t,{L:()=>l,r:()=>s});var i=r(67076),o=r(90360),n=r(41214);function s(e,t){return l(e,null,t)}const a=(0,o.C)({types:n.Hg});function l(e,t,r){return e?e&&(e.styleName||e.styleUrl)&&"uniqueValue"!==e.type?(r?.messages&&r.messages.push(new i.A("renderer:unsupported","Only UniqueValueRenderer can be referenced from a web style, but found '"+e.type+"'",{definition:e,context:r})),null):a(e,t,r):null}},69052:(e,t,r)=>{r.d(t,{hr:()=>o,ie:()=>l,uC:()=>a});var i=r(34727);class o{constructor(e,t){this.min=e,this.max=t,this.range=t-e}normalize(e,t=0,r=!1){return n(this.range,this.min,this.max,e,t,r)}clamp(e,t=0){return(0,i.qE)(e-t,this.min,this.max)+t}monotonic(e,t,r){return e<t?t:t+s(this.range,e-t,r)}minimalMonotonic(e,t,r){return n(this.range,e,e+this.range,t,r)}center(e,t,r){return t=this.monotonic(e,t,r),this.normalize((e+t)/2,r)}diff(e,t,r){return this.monotonic(e,t,r)-e}shortestSignedDiff(e,t){e=this.normalize(e);const r=(t=this.normalize(t))-e,i=t<e?this.minimalMonotonic(e,t)-e:t-this.minimalMonotonic(t,e);return Math.abs(r)<Math.abs(i)?r:i}contains(e,t,r){return t=this.minimalMonotonic(e,t),(r=this.minimalMonotonic(e,r))>e&&r<t}}function n(e,t,r,i,o=0,n=!1){return(i-=o)<t?i+=s(e,t-i):i>r&&(i-=s(e,i-r)),n&&i===r&&(i=t),i+o}function s(e,t,r=0){return Math.ceil((t-r)/e)*e+r}const a=new o(0,2*Math.PI),l=(new o(-Math.PI,Math.PI),new o(0,360))},70328:(e,t,r)=>{r.d(t,{BI:()=>b,DC:()=>c,Ej:()=>m,Ie:()=>g,Jt:()=>v,Ne:()=>y,RF:()=>p,aI:()=>T,fA:()=>s,gE:()=>l,hZ:()=>h,iT:()=>d,is:()=>w,qv:()=>C,vI:()=>f,vY:()=>a,v_:()=>S,vt:()=>n,w1:()=>u});var i=r(5443),o=(r(19419),r(4197));function n(e=S){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function s(e,t,r,i,o,s,a=n()){return a[0]=e,a[1]=t,a[2]=r,a[3]=i,a[4]=o,a[5]=s,a}function a(e,t=n()){return function(e,t,r,i=n()){return h(i,C),function(e,t,r=0,i=t.length/3){let o=e[0],n=e[1],s=e[2],a=e[3],l=e[4],u=e[5];for(let e=0;e<i;e++)o=Math.min(o,t[r+3*e]),n=Math.min(n,t[r+3*e+1]),s=Math.min(s,t[r+3*e+2]),a=Math.max(a,t[r+3*e]),l=Math.max(l,t[r+3*e+1]),u=Math.max(u,t[r+3*e+2]);e[0]=o,e[1]=n,e[2]=s,e[3]=a,e[4]=l,e[5]=u}(i,e,t,r),i}(e,0,e.length/3,t)}function l(e,t=(0,o.jh)(24)){const[r,i,n,s,a,l]=e;return t[0]=r,t[1]=i,t[2]=n,t[3]=r,t[4]=i,t[5]=l,t[6]=r,t[7]=a,t[8]=n,t[9]=r,t[10]=a,t[11]=l,t[12]=s,t[13]=i,t[14]=n,t[15]=s,t[16]=i,t[17]=l,t[18]=s,t[19]=a,t[20]=n,t[21]=s,t[22]=a,t[23]=l,t}function u(e,t){const r=isFinite(e[2])||isFinite(e[5]);return new i.A(r?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function p(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function c(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[3]=Math.max(e[3],t[2]),e[4]=Math.max(e[4],t[3])}function d(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function m(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function y(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function f(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function h(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function g(e){return e?h(e,C):n(C)}function v(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function b(e,t,r,i,o){return e[0]=t,e[1]=r,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=o,e[5]=Number.POSITIVE_INFINITY,e}function w(e){return 6===e.length}function T(e,t,r){if(null==e||null==t)return e===t;if(!w(e)||!w(t))return!1;if(r){for(let i=0;i<e.length;i++)if(!r(e[i],t[i]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}const C=[1/0,1/0,1/0,-1/0,-1/0,-1/0],S=[0,0,0,0,0,0];n()},73681:(e,t,r)=>{r.d(t,{n:()=>l});var i=r(49186),o=r(53966),n=r(46140),s=r(95466),a=r(55674);class l{static async from(e,t,r){const s=e.dictionary_version?n.R.parse(e.dictionary_version):null,p=new Set(e.itemsNames),c={};if(t)for(const e in t)c[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)c.hasOwnProperty(t.name)||(c[t.name]=t.value);const d=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))d.delete(e);d.size&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:d});const m=await(0,a.xR)(e.expression,null,c);if(!m)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const y=!s||!s.greaterEqual(4,0);y&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:s});const f=new u(r,y);return new l(y,p,m,f)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new s.A(e);const t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new s.A(t)}}class u extends a.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},76369:(e,t,r)=>{r.d(t,{LF:()=>C,M9:()=>S});var i=r(49186),o=r(93637),n=r(40876),s=r(59247),a=r(27865);class l extends SyntaxError{constructor(e,t,r,i){super(e),this.expected=t,this.found=r,this.location=i,this.name="SyntaxError"}format(e){let t="Error: "+this.message;if(this.location){let r=null;const i=e.find(e=>e.source===this.location.source);i&&(r=i.text.split(/\r\n|\n|\r/g));const o=this.location.start,n=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(o):o,s=this.location.source+":"+n.line+":"+n.column;if(r){const e=this.location.end,i="".padEnd(n.line.toString().length," "),a=r[o.line-1],l=(o.line===e.line?e.column:a.length+1)-o.column||1;t+="\n --\x3e "+s+"\n"+i+" |\n"+n.line+" | "+a+"\n"+i+" | "+"".padEnd(o.column-1," ")+"".padEnd(l,"^")}else t+="\n at "+s}return t}static buildMessage(e,t){function r(e){return e.codePointAt(0).toString(16).toUpperCase()}const i=Object.prototype.hasOwnProperty.call(RegExp.prototype,"unicode")?new RegExp("[\\p{C}\\p{Mn}\\p{Mc}]","gu"):null;function o(e){return i?e.replace(i,e=>"\\u{"+r(e)+"}"):e}function n(e){return o(e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,e=>"\\x0"+r(e)).replace(/[\x10-\x1F\x7F-\x9F]/g,e=>"\\x"+r(e)))}function s(e){return o(e.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,e=>"\\x0"+r(e)).replace(/[\x10-\x1F\x7F-\x9F]/g,e=>"\\x"+r(e)))}const a={literal:e=>'"'+n(e.text)+'"',class(e){const t=e.parts.map(e=>Array.isArray(e)?s(e[0])+"-"+s(e[1]):s(e));return"["+(e.inverted?"^":"")+t.join("")+"]"+(e.unicode?"u":"")},any:()=>"any character",end:()=>"end of input",other:e=>e.description};function l(e){return a[e.type](e)}return"Expected "+function(e){const t=e.map(l);if(t.sort(),t.length>0){let e=1;for(let r=1;r<t.length;r++)t[r-1]!==t[r]&&(t[e]=t[r],e++);t.length=e}switch(t.length){case 1:return t[0];case 2:return t[0]+" or "+t[1];default:return t.slice(0,-1).join(", ")+", or "+t[t.length-1]}}(e)+" but "+function(e){return e?'"'+n(e)+'"':"end of input"}(t)+" found."}}function u(e){if(!e||0===e.length)return null;if("string"==typeof e){const t=p(e);return t&&0!==t.length?t:null}const t=e.map(e=>{if(!Number.isFinite(e.scale)||e.scale<=0)throw new i.A("effect:invalid-scale","scale must be finite and greater than 0",{stop:e});return{scale:e.scale,effects:p(e.value)}});t.sort((e,t)=>t.effects.length-e.effects.length);for(let e=0;e<t.length-1;e++){if(!(0,a.mj)(t[e].effects,t[e+1].effects))throw new i.A("effect:interpolation-impossible","Cannot interpolate by scale between 2 lists of mixed effects",{a:t[e].effects,b:t[e+1].effects});(0,a.O9)(t[e].effects,t[e+1].effects)}return t.sort((e,t)=>t.scale-e.scale),t}function p(e){let t;if(!e)return[];try{t=function(e,t){const r={},i=(t=void 0!==t?t:{}).grammarSource,o={start:Te};let n=Te;const s="none",a=")",u=",",p="(",c="%",d="px",m="cm",y="mm",f="in",h="pt",g="pc",v="deg",b="rad",w="grad",T="turn",C="#",S=".",M="e",A=/^[ \t\n\r]/,I=/^[a-z\-]/,O=/^[0-9a-fA-F]/,N=/^[+\-]/,Z=/^[0-9]/,j=ge("none"),D=fe("none",!1),F=fe(")",!1),x=fe(",",!1),B=he([" ","\t","\n","\r"],!1,!1,!1),R=ge("function"),_=fe("(",!1),P=ge("identifier"),E=he([["a","z"],"-"],!1,!1,!1),L=ge("percentage"),J=fe("%",!1),U=ge("length"),k=fe("px",!1),$=fe("cm",!1),W=fe("mm",!1),V=fe("in",!1),q=fe("pt",!1),G=fe("pc",!1),K=ge("angle"),z=fe("deg",!1),Y=fe("rad",!1),H=fe("grad",!1),X=fe("turn",!1),Q=ge("number"),ee=ge("color"),te=fe("#",!1),re=he([["0","9"],["a","f"],["A","F"]],!1,!1,!1),ie=he(["+","-"],!1,!1,!1),oe=he([["0","9"]],!1,!1,!1),ne=fe(".",!1),se=fe("e",!1);let ae=0|t.peg$currPos,le=ae;const ue=[{line:1,column:1}];let pe,ce=ae,de=t.peg$maxFailExpected||[],me=0|t.peg$silentFails;if(t.startRule){if(!(t.startRule in o))throw new Error("Can't start parsing from rule \""+t.startRule+'".');n=o[t.startRule]}function ye(){return e.substring(le,ae)}function fe(e,t){return{type:"literal",text:e,ignoreCase:t}}function he(e,t,r,i){return{type:"class",parts:e,inverted:t,ignoreCase:r,unicode:i}}function ge(e){return{type:"other",description:e}}function ve(t){let r,i=ue[t];if(i)return i;if(t>=ue.length)r=ue.length-1;else for(r=t;!ue[--r];);for(i=ue[r],i={line:i.line,column:i.column};r<t;)10===e.charCodeAt(r)?(i.line++,i.column=1):i.column++,r++;return ue[t]=i,i}function be(e,t,r){const o=ve(e),n=ve(t);return{source:i,start:{offset:e,line:o.line,column:o.column},end:{offset:t,line:n.line,column:n.column}}}function we(e){ae<ce||(ae>ce&&(ce=ae,de=[]),de.push(e))}function Te(){let e;return e=Ce(),e===r&&(e=function(){let e,t;if(e=[],t=Se(),t!==r)for(;t!==r;)e.push(t),t=Se();else e=r;return e}()),e}function Ce(){let t,i;return me++,t=ae,Ae(),e.substr(ae,4)===s?(i=s,ae+=4):(i=r,0===me&&we(D)),i!==r?(Ae(),le=t,t=[]):(ae=t,t=r),me--,t===r&&0===me&&we(j),t}function Se(){let t,i,o,n;return t=ae,Ae(),i=function(){let t,i,o;return me++,t=ae,i=Ie(),i!==r?(40===e.charCodeAt(ae)?(o=p,ae++):(o=r,0===me&&we(_)),o!==r?(le=t,t=i):(ae=t,t=r)):(ae=t,t=r),me--,t===r&&(i=r,0===me&&we(R)),t}(),i!==r?(Ae(),o=function(){let t,i,o,n,s,a,l,p;if(t=ae,i=Me(),i!==r){for(o=[],n=ae,s=Ae(),44===e.charCodeAt(ae)?(a=u,ae++):(a=r,0===me&&we(x)),a===r&&(a=null),l=Ae(),p=Me(),p!==r?(s=[s,a,l,p],n=s):(ae=n,n=r);n!==r;)o.push(n),n=ae,s=Ae(),44===e.charCodeAt(ae)?(a=u,ae++):(a=r,0===me&&we(x)),a===r&&(a=null),l=Ae(),p=Me(),p!==r?(s=[s,a,l,p],n=s):(ae=n,n=r);le=t,t=function(e,t){return t.length>0?function(e,t){return[e].concat(function(e){return e.map(function(e){return e[3]})}(t))}(e,t):[e]}(i,o)}else ae=t,t=r;return t}(),o===r&&(o=null),Ae(),41===e.charCodeAt(ae)?(n=a,ae++):(n=r,0===me&&we(F)),n!==r?(Ae(),le=t,t=function(e,t){return{type:"function",name:e,parameters:t||[]}}(i,o)):(ae=t,t=r)):(ae=t,t=r),t}function Me(){let e,t;return e=ae,t=Oe(),t===r&&(t=Ne(),t===r&&(t=Ze(),t===r&&(t=function(){let e,t;return me++,e=ae,Ae(),t=De(),t!==r?(le=e,e=function(e){return{value:e,unit:null}}(t)):(ae=e,e=r),me--,e===r&&0===me&&we(Q),e}()))),t!==r&&(le=e,t=function(e){return{type:"quantity",value:e.value,unit:e.unit}}(t)),e=t,e===r&&(e=ae,t=je(),t!==r&&(le=e,t=function(e){return{type:"color",colorType:e.type,value:e.value}}(t)),e=t),e}function Ae(){let t,i;for(me++,t=[],i=e.charAt(ae),A.test(i)?ae++:(i=r,0===me&&we(B));i!==r;)t.push(i),i=e.charAt(ae),A.test(i)?ae++:(i=r,0===me&&we(B));return me--,t}function Ie(){let t,i,o;if(me++,t=ae,i=[],o=e.charAt(ae),I.test(o)?ae++:(o=r,0===me&&we(E)),o!==r)for(;o!==r;)i.push(o),o=e.charAt(ae),I.test(o)?ae++:(o=r,0===me&&we(E));else i=r;return i!==r&&(le=t,i=ye()),t=i,me--,t===r&&(i=r,0===me&&we(P)),t}function Oe(){let t,i,o;return me++,t=ae,Ae(),i=De(),i!==r?(37===e.charCodeAt(ae)?(o=c,ae++):(o=r,0===me&&we(J)),o!==r?(le=t,t=function(e){return{value:e,unit:"%"}}(i)):(ae=t,t=r)):(ae=t,t=r),me--,t===r&&0===me&&we(L),t}function Ne(){let t,i,o;return me++,t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===d?(o=d,ae+=2):(o=r,0===me&&we(k)),o!==r?(le=t,t=function(e){return{value:e,unit:"px"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===m?(o=m,ae+=2):(o=r,0===me&&we($)),o!==r?(le=t,t=function(e){return{value:e,unit:"cm"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===y?(o=y,ae+=2):(o=r,0===me&&we(W)),o!==r?(le=t,t=function(e){return{value:e,unit:"mm"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===f?(o=f,ae+=2):(o=r,0===me&&we(V)),o!==r?(le=t,t=function(e){return{value:e,unit:"in"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===h?(o=h,ae+=2):(o=r,0===me&&we(q)),o!==r?(le=t,t=function(e){return{value:e,unit:"pt"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,Ae(),i=De(),i!==r?(e.substr(ae,2)===g?(o=g,ae+=2):(o=r,0===me&&we(G)),o!==r?(le=t,t=function(e){return{value:e,unit:"pc"}}(i)):(ae=t,t=r)):(ae=t,t=r)))))),me--,t===r&&0===me&&we(U),t}function Ze(){let t,i,o;return me++,t=ae,i=De(),i!==r?(e.substr(ae,3)===v?(o=v,ae+=3):(o=r,0===me&&we(z)),o!==r?(le=t,t=function(e){return{value:e,unit:"deg"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,i=De(),i!==r?(e.substr(ae,3)===b?(o=b,ae+=3):(o=r,0===me&&we(Y)),o!==r?(le=t,t=function(e){return{value:e,unit:"rad"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,i=De(),i!==r?(e.substr(ae,4)===w?(o=w,ae+=4):(o=r,0===me&&we(H)),o!==r?(le=t,t=function(e){return{value:e,unit:"grad"}}(i)):(ae=t,t=r)):(ae=t,t=r),t===r&&(t=ae,i=De(),i!==r?(e.substr(ae,4)===T?(o=T,ae+=4):(o=r,0===me&&we(X)),o!==r?(le=t,t=function(e){return{value:e,unit:"turn"}}(i)):(ae=t,t=r)):(ae=t,t=r)))),me--,t===r&&(i=r,0===me&&we(K)),t}function je(){let t,i,o,n;if(me++,t=ae,35===e.charCodeAt(ae)?(i=C,ae++):(i=r,0===me&&we(te)),i!==r){if(o=[],n=e.charAt(ae),O.test(n)?ae++:(n=r,0===me&&we(re)),n!==r)for(;n!==r;)o.push(n),n=e.charAt(ae),O.test(n)?ae++:(n=r,0===me&&we(re));else o=r;o!==r?(le=t,t={type:"hex",value:ye()}):(ae=t,t=r)}else ae=t,t=r;return t===r&&(t=ae,i=Se(),i!==r&&(le=t,i=function(e){return{type:"function",value:e}}(i)),t=i,t===r&&(t=ae,i=Ie(),i!==r&&(le=t,i={type:"named",value:ye()}),t=i)),me--,t===r&&(i=r,0===me&&we(ee)),t}function De(){let t,i,o,n,s,a,l,u;for(t=ae,i=e.charAt(ae),N.test(i)?ae++:(i=r,0===me&&we(ie)),i===r&&(i=null),o=ae,n=[],s=e.charAt(ae),Z.test(s)?ae++:(s=r,0===me&&we(oe));s!==r;)n.push(s),s=e.charAt(ae),Z.test(s)?ae++:(s=r,0===me&&we(oe));if(46===e.charCodeAt(ae)?(s=S,ae++):(s=r,0===me&&we(ne)),s!==r){if(a=[],l=e.charAt(ae),Z.test(l)?ae++:(l=r,0===me&&we(oe)),l!==r)for(;l!==r;)a.push(l),l=e.charAt(ae),Z.test(l)?ae++:(l=r,0===me&&we(oe));else a=r;a!==r?(n=[n,s,a],o=n):(ae=o,o=r)}else ae=o,o=r;if(o===r)if(o=[],n=e.charAt(ae),Z.test(n)?ae++:(n=r,0===me&&we(oe)),n!==r)for(;n!==r;)o.push(n),n=e.charAt(ae),Z.test(n)?ae++:(n=r,0===me&&we(oe));else o=r;if(o!==r){if(n=ae,101===e.charCodeAt(ae)?(s=M,ae++):(s=r,0===me&&we(se)),s!==r){if(a=e.charAt(ae),N.test(a)?ae++:(a=r,0===me&&we(ie)),a===r&&(a=null),l=[],u=e.charAt(ae),Z.test(u)?ae++:(u=r,0===me&&we(oe)),u!==r)for(;u!==r;)l.push(u),u=e.charAt(ae),Z.test(u)?ae++:(u=r,0===me&&we(oe));else l=r;l!==r?(s=[s,a,l],n=s):(ae=n,n=r)}else ae=n,n=r;n===r&&(n=null),le=t,t=parseFloat(ye())}else ae=t,t=r;return t}pe=n();const Fe=pe!==r&&ae===e.length;function xe(){throw pe!==r&&ae<e.length&&we({type:"end"}),function(e,t,r){return new l(l.buildMessage(e,t),e,t,r)}(de,ce<e.length?function(t=ae){const r=e.codePointAt(t);return void 0===r?"":String.fromCodePoint(r)}(ce):null,ce<e.length?be(ce,ce+1):be(ce,ce))}return t.peg$library?{peg$result:pe,peg$currPos:ae,peg$FAILED:r,peg$maxFailExpected:de,peg$maxFailPos:ce,peg$success:Fe,peg$throw:Fe?void 0:xe}:Fe?pe:void xe()}(e)}catch(t){throw new i.A("effect:invalid-syntax","Invalid effect syntax",{value:e,error:t})}return t.map(e=>function(e){try{switch(e.name){case"grayscale":case"sepia":case"saturate":case"invert":case"brightness":case"contrast":return function(e){let t=1;return c(e.parameters,1),1===e.parameters.length&&(t=h(e.parameters[0])),new s.yG(e.name,t)}(e);case"opacity":return function(e){let t=1;return c(e.parameters,1),1===e.parameters.length&&(t=h(e.parameters[0])),new s.jm(t)}(e);case"hue-rotate":return function(e){let t=0;return c(e.parameters,1),1===e.parameters.length&&(t=function(e){return function(e){if("quantity"!==e.type||!(0===e.value&&null===e.unit||e.unit&&null!=y[e.unit]))throw new i.A("effect:type-error",`Expected <angle>, Actual: ${d(e)}`,{term:e})}(e),e.value*y[e.unit]||0}(e.parameters[0])),new s.Nd(t)}(e);case"blur":return function(e){let t=0;return c(e.parameters,1),1===e.parameters.length&&(t=g(e.parameters[0]),m(t,e.parameters[0])),new s.Fk(t)}(e);case"drop-shadow":return function(e){const t=[];let r=null;for(const o of e.parameters)if("color"===o.type){if(t.length&&Object.freeze(t),r)throw new i.A("effect:type-error","Accepts only one color",{});r=v(o)}else{const e=g(o);if(Object.isFrozen(t))throw new i.A("effect:type-error","<length> parameters not consecutive",{lengths:t});t.push(e),3===t.length&&m(e,o)}if(t.length<2||t.length>3)throw new i.A("effect:type-error",`Expected <length>{2,3}, Actual: <length>{${t.length}}`,{lengths:t});return new s.$b(t[0],t[1],t[2]||0,r||b("black"))}(e);case"bloom":return function(e){let t=1,r=0,i=0;return c(e.parameters,3),e.parameters[0]&&(t=h(e.parameters[0])),e.parameters[1]&&(r=g(e.parameters[1]),m(r,e.parameters[1])),e.parameters[2]&&(i=h(e.parameters[2])),new s.bv(t,r,i)}(e)}}catch(t){throw t.details.filter=e,t}throw new i.A("effect:unknown-effect",`Effect '${e.name}' is not supported`,{effect:e})}(e))}function c(e,t){if(e.length>t)throw new i.A("effect:type-error",`Function supports up to ${t} parameters, Actual: ${e.length}`,{parameters:e})}function d(e){if("color"===e.type)return"<color>";if(e.unit){if(e.unit in f)return"<length>";if(e.unit in y)return"<angle>";if("%"===e.unit)return"<percentage>"}return"<double>"}function m(e,t){if(e<0)throw new i.A("effect:type-error",`Negative values are not allowed, Actual: ${e}`,{term:t})}const y={deg:1,grad:.9,rad:180/Math.PI,turn:360},f={px:1,cm:96/2.54,mm:96/2.54/10,in:96,pc:16,pt:96/72};function h(e){!function(e){if("quantity"!==e.type||null!==e.unit&&"%"!==e.unit)throw new i.A("effect:type-error",`Expected <double> or <percentage>, Actual: ${d(e)}`,{term:e})}(e);const t=e.value;return m(t,e),"%"===e.unit?.01*t:t}function g(e){return function(e){if("quantity"!==e.type||!(0===e.value&&null===e.unit||e.unit&&null!=f[e.unit]))throw new i.A("effect:type-error",`Expected <length>, Actual: ${d(e)}`,{term:e})}(e),e.value*f[e.unit]||0}function v(e){switch(e.colorType){case"hex":return(0,n.j5)(e.value);case"named":return b(e.value);case"function":return function(e){if(c(e.parameters,4),w.test(e.name))return[h(e.parameters[0]),h(e.parameters[1]),h(e.parameters[2]),e.parameters[3]?h(e.parameters[3]):1];if(T.test(e.name))return(0,n.ay)(function(e){return function(e){if("quantity"!==e.type||null!==e.unit)throw new i.A("effect:type-error",`Expected <double>, Actual: ${d(e)}`,{term:e})}(e),m(e.value,e),e.value}(e.parameters[0]),h(e.parameters[1]),h(e.parameters[2]),e.parameters[3]?h(e.parameters[3]):1);throw new i.A("effect:syntax-error",`Invalid color function '${e.name}'`,{colorFunction:e})}(e.value)}}function b(e){if(!(0,n.V6)(e))throw new i.A("effect:unknown-color",`color '${e}' isn't valid`,{namedColor:e});return(0,n.c4)(e)}const w=/^rgba?/i,T=/^hsla?/i;function C(e,t,r){try{return function(e){if(!e||0===e.length)return null;if(function(e){const t=e[0];return!!t&&"scale"in t}(e)){const t=[];for(const r of e)t.push({scale:r.scale,value:M(r.value)});return t}return M(e)}(e)}catch(e){r?.messages?.push(e)}return null}function S(e,t,r,i){try{const i=function(e){const t=u(e);return t?(0,a.dw)(t)?t.map(e=>e.toJSON()):t.map(({scale:e,effects:t})=>({scale:e,value:t.map(e=>e.toJSON())})):null}(e);(0,o.sM)(r,i,t)}catch(e){i.messages&&i.messages.push(e)}}function M(e){if(!e?.length)return"";const t=[];for(const r of e){let e=[];switch(r.type){case"grayscale":case"sepia":case"saturate":case"invert":case"brightness":case"contrast":case"opacity":e=[A(r,"amount")];break;case"blur":e=[A(r,"radius","pt")];break;case"hue-rotate":e=[A(r,"angle","deg")];break;case"drop-shadow":e=[A(r,"xoffset","pt"),A(r,"yoffset","pt"),A(r,"blurRadius","pt"),I(r,"color")];break;case"bloom":e=[A(r,"strength"),A(r,"radius","pt"),A(r,"threshold")]}const i=`${r.type}(${e.filter(Boolean).join(" ")})`;u(i),t.push(i)}return t.join(" ")}function A(e,t,r){if(null==e[t])throw new i.A("effect:missing-parameter",`Missing parameter '${t}' in ${e.type} effect`,{effect:e});return r?e[t]+r:""+e[t]}function I(e,t){if(null==e[t])throw new i.A("effect:missing-parameter",`Missing parameter '${t}' in ${e.type} effect`,{effect:e});const r=e[t];return`rgba(${r[0]||0}, ${r[1]||0}, ${r[2]||0}, ${r[3]/255||0})`}},76553:(e,t,r)=>{function i(e){return e&&"getAtOrigin"in e&&"originOf"in e}r.d(t,{H:()=>i})},80754:(e,t,r)=>{r.d(t,{j7:()=>s,kS:()=>l,kd:()=>a,r8:()=>u});var i=r(82799),o=r(16930),n=r(60408);const s={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new i.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:o.A.WebMercator}),minus180Line:new i.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:o.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new i.A({paths:[[[180,-180],[180,180]]],spatialReference:o.A.WGS84}),minus180Line:new i.A({paths:[[[-180,-180],[-180,180]]],spatialReference:o.A.WGS84})}};function a(e,t){return Math.ceil((e-t)/(2*t))}function l(e,t){const r=u(e);for(const e of r)for(const r of e)r[0]+=t;return e}function u(e){return(0,n.Bi)(e)?e.rings:e.paths}},91218:(e,t,r)=>{r.r(t),r.d(t,{canProjectWithoutEngine:()=>$,initializeProjection:()=>V,isEqualBaseGCS:()=>W,isLoaded:()=>Z,isLoadedOrLoad:()=>j,isLoadedOrLoadFor:()=>D,load:()=>x,project:()=>B,projectAsync:()=>k,projectExtent:()=>te,projectMany:()=>R,projectMultipoint:()=>z,projectOrLoad:()=>P,projectOrLoadMany:()=>E,projectPoint:()=>G,projectPolygon:()=>Q,projectPolyline:()=>H,projectWithoutEngine:()=>q,requiresLoad:()=>F,test:()=>U,tryProject:()=>_,unload:()=>J});var i=r(49186),o=r(74887),n=r(62788),s=r(95488),a=r(51850),l=r(21276),u=r(73941),p=r(5443),c=r(91075),d=r(48526),m=r(86738),y=r(39829),f=r(82799),h=r(16930),g=r(159),v=r(9762),b=r(37539);function w(e,t,r,i,o,n){return T[0]=e,T[1]=t,T[2]=r,(0,v.projectBuffer)(T,i,0,o,n,0)}const T=(0,a.vt)();var C=r(21325);let S=null,M=null,A=null,I=null,O={};const N=new s.I;function Z(){return!!(M?.isLoaded()&&A?.isLoaded()&&I?.isLoaded())}function j(){return!!Z()||((0,n.gc)(N),x(),!1)}function D(e,t){return!e||!t||$(e,t)||j()}function F(e,t){return!$(e,t)&&!Z()}async function x(e){null==S&&(S=Promise.all([r.e(3276).then(r.bind(r,83276)).then(e=>(M=e,M.load())),r.e(8377).then(r.bind(r,8377)).then(e=>(A=e,A.load())),r.e(2158).then(r.bind(r,12158)).then(e=>(I=e,I.load()))])),await S,(0,o.Te)(e),N.notify()}function B(e,t,r){return Array.isArray(e)?0===e.length?[]:((0,l.H)(e),R(e,e[0].spatialReference,t,r)):((0,l.f)(e),R([e],e.spatialReference,t,r)[0])}function R(e,t,r,i){if(null==t||null==r)return e;if($(t,r,i))return e.map(e=>q(e,t,r));if(null==i?.geographicTransformation&&(0,u.jA)(t))return R(e.map(e=>q(e,t,h.A.WGS84)),h.A.WGS84,r,{zConversionDisabled:i?.zConversionDisabled});if(null==i?.geographicTransformation&&(0,u.jA)(r))return R(e,t,h.A.WGS84).map(e=>q(e,h.A.WGS84,r));if(!Z())throw new L;if(!i?.geographicTransformation)if(i?.extendedParams)i={...i,geographicTransformation:I.getTransformation(t,r,i.areaOfInterestExtent)||new g.A};else if(!i?.areaOfInterestExtent){const e=function(e,t){return[e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??"",t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??""].join()}(t,r);let o=O[e];o||(o=I.getTransformation(t,r)||new g.A,O[e]=o),i={geographicTransformation:o,zConversionDisabled:i?.zConversionDisabled}}return e[0].spatialReference||(e[0].spatialReference=t),e[0]instanceof c.A?M.executeMany(e,r,i):A.executeMany(e,r,i)}function _(e,t,r){try{return B(e,t,r)}catch(e){return null}}function P(e,t){const r=E([e],t);return null!=r.pending?{pending:r.pending,geometry:null}:null!=r.geometries?{pending:null,geometry:r.geometries[0]}:{pending:null,geometry:null}}function E(e,t,r){if(!Z())for(const r of e)if(null!=r&&!(0,C.aI)(r.spatialReference,t)&&(0,C.fn)(r.spatialReference)&&(0,C.fn)(t)&&!$(r.spatialReference,t))return(0,n.gc)(N),{pending:x(),geometries:null};return{pending:null,geometries:e.map(e=>null==e?null:(0,C.aI)(e.spatialReference,t)?e:(0,C.fn)(e.spatialReference)&&(0,C.fn)(t)?B(e,t,r):null)}}class L extends i.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function J(){S=null,M=null,A=null,I=null,O={}}const U={get loadPromise(){return S}};async function k(e,t,r){if((0,o.Te)(r),!e)return e;const i=E(Array.isArray(e)?e:[e],t,r);if(i.pending)return await i.pending,(0,o.Te)(r),k(e,t,r);const n=i.geometries??[];return Array.isArray(e)?n:n[0]}function $(e,t,r){return!(r?.areaOfInterestExtent||r?.extendedParams||r?.geographicTransformation)&&(!!(0,C.aI)(e,t)||(0,C.fn)(e)&&(0,C.fn)(t)&&!!(0,b.jd)(e,t))}function W(e,t){if((0,C.aI)(e,t))return!0;if(!(0,C.fn)(e)||!(0,C.fn)(t))return!1;const r=(0,C.oT)(e)||(0,C.K8)(e)||(0,C.x1)(e),i=(0,C.oT)(t)||(0,C.K8)(t)||(0,C.x1)(t);return r&&i}async function V(e,t,r,i){if(Z())return(0,o.NO)(i);if(Array.isArray(e)){for(const{source:t,dest:r,options:o}of e)if(t&&r&&!$(t,r,o))return x(i)}else if(e&&t&&!$(e,t,r))return x(i);return(0,o.NO)(i)}function q(e,t,r){return e?"x"in e?K(e,t,new m.A,r,0):"xmin"in e?re(e,t,new p.A,r,0):"rings"in e?ee(e,t,new y.A,r,0):"paths"in e?X(e,t,new f.A,r,0):"points"in e?Y(e,t,new d.A,r,0):null:null}function G(e,t,r=t.spatialReference,i=0){return null!=r&&null!=e.spatialReference&&null!=K(e,e.spatialReference,t,r,i)}function K(e,t,r,i,o){oe[0]=e.x,oe[1]=e.y;const n=e.z;return oe[2]=void 0!==n?n:o,(0,v.projectBuffer)(oe,t,0,oe,i,0)?(r.x=oe[0],r.y=oe[1],r.spatialReference=i,void 0!==n||(0,u.xP)(i)?(r.z=oe[2],r.hasZ=!0):(r.z=void 0,r.hasZ=!1),void 0===e.m?(r.m=void 0,r.hasM=!1):(r.m=e.m,r.hasM=!0),r):null}function z(e,t,r=t.spatialReference,i=0){return null!=e.spatialReference&&null!=r&&null!=Y(e,e.spatialReference,t,r,i)}function Y(e,t,r,i,o){const{points:n,hasZ:s,hasM:a}=e,l=[],p=n.length,c=[];for(const e of n)c.push(e[0],e[1],s?e[2]:o);if(!(0,v.projectBuffer)(c,t,0,c,i,0,p))return null;const d=s||(0,u.xP)(i);for(let e=0;e<p;++e){const t=3*e,r=c[t],i=c[t+1];d&&a?l.push([r,i,c[t+2],n[e][3]]):d?l.push([r,i,c[t+2]]):a?l.push([r,i,n[e][2]]):l.push([r,i])}return r.points=l,r.spatialReference=i,r.hasZ=s,r.hasM=a,r}function H(e,t,r=t.spatialReference,i=0){return null!=e.spatialReference&&null!=r&&null!=X(e,e.spatialReference,t,r,i)}function X(e,t,r,i,o){const{paths:n,hasZ:s,hasM:a}=e,l=[];if(!ie(n,s??!1,a??!1,t,l,i,o))return null;const p=s||(0,u.xP)(i);return r.paths=l,r.spatialReference=i,r.hasZ=p,r.hasM=a,r}function Q(e,t,r=t.spatialReference,i=0){return null!=e.spatialReference&&null!=r&&null!=ee(e,e.spatialReference,t,r,i)}function ee(e,t,r,i,o){const{rings:n,hasZ:s,hasM:a}=e,l=[];if(!ie(n,s??!1,a??!1,t,l,i,o))return null;const p=s||(0,u.xP)(i);return r.rings=l,r.spatialReference=i,r.hasZ=p,r.hasM=a,r}function te(e,t,r=t.spatialReference,i=0){return null!=e.spatialReference&&null!=r&&null!=re(e,e.spatialReference,t,r,i)}function re(e,t,r,i,o){const{xmin:n,ymin:s,xmax:a,ymax:l,hasZ:p,hasM:c}=e;if(!w(n,s,p?e.zmin:o,t,oe,i))return null;const d=p||(0,u.xP)(i);return r.xmin=oe[0],r.ymin=oe[1],d&&(r.zmin=oe[2]),w(a,l,p?e.zmax:o,t,oe,i)?(r.xmax=oe[0],r.ymax=oe[1],d&&(r.zmax=oe[2]),c&&(r.mmin=e.mmin,r.mmax=e.mmax),r.spatialReference=i,r):null}function ie(e,t,r,i,o,n,s=0){const a=new Array;for(const r of e)for(const e of r)a.push(e[0],e[1],t?e[2]:s);if(!(0,v.projectBuffer)(a,i,0,a,n,0))return!1;let l=0;o.length=0;const p=t||(0,u.xP)(n);for(const t of e){const e=new Array;for(const i of t)p&&r?e.push([a[l++],a[l++],a[l++],i[3]]):p?e.push([a[l++],a[l++],a[l++]]):r?(e.push([a[l++],a[l++],i[2]]),l++):(e.push([a[l++],a[l++]]),l++);o.push(e)}return!0}const oe=(0,a.vt)()},92300:(e,t,r)=>{r.d(t,{V:()=>s,X:()=>n});var i=r(60408),o=r(65864);function n(e){return{geometryType:(0,i.$B)(e[0]),geometries:e.map(e=>e.toJSON())}}function s(e,t,r){const i=(0,o.xD)(t);return e.map(e=>{const t=i.fromJSON(e);return t.spatialReference=r,t})}},95466:(e,t,r)=>{r.d(t,{A:()=>m});var i=r(49186),o=r(53966),n=r(91869),s=r(3330),a=r(12195),l=r(30524),u=r(98623),p=r(56400),c=r(28097);const d=new Map;class m{static fromJSON(e){return new m(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new m(e.fields??[],g(e))}static fromLayerJSON(e){return new m(e.fields??[],g(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const r=[];for(const e of this.fields){const t=e?.name,i=f(t);if(t&&i){const o=y(t);this._fieldsMap.set(t,e),this._fieldsMap.set(o,e),this._normalizedFieldsMap.set(i,e),r.push(`${o}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,l.vE)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,l.WA)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,l.te)(e)||(0,l.Xz)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}r.sort(),this.uid=r.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,l.te)(e)||(0,l.Xz)(e)||e.nullable||void 0!==(0,l.lD)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(y(e))??this._normalizedFieldsMap.get(f(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(o.A.getLogger("esri.layers.support.FieldsIndex").errorOnce(new i.A("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),u.n$):h.has(t.type)?u.L5:null:null}getLuxonTimeZone(e){const t=this.getTimeZone(e);return t?t===u.L5?s.GB.instance:t===u.n$?c.mQ.utcInstance:(0,n.tE)(d,t,()=>c.oh.create(t)):null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,l.OH)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map(e=>(0,a.W)(e)?e.toJSON():e),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function y(e){return e.trim().toLowerCase()}function f(e){return(0,l.rS)(e)?.toLowerCase()??""}const h=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function g(e){const t=new Map;if(!e.fields)return t;const r=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:o}=e,n=(i?"startField"in i?i.startField:i.startTimeField:"")??"",s=(i?"endField"in i?i.endField:i.endTimeField:"")??"",a=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,p.ZS)(e.dateFieldsTimeReference):null,l=o?function(e){return"timeZone"in e}(o)?o.timeZone??a:o.dateFieldsTimeReference?(0,p.ZS)(o.dateFieldsTimeReference):a??u.n$:null,c=i?function(e){return"timeZone"in e}(i)?i.timeZone??a:i.timeReference?(0,p.ZS)(i.timeReference):a:null,d=new Map([[y(o?.creationDateField??""),l],[y(o?.editDateField??""),l],[y(n),c],[y(s),c]]);for(const{name:i,type:o}of e.fields)if(h.has(o))t.set(i,u.L5);else if("date"!==o&&"esriFieldTypeDate"!==o)t.set(i,null);else if(r)t.set(i,u.L5);else{const e=d.get(y(i??""))??a;t.set(i,e)}return t}},96576:(e,t,r)=>{r.d(t,{A:()=>c});var i,o=r(31635),n=r(4718),s=r(91429),a=r(92438),l=r(63988),u=r(49849),p=r(93223);let c=i=class extends((0,l.h)(a.A)){constructor(e){super(e),this.description=null,this.label=null,this.symbol=null,this.type="simple"}async collectRequiredFields(e,t){await Promise.all([this.collectSymbolFields(e,t),this.collectVVRequiredFields(e,t)])}async collectSymbolFields(e,t){await Promise.all(this.symbols.map(r=>r.collectRequiredFields(e,t)))}getSymbol(e,t){return this.symbol}async getSymbolAsync(e,t){return this.symbol}get symbols(){return this.symbol?[this.symbol]:[]}getAttributeHash(){return this.visualVariables?.reduce((e,t)=>e+t.getAttributeHash(),"")??""}getMeshHash(){return this.symbols.reduce((e,t)=>e+JSON.stringify(t),"")}get arcadeRequired(){return this.arcadeRequiredForVisualVariables}clone(){return new i({description:this.description,label:this.label,symbol:(0,n.o8)(this.symbol),visualVariables:(0,n.o8)(this.visualVariables),authoringInfo:(0,n.o8)(this.authoringInfo)})}};(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],c.prototype,"description",void 0),(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],c.prototype,"label",void 0),(0,o.Cg)([(0,s.MZ)(u.Wp)],c.prototype,"symbol",void 0),(0,o.Cg)([(0,p.e)({simple:"simple"})],c.prototype,"type",void 0),c=i=(0,o.Cg)([(0,s.$K)("esri.renderers.SimpleRenderer")],c)},99157:(e,t,r)=>{r.d(t,{A:()=>a});var i,o=r(31635),n=r(69622),s=r(91429);let a=i=class extends n.A{constructor(e){super(e),this.isInverse=!1,this.wkt=null,this.wkid=null}getInverse(){return new i({isInverse:!this.isInverse,wkid:this.wkid,wkt:this.wkt})}};(0,o.Cg)([(0,s.MZ)()],a.prototype,"isInverse",void 0),(0,o.Cg)([(0,s.MZ)()],a.prototype,"wkt",void 0),(0,o.Cg)([(0,s.MZ)()],a.prototype,"wkid",void 0),a=i=(0,o.Cg)([(0,s.$K)("esri.geometry.operators.support.GeographicTransformationStep")],a)}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9466],{7142:(t,e,r)=>{function n(t,e){return s(t,"any",e?.origin)}function o(t,e){return s(t,"read",e?.origin)}function i(t,e){return s(t,"write",e?.origin)}function s(t,e,r){let n=t?.json;if(n?.origins&&r){let t;t="link-chart"===r?n.origins[r]&&("any"===e||e in n.origins[r])?n.origins[r]:n.origins["web-map"]:n.origins[r],t&&("any"===e||e in t)&&(n=t)}return n}r.d(e,{N5:()=>o,k4:()=>i,xF:()=>n})},10107:(t,e,r)=>{r.d(e,{MZ:()=>c,rM:()=>l});var n=r(53966),o=r(56507),i=r(16649),s=r(96156),a=r(47821);function c(t={}){return(e,r)=>{if(e===Function.prototype)throw new Error(`Inappropriate use of @property() on a static field: ${e.name}.${r}. Accessor does not support static properties.`);const c=Object.getOwnPropertyDescriptor(e,r),l=(0,s.z4)(e,r);c&&(c.get||c.set?(l.get=c.get||l.get,l.set=c.set||l.set):"value"in c&&("value"in t&&n.A.getLogger("esri.core.accessorSupport.decorators.property").warn(`@property() will redefine the value of "${r}" on "${e.constructor.name}" already defined in the metadata`,t),l.value=t.value=c.value)),null!=t.readOnly&&(l.readOnly=t.readOnly);const u=t.aliasOf;if(u){const t="string"==typeof u?u:u.source,e="string"==typeof u?null:!0===u.overridable;let n;l.dependsOn=[t],l.get=function(){let e=(0,i.Jt)(this,t);if("function"==typeof e){n||(n=t.split(".").slice(0,-1).join("."));const r=(0,i.Jt)(this,n);r&&(e=e.bind(r))}return e},l.readOnly||(l.set=e?function(t){this._override(r,t)}:function(e){(0,a.h)(this,t,e)})}const f=t.type,h=t.types;if(!l.cast){let e;f&&!1!==t.useTypeForAutocast?e=function(t){let e=0,r=t;if((0,o.Zu)(t))return(0,o.Nd)(t);for(;Array.isArray(r)&&1===r.length&&"string"!=typeof r[0]&&"number"!=typeof r[0];)r=r[0],e++;const n=r;if((0,o.EK)(n))return 0===e?(0,o.MB)(n):(0,o._e)((0,o.MB)(n),e);if(1===e)return(0,o.eC)(n);if(e>1)return(0,o.e6)(n,e);const i=t;return i.from?i.from:(0,o.dp)(i)}(f):h&&(e=Array.isArray(h)?(0,o.wB)((0,o.aq)(h[0])):(0,o.aq)(h)),t.cast=function(t,e){if(t||e)return t?e?(r,n)=>e(t(r,n),n):t:e}(t.cast,e)}(0,s.CX)(l,t),t.range&&(l.cast=(0,o.Qp)(l.cast,t.range))}}function l(t,e,r){const n=(0,s.z4)(t,r);n.json||(n.json={});let o=n.json;return void 0!==e&&(o.origins||(o.origins={}),o.origins[e]||(o.origins[e]={}),o=o.origins[e]),o}},15142:(t,e,r)=>{r.d(e,{A:()=>l});var n=r(4576),o=r(21818);const i=(t,e,r,n)=>{let o=e,i=e;const s=r>>>1,a=t[o-1];for(;i<=s;){i=o<<1,i<r&&n(t[i-1],t[i])<0&&++i;const e=t[i-1];if(n(e,a)<=0)break;t[o-1]=e,o=i}t[o-1]=a},s=(t,e)=>t<e?-1:t>e?1:0;function a(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n);const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n)}}function*c(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n),yield;const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n),yield}}class l{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new n.vW,t&&(t.initialSize&&(this.data=new Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>u(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){const e=new Array;for(let r=0;r<this._length;r++){const n=this.data[r];t(n)&&e.push(n)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){const r=this.data.indexOf(t,e);return-1!==r&&r<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let r=0;r<e;r++)this.data[this._length++]=t[r]}pushAll(t){for(const e of t)this.data[this._length++]=e}fill(t,e){for(let r=0;r<e;r++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));const t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,u(this)}pop(){if(0===this.length)return;const t=this.data[this.length-1];return this.length=this.length-1,this._shrink(),t}remove(t){const e=(0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),this.length=this.length-1,t}removeUnordered(t){return this.removeUnorderedIndex((0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,r){this.length=(0,n.mW)(this.data,t,this.length,e,this._hint,r),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;const r=this.data[t];this.data[t]=this.data[e],this.data[e]=r}sort(t){a(this.data,0,this.length,t)}iterableSort(t){return c(this.data,0,this.length,t)}some(t,e){for(let r=0;r<this.length;++r)if(t.call(e,this.data[r],r,this.data))return!0;return!1}find(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)if(t.call(e,r[o]))return r[o]}filterInPlace(t,e){let r=0;for(let n=0;n<this._length;++n){const o=this.data[n];t.call(e,o,n,this.data)&&(this.data[n]=this.data[r],this.data[r]=o,r++)}if(this._deallocator)for(let t=r;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=r,this._shrink(),this}forAll(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)t.call(e,r[o],o,r)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){const r=new Array(this.length);for(let n=0;n<this.length;++n)r[n]=t.call(e,this.data[n],n,this.data);return r}reduce(t,e){let r=e;for(let e=0;e<this.length;++e)r=t(r,this.data[e],e,this.data);return r}has(t){const e=this.length,r=this.data;for(let n=0;n<e;++n)if(r[n]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;t++)yield this.data[t]}}function u(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},15903:(t,e,r)=>{function n(t){return!!t&&t.prototype?.declaredClass&&0===t.prototype.declaredClass.indexOf("esri.core.Collection")}r.d(e,{P:()=>n})},16649:(t,e,r)=>{r.d(e,{Jt:()=>a,RP:()=>s,t2:()=>c});var n=r(88620);function o(t,e){const r=t.endsWith("?")?t.slice(0,-1):t;if(null!=e.getItemAt||Array.isArray(e)){const t=parseInt(r,10);if(!isNaN(t))return Array.isArray(e)?e[t]:e.at(t)}const o=(0,n.oY)(e);return(0,n.yh)(o,r)?o.get(r):e[r]}function i(t,e,r){if(null==t)return t;const n=o(e[r],t);return!n&&r<e.length-1?void 0:r===e.length-1?n:i(n,e,r+1)}function s(t,e,r=0){return"string"!=typeof e||e.includes(".")?i(t,(0,n.AH)(e),r):o(e,t)}function a(t,e){return s(t,e)}function c(t,e){return void 0!==s(e,t)}},24326:(t,e,r)=>{r.d(e,{c:()=>o});let n=0;function o(){return++n}},26390:(t,e,r)=>{r.d(e,{d:()=>o});const n=[];function o(t){n.push(t),1===n.length&&queueMicrotask(()=>{const t=n.slice();n.length=0;for(const e of t)e()})}},36005:(t,e,r)=>{r.d(e,{w:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e||Array.isArray(e)?(i=t,r=e,o=[void 0]):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;o.forEach(o=>{const a=(0,n.rM)(t,o,i);a.read&&"object"==typeof a.read||(a.read={}),a.read.reader=s[e],r&&(a.read.source=(a.read.source||[]).concat(r))})}}},43937:(t,e,r)=>{r.d(e,{K:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e?(i=t,o=[void 0]):"string"!=typeof e?(i=t,o=[void 0],r=e):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;for(const a of o){const o=(0,n.rM)(t,a,i);o.write&&"object"==typeof o.write||(o.write={}),r&&(o.write.target=r),o.write.writer=s[e]}}}},47328:(t,e,r)=>{r.d(e,{i:()=>n});const n={Dirty:1,Overridden:2,Computing:4,NonNullable:8,HasDefaultValue:16,DepTrackingInitialized:32,AutoTracked:64,ExplicitlyTracking:128}},47821:(t,e,r)=>{r.d(e,{h:()=>s});var n=r(49186),o=r(44208),i=(r(53966),r(16649));function s(t,e,r){if(t&&e)if("object"==typeof e)for(const r of Object.getOwnPropertyNames(e))s(t,r,e[r]);else{if(e.includes(".")){const n=e.split("."),o=n.splice(-1,1)[0];return void s((0,i.Jt)(t,n),o,r)}const a=t.__accessor__;null!=a&&function(t,e){if((0,o.A)("esri-unknown-property-errors")&&!function(t,e){return null!=e.metadata[t]}(t,e))throw new n.A("set:unknown-property",function(t,e){return"setting unknown property '"+t+"' on instance of "+e.host.declaredClass}(t,e))}(e,a),t[e]=r}}},56454:(t,e,r)=>{r.d(e,{G:()=>n});const n=Symbol("Accessor-beforeDestroy")},56507:(t,e,r)=>{r.d(e,{EK:()=>S,GB:()=>l,GX:()=>c,MB:()=>T,Nd:()=>z,PZ:()=>v,Qp:()=>h,Uv:()=>E,Vr:()=>u,Zu:()=>C,_e:()=>k,aq:()=>M,dp:()=>A,e6:()=>N,eC:()=>j,gK:()=>P,jz:()=>$,wB:()=>m}),r(44208);var n=r(53966),o=r(91869);const i=()=>n.A.getLogger("esri.core.accessorSupport.ensureTypes");function s(t){if(null==t)return t;const e=new Date(t);return isNaN(e.getTime())?(i().error("Accessor#set",`Invalid date value: '${t}', falling back to current date`),new Date):e}function a(t){return null==t?t:!!t}function c(t){return null==t?t:t.toString()}function l(t,e=0){return null==t?t:(t=parseFloat(t),isNaN(t)?e:t)}function u(t){return null==t?t:Math.round(parseFloat(t))}function f(t){return null}function h(t,e){return r=>{let n=t(r);return null!=e.step&&(n=Math.round(n/e.step)*e.step),null!=e.min&&(n=Math.max(e.min,n)),null!=e.max&&(n=Math.min(e.max,n)),n}}function p(t){return t?.constructor&&void 0!==t.constructor.__accessorMetadata__}function d(t,e){return null!=e&&t&&!(e instanceof t)}function y(t){return t&&"isCollection"in t}function g(t){return t?.Type?"function"==typeof t.Type?t.Type:t.Type.base:null}function _(t,e){return!!p(e)&&(i().error("Accessor#set","Assigning an instance of '"+(e.declaredClass||"unknown")+"' which is not a subclass of '"+w(t)+"'"),!0)}function v(t,e){return null==e?e:y(t)?function(t,e){if(!e?.constructor||!y(e.constructor))return _(t,e)?e:new t(e);const r=g(t.prototype.itemType),n=g(e.constructor.prototype.itemType);return r?n?r===n?e:r.prototype.isPrototypeOf(n.prototype)?new t(e):(_(t,e),e):new t(e):e}(t,e):d(t,e)?_(t,e)?e:new t(e):e}function w(t){return t?.prototype?.declaredClass||"unknown"}const b=new WeakMap;function A(t,e){const r=function(t){switch(t){case Number:return t=>l(t);case $:return u;case Boolean:return a;case String:return c;case Date:return s;case E:return f;default:return(0,o.tE)(b,t,()=>v.bind(null,t))}}(t);return 1===arguments.length?r:r(e)}function m(t,e,r){return 1===arguments.length?m.bind(null,t):e?Array.isArray(e)?e.map(e=>t(e,r)):[t(e,r)]:e}function j(t,e){return 1===arguments.length?m(e=>A(t,e)):m(e=>A(t,e),e)}function O(t,e,r){return 0!==e&&Array.isArray(r)?r.map(r=>O(t,e-1,r)):t(r)}function k(t,e,r){if(2===arguments.length)return r=>k(t,e,r);if(!r)return r;r=O(t,e,r);let n=e,o=r;for(;n>0&&Array.isArray(o);)n--,o=o[0];if(void 0!==o)for(let t=0;t<n;t++)r=[r];return r}function N(t,e,r){return 2===arguments.length?k(e=>A(t,e),e):k(e=>A(t,e),e,r)}function S(t){return!!Array.isArray(t)&&!t.some(e=>{const r=typeof e;return!("string"===r||"number"===r||"function"===r&&t.length>1)})}function T(t,e){if(2===arguments.length)return T(t).call(null,e);const r=new Set,n=t.filter(t=>"function"!=typeof t),o=t.filter(t=>"function"==typeof t);for(const e of t)"string"!=typeof e&&"number"!=typeof e||r.add(e);let s=null,a=null;return(t,e)=>{if(null==t)return t;const c=typeof t,l="string"===c||"number"===c;return l&&(r.has(t)||o.some(t=>"string"===c&&t===String||"number"===c&&t===Number))||"object"===c&&o.some(e=>!d(e,t))?t:(l&&n.length?(s||(s=n.map(t=>"string"==typeof t?`'${t}'`:`${t}`).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, only the following values are valid: ${s}`)):"object"==typeof t&&o.length?(a||(a=o.map(t=>w(t)).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, value must be one of ${a}`)):i().error("Accessor#set",`'${t}' is not a valid value for this property`),e&&(e.valid=!1),null)}}function M(t,e){if(2===arguments.length)return M(t).call(null,e);const r={},n=[],o=[];for(const e in t.typeMap){const i=t.typeMap[e];r[e]=A(i),n.push(w(i)),o.push(e)}const s=()=>`'${n.join("', '")}'`,a=()=>`'${o.join("', '")}'`,c="string"==typeof t.key?e=>e[t.key]:t.key;return e=>{if(t.base&&!d(t.base,e))return e;if(null==e)return e;const n=c(e)||t.defaultKeyValue,o=r[n];if(!o)return i().error("Accessor#set",`Invalid property value, value needs to be one of ${s()}, or a plain object that can autocast (having .type = ${a()})`),null;if(!d(t.typeMap[n],e))return e;if("string"==typeof t.key&&!p(e)){const r={};for(const n in e)n!==t.key&&(r[n]=e[n]);return o(r)}return o(e)}}class ${}class E{}const P={native:t=>({type:"native",value:t}),array:t=>({type:"array",value:t}),oneOf:t=>({type:"one-of",values:t})};function C(t){if(!t||"object"!=typeof t&&"function"!=typeof t||!("type"in t))return!1;switch(t.type){case"native":case"array":case"one-of":return!0}return!1}function z(t){switch(t.type){case"native":return A(t.value);case"array":return m(z(t.value));case"one-of":return function(t){let e=null;return(r,n)=>D(r,t)?r:(null==e&&(e=I(t)),i().error("Accessor#set",`Invalid property value, value needs to be of type ${e}`),n&&(n.valid=!1),null)}(t);default:return null}}function I(t){switch(t.type){case"native":switch(t.value){case Number:return"number";case String:return"string";case Boolean:return"boolean";case $:return"integer";case Date:return"date";case E:return"null";default:return w(t.value)}case"array":return`array of ${I(t.value)}`;case"one-of":{const e=t.values.map(t=>I(t));return`one of ${e.slice(0,-1)} or ${e[e.length-1]}`}}return"unknown"}function D(t,e){if(null==t)return!0;switch(e.type){case"native":switch(e.value){case Number:case $:return"number"==typeof t;case Boolean:return"boolean"==typeof t;case String:return"string"==typeof t;case E:return null===t}return t instanceof e.value;case"array":return!!Array.isArray(t)&&!t.some(t=>!D(t,e.value));case"one-of":return e.values.some(e=>D(t,e))}}},62788:(t,e,r)=>{r.d(e,{F_:()=>p,Xr:()=>v,a:()=>h,fE:()=>g,gc:()=>l}),r(44208);var n=r(53966),o=r(88620),i=r(47328);const s=new(r(67867).R),a=[];let c=s;function l(t){c.onAccessed(t)}let u=!1,f=!1;function h(t,e,r){if(u)return d(t,e,r);let o=null;if(f){c=t,a.push(t);try{o=e.call(r)}catch(t){throw n.A.getLogger("esri.core.accessorSupport.tracking").error(t),t}finally{y()}}else{c=t,a.push(t);try{o=e.call(r)}finally{y()}}return o}function p(t,e){return h(s,t,e)}function d(t,e,r){const o=u;u=!0,c=t,a.push(t);let i=null;try{i=e.call(r)}catch(t){f&&n.A.getLogger("esri.core.accessorSupport.tracking").error(t)}return y(),u=o,i}function y(){const t=a.length;if(t>1){const e=a.pop();c=a[t-2],e.onTrackingEnd()}else if(1===t){const t=a.pop();c=s,t.onTrackingEnd()}else c=s}function g(t,e){if(e.flags&i.i.DepTrackingInitialized)return;e.flags|=i.i.DepTrackingInitialized;const r=f;f=!1,e.flags&i.i.AutoTracked?d(e.trackingTarget,e.metadata.get,t):v(t,e),f=r}const _=[];function v(t,e){e.flags&i.i.ExplicitlyTracking||(e.flags|=i.i.ExplicitlyTracking,d(e.trackingTarget,()=>{const r=e.metadata.dependsOn||_;for(const e of r)if("string"!=typeof e||e.includes(".")){const r=(0,o.AH)(e);for(let e=0,n=t;e<r.length&&null!=n&&"object"==typeof n;++e)n=w(n,r[e],e!==r.length-1)}else w(t,e,!1)}),e.flags&=~i.i.ExplicitlyTracking)}function w(t,e,r){const n=e.endsWith("?")?e.slice(0,-1):e;if(null!=t.getItemAt||Array.isArray(t)){const e=parseInt(n,10);if(!isNaN(e))return Array.isArray(t)?t[e]:t.at(e)}const i=(0,o.oY)(t);if(i){const e=i.propertiesByName.get(n);e&&(l(e),g(t,e))}return r?t[n]:void 0}},64108:(t,e,r)=>{r.d(e,{$:()=>A}),r(44208);var n=r(53966),o=r(56454),i=r(85537),s=r(96156),a=r(62788),c=r(56507),l=r(90360);function u(t){if(t.json||(t.json={}),h(t.json),p(t.json),f(t.json),t.json.origins)for(const e in t.json.origins)h(t.json.origins[e]),p(t.json.origins[e]),f(t.json.origins[e]);return!0}function f(t){t.name&&(t.read&&"object"==typeof t.read?void 0===t.read.source&&(t.read.source=t.name):t.read={source:t.name},t.write&&"object"==typeof t.write?void 0===t.write.target&&(t.write.target=t.name):t.write={target:t.name})}function h(t){"boolean"==typeof t.read?t.read={enabled:t.read}:"function"==typeof t.read?t.read={enabled:!0,reader:t.read}:t.read&&"object"==typeof t.read&&void 0===t.read.enabled&&(t.read.enabled=!0)}function p(t){"boolean"==typeof t.write?t.write={enabled:t.write}:"function"==typeof t.write?t.write={enabled:!0,writer:t.write}:t.write&&"object"==typeof t.write&&void 0===t.write.enabled&&(t.write.enabled=!0)}var d=r(67124);function y(t){return t.type?g(t):_(t)}function g(t){if(!t.type)return;let e=0,r=t.type;for(;Array.isArray(r)&&!(0,c.EK)(r);)r=r[0],e++;return{type:r,ndimArray:e}}function _(t){if(!t.types)return;let e=0,r=t.types;for(;Array.isArray(r);)r=r[0],e++;return{types:r,ndimArray:e}}function v(t){u(t)&&(function(t){if(t.json&&t.json.origins){const e=t.json.origins,r={"web-document":["web-scene","web-map"]};for(const t in r)if(e[t]){const n=e[t];r[t].forEach(t=>{e[t]=n}),delete e[t]}}}(t),function(t){const e=function(t){return t.json.types?_(t.json):t.type?g(t):_(t)}(t);if(t.json.origins)for(const r in t.json.origins){const n=t.json.origins[r],o=n.types?y(n):e;(0,l.v)(o,n,!1),n.types&&!n.write&&t.json.write?.enabled&&(n.write={...t.json.write}),(0,d.v)(o,n)}(0,l.v)(e,t.json,!0),(0,d.v)(e,t.json)}(t))}const w=new Set,b=new Set;function A(t){return e=>{t??="esri.core.Accessor",e.prototype.declaredClass=t,k(e);const r=[],n=[];let a=e.prototype;for(;a;)a.hasOwnProperty("initialize")&&!w.has(a.initialize)&&(w.add(a.initialize),r.push(a.initialize)),a.hasOwnProperty("destroy")&&!b.has(a.destroy)&&(b.add(a.destroy),n.push(a.destroy)),a=Object.getPrototypeOf(a);w.clear(),b.clear();const c=class extends e{constructor(...t){if(super(...t),this.constructor===c&&"function"==typeof this.postscript){if(r.length&&Object.defineProperty(this,"initialize",{enumerable:!1,configurable:!0,value(){for(let t=r.length-1;t>=0;t--)r[t].call(this)}}),n.length){let t=!1;const e=this[o.G];Object.defineProperty(this,"destroy",{enumerable:!1,configurable:!0,value(){if(!t){this.__accessor__.lifecycle=i.v.DESTROYING,t=!0,e.call(this);for(let t=0;t<n.length;t++)n[t].call(this)}}})}Object.defineProperty(this,Symbol.dispose,{enumerable:!1,configurable:!0,value(){this.destroy()}}),this.postscript()}}};c.__accessorMetadata__=(0,s.tD)(e.prototype),c.prototype.declaredClass=t;const l=(t||"AccessorSubclass").split(".").slice(-1)[0];return Object.defineProperty(c,"name",{value:l,configurable:!0}),c}}function m(t,{get:e,value:r}){return null==e?function(){const e=this.__accessor__,n=e.propertiesByName.get(t);if(void 0===n)return;e.mutable&&(0,a.gc)(n);const o=e.store;return o.has(t)?o.get(t):r}:function(){const r=this.__accessor__;return r.propertiesByName.get(t)?.getComputed(r,e)}}function j(t,e,r){Object.defineProperty(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r})}function O(t,e){return e.readOnly&&e.constructOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.initialized&&e.readOnly?N("read-only",t):n.lifecycle===i.v.CONSTRUCTED&&e.constructOnly?N("construct-only",t):void n.set(t,r)}else j(this,t,r)}:e.readOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.initialized&&e.readOnly?N("read-only",t):void n.set(t,r)}else j(this,t,r)}:e.constructOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.lifecycle===i.v.CONSTRUCTED&&e.constructOnly?N("construct-only",t):void n.set(t,r)}else j(this,t,r)}:function(e){const r=this.__accessor__;r?r.mutable&&r.set(t,e):j(this,t,e)}}function k(t){const e=t.prototype,r=(0,s.tD)(e),n={};for(const t of Object.getOwnPropertyNames(r)){const e=r[t];v(e),n[t]={enumerable:!0,configurable:!0,get:m(t,e),set:O(t,e)}}Object.defineProperties(t.prototype,n)}const N=(t,e)=>{n.A.getLogger("esri.core.Accessor").error(`cannot assign to ${t} property '${e}'`)}},66552:(t,e,r)=>{r.d(e,{J:()=>o,O:()=>s});var n=r(93637);class o{constructor(t,e={ignoreUnknown:!1,useNumericKeys:!1}){this._jsonToAPI=t,this._options=e,this.apiValues=[],this.jsonValues=[],this._apiToJSON=function(t){const e={};for(const r in t)e[t[r]]=r;return e}(t),this.apiValues=i(this._apiToJSON),this.jsonValues=i(this._jsonToAPI),this.read=t=>this.fromJSON(t),this.write=(t,e,r)=>{const o=this.toJSON(t);void 0!==o&&(0,n.sM)(r,o,e)},this.write.isJSONMapWriter=!0}toJSON(t){if(null==t)return null;if(this._apiToJSON.hasOwnProperty(t)){const e=this._apiToJSON[t];return this._options.useNumericKeys?+e:e}return this._options.ignoreUnknown?null:t}fromJSON(t){return null!=t&&this._jsonToAPI.hasOwnProperty(t)?this._jsonToAPI[t]:this._options.ignoreUnknown?void 0:t}}function i(t){const e=[];for(const r in t)e.push(r);return e.sort(),e}function s(){return function(t,e){return new o(t,{ignoreUnknown:!0,...e})}}},67076:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(79907);class o extends n.A{constructor(t,e,r){super(t,e,r)}}o.prototype.type="warning"},67124:(t,e,r)=>{r.d(e,{B:()=>f,v:()=>a});var n=r(49186),o=r(53966),i=r(93637),s=r(15903);function a(t,e){if(!e.write||e.write.writer||!1===e.write.enabled&&!e.write.overridePolicy)return;const r=t?.ndimArray??0;t&&(1===r||"type"in t&&(0,s.P)(t.type))?e.write.writer=h:r>1?e.write.writer=function(t){return(e,r,n,o)=>{let s;if(null===e)s=null;else{s=p(e,o,t);let r=t,n=s;for(;r>0&&Array.isArray(n);)r--,n=n[0];if(void 0!==n)for(let t=0;t<r;t++)s=[s]}(0,i.sM)(n,s,r)}}(r):e.types?Array.isArray(e.types)?e.write.writer=function(t){return(e,r,n,o)=>e&&Array.isArray(e)?l(e.filter(e=>c(e,t,o)),r,n,o):l(e,r,n,o)}(e.types[0]):e.write.writer=function(t){return(e,r,n,o)=>e?c(e,t,o)?l(e,r,n,o):void 0:l(e,r,n,o)}(e.types):e.write.writer=l}function c(t,e,r){for(const r in e.typeMap)if(t instanceof e.typeMap[r])return!0;if(r?.messages){const i=e.errorContext??"type",s=`Values of type '${("function"!=typeof e.key?t[e.key]:t.declaredClass)??"Unknown"}' cannot be written`;r&&r.messages&&t&&r.messages.push(new n.A(`${i}:unsupported`,s,{definition:t,context:r})),o.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.writer").error(s)}return!1}function l(t,e,r,n){(0,i.sM)(r,u(t,n),e)}function u(t,e){return t&&"function"==typeof t.write?t.write({},e):t&&"function"==typeof t.toJSON?t.toJSON():"number"==typeof t?f(t):t}function f(t){return t===-1/0?-Number.MAX_VALUE:t===1/0?Number.MAX_VALUE:isNaN(t)?null:t}function h(t,e,r,n){let o;null===t?o=null:t&&"function"==typeof t.map?(o=t.map(t=>u(t,n)),"function"==typeof o.toArray&&(o=o.toArray())):o=[u(t,n)],(0,i.sM)(r,o,e)}function p(t,e,r){return 0!==r&&Array.isArray(t)?t.map(t=>p(t,e,r-1)):u(t,e)}},67867:(t,e,r)=>{r.d(e,{R:()=>n});class n{constructor(t){this.accessed=void 0,this._handles=void 0,this._observer=t}destroy(){this.clear(),this.accessed=void 0,this._observer=void 0}onAccessed(t){null!=this._observer&&t!==this._observer&&(null==this.accessed&&(this.accessed=new Set),this.accessed.add(t))}onTrackingEnd(){null!=this._observer&&(this.clear(),null!=this.accessed&&(null==this._handles&&(this._handles=[]),this.accessed.forEach(t=>{this._handles.push(t.observe(this._observer))}),this.accessed.clear()))}clear(){if(null!=this._handles)for(;this._handles.length;)this._handles.pop().remove()}}},79901:(t,e,r)=>{r.d(e,{w:()=>c});var n=r(56507),o=r(96156);const i=Object.prototype.toString;function s(t){const e="__accessorMetadata__"in t?(0,n.dp)(t):t;return function(...t){if(t.push(e),"number"==typeof t[2])throw new Error("Using @cast has parameter decorator is not supported since 4.16");return a.apply(this,t)}}function a(t,e,r,n){(0,o.z4)(t,e).cast=n}function c(...t){if(3!==t.length||"string"!=typeof t[1])return 1===t.length&&"[object Function]"===i.call(t[0])?s(t[0]):1===t.length&&"string"==typeof t[0]?function(t){return(e,r)=>{(0,o.z4)(e,t).cast=e[r]}}(t[0]):void 0}},85537:(t,e,r)=>{r.d(e,{v:()=>n});const n={INITIALIZING:0,CONSTRUCTING:1,CONSTRUCTED:2,DESTROYING:3,DESTROYED:4}},88620:(t,e,r)=>{r.d(e,{AH:()=>l,h1:()=>a,oY:()=>i,qg:()=>f,yh:()=>s});var n=r(36563),o=r(4718);function i(t){return t.__accessor__??null}function s(t,e){return null!=t?.metadata?.[e]}function a(t,e,r){return c(t,e,r?{policy:r,path:""}:null)}function c(t,e,r){return e?Object.keys(e).reduce((t,n)=>{const i=n;if("__proto__"===i)return t;let s=null,a="merge";if(r&&(s=r.path?`${r.path}.${n}`:n,a=r.policy(s)),"replace"===a)return t[i]=e[i],t;if("replace-arrays"===a&&Array.isArray(t[i]))return t[i]=e[i],t;if(void 0===t[i])return t[i]=(0,o.o8)(e[i]),t;let l=t[i],u=e[i];if(l===u)return t;if(Array.isArray(u)||Array.isArray(t))l=l?Array.isArray(l)?t[i]=l.slice():t[i]=[l]:t[i]=[],u&&(Array.isArray(u)||(u=[u]),u.forEach(t=>{l.includes(t)||l.push(t)}));else if(u&&"object"==typeof u)if(r){const e=r.path;r.path=s,t[i]=c(l,u,r),r.path=e}else t[i]=c(l,u,null);else t.hasOwnProperty(n)&&!e.hasOwnProperty(n)||(t[i]=u);return t},t||{}):t}function l(t){return Array.isArray(t)?t:t.split(".")}function u(t){return t.includes(",")?t.split(",").map(t=>t.trim()):[t.trim()]}function f(t,e,r,o){const i=function(t){if(Array.isArray(t)){const e=[];for(const r of t)e.push(...u(r));return e}return u(t)}(e);if(1!==i.length){const e=i.map(e=>o(t,e,r));return(0,n.vE)(e)}return o(t,i[0],r)}},90360:(t,e,r)=>{r.d(e,{C:()=>f,v:()=>u});var n=r(53966),o=r(93637),i=r(67076),s=r(96156),a=r(15903),c=r(7142);const l=()=>n.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.reader");function u(t,e,r){t&&(!r&&!e.read||e.read?.reader||!1===e.read?.enabled||function(t){return"types"in t?_(t.types):g(t.type)}(t)&&(0,o.sM)("read.reader",f(t),e))}function f(t){const e=t.ndimArray??0;if(e>1)return function(t){const e=h(t),r=p.bind(null,e),n=t.ndimArray??0;return(t,e,o)=>{if(null==t)return t;t=r(t,o,n);let i=n,s=t;for(;i>0&&Array.isArray(s);)i--,s=s[0];if(void 0!==s)for(let e=0;e<i;e++)t=[t];return t}}(t);if(1===e)return d(t);if("type"in t&&y(t.type)){const e=t.type.prototype?.itemType?.Type,r=d("function"==typeof e?{type:e}:{types:e});return(e,n,o)=>{const i=r(e,n,o);return i?new t.type(i):i}}return h(t)}function h(t){return"type"in t?function(t){return t.prototype.read?(e,r,n)=>{if(null==e)return e;const o=typeof e;if("object"!==o)return void l().error(`Expected JSON value of type 'object' to deserialize type '${t.prototype.declaredClass}', but got '${o}'`);const i=new t;return i.read(e,n),i}:t.fromJSON}(t.type):function(t){let e=null;const r=t.errorContext??"type",n=t.validate;return(o,a,u)=>{if(null==o)return o;const f=typeof o;if("object"!==f)return void l().error(`Expected JSON value of type 'object' to deserialize, but got '${f}'`);e||(e=function(t){const e={};for(const r in t.typeMap){const n=t.typeMap[r],o=(0,s.tD)(n.prototype);if("function"==typeof t.key)continue;const i=o[t.key];if(!i)continue;if(i.json?.type&&Array.isArray(i.json.type)&&1===i.json.type.length&&"string"==typeof i.json.type[0]){e[i.json.type[0]]=n;continue}const a=i.json?.write;if(!a?.writer){e[r]=n;continue}const c=a.target,l="string"==typeof c?c:t.key,u={};a.writer(r,u,l),u[l]&&(e[u[l]]=n)}return e}(t));const h=t.key;if("string"!=typeof h)return;const p=o[function(t,e,r){const n=Object.values(e)[0],o=(0,s.tD)(n.prototype)[t],i=(0,c.N5)(o,r),a=i?.read?.source;return a&&"string"==typeof a?a:t}(h,e,u)],d=p?e[p]:t.defaultKeyValue?t.typeMap[t.defaultKeyValue]:void 0;if(!d){const t=`Type '${p||"unknown"}' is not supported`;return u?.messages&&o&&u.messages.push(new i.A(`${r}:unsupported`,t,{definition:o,context:u})),void l().error(t)}const y=new d;return y.read(o,u),n?n(y):y}}(t.types)}function p(t,e,r,n){return 0!==n&&Array.isArray(e)?e.map(e=>p(t,e,r,n-1)):t(e,void 0,r)}function d(t){const e=h(t);return(t,r,n)=>{if(null==t)return t;if(Array.isArray(t)){const r=[];for(const o of t){const t=e(o,void 0,n);void 0!==t&&r.push(t)}return r}const o=e(t,void 0,n);return void 0!==o?[o]:void 0}}function y(t){if(!(0,a.P)(t))return!1;const e=t.prototype.itemType;return!(!e||!e.Type)&&("function"==typeof e.Type?g(e.Type):_(e.Type))}function g(t){return!Array.isArray(t)&&!!t&&("object"==typeof t||"function"==typeof t)&&t.prototype&&("read"in t.prototype||"fromJSON"in t||y(t))}function _(t){for(const e in t.typeMap)if(!g(t.typeMap[e]))return!1;return!0}},91429:(t,e,r)=>{r.d(e,{wg:()=>c,MZ:()=>s,$K:()=>a});var n=r(10107),o=r(79901),i=r(64108);r(93223),r(36005),r(43937);const s=n.MZ,a=i.$;function c(...t){return(0,o.w)(...t)}},93223:(t,e,r)=>{r.d(e,{e:()=>i});var n=r(66552),o=r(10107);function i(t,e={}){const r=t instanceof n.J?t:new n.J(t,e),{alwaysWriteDefaults:i,default:s,ignoreUnknown:a=!0,name:c,nonNullable:l,readOnly:u=!1}=e;return(0,o.MZ)({type:a?r.apiValues:String,json:{type:r.jsonValues,default:s,name:c,read:!u&&{reader:r.read},write:{writer:r.write,alwaysWriteDefaults:i}},nonNullable:l,readOnly:u})}},93687:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(44208);class o{constructor(t,e,r,n=1,o=0){this._creator=t,this._acquireFunction=e,this._releaseFunction=r,this.allocationSize=n,this._pool=new Array(o),this._initialSize=o;for(let t=0;t<o;t++)this._pool[t]=this._creator();this.allocationSize=Math.max(n,1)}destroy(){this.prune(0)}acquire(...t){let e;if(o.test.disabled)e=this._creator();else{if(0===this._pool.length){const t=this.allocationSize;for(let e=0;e<t;e++)this._pool[e]=this._creator()}e=this._pool.pop()}return this._acquireFunction?this._acquireFunction(e,...t):function(t){return t?.acquire&&"function"==typeof t.acquire}(e)&&e.acquire(...t),e}release(t){var e;t&&!o.test.disabled&&(this._releaseFunction?this._releaseFunction(t):(e=t,e?.release&&"function"==typeof e.release&&t.release()),this._pool.push(t))}prune(t=this._initialSize){if(!(t>=this._pool.length)){for(let e=t;e<this._pool.length;++e){const t=this._pool[e];this._dispose(t)}this._pool.length=t}}_dispose(t){t.dispose&&"function"==typeof t.dispose&&t.dispose()}static{this.test={disabled:!!(0,n.A)("esri-tests-disable-memory-pools")}}}},96156:(t,e,r)=>{r.d(e,{CX:()=>a,tD:()=>i,z4:()=>s});var n=r(4718),o=r(88620);function i(t){let e=t.constructor.__accessorMetadata__;const r=Object.prototype.hasOwnProperty.call(t.constructor,"__accessorMetadata__");if(e){if(!r){e=Object.create(e);for(const t in e)e[t]=(0,n.o8)(e[t]);Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0})}}else e={},Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0});return t.constructor.__accessorMetadata__}function s(t,e){const r=i(t);let n=r[e];return n||(n=r[e]={}),n}function a(t,e){return(0,o.h1)(t,e,l)}const c=/^(?:[^.]+\.)?(?:value|type|(?:json\.type|json\.origins\.[^.]\.type))$/;function l(t){return c.test(t)?"replace":"merge"}}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9466],{7142:(t,e,r)=>{function n(t,e){return s(t,"any",e?.origin)}function o(t,e){return s(t,"read",e?.origin)}function i(t,e){return s(t,"write",e?.origin)}function s(t,e,r){let n=t?.json;if(n?.origins&&r){let t;t="link-chart"===r?n.origins[r]&&("any"===e||e in n.origins[r])?n.origins[r]:n.origins["web-map"]:n.origins[r],t&&("any"===e||e in t)&&(n=t)}return n}r.d(e,{N5:()=>o,k4:()=>i,xF:()=>n})},10107:(t,e,r)=>{r.d(e,{MZ:()=>c,rM:()=>l});var n=r(53966),o=r(56507),i=r(16649),s=r(96156),a=r(47821);function c(t={}){return(e,r)=>{if(e===Function.prototype)throw new Error(`Inappropriate use of @property() on a static field: ${e.name}.${r}. Accessor does not support static properties.`);const c=Object.getOwnPropertyDescriptor(e,r),l=(0,s.z4)(e,r);c&&(c.get||c.set?(l.get=c.get||l.get,l.set=c.set||l.set):"value"in c&&("value"in t&&n.A.getLogger("esri.core.accessorSupport.decorators.property").warn(`@property() will redefine the value of "${r}" on "${e.constructor.name}" already defined in the metadata`,t),l.value=t.value=c.value)),null!=t.readOnly&&(l.readOnly=t.readOnly);const u=t.aliasOf;if(u){const t="string"==typeof u?u:u.source,e="string"==typeof u?null:!0===u.overridable;let n;l.dependsOn=[t],l.get=function(){let e=(0,i.Jt)(this,t);if("function"==typeof e){n||(n=t.split(".").slice(0,-1).join("."));const r=(0,i.Jt)(this,n);r&&(e=e.bind(r))}return e},l.readOnly||(l.set=e?function(t){this._override(r,t)}:function(e){(0,a.h)(this,t,e)})}const f=t.type,h=t.types;if(!l.cast){let e;f&&!1!==t.useTypeForAutocast?e=function(t){let e=0,r=t;if((0,o.Zu)(t))return(0,o.Nd)(t);for(;Array.isArray(r)&&1===r.length&&"string"!=typeof r[0]&&"number"!=typeof r[0];)r=r[0],e++;const n=r;if((0,o.EK)(n))return 0===e?(0,o.MB)(n):(0,o._e)((0,o.MB)(n),e);if(1===e)return(0,o.eC)(n);if(e>1)return(0,o.e6)(n,e);const i=t;return i.from?i.from:(0,o.dp)(i)}(f):h&&(e=Array.isArray(h)?(0,o.wB)((0,o.aq)(h[0])):(0,o.aq)(h)),t.cast=function(t,e){if(t||e)return t?e?(r,n)=>e(t(r,n),n):t:e}(t.cast,e)}(0,s.CX)(l,t),t.range&&(l.cast=(0,o.Qp)(l.cast,t.range))}}function l(t,e,r){const n=(0,s.z4)(t,r);n.json||(n.json={});let o=n.json;return void 0!==e&&(o.origins||(o.origins={}),o.origins[e]||(o.origins[e]={}),o=o.origins[e]),o}},15142:(t,e,r)=>{r.d(e,{A:()=>l});var n=r(4576),o=r(21818);const i=(t,e,r,n)=>{let o=e,i=e;const s=r>>>1,a=t[o-1];for(;i<=s;){i=o<<1,i<r&&n(t[i-1],t[i])<0&&++i;const e=t[i-1];if(n(e,a)<=0)break;t[o-1]=e,o=i}t[o-1]=a},s=(t,e)=>t<e?-1:t>e?1:0;function a(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n);const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n)}}function*c(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n),yield;const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n),yield}}class l{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new n.vW,t&&(t.initialSize&&(this.data=new Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>u(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){const e=new Array;for(let r=0;r<this._length;r++){const n=this.data[r];t(n)&&e.push(n)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){const r=this.data.indexOf(t,e);return-1!==r&&r<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let r=0;r<e;r++)this.data[this._length++]=t[r]}pushAll(t){for(const e of t)this.data[this._length++]=e}fill(t,e){for(let r=0;r<e;r++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));const t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,u(this)}pop(){if(0===this.length)return;const t=this.data[this.length-1];return this.length=this.length-1,this._shrink(),t}remove(t){const e=(0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),this.length=this.length-1,t}removeUnordered(t){return this.removeUnorderedIndex((0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,r){this.length=(0,n.mW)(this.data,t,this.length,e,this._hint,r),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;const r=this.data[t];this.data[t]=this.data[e],this.data[e]=r}sort(t){a(this.data,0,this.length,t)}iterableSort(t){return c(this.data,0,this.length,t)}some(t,e){for(let r=0;r<this.length;++r)if(t.call(e,this.data[r],r,this.data))return!0;return!1}find(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)if(t.call(e,r[o]))return r[o]}filterInPlace(t,e){let r=0;for(let n=0;n<this._length;++n){const o=this.data[n];t.call(e,o,n,this.data)&&(this.data[n]=this.data[r],this.data[r]=o,r++)}if(this._deallocator)for(let t=r;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=r,this._shrink(),this}forAll(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)t.call(e,r[o],o,r)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){const r=new Array(this.length);for(let n=0;n<this.length;++n)r[n]=t.call(e,this.data[n],n,this.data);return r}reduce(t,e){let r=e;for(let e=0;e<this.length;++e)r=t(r,this.data[e],e,this.data);return r}has(t){const e=this.length,r=this.data;for(let n=0;n<e;++n)if(r[n]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;t++)yield this.data[t]}}function u(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},15903:(t,e,r)=>{function n(t){return!!t&&t.prototype?.declaredClass&&0===t.prototype.declaredClass.indexOf("esri.core.Collection")}r.d(e,{P:()=>n})},16649:(t,e,r)=>{r.d(e,{Jt:()=>a,RP:()=>s,t2:()=>c});var n=r(88620);function o(t,e){const r=t.endsWith("?")?t.slice(0,-1):t;if(null!=e.getItemAt||Array.isArray(e)){const t=parseInt(r,10);if(!isNaN(t))return Array.isArray(e)?e[t]:e.at(t)}const o=(0,n.oY)(e);return(0,n.yh)(o,r)?o.get(r):e[r]}function i(t,e,r){if(null==t)return t;const n=o(e[r],t);return!n&&r<e.length-1?void 0:r===e.length-1?n:i(n,e,r+1)}function s(t,e,r=0){return"string"!=typeof e||e.includes(".")?i(t,(0,n.AH)(e),r):o(e,t)}function a(t,e){return s(t,e)}function c(t,e){return void 0!==s(e,t)}},24326:(t,e,r)=>{r.d(e,{c:()=>o});let n=0;function o(){return++n}},26390:(t,e,r)=>{r.d(e,{d:()=>o});const n=[];function o(t){n.push(t),1===n.length&&queueMicrotask(()=>{const t=n.slice();n.length=0;for(const e of t)e()})}},36005:(t,e,r)=>{r.d(e,{w:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e||Array.isArray(e)?(i=t,r=e,o=[void 0]):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;o.forEach(o=>{const a=(0,n.rM)(t,o,i);a.read&&"object"==typeof a.read||(a.read={}),a.read.reader=s[e],r&&(a.read.source=(a.read.source||[]).concat(r))})}}},43937:(t,e,r)=>{r.d(e,{K:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e?(i=t,o=[void 0]):"string"!=typeof e?(i=t,o=[void 0],r=e):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;for(const a of o){const o=(0,n.rM)(t,a,i);o.write&&"object"==typeof o.write||(o.write={}),r&&(o.write.target=r),o.write.writer=s[e]}}}},47328:(t,e,r)=>{r.d(e,{i:()=>n});const n={Dirty:1,Overridden:2,Computing:4,NonNullable:8,HasDefaultValue:16,DepTrackingInitialized:32,AutoTracked:64,ExplicitlyTracking:128}},47821:(t,e,r)=>{r.d(e,{h:()=>s});var n=r(49186),o=r(44208),i=(r(53966),r(16649));function s(t,e,r){if(t&&e)if("object"==typeof e)for(const r of Object.getOwnPropertyNames(e))s(t,r,e[r]);else{if(e.includes(".")){const n=e.split("."),o=n.splice(-1,1)[0];return void s((0,i.Jt)(t,n),o,r)}const a=t.__accessor__;null!=a&&function(t,e){if((0,o.A)("esri-unknown-property-errors")&&!function(t,e){return null!=e.metadata[t]}(t,e))throw new n.A("set:unknown-property",function(t,e){return"setting unknown property '"+t+"' on instance of "+e.host.declaredClass}(t,e))}(e,a),t[e]=r}}},56454:(t,e,r)=>{r.d(e,{G:()=>n});const n=Symbol("Accessor-beforeDestroy")},56507:(t,e,r)=>{r.d(e,{EK:()=>S,GB:()=>l,GX:()=>c,MB:()=>T,Nd:()=>z,PZ:()=>v,Qp:()=>h,Uv:()=>E,Vr:()=>u,Zu:()=>C,_e:()=>k,aq:()=>M,dp:()=>m,e6:()=>N,eC:()=>j,gK:()=>P,jz:()=>$,wB:()=>A}),r(44208);var n=r(53966),o=r(91869);const i=()=>n.A.getLogger("esri.core.accessorSupport.ensureTypes");function s(t){if(null==t)return t;const e=new Date(t);return isNaN(e.getTime())?(i().error("Accessor#set",`Invalid date value: '${t}', falling back to current date`),new Date):e}function a(t){return null==t?t:!!t}function c(t){return null==t?t:t.toString()}function l(t,e=0){return null==t?t:(t=parseFloat(t),isNaN(t)?e:t)}function u(t){return null==t?t:Math.round(parseFloat(t))}function f(t){return null}function h(t,e){return r=>{let n=t(r);return null!=e.step&&(n=Math.round(n/e.step)*e.step),null!=e.min&&(n=Math.max(e.min,n)),null!=e.max&&(n=Math.min(e.max,n)),n}}function p(t){return t?.constructor&&void 0!==t.constructor.__accessorMetadata__}function d(t,e){return null!=e&&t&&!(e instanceof t)}function y(t){return t&&"isCollection"in t}function g(t){return t?.Type?"function"==typeof t.Type?t.Type:t.Type.base:null}function _(t,e){return!!p(e)&&(i().error("Accessor#set","Assigning an instance of '"+(e.declaredClass||"unknown")+"' which is not a subclass of '"+w(t)+"'"),!0)}function v(t,e){return null==e?e:y(t)?function(t,e){if(!e?.constructor||!y(e.constructor))return _(t,e)?e:new t(e);const r=g(t.prototype.itemType),n=g(e.constructor.prototype.itemType);return r?n?r===n?e:r.prototype.isPrototypeOf(n.prototype)?new t(e):(_(t,e),e):new t(e):e}(t,e):d(t,e)?_(t,e)?e:new t(e):e}function w(t){return t?.prototype?.declaredClass||"unknown"}const b=new WeakMap;function m(t,e){const r=function(t){switch(t){case Number:return t=>l(t);case $:return u;case Boolean:return a;case String:return c;case Date:return s;case E:return f;default:return(0,o.tE)(b,t,()=>v.bind(null,t))}}(t);return 1===arguments.length?r:r(e)}function A(t,e,r){return 1===arguments.length?A.bind(null,t):e?Array.isArray(e)?e.map(e=>t(e,r)):[t(e,r)]:e}function j(t,e){return 1===arguments.length?A(e=>m(t,e)):A(e=>m(t,e),e)}function O(t,e,r){return 0!==e&&Array.isArray(r)?r.map(r=>O(t,e-1,r)):t(r)}function k(t,e,r){if(2===arguments.length)return r=>k(t,e,r);if(!r)return r;r=O(t,e,r);let n=e,o=r;for(;n>0&&Array.isArray(o);)n--,o=o[0];if(void 0!==o)for(let t=0;t<n;t++)r=[r];return r}function N(t,e,r){return 2===arguments.length?k(e=>m(t,e),e):k(e=>m(t,e),e,r)}function S(t){return!!Array.isArray(t)&&!t.some(e=>{const r=typeof e;return!("string"===r||"number"===r||"function"===r&&t.length>1)})}function T(t,e){if(2===arguments.length)return T(t).call(null,e);const r=new Set,n=t.filter(t=>"function"!=typeof t),o=t.filter(t=>"function"==typeof t);for(const e of t)"string"!=typeof e&&"number"!=typeof e||r.add(e);let s=null,a=null;return(t,e)=>{if(null==t)return t;const c=typeof t,l="string"===c||"number"===c;return l&&(r.has(t)||o.some(t=>"string"===c&&t===String||"number"===c&&t===Number))||"object"===c&&o.some(e=>!d(e,t))?t:(l&&n.length?(s||(s=n.map(t=>"string"==typeof t?`'${t}'`:`${t}`).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, only the following values are valid: ${s}`)):"object"==typeof t&&o.length?(a||(a=o.map(t=>w(t)).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, value must be one of ${a}`)):i().error("Accessor#set",`'${t}' is not a valid value for this property`),e&&(e.valid=!1),null)}}function M(t,e){if(2===arguments.length)return M(t).call(null,e);const r={},n=[],o=[];for(const e in t.typeMap){const i=t.typeMap[e];r[e]=m(i),n.push(w(i)),o.push(e)}const s=()=>`'${n.join("', '")}'`,a=()=>`'${o.join("', '")}'`,c="string"==typeof t.key?e=>e[t.key]:t.key;return e=>{if(t.base&&!d(t.base,e))return e;if(null==e)return e;const n=c(e)||t.defaultKeyValue,o=r[n];if(!o)return i().error("Accessor#set",`Invalid property value, value needs to be one of ${s()}, or a plain object that can autocast (having .type = ${a()})`),null;if(!d(t.typeMap[n],e))return e;if("string"==typeof t.key&&!p(e)){const r={};for(const n in e)n!==t.key&&(r[n]=e[n]);return o(r)}return o(e)}}class ${}class E{}const P={native:t=>({type:"native",value:t}),array:t=>({type:"array",value:t}),oneOf:t=>({type:"one-of",values:t})};function C(t){if(!t||"object"!=typeof t&&"function"!=typeof t||!("type"in t))return!1;switch(t.type){case"native":case"array":case"one-of":return!0}return!1}function z(t){switch(t.type){case"native":return m(t.value);case"array":return A(z(t.value));case"one-of":return function(t){let e=null;return(r,n)=>D(r,t)?r:(null==e&&(e=I(t)),i().error("Accessor#set",`Invalid property value, value needs to be of type ${e}`),n&&(n.valid=!1),null)}(t);default:return null}}function I(t){switch(t.type){case"native":switch(t.value){case Number:return"number";case String:return"string";case Boolean:return"boolean";case $:return"integer";case Date:return"date";case E:return"null";default:return w(t.value)}case"array":return`array of ${I(t.value)}`;case"one-of":{const e=t.values.map(t=>I(t));return`one of ${e.slice(0,-1)} or ${e[e.length-1]}`}}return"unknown"}function D(t,e){if(null==t)return!0;switch(e.type){case"native":switch(e.value){case Number:case $:return"number"==typeof t;case Boolean:return"boolean"==typeof t;case String:return"string"==typeof t;case E:return null===t}return t instanceof e.value;case"array":return!!Array.isArray(t)&&!t.some(t=>!D(t,e.value));case"one-of":return e.values.some(e=>D(t,e))}}},62788:(t,e,r)=>{r.d(e,{F_:()=>p,Xr:()=>v,a:()=>h,fE:()=>g,gc:()=>l}),r(44208);var n=r(53966),o=r(88620),i=r(47328);const s=new(r(67867).R),a=[];let c=s;function l(t){c.onAccessed(t)}let u=!1,f=!1;function h(t,e,r){if(u)return d(t,e,r);let o=null;if(f){c=t,a.push(t);try{o=e.call(r)}catch(t){throw n.A.getLogger("esri.core.accessorSupport.tracking").error(t),t}finally{y()}}else{c=t,a.push(t);try{o=e.call(r)}finally{y()}}return o}function p(t,e){return h(s,t,e)}function d(t,e,r){const o=u;u=!0,c=t,a.push(t);let i=null;try{i=e.call(r)}catch(t){f&&n.A.getLogger("esri.core.accessorSupport.tracking").error(t)}return y(),u=o,i}function y(){const t=a.length;if(t>1){const e=a.pop();c=a[t-2],e.onTrackingEnd()}else if(1===t){const t=a.pop();c=s,t.onTrackingEnd()}else c=s}function g(t,e){if(e.flags&i.i.DepTrackingInitialized)return;e.flags|=i.i.DepTrackingInitialized;const r=f;f=!1,e.flags&i.i.AutoTracked?d(e.trackingTarget,e.metadata.get,t):v(t,e),f=r}const _=[];function v(t,e){e.flags&i.i.ExplicitlyTracking||(e.flags|=i.i.ExplicitlyTracking,d(e.trackingTarget,()=>{const r=e.metadata.dependsOn||_;for(const e of r)if("string"!=typeof e||e.includes(".")){const r=(0,o.AH)(e);for(let e=0,n=t;e<r.length&&null!=n&&"object"==typeof n;++e)n=w(n,r[e],e!==r.length-1)}else w(t,e,!1)}),e.flags&=~i.i.ExplicitlyTracking)}function w(t,e,r){const n=e.endsWith("?")?e.slice(0,-1):e;if(null!=t.getItemAt||Array.isArray(t)){const e=parseInt(n,10);if(!isNaN(e))return Array.isArray(t)?t[e]:t.at(e)}const i=(0,o.oY)(t);if(i){const e=i.propertiesByName.get(n);e&&(l(e),g(t,e))}return r?t[n]:void 0}},64108:(t,e,r)=>{r.d(e,{$:()=>m}),r(44208);var n=r(53966),o=r(56454),i=r(85537),s=r(96156),a=r(62788),c=r(56507),l=r(90360);function u(t){if(t.json||(t.json={}),h(t.json),p(t.json),f(t.json),t.json.origins)for(const e in t.json.origins)h(t.json.origins[e]),p(t.json.origins[e]),f(t.json.origins[e]);return!0}function f(t){t.name&&(t.read&&"object"==typeof t.read?void 0===t.read.source&&(t.read.source=t.name):t.read={source:t.name},t.write&&"object"==typeof t.write?void 0===t.write.target&&(t.write.target=t.name):t.write={target:t.name})}function h(t){"boolean"==typeof t.read?t.read={enabled:t.read}:"function"==typeof t.read?t.read={enabled:!0,reader:t.read}:t.read&&"object"==typeof t.read&&void 0===t.read.enabled&&(t.read.enabled=!0)}function p(t){"boolean"==typeof t.write?t.write={enabled:t.write}:"function"==typeof t.write?t.write={enabled:!0,writer:t.write}:t.write&&"object"==typeof t.write&&void 0===t.write.enabled&&(t.write.enabled=!0)}var d=r(67124);function y(t){return t.type?g(t):_(t)}function g(t){if(!t.type)return;let e=0,r=t.type;for(;Array.isArray(r)&&!(0,c.EK)(r);)r=r[0],e++;return{type:r,ndimArray:e}}function _(t){if(!t.types)return;let e=0,r=t.types;for(;Array.isArray(r);)r=r[0],e++;return{types:r,ndimArray:e}}function v(t){u(t)&&(function(t){if(t.json&&t.json.origins){const e=t.json.origins,r={"web-document":["web-scene","web-map"]};for(const t in r)if(e[t]){const n=e[t];r[t].forEach(t=>{e[t]=n}),delete e[t]}}}(t),function(t){const e=function(t){return t.json.types?_(t.json):t.type?g(t):_(t)}(t);if(t.json.origins)for(const r in t.json.origins){const n=t.json.origins[r],o=n.types?y(n):e;(0,l.v)(o,n,!1),n.types&&!n.write&&t.json.write?.enabled&&(n.write={...t.json.write}),(0,d.v)(o,n)}(0,l.v)(e,t.json,!0),(0,d.v)(e,t.json)}(t))}const w=new Set,b=new Set;function m(t){return e=>{t??="esri.core.Accessor",e.prototype.declaredClass=t,k(e);const r=[],n=[];let a=e.prototype;for(;a;)a.hasOwnProperty("initialize")&&!w.has(a.initialize)&&(w.add(a.initialize),r.push(a.initialize)),a.hasOwnProperty("destroy")&&!b.has(a.destroy)&&(b.add(a.destroy),n.push(a.destroy)),a=Object.getPrototypeOf(a);w.clear(),b.clear();const c=class extends e{constructor(...t){if(super(...t),this.constructor===c&&"function"==typeof this.postscript){if(r.length&&Object.defineProperty(this,"initialize",{enumerable:!1,configurable:!0,value(){for(let t=r.length-1;t>=0;t--)r[t].call(this)}}),n.length){let t=!1;const e=this[o.G];Object.defineProperty(this,"destroy",{enumerable:!1,configurable:!0,value(){if(!t){this.__accessor__.lifecycle=i.v.DESTROYING,t=!0,e.call(this);for(let t=0;t<n.length;t++)n[t].call(this)}}})}Object.defineProperty(this,Symbol.dispose,{enumerable:!1,configurable:!0,value(){this.destroy()}}),this.postscript()}}};c.__accessorMetadata__=(0,s.tD)(e.prototype),c.prototype.declaredClass=t;const l=(t||"AccessorSubclass").split(".").slice(-1)[0];return Object.defineProperty(c,"name",{value:l,configurable:!0}),c}}function A(t,{get:e,value:r}){return null==e?function(){const e=this.__accessor__,n=e.propertiesByName.get(t);if(void 0===n)return;e.mutable&&(0,a.gc)(n);const o=e.store;return o.has(t)?o.get(t):r}:function(){const r=this.__accessor__;return r.propertiesByName.get(t)?.getComputed(r,e)}}function j(t,e,r){Object.defineProperty(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r})}function O(t,e){return e.readOnly&&e.constructOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.initialized&&e.readOnly?N("read-only",t):n.lifecycle===i.v.CONSTRUCTED&&e.constructOnly?N("construct-only",t):void n.set(t,r)}else j(this,t,r)}:e.readOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.initialized&&e.readOnly?N("read-only",t):void n.set(t,r)}else j(this,t,r)}:e.constructOnly?function(r){const n=this.__accessor__;if(n){if(n.mutable)return n.lifecycle===i.v.CONSTRUCTED&&e.constructOnly?N("construct-only",t):void n.set(t,r)}else j(this,t,r)}:function(e){const r=this.__accessor__;r?r.mutable&&r.set(t,e):j(this,t,e)}}function k(t){const e=t.prototype,r=(0,s.tD)(e),n={};for(const t of Object.getOwnPropertyNames(r)){const e=r[t];v(e),n[t]={enumerable:!0,configurable:!0,get:A(t,e),set:O(t,e)}}Object.defineProperties(t.prototype,n)}const N=(t,e)=>{n.A.getLogger("esri.core.Accessor").error(`cannot assign to ${t} property '${e}'`)}},66552:(t,e,r)=>{r.d(e,{J:()=>o,O:()=>s});var n=r(93637);class o{constructor(t,e={ignoreUnknown:!1,useNumericKeys:!1}){this._jsonToAPI=t,this._options=e,this.apiValues=[],this.jsonValues=[],this._apiToJSON=function(t){const e={};for(const r in t)e[t[r]]=r;return e}(t),this.apiValues=i(this._apiToJSON),this.jsonValues=i(this._jsonToAPI),this.read=t=>this.fromJSON(t),this.write=(t,e,r)=>{const o=this.toJSON(t);void 0!==o&&(0,n.sM)(r,o,e)},this.write.isJSONMapWriter=!0}toJSON(t){if(null==t)return null;if(this._apiToJSON.hasOwnProperty(t)){const e=this._apiToJSON[t];return this._options.useNumericKeys?+e:e}return this._options.ignoreUnknown?null:t}fromJSON(t){return null!=t&&this._jsonToAPI.hasOwnProperty(t)?this._jsonToAPI[t]:this._options.ignoreUnknown?void 0:t}}function i(t){const e=[];for(const r in t)e.push(r);return e.sort(),e}function s(){return function(t,e){return new o(t,{ignoreUnknown:!0,...e})}}},67076:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(799);class o{constructor(t,e,r){this.name=t,this.details=r,this.type="warning",this.message=e?(0,n.V2)(e,r):""}toString(){const{name:t,message:e}=this;return`[${t}]: ${e}`}}},67124:(t,e,r)=>{r.d(e,{B:()=>f,v:()=>a});var n=r(49186),o=r(53966),i=r(93637),s=r(15903);function a(t,e){if(!e.write||e.write.writer||!1===e.write.enabled&&!e.write.overridePolicy)return;const r=t?.ndimArray??0;t&&(1===r||"type"in t&&(0,s.P)(t.type))?e.write.writer=h:r>1?e.write.writer=function(t){return(e,r,n,o)=>{let s;if(null===e)s=null;else{s=p(e,o,t);let r=t,n=s;for(;r>0&&Array.isArray(n);)r--,n=n[0];if(void 0!==n)for(let t=0;t<r;t++)s=[s]}(0,i.sM)(n,s,r)}}(r):e.types?Array.isArray(e.types)?e.write.writer=function(t){return(e,r,n,o)=>e&&Array.isArray(e)?l(e.filter(e=>c(e,t,o)),r,n,o):l(e,r,n,o)}(e.types[0]):e.write.writer=function(t){return(e,r,n,o)=>e?c(e,t,o)?l(e,r,n,o):void 0:l(e,r,n,o)}(e.types):e.write.writer=l}function c(t,e,r){for(const r in e.typeMap)if(t instanceof e.typeMap[r])return!0;if(r?.messages){const i=e.errorContext??"type",s=`Values of type '${("function"!=typeof e.key?t[e.key]:t.declaredClass)??"Unknown"}' cannot be written`;r&&r.messages&&t&&r.messages.push(new n.A(`${i}:unsupported`,s,{definition:t,context:r})),o.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.writer").error(s)}return!1}function l(t,e,r,n){(0,i.sM)(r,u(t,n),e)}function u(t,e){return t&&"function"==typeof t.write?t.write({},e):t&&"function"==typeof t.toJSON?t.toJSON():"number"==typeof t?f(t):t}function f(t){return t===-1/0?-Number.MAX_VALUE:t===1/0?Number.MAX_VALUE:isNaN(t)?null:t}function h(t,e,r,n){let o;null===t?o=null:t&&"function"==typeof t.map?(o=t.map(t=>u(t,n)),"function"==typeof o.toArray&&(o=o.toArray())):o=[u(t,n)],(0,i.sM)(r,o,e)}function p(t,e,r){return 0!==r&&Array.isArray(t)?t.map(t=>p(t,e,r-1)):u(t,e)}},67867:(t,e,r)=>{r.d(e,{R:()=>n});class n{constructor(t){this.accessed=void 0,this._handles=void 0,this._observer=t}destroy(){this.clear(),this.accessed=void 0,this._observer=void 0}onAccessed(t){null!=this._observer&&t!==this._observer&&(null==this.accessed&&(this.accessed=new Set),this.accessed.add(t))}onTrackingEnd(){null!=this._observer&&(this.clear(),null!=this.accessed&&(null==this._handles&&(this._handles=[]),this.accessed.forEach(t=>{this._handles.push(t.observe(this._observer))}),this.accessed.clear()))}clear(){if(null!=this._handles)for(;this._handles.length;)this._handles.pop().remove()}}},79901:(t,e,r)=>{r.d(e,{w:()=>c});var n=r(56507),o=r(96156);const i=Object.prototype.toString;function s(t){const e="__accessorMetadata__"in t?(0,n.dp)(t):t;return function(...t){if(t.push(e),"number"==typeof t[2])throw new Error("Using @cast has parameter decorator is not supported since 4.16");return a.apply(this,t)}}function a(t,e,r,n){(0,o.z4)(t,e).cast=n}function c(...t){if(3!==t.length||"string"!=typeof t[1])return 1===t.length&&"[object Function]"===i.call(t[0])?s(t[0]):1===t.length&&"string"==typeof t[0]?function(t){return(e,r)=>{(0,o.z4)(e,t).cast=e[r]}}(t[0]):void 0}},85537:(t,e,r)=>{r.d(e,{v:()=>n});const n={INITIALIZING:0,CONSTRUCTING:1,CONSTRUCTED:2,DESTROYING:3,DESTROYED:4}},88620:(t,e,r)=>{r.d(e,{AH:()=>l,h1:()=>a,oY:()=>i,qg:()=>f,yh:()=>s});var n=r(36563),o=r(4718);function i(t){return t.__accessor__??null}function s(t,e){return null!=t?.metadata?.[e]}function a(t,e,r){return c(t,e,r?{policy:r,path:""}:null)}function c(t,e,r){return e?Object.keys(e).reduce((t,n)=>{const i=n;if("__proto__"===i)return t;let s=null,a="merge";if(r&&(s=r.path?`${r.path}.${n}`:n,a=r.policy(s)),"replace"===a)return t[i]=e[i],t;if("replace-arrays"===a&&Array.isArray(t[i]))return t[i]=e[i],t;if(void 0===t[i])return t[i]=(0,o.o8)(e[i]),t;let l=t[i],u=e[i];if(l===u)return t;if(Array.isArray(u)||Array.isArray(t))l=l?Array.isArray(l)?t[i]=l.slice():t[i]=[l]:t[i]=[],u&&(Array.isArray(u)||(u=[u]),u.forEach(t=>{l.includes(t)||l.push(t)}));else if(u&&"object"==typeof u)if(r){const e=r.path;r.path=s,t[i]=c(l,u,r),r.path=e}else t[i]=c(l,u,null);else t.hasOwnProperty(n)&&!e.hasOwnProperty(n)||(t[i]=u);return t},t||{}):t}function l(t){return Array.isArray(t)?t:t.split(".")}function u(t){return t.includes(",")?t.split(",").map(t=>t.trim()):[t.trim()]}function f(t,e,r,o){const i=function(t){if(Array.isArray(t)){const e=[];for(const r of t)e.push(...u(r));return e}return u(t)}(e);if(1!==i.length){const e=i.map(e=>o(t,e,r));return(0,n.vE)(e)}return o(t,i[0],r)}},90360:(t,e,r)=>{r.d(e,{C:()=>f,v:()=>u});var n=r(53966),o=r(93637),i=r(67076),s=r(96156),a=r(15903),c=r(7142);const l=()=>n.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.reader");function u(t,e,r){t&&(!r&&!e.read||e.read?.reader||!1===e.read?.enabled||function(t){return"types"in t?_(t.types):g(t.type)}(t)&&(0,o.sM)("read.reader",f(t),e))}function f(t){const e=t.ndimArray??0;if(e>1)return function(t){const e=h(t),r=p.bind(null,e),n=t.ndimArray??0;return(t,e,o)=>{if(null==t)return t;t=r(t,o,n);let i=n,s=t;for(;i>0&&Array.isArray(s);)i--,s=s[0];if(void 0!==s)for(let e=0;e<i;e++)t=[t];return t}}(t);if(1===e)return d(t);if("type"in t&&y(t.type)){const e=t.type.prototype?.itemType?.Type,r=d("function"==typeof e?{type:e}:{types:e});return(e,n,o)=>{const i=r(e,n,o);return i?new t.type(i):i}}return h(t)}function h(t){return"type"in t?function(t){return t.prototype.read?(e,r,n)=>{if(null==e)return e;const o=typeof e;if("object"!==o)return void l().error(`Expected JSON value of type 'object' to deserialize type '${t.prototype.declaredClass}', but got '${o}'`);const i=new t;return i.read(e,n),i}:t.fromJSON}(t.type):function(t){let e=null;const r=t.errorContext??"type",n=t.validate;return(o,a,u)=>{if(null==o)return o;const f=typeof o;if("object"!==f)return void l().error(`Expected JSON value of type 'object' to deserialize, but got '${f}'`);e||(e=function(t){const e={};for(const r in t.typeMap){const n=t.typeMap[r],o=(0,s.tD)(n.prototype);if("function"==typeof t.key)continue;const i=o[t.key];if(!i)continue;if(i.json?.type&&Array.isArray(i.json.type)&&1===i.json.type.length&&"string"==typeof i.json.type[0]){e[i.json.type[0]]=n;continue}const a=i.json?.write;if(!a?.writer){e[r]=n;continue}const c=a.target,l="string"==typeof c?c:t.key,u={};a.writer(r,u,l),u[l]&&(e[u[l]]=n)}return e}(t));const h=t.key;if("string"!=typeof h)return;const p=o[function(t,e,r){const n=Object.values(e)[0],o=(0,s.tD)(n.prototype)[t],i=(0,c.N5)(o,r),a=i?.read?.source;return a&&"string"==typeof a?a:t}(h,e,u)],d=p?e[p]:t.defaultKeyValue?t.typeMap[t.defaultKeyValue]:void 0;if(!d){const t=`Type '${p||"unknown"}' is not supported`;return u?.messages&&o&&u.messages.push(new i.A(`${r}:unsupported`,t,{definition:o,context:u})),void l().error(t)}const y=new d;return y.read(o,u),n?n(y):y}}(t.types)}function p(t,e,r,n){return 0!==n&&Array.isArray(e)?e.map(e=>p(t,e,r,n-1)):t(e,void 0,r)}function d(t){const e=h(t);return(t,r,n)=>{if(null==t)return t;if(Array.isArray(t)){const r=[];for(const o of t){const t=e(o,void 0,n);void 0!==t&&r.push(t)}return r}const o=e(t,void 0,n);return void 0!==o?[o]:void 0}}function y(t){if(!(0,a.P)(t))return!1;const e=t.prototype.itemType;return!(!e||!e.Type)&&("function"==typeof e.Type?g(e.Type):_(e.Type))}function g(t){return!Array.isArray(t)&&!!t&&("object"==typeof t||"function"==typeof t)&&t.prototype&&("read"in t.prototype||"fromJSON"in t||y(t))}function _(t){for(const e in t.typeMap)if(!g(t.typeMap[e]))return!1;return!0}},91429:(t,e,r)=>{r.d(e,{wg:()=>c,MZ:()=>s,$K:()=>a});var n=r(10107),o=r(79901),i=r(64108);r(93223),r(36005),r(43937);const s=n.MZ,a=i.$;function c(...t){return(0,o.w)(...t)}},93223:(t,e,r)=>{r.d(e,{e:()=>i});var n=r(66552),o=r(10107);function i(t,e={}){const r=t instanceof n.J?t:new n.J(t,e),{alwaysWriteDefaults:i,default:s,ignoreUnknown:a=!0,name:c,nonNullable:l,readOnly:u=!1}=e;return(0,o.MZ)({type:a?r.apiValues:String,json:{type:r.jsonValues,default:s,name:c,read:!u&&{reader:r.read},write:{writer:r.write,alwaysWriteDefaults:i}},nonNullable:l,readOnly:u})}},93687:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(44208);class o{constructor(t,e,r,n=1,o=0){this._creator=t,this._acquireFunction=e,this._releaseFunction=r,this.allocationSize=n,this._pool=new Array(o),this._initialSize=o;for(let t=0;t<o;t++)this._pool[t]=this._creator();this.allocationSize=Math.max(n,1)}destroy(){this.prune(0)}acquire(...t){let e;if(o.test.disabled)e=this._creator();else{if(0===this._pool.length){const t=this.allocationSize;for(let e=0;e<t;e++)this._pool[e]=this._creator()}e=this._pool.pop()}return this._acquireFunction?this._acquireFunction(e,...t):function(t){return t?.acquire&&"function"==typeof t.acquire}(e)&&e.acquire(...t),e}release(t){var e;t&&!o.test.disabled&&(this._releaseFunction?this._releaseFunction(t):(e=t,e?.release&&"function"==typeof e.release&&t.release()),this._pool.push(t))}prune(t=this._initialSize){if(!(t>=this._pool.length)){for(let e=t;e<this._pool.length;++e){const t=this._pool[e];this._dispose(t)}this._pool.length=t}}_dispose(t){t.dispose&&"function"==typeof t.dispose&&t.dispose()}static{this.test={disabled:!!(0,n.A)("esri-tests-disable-memory-pools")}}}},96156:(t,e,r)=>{r.d(e,{CX:()=>a,tD:()=>i,z4:()=>s});var n=r(4718),o=r(88620);function i(t){let e=t.constructor.__accessorMetadata__;const r=Object.prototype.hasOwnProperty.call(t.constructor,"__accessorMetadata__");if(e){if(!r){e=Object.create(e);for(const t in e)e[t]=(0,n.o8)(e[t]);Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0})}}else e={},Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0});return t.constructor.__accessorMetadata__}function s(t,e){const r=i(t);let n=r[e];return n||(n=r[e]={}),n}function a(t,e){return(0,o.h1)(t,e,l)}const c=/^(?:[^.]+\.)?(?:value|type|(?:json\.type|json\.origins\.[^.]\.type))$/;function l(t){return c.test(t)?"replace":"merge"}}}]);
|