@arcgis/core 4.28.0-next.20230921 → 4.28.0-next.20230923
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Graphic.js +1 -1
- package/PopupTemplate.js +1 -1
- package/TimeExtent.js +1 -1
- package/arcade/ArcadeDate.js +1 -1
- package/arcade/Feature.js +1 -1
- package/arcade/featureSetUtils.js +1 -1
- package/arcade/featureset/actions/Adapted.js +1 -1
- package/arcade/featureset/actions/GroupBy.js +1 -1
- package/arcade/featureset/support/FeatureSet.js +1 -1
- package/arcade/featureset/support/FeatureSetIterator.js +1 -1
- package/arcade/featureset/support/StatsField.js +1 -1
- package/arcade/featureset/support/sqlUtils.js +1 -1
- package/arcade/functions/convertdirection.js +1 -1
- package/arcade/functions/date.js +1 -1
- package/arcade/functions/featuresetbase.js +1 -1
- package/arcade/functions/featuresetstats.js +1 -1
- package/arcade/treeAnalysis.js +1 -1
- package/arcade.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/02156fd04279f4d0fd3f.js +1 -0
- package/assets/esri/core/workers/chunks/07f6175b52366b2c28bd.js +1 -0
- package/assets/esri/core/workers/chunks/098073c3b2849f56dad8.js +1 -0
- package/assets/esri/core/workers/chunks/1186ba1947bd0c32f148.js +1 -0
- package/assets/esri/core/workers/chunks/186445b9fbedd261f684.js +1 -0
- package/assets/esri/core/workers/chunks/{580039dd491854ca325c.js → 21fc02f0d5716c4a7acd.js} +1 -1
- package/assets/esri/core/workers/chunks/{dff1c3c38dda2bd1a9d6.js → 246a954347fe9318190e.js} +1 -1
- package/assets/esri/core/workers/chunks/{c9dfb145f0c1d93e0fbd.js → 250bb6ae6f1992b5b4f9.js} +1 -1
- package/assets/esri/core/workers/chunks/{314c307e30f308a40a28.js → 25b09e9c0511c8e1cf8a.js} +1 -1
- package/assets/esri/core/workers/chunks/2a0b3b52ecd787a613bc.js +1 -0
- package/assets/esri/core/workers/chunks/2bc9b55e655968229ef4.js +1 -0
- package/assets/esri/core/workers/chunks/2f0924e7aa89e689da4a.js +1 -0
- package/assets/esri/core/workers/chunks/3f218d65ec451b2a1027.js +1 -0
- package/assets/esri/core/workers/chunks/425b5733bb88e6efe242.js +1 -0
- package/assets/esri/core/workers/chunks/45d6b942cdccca2ce44a.js +1 -0
- package/assets/esri/core/workers/chunks/4bf1a7e82a68ccee0ee1.js +1 -0
- package/assets/esri/core/workers/chunks/4c110c7f4f940ec58010.js +1 -0
- package/assets/esri/core/workers/chunks/{bde89b2684b6185992ef.js → 4ed77097e69fa3096ce4.js} +1 -1
- package/assets/esri/core/workers/chunks/4fe5bac782a742d5b1c0.js +1 -0
- package/assets/esri/core/workers/chunks/{1cbaba30f55f00f7498b.js → 51324d042f469f3b8914.js} +1 -1
- package/assets/esri/core/workers/chunks/{3f4e9b1663ec521bfe00.js → 542ce10e1872399790b4.js} +1 -1
- package/assets/esri/core/workers/chunks/54d2b7e2ac4ba883bee8.js +1 -0
- package/assets/esri/core/workers/chunks/54ecb6cae310818d1aa2.js +1 -0
- package/assets/esri/core/workers/chunks/57c932e289d89d97da4b.js +1 -0
- package/assets/esri/core/workers/chunks/{6403de6fc067cf8f7436.js → 592c1fb531f2be928e8a.js} +1 -1
- package/assets/esri/core/workers/chunks/59a807220d6f0dd18776.js +1 -0
- package/assets/esri/core/workers/chunks/59dff10d7ad2b1bf469e.js +1 -0
- package/assets/esri/core/workers/chunks/609a475ab395f2ce63e2.js +1 -0
- package/assets/esri/core/workers/chunks/612c485c5aad1548d708.js +1 -0
- package/assets/esri/core/workers/chunks/{2bb69d76a13564e8e455.js → 645ba2d5c10184632d23.js} +1 -1
- package/assets/esri/core/workers/chunks/{332689bf60d246485993.js → 65186e168dd112ac6221.js} +1 -1
- package/assets/esri/core/workers/chunks/6b9248fb2d6aadbce7bb.js +1 -0
- package/assets/esri/core/workers/chunks/709465832d306e02df52.js +1 -0
- package/assets/esri/core/workers/chunks/72c5bd6f7b8541b8d69e.js +1 -0
- package/assets/esri/core/workers/chunks/{bbc0dcd316c5598bc9ad.js → 74368a5213def6c200a2.js} +1 -1
- package/assets/esri/core/workers/chunks/{94188fe381239d48a975.js → 76483c9a8848f3106126.js} +1 -1
- package/assets/esri/core/workers/chunks/7aa58c96798447ce5907.js +1 -0
- package/assets/esri/core/workers/chunks/7d078b8b9997b5300c0a.js +1 -0
- package/assets/esri/core/workers/chunks/7fe641cf1467496e670a.js +1 -0
- package/assets/esri/core/workers/chunks/{df8f62beb36fb9d2ac81.js → 810c8d6ff19976fd1366.js} +1 -1
- package/assets/esri/core/workers/chunks/8458ed96f3e72814cef2.js +1 -0
- package/assets/esri/core/workers/chunks/{243a4eed107d363dfad8.js → 887652bbdb3b71d0a089.js} +1 -1
- package/assets/esri/core/workers/chunks/896bfda379cf620b63ec.js +1 -0
- package/assets/esri/core/workers/chunks/91c9f0d59eaed7a735ce.js +1 -0
- package/assets/esri/core/workers/chunks/{1f7e041140088f8ac489.js → 97073a60f0ea2a397165.js} +1 -1
- package/assets/esri/core/workers/chunks/97658ac749664a07c92d.js +1 -0
- package/assets/esri/core/workers/chunks/{1da74a306aa5b4eacaae.js → 9866bbaeaf885c2dcca9.js} +1 -1
- package/assets/esri/core/workers/chunks/a39ae87298ac674f129d.js +1 -0
- package/assets/esri/core/workers/chunks/a7b3048c19348540e004.js +1 -0
- package/assets/esri/core/workers/chunks/a8ca4b116909e47722f9.js +1 -0
- package/assets/esri/core/workers/chunks/{101f776316a85b708927.js → a99070ec4c06c435b744.js} +1 -1
- package/assets/esri/core/workers/chunks/ab145d13932d87dd7bf9.js +1 -0
- package/assets/esri/core/workers/chunks/{77c15b1c2729c780f75a.js → aeeeb386134b341d7ad2.js} +1 -1
- package/assets/esri/core/workers/chunks/{3ca759f72d3bb29e9ea9.js → af54b233f6d6ad70b4a3.js} +2 -2
- package/assets/esri/core/workers/chunks/b9146daae8457224fd08.js +1 -0
- package/assets/esri/core/workers/chunks/bcdd2e8841abcb4df6da.js +1 -0
- package/assets/esri/core/workers/chunks/be05cc0cdabd5e051045.js +1 -0
- package/assets/esri/core/workers/chunks/c5f5f37bef11c6fbdc40.js +1 -0
- package/assets/esri/core/workers/chunks/d414dba3179bcf75bc6b.js +1 -0
- package/assets/esri/core/workers/chunks/{b449d6bd5851187d419f.js → d6e5408f9fa6b4bcd118.js} +1 -1
- package/assets/esri/core/workers/chunks/d9fb500cbd0f04d219a3.js +1 -0
- package/assets/esri/core/workers/chunks/e0dd6789fb797e9b7206.js +1 -0
- package/assets/esri/core/workers/chunks/{6f271249e042086d5a16.js → e4e49deae8da74f629db.js} +1 -1
- package/assets/esri/core/workers/chunks/e5dcff7a4fa84ba09670.js +1 -0
- package/assets/esri/core/workers/chunks/{f508ccfde6425dabe9ac.js → ee0bf611d191103a7046.js} +1 -1
- package/assets/esri/core/workers/chunks/{ed1fbc1bc8d50453e2f5.js → f793cd41fcd022baeea2.js} +1 -1
- package/assets/esri/core/workers/chunks/fad6a7bb82a0a2df726f.js +1 -0
- package/assets/esri/themes/base/widgets/_FeatureForm.scss +2 -84
- package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +2 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/chunks/arcade.js +1 -1
- package/config.js +1 -1
- package/core/Accessor.js +1 -1
- package/core/accessorSupport/diffUtils.js +1 -1
- package/core/has.js +1 -1
- package/core/number.js +1 -1
- package/core/reactiveUtils.js +1 -1
- package/core/sql/DateOnly.js +1 -1
- package/core/sql/WhereClause.js +1 -1
- package/core/sql.js +1 -1
- package/core/timeUtils.js +1 -1
- package/identity/IdentityForm.js +1 -1
- package/identity/IdentityModal.js +1 -1
- package/interfaces.d.ts +48 -203
- package/layers/LinkChartLayer.js +1 -1
- package/layers/OrientedImageryLayer.js +1 -1
- package/layers/SceneLayer.js +1 -1
- package/layers/graphics/applyEditsUtils.js +5 -0
- package/layers/graphics/editingSupport.js +1 -1
- package/layers/graphics/sources/FeatureLayerSource.js +1 -1
- package/layers/knowledgeGraph/KnowledgeGraphLayerDataManager.js +1 -1
- package/layers/mixins/ArcGISImageService.js +1 -1
- package/layers/mixins/EditBusLayer.js +1 -1
- package/layers/orientedImagery/core/CameraOrientationLTP.js +1 -1
- package/layers/orientedImagery/core/ElevationSourceDefinitions.js +5 -0
- package/layers/orientedImagery/core/ExposurePoint.js +1 -1
- package/layers/orientedImagery/core/cameraOrientationFactory.js +1 -1
- package/layers/orientedImagery/core/utils.js +5 -0
- package/layers/orientedImagery/transformations/groundToImageUtils.js +1 -1
- package/layers/support/fieldProperties.js +1 -1
- package/layers/support/fieldUtils.js +1 -1
- package/layers/support/imageryRendererUtils.js +1 -1
- package/layers/support/kmlUtils.js +1 -1
- package/layers/support/rasterFunctions/BaseRasterFunction.js +1 -1
- package/layers/support/rasterFunctions/creators/createDataManagementFunctions.js +1 -1
- package/networks/Network.js +1 -1
- package/package.json +1 -1
- package/request.js +1 -1
- package/rest/featureService/FeatureService.js +1 -1
- package/rest/support/DirectionsFeatureSet.js +1 -1
- package/smartMapping/renderers/pieChart.js +1 -1
- package/smartMapping/renderers/relationship.js +1 -1
- package/smartMapping/renderers/support/utils.js +1 -1
- package/smartMapping/statistics/support/ageUtils.js +1 -1
- package/smartMapping/support/adapters/support/utils.js +1 -1
- package/smartMapping/support/utils.js +1 -1
- package/support/apiKeyUtils.js +1 -1
- package/support/arcadeUtils.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/cim/cimAnalyzer.js +1 -1
- package/symbols/support/svgUtils.js +1 -1
- package/time/TimeReference.js +1 -1
- package/time/timeReferenceUtils.js +1 -1
- package/versionManagement/VersionManagementService.js +1 -1
- package/versionManagement/support/EditMomentStack.js +5 -0
- package/versionManagement/support/versionManagementUtils.js +1 -1
- package/views/2d/engine/Container.js +1 -1
- package/views/2d/engine/DisplayObject.js +1 -1
- package/views/2d/engine/ManagedCanvas.js +5 -0
- package/views/2d/engine/Stage.js +1 -1
- package/views/2d/engine/webgl/GroupContainer.js +1 -1
- package/views/2d/engine/webgl/Painter.js +1 -1
- package/views/2d/engine/webgl/WGLContainer.js +1 -1
- package/views/2d/engine/webgl/WorldExtentClipRenderer.js +1 -1
- package/views/2d/engine/webgl/effects/FeatureEffect.js +1 -1
- package/views/2d/engine/webgl/effects/HighlightEffect.js +1 -1
- package/views/2d/engine/webgl/effects/HittestEffectVTL.js +1 -1
- package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
- package/views/2d/interactive/editingTools/TransformTool.js +1 -1
- package/views/2d/layers/GeoRSSLayerView2D.js +1 -1
- package/views/2d/layers/MediaLayerView2D.js +1 -1
- package/views/2d/layers/TileLayerView2D.js +1 -1
- package/views/2d/layers/WMTSLayerView2D.js +1 -1
- package/views/2d/layers/features/support/FeatureSetReader.js +1 -1
- package/views/2d/layers/features/tileRenderers/support/WGLFeatureView.js +1 -1
- package/views/2d/layers/graphics/BaseGraphicContainer.js +1 -1
- package/views/2d/layers/graphics/GraphicContainer.js +1 -1
- package/views/2d/layers/graphics/GraphicsView2D.js +1 -1
- package/views/2d/layers/graphics/HighlightGraphicContainer.js +1 -1
- package/views/2d/layers/imagery/VectorFieldView2D.js +1 -1
- package/views/2d/layers/support/DisplayGL.js +1 -1
- package/views/2d/webglDeps.js +1 -1
- package/views/3d/glTF/loader.js +1 -1
- package/views/3d/interactive/editingTools/manipulations/MoveManipulation.js +1 -1
- package/views/3d/interactive/editingTools/transformGraphic/isSupportedGraphic.js +1 -1
- package/views/3d/interactive/visualElements/ExtendedLineVisualElement.js +1 -1
- package/views/3d/interactive/visualElements/ParallelLineVisualElement.js +1 -1
- package/views/3d/interactive/visualElements/PointVisualElement.js +1 -1
- package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
- package/views/3d/layers/SceneLayerView3D.js +1 -1
- package/views/3d/layers/graphics/ElevationAligners.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DPathSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Labeler.js +1 -1
- package/views/3d/layers/graphics/graphicUtils.js +1 -1
- package/views/3d/layers/i3s/featureEditing.js +1 -1
- package/views/3d/layers/support/StageLayerElevationProvider.js +1 -1
- package/views/3d/state/ViewStateManager.js +1 -1
- package/views/3d/support/buffer/glUtil.js +1 -1
- package/views/3d/support/engineContent/line.js +1 -1
- package/views/3d/support/viewpointUtils.js +1 -1
- package/views/3d/webgl-engine/Stage.js +1 -1
- package/views/3d/webgl-engine/effects/RenderPluginInput.js +1 -1
- package/views/3d/webgl-engine/effects/blit/Blit.js +5 -0
- package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
- package/views/3d/webgl-engine/effects/highlight/ShadowHighlight.js +1 -1
- package/views/3d/webgl-engine/effects/smaa/SMAA.js +1 -1
- package/views/3d/webgl-engine/effects/ssao/SSAO.js +1 -1
- package/views/3d/webgl-engine/lib/Geometry.js +1 -1
- package/views/3d/webgl-engine/lib/ModelDirtySet.js +1 -1
- package/views/3d/webgl-engine/lib/Object3D.js +1 -1
- package/views/3d/webgl-engine/lib/RenderSlot.js +1 -1
- package/views/3d/webgl-engine/lib/Renderer.js +1 -1
- package/views/3d/webgl-engine/lib/TextRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/TextTextureAtlas.js +1 -1
- package/views/3d/webgl-engine/lib/TextTextureFactory.js +1 -1
- package/views/3d/webgl-engine/lib/VertexAttribute.js +1 -1
- package/views/3d/webgl-engine/lib/edgeRendering/EdgeView.js +1 -1
- package/views/3d/webgl-engine/lib/edgeRendering/bufferLayouts.js +1 -1
- package/views/3d/webgl-engine/lib/edgeRendering/edgeProcessing.js +1 -1
- package/views/View.js +1 -1
- package/views/interactive/tooltip/TooltipContentWithHelpMessage.js +1 -1
- package/views/interactive/tooltip/TooltipEditableField.js +1 -1
- package/views/interactive/tooltip/constraintUtils.js +1 -1
- package/views/interactive/tooltip/content/Fields.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawCircle.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawMesh.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawPoint.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawPolygon.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawPolyline.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentDrawRectangle.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentExtentRotate.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentExtentScale.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentReshapeEdgeOffset.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTransformAbsolute.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTransformRotate.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTransformScale.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateGraphic.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateGraphicXY.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateGraphicZ.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateVertex.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateVertexXY.js +1 -1
- package/views/interactive/tooltip/content/TooltipContentTranslateVertexZ.js +1 -1
- package/views/support/angularMeasurementUtils.js +1 -1
- package/views/ui/UI.js +1 -1
- package/views/webgl/ShaderTranspiler.js +1 -1
- package/views/webgl/Texture.js +1 -1
- package/views/webgl/contextUtils.js +1 -1
- package/webmap/InitialViewProperties.js +1 -1
- package/widgets/AreaMeasurement2D.js +1 -1
- package/widgets/AreaMeasurement3D.js +1 -1
- package/widgets/Attachments/AttachmentsViewModel.js +1 -1
- package/widgets/Attachments.js +1 -1
- package/widgets/Attribution.js +1 -1
- package/widgets/BasemapGallery.js +1 -1
- package/widgets/BasemapLayerList.js +1 -1
- package/widgets/BasemapToggle.js +1 -1
- package/widgets/Bookmarks.js +1 -1
- package/widgets/BuildingExplorer/BuildingDisciplinesTree/BuildingDisciplinesNode.js +1 -1
- package/widgets/BuildingExplorer/BuildingDisciplinesTree/BuildingDisciplinesTree.js +1 -1
- package/widgets/BuildingExplorer/BuildingLevelPicker/BuildingLevelPicker.js +1 -1
- package/widgets/BuildingExplorer/BuildingLevelPicker/Label.js +1 -1
- package/widgets/BuildingExplorer/BuildingLevelPicker/LevelItem.js +1 -1
- package/widgets/BuildingExplorer/BuildingPhasePicker/BuildingPhasePicker.js +1 -1
- package/widgets/BuildingExplorer.js +1 -1
- package/widgets/Compass.js +1 -1
- package/widgets/CoordinateConversion.js +1 -1
- package/widgets/Daylight/support/SliderWithDropdown.js +1 -1
- package/widgets/Daylight.js +1 -1
- package/widgets/DirectLineMeasurement3D.js +1 -1
- package/widgets/DirectionalPad.js +1 -1
- package/widgets/Directions/components/SaveLayer.js +1 -1
- package/widgets/Directions.js +1 -1
- package/widgets/DistanceMeasurement2D.js +1 -1
- package/widgets/Editor/components/FooterActions.js +1 -1
- package/widgets/Editor/components/Notices.js +1 -1
- package/widgets/Editor/components/PanelContent.js +1 -1
- package/widgets/Editor/components/PanelToolbar.js +1 -1
- package/widgets/Editor/components/Prompt.js +1 -1
- package/widgets/Editor/components/Settings.js +1 -1
- package/widgets/Editor/components/UpdateFeaturePanelContent.js +1 -1
- package/widgets/Editor/components/UploadDetails.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/ElevationProfile/components/LegendItem.js +1 -1
- package/widgets/ElevationProfile/components/SettingsButton.js +1 -1
- package/widgets/ElevationProfile/components/Statistics.js +1 -1
- package/widgets/ElevationProfile.js +1 -1
- package/widgets/Expand.js +1 -1
- package/widgets/Feature/FeatureContent.js +1 -1
- package/widgets/Feature/FeatureExpression.js +1 -1
- package/widgets/Feature/FeatureFields.js +1 -1
- package/widgets/Feature/FeatureMedia.js +1 -1
- package/widgets/Feature/FeatureRelationship.js +1 -1
- package/widgets/Feature/FeatureViewModel.js +1 -1
- package/widgets/Feature/support/FeatureContentMixin.js +1 -1
- package/widgets/Feature/support/FeatureElementInfo.js +1 -1
- package/widgets/Feature.js +1 -1
- package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
- package/widgets/FeatureForm/GroupInput.js +1 -1
- package/widgets/FeatureForm/css.js +1 -1
- package/widgets/FeatureForm.js +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/Grid/Grid.js +1 -1
- package/widgets/FeatureTable/Grid/support/ButtonMenu.js +1 -1
- package/widgets/FeatureTable.js +1 -1
- package/widgets/FeatureTemplates/ItemList.js +1 -1
- package/widgets/FeatureTemplates.js +1 -1
- package/widgets/Features/FeaturesRelatedRecords.js +1 -1
- package/widgets/Features.js +1 -1
- package/widgets/FloorFilter/FloorFilterViewModel.js +1 -1
- package/widgets/FloorFilter.js +1 -1
- package/widgets/Fullscreen.js +1 -1
- package/widgets/Histogram.js +1 -1
- package/widgets/HistogramRangeSlider.js +1 -1
- package/widgets/Home.js +1 -1
- package/widgets/LayerList/ListItemPanel.js +1 -1
- package/widgets/LayerList.js +1 -1
- package/widgets/Legend/LegendViewModel.js +1 -1
- package/widgets/Legend/styles/Card.js +1 -1
- package/widgets/Legend/styles/Classic.js +1 -1
- package/widgets/Legend/styles/support/relationshipUtils.js +1 -1
- package/widgets/Legend/styles/support/univariateUtils.js +1 -1
- package/widgets/LineOfSight.js +1 -1
- package/widgets/Locate.js +1 -1
- package/widgets/NavigationToggle.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/Popup.js +1 -1
- package/widgets/Print.js +1 -1
- package/widgets/ScaleRangeSlider/scalePreviewUtils.js +1 -1
- package/widgets/ScaleRangeSlider.js +1 -1
- package/widgets/Search/SearchResultRenderer.js +1 -1
- package/widgets/Search.js +1 -1
- package/widgets/ShadowCast/components/DiscreteConfigurator.js +1 -1
- package/widgets/ShadowCast/components/DurationConfigurator.js +1 -1
- package/widgets/ShadowCast/components/ShadowTooltipContent.js +1 -1
- package/widgets/ShadowCast/components/ThresholdConfigurator.js +1 -1
- package/widgets/ShadowCast.js +1 -1
- package/widgets/Sketch.js +1 -1
- package/widgets/Slice.js +1 -1
- package/widgets/Slider.js +1 -1
- package/widgets/Swipe.js +1 -1
- package/widgets/TableList.js +1 -1
- package/widgets/TimeSlider.js +1 -1
- package/widgets/Track.js +1 -1
- package/widgets/UtilityNetworkAssociations/UtilityNetworkAssociationsLineSymbolPicker.js +1 -1
- package/widgets/UtilityNetworkAssociations.js +1 -1
- package/widgets/UtilityNetworkTrace.js +1 -1
- package/widgets/UtilityNetworkValidateTopology.js +1 -1
- package/widgets/ValuePicker.js +1 -1
- package/widgets/VideoPlayer/components/PlayerControlsGroup.js +1 -1
- package/widgets/VideoPlayer/components/SettingsButton.js +1 -1
- package/widgets/VideoPlayer.js +1 -1
- package/widgets/Weather/LabeledSlider.js +1 -1
- package/widgets/Weather.js +1 -1
- package/widgets/Zoom/IconButton.js +1 -1
- package/widgets/smartMapping/BinaryColorSizeSlider.js +1 -1
- package/widgets/smartMapping/ClassedColorSlider.js +1 -1
- package/widgets/smartMapping/ClassedSizeSlider.js +1 -1
- package/widgets/smartMapping/ColorSizeSlider.js +1 -1
- package/widgets/smartMapping/ColorSlider.js +1 -1
- package/widgets/smartMapping/HeatmapSlider.js +1 -1
- package/widgets/smartMapping/OpacitySlider.js +1 -1
- package/widgets/smartMapping/SizeSlider.js +1 -1
- package/widgets/smartMapping/SmartMappingSliderBase.js +1 -1
- package/widgets/support/ColorPicker.js +1 -1
- package/widgets/support/DatePicker.js +1 -1
- package/widgets/support/Heading.js +1 -1
- package/widgets/support/LabeledSwitch.js +1 -1
- package/widgets/support/MeasurementWidgetContent.js +1 -1
- package/widgets/support/Popover.js +1 -1
- package/widgets/support/SelectionToolbar.js +1 -1
- package/widgets/support/SketchTooltipControls.js +1 -1
- package/widgets/support/SnappingControls.js +1 -1
- package/widgets/support/TimePicker.js +1 -1
- package/widgets/support/TimezonePicker.js +1 -1
- package/widgets/support/UnitSelect.js +1 -1
- package/widgets/support/dateUtils.js +1 -1
- package/assets/esri/core/workers/chunks/072b4e041b8630c513a0.js +0 -1
- package/assets/esri/core/workers/chunks/092920c25cac89c038ee.js +0 -1
- package/assets/esri/core/workers/chunks/114269dda1d296893908.js +0 -1
- package/assets/esri/core/workers/chunks/126df6237fc80608344e.js +0 -1
- package/assets/esri/core/workers/chunks/1b3655f5bf5d90fa8730.js +0 -1
- package/assets/esri/core/workers/chunks/1c83f47d446f2bca1721.js +0 -1
- package/assets/esri/core/workers/chunks/1cf7bb514e7eefc3e9c6.js +0 -1
- package/assets/esri/core/workers/chunks/21a9c8aa2a9e9990df41.js +0 -1
- package/assets/esri/core/workers/chunks/24629402c647ef6b5f6b.js +0 -1
- package/assets/esri/core/workers/chunks/2a1c1be9c202462cf54d.js +0 -1
- package/assets/esri/core/workers/chunks/2cb36f9686693234991a.js +0 -1
- package/assets/esri/core/workers/chunks/2d0d03cbea83c868edba.js +0 -1
- package/assets/esri/core/workers/chunks/2e130cb2f1038055c07b.js +0 -1
- package/assets/esri/core/workers/chunks/3619e04cbb6691549014.js +0 -1
- package/assets/esri/core/workers/chunks/3dbfb4f370a874393822.js +0 -1
- package/assets/esri/core/workers/chunks/406db5c90271a3a203d4.js +0 -1
- package/assets/esri/core/workers/chunks/4369a6c1e0a82ab4db6a.js +0 -1
- package/assets/esri/core/workers/chunks/4f4a424d1747d04501df.js +0 -1
- package/assets/esri/core/workers/chunks/59c00d6fba0fd1c03d01.js +0 -1
- package/assets/esri/core/workers/chunks/5a5720caa64a46daadf9.js +0 -1
- package/assets/esri/core/workers/chunks/5edb99b58549cd66b394.js +0 -1
- package/assets/esri/core/workers/chunks/6203ddf6caad3d356327.js +0 -1
- package/assets/esri/core/workers/chunks/650a317b6dc245a7060f.js +0 -1
- package/assets/esri/core/workers/chunks/7a358b1fd0c0cce59e9b.js +0 -1
- package/assets/esri/core/workers/chunks/83d1a1b3d371c991cc4c.js +0 -1
- package/assets/esri/core/workers/chunks/846b7a81b870c8b238a1.js +0 -1
- package/assets/esri/core/workers/chunks/8ab832468300cc4feb5a.js +0 -1
- package/assets/esri/core/workers/chunks/bc1dc6383e60e7e61d50.js +0 -1
- package/assets/esri/core/workers/chunks/bc6323bdc98013da6fe5.js +0 -1
- package/assets/esri/core/workers/chunks/c4bb67150ccd01ea6014.js +0 -1
- package/assets/esri/core/workers/chunks/c60cf62f374e71e562fc.js +0 -1
- package/assets/esri/core/workers/chunks/c6ea5aac232d1eca04dd.js +0 -1
- package/assets/esri/core/workers/chunks/c8438c2d9ac48afe4033.js +0 -1
- package/assets/esri/core/workers/chunks/c8f239c25fe864f0e47a.js +0 -1
- package/assets/esri/core/workers/chunks/cad260881653567bc8f9.js +0 -1
- package/assets/esri/core/workers/chunks/d824f4b405a72cd2fa74.js +0 -1
- package/assets/esri/core/workers/chunks/dd7508d4016715371e0c.js +0 -1
- package/assets/esri/core/workers/chunks/e55f7fc7eff0074ce0fc.js +0 -1
- package/assets/esri/core/workers/chunks/eef27d305023034084a4.js +0 -1
- package/assets/esri/core/workers/chunks/f38c54ada9e7012a2960.js +0 -1
- package/assets/esri/core/workers/chunks/f5e0ff5292b9fd18fc92.js +0 -1
- package/assets/esri/core/workers/chunks/f5eb8b5021620be7538e.js +0 -1
- package/core/watchUtils.d.ts +0 -4
- package/core/watchUtils.js +0 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5613],{95401:(e,t,n)=>{n.d(t,{e:()=>l});var r,i,o,s=n(5732),a={exports:{}};r=a,i=function(){function e(e,n,i){i=i||2;var o,s,a,c,u,h,f,p=n&&n.length,d=p?n[0]*i:e.length,g=t(e,0,d,i,!0),m=[];if(!g||g.next===g.prev)return m;if(p&&(g=l(e,n,g,i)),e.length>80*i){o=a=e[0],s=c=e[1];for(var y=i;y<d;y+=i)(u=e[y])<o&&(o=u),(h=e[y+1])<s&&(s=h),u>a&&(a=u),h>c&&(c=h);f=0!==(f=Math.max(a-o,c-s))?1/f:0}return r(g,m,i,o,s,f),m}function t(e,t,n,r,i){var o,s;if(i===S(e,t,n,r)>0)for(o=t;o<n;o+=r)s=M(o,e[o],e[o+1],s);else for(o=n-r;o>=t;o-=r)s=M(o,e[o],e[o+1],s);if(s&&v(s,s.next)){var a=s.next;C(s),s=a}return s}function n(e,t){if(!e)return e;t||(t=e);var n,r=e;do{if(n=!1,r.steiner||!v(r,r.next)&&0!==x(r.prev,r,r.next))r=r.next;else{var i=r.prev;if(C(r),(r=t=i)===r.next)break;n=!0}}while(n||r!==t);return t}function r(e,t,l,c,u,h,f){if(e){!f&&h&&p(e,c,u,h);for(var d,g,m=e;e.prev!==e.next;)if(d=e.prev,g=e.next,h?o(e,c,u,h):i(e))t.push(d.i/l),t.push(e.i/l),t.push(g.i/l),C(e),e=g.next,m=g.next;else if((e=g)===m){f?1===f?r(e=s(n(e),t,l),t,l,c,u,h,2):2===f&&a(e,t,l,c,u,h):r(n(e),t,l,c,u,h,1);break}}}function i(e){var t=e.prev,n=e,r=e.next;if(x(t,n,r)>=0)return!1;for(var i=e.next.next;i!==e.prev;){if(m(t.x,t.y,n.x,n.y,r.x,r.y,i.x,i.y)&&x(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function o(e,t,n,r){var i=e.prev,o=e,s=e.next;if(x(i,o,s)>=0)return!1;for(var a=i.x<o.x?i.x<s.x?i.x:s.x:o.x<s.x?o.x:s.x,l=i.y<o.y?i.y<s.y?i.y:s.y:o.y<s.y?o.y:s.y,c=i.x>o.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,u=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,h=d(a,l,t,n,r),f=d(c,u,t,n,r),p=e.prevZ,g=e.nextZ;p&&p.z>=h&&g&&g.z<=f;){if(p!==e.prev&&p!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&x(p.prev,p,p.next)>=0)return!1;if(p=p.prevZ,g!==e.prev&&g!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,g.x,g.y)&&x(g.prev,g,g.next)>=0)return!1;g=g.nextZ}for(;p&&p.z>=h;){if(p!==e.prev&&p!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&x(p.prev,p,p.next)>=0)return!1;p=p.prevZ}for(;g&&g.z<=f;){if(g!==e.prev&&g!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,g.x,g.y)&&x(g.prev,g,g.next)>=0)return!1;g=g.nextZ}return!0}function s(e,t,r){var i=e;do{var o=i.prev,s=i.next.next;!v(o,s)&&w(o,i,i.next,s)&&_(o,s)&&_(s,o)&&(t.push(o.i/r),t.push(i.i/r),t.push(s.i/r),C(i),C(i.next),i=e=s),i=i.next}while(i!==e);return n(i)}function a(e,t,i,o,s,a){var l=e;do{for(var c=l.next.next;c!==l.prev;){if(l.i!==c.i&&y(l,c)){var u=T(l,c);return l=n(l,l.next),u=n(u,u.next),r(l,t,i,o,s,a),void r(u,t,i,o,s,a)}c=c.next}l=l.next}while(l!==e)}function l(e,r,i,o){var s,a,l,u=[];for(s=0,a=r.length;s<a;s++)(l=t(e,r[s]*o,s<a-1?r[s+1]*o:e.length,o,!1))===l.next&&(l.steiner=!0),u.push(g(l));for(u.sort(c),s=0;s<u.length;s++)i=n(i=h(u[s],i),i.next);return i}function c(e,t){return e.x-t.x}function u(e){if(e.next.prev===e)return e;let t=e;for(;;){const n=t.next;if(n.prev===t||n===t||n===e)break;t=n}return t}function h(e,t){var r=function(e,t){var n,r=t,i=e.x,o=e.y,s=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var a=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(a<=i&&a>s){if(s=a,a===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==t);if(!n)return null;if(i===s)return n;var l,c=n,u=n.x,h=n.y,p=1/0;r=n;do{i>=r.x&&r.x>=u&&i!==r.x&&m(o<h?i:s,o,u,h,o<h?s:i,o,r.x,r.y)&&(l=Math.abs(o-r.y)/(i-r.x),_(r,e)&&(l<p||l===p&&(r.x>n.x||r.x===n.x&&f(n,r)))&&(n=r,p=l)),r=r.next}while(r!==c);return n}(e,t);if(!r)return t;var i=T(r,e),o=n(r,r.next);let s=u(i);return n(s,s.next),o=u(o),u(t===r?o:t)}function f(e,t){return x(e.prev,e,t.prev)<0&&x(t.next,e,e.next)<0}function p(e,t,n,r){var i=e;do{null===i.z&&(i.z=d(i.x,i.y,t,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==e);i.prevZ.nextZ=null,i.prevZ=null,function(e){var t,n,r,i,o,s,a,l,c=1;do{for(n=e,e=null,o=null,s=0;n;){for(s++,r=n,a=0,t=0;t<c&&(a++,r=r.nextZ);t++);for(l=c;a>0||l>0&&r;)0!==a&&(0===l||!r||n.z<=r.z)?(i=n,n=n.nextZ,a--):(i=r,r=r.nextZ,l--),o?o.nextZ=i:e=i,i.prevZ=o,o=i;n=r}o.nextZ=null,c*=2}while(s>1)}(i)}function d(e,t,n,r,i){return(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)*i)|e<<8))|e<<4))|e<<2))|e<<1))|(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*i)|t<<8))|t<<4))|t<<2))|t<<1))<<1}function g(e){var t=e,n=e;do{(t.x<n.x||t.x===n.x&&t.y<n.y)&&(n=t),t=t.next}while(t!==e);return n}function m(e,t,n,r,i,o,s,a){return(i-s)*(t-a)-(e-s)*(o-a)>=0&&(e-s)*(r-a)-(n-s)*(t-a)>=0&&(n-s)*(o-a)-(i-s)*(r-a)>=0}function y(e,t){return e.next.i!==t.i&&e.prev.i!==t.i&&!function(e,t){var n=e;do{if(n.i!==e.i&&n.next.i!==e.i&&n.i!==t.i&&n.next.i!==t.i&&w(n,n.next,e,t))return!0;n=n.next}while(n!==e);return!1}(e,t)&&(_(e,t)&&_(t,e)&&function(e,t){var n=e,r=!1,i=(e.x+t.x)/2,o=(e.y+t.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==e);return r}(e,t)&&(x(e.prev,e,t.prev)||x(e,t.prev,t))||v(e,t)&&x(e.prev,e,e.next)>0&&x(t.prev,t,t.next)>0)}function x(e,t,n){return(t.y-e.y)*(n.x-t.x)-(t.x-e.x)*(n.y-t.y)}function v(e,t){return e.x===t.x&&e.y===t.y}function w(e,t,n,r){var i=A(x(e,t,n)),o=A(x(e,t,r)),s=A(x(n,r,e)),a=A(x(n,r,t));return i!==o&&s!==a||!(0!==i||!b(e,n,t))||!(0!==o||!b(e,r,t))||!(0!==s||!b(n,e,r))||!(0!==a||!b(n,t,r))}function b(e,t,n){return t.x<=Math.max(e.x,n.x)&&t.x>=Math.min(e.x,n.x)&&t.y<=Math.max(e.y,n.y)&&t.y>=Math.min(e.y,n.y)}function A(e){return e>0?1:e<0?-1:0}function _(e,t){return x(e.prev,e,e.next)<0?x(e,t,e.next)>=0&&x(e,e.prev,t)>=0:x(e,t,e.prev)<0||x(e,e.next,t)<0}function T(e,t){var n=new Z(e.i,e.x,e.y),r=new Z(t.i,t.x,t.y),i=e.next,o=t.prev;return e.next=t,t.prev=e,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function M(e,t,n,r){var i=new Z(e,t,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function C(e){e.next.prev=e.prev,e.prev.next=e.next,e.prevZ&&(e.prevZ.nextZ=e.nextZ),e.nextZ&&(e.nextZ.prevZ=e.prevZ)}function Z(e,t,n){this.i=e,this.x=t,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function S(e,t,n,r){for(var i=0,o=t,s=n-r;o<n;o+=r)i+=(e[s]-e[o])*(e[o+1]+e[s+1]),s=o;return i}return e.deviation=function(e,t,n,r){var i=t&&t.length,o=i?t[0]*n:e.length,s=Math.abs(S(e,0,o,n));if(i)for(var a=0,l=t.length;a<l;a++){var c=t[a]*n,u=a<l-1?t[a+1]*n:e.length;s-=Math.abs(S(e,c,u,n))}var h=0;for(a=0;a<r.length;a+=3){var f=r[a]*n,p=r[a+1]*n,d=r[a+2]*n;h+=Math.abs((e[f]-e[d])*(e[p+1]-e[f+1])-(e[f]-e[p])*(e[d+1]-e[f+1]))}return 0===s&&0===h?0:Math.abs((h-s)/s)},e.flatten=function(e){for(var t=e[0][0].length,n={vertices:[],holes:[],dimensions:t},r=0,i=0;i<e.length;i++){for(var o=0;o<e[i].length;o++)for(var s=0;s<t;s++)n.vertices.push(e[i][o][s]);i>0&&(r+=e[i-1].length,n.holes.push(r))}return n},e},void 0!==(o=i())&&(r.exports=o);const l=(0,s.g)(a.exports)},20773:(e,t,n)=>{n.d(t,{a:()=>a,b:()=>s,c:()=>i,d:()=>u,e:()=>l,n:()=>h,s:()=>c,t:()=>o});var r=n(72220);function i(e,t,n){o(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function o(e,t,n,i=3,o=i){if(e.length/i!==Math.ceil(t.length/o))return r.c.error("source and destination buffers need to have the same number of elements"),e;const s=e.length/i,a=n[0],l=n[1],c=n[2],u=n[4],h=n[5],f=n[6],p=n[8],d=n[9],g=n[10],m=n[12],y=n[13],x=n[14];let v=0,w=0;for(let n=0;n<s;n++){const n=t[v],r=t[v+1],s=t[v+2];e[w]=a*n+u*r+p*s+m,e[w+1]=l*n+h*r+d*s+y,e[w+2]=c*n+f*r+g*s+x,v+=o,w+=i}return e}function s(e,t,n){a(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function a(e,t,n,i=3,o=i){if(e.length/i!==Math.ceil(t.length/o))return void r.c.error("source and destination buffers need to have the same number of elements");const s=e.length/i,a=n[0],l=n[1],c=n[2],u=n[3],h=n[4],f=n[5],p=n[6],d=n[7],g=n[8];let m=0,y=0;for(let n=0;n<s;n++){const n=t[m],r=t[m+1],s=t[m+2];e[y]=a*n+u*r+p*s,e[y+1]=l*n+h*r+d*s,e[y+2]=c*n+f*r+g*s,m+=o,y+=i}}function l(e,t,n){c(e.typedBuffer,t,n,e.typedBufferStride)}function c(e,t,n,r=3){const i=Math.min(e.length/r,t.count),o=t.typedBuffer,s=t.typedBufferStride;let a=0,l=0;for(let t=0;t<i;t++)e[l]=n*o[a],e[l+1]=n*o[a+1],e[l+2]=n*o[a+2],a+=s,l+=r}function u(e,t){h(e.typedBuffer,t.typedBuffer,e.typedBufferStride,t.typedBufferStride)}function h(e,t,n=3,r=n){const i=Math.min(e.length/n,t.length/r);let o=0,s=0;for(let a=0;a<i;a++){const i=t[o],a=t[o+1],l=t[o+2],c=i*i+a*a+l*l;if(c>0){const t=1/Math.sqrt(c);e[s]=t*i,e[s+1]=t*a,e[s+2]=t*l}o+=r,s+=n}}Object.freeze(Object.defineProperty({__proto__:null,normalize:h,normalizeView:u,scale:c,scaleView:l,shiftRight:function(e,t,n){const r=Math.min(e.count,t.count),i=e.typedBuffer,o=e.typedBufferStride,s=t.typedBuffer,a=t.typedBufferStride;let l=0,c=0;for(let e=0;e<r;e++)i[c]=s[l]>>n,i[c+1]=s[l+1]>>n,i[c+2]=s[l+2]>>n,l+=a,c+=o},transformMat3:a,transformMat3View:s,transformMat4:o,transformMat4View:i},Symbol.toStringTag,{value:"Module"}))},70163:(e,t,n)=>{n.d(t,{Jl:()=>u,n$:()=>h});var r=n(3172),i=n(20102),o=n(95330),s=n(17452),a=n(49917);let l=null,c=!0;function u(e,t,n,r){if(!t||!n)throw new Error("Cannot construct image data without dimensions");if(c)try{return new ImageData(e,t,n)}catch(e){c=!1}const i=function(e,t,n){return n||(l||(l=document.createElement("canvas"),l.width=1,l.height=1),n=l),n.getContext("2d").createImageData(e,t)}(t,n,r);return i.data.set(e,0),i}async function h(e,t){const{arrayBuffer:l,mediaType:c}=await async function(e,t){const n=(0,s.sJ)(e);if(n?.isBase64)return{arrayBuffer:(0,a.R)(n.data),mediaType:n.mediaType};const i=await(0,r.Z)(e,{responseType:"array-buffer",...t});return{arrayBuffer:i.data,mediaType:i.getHeader("Content-Type")}}(e,t),u="image/png"===c;if("image/gif"===c){const{isAnimatedGIF:e,parseGif:r}=await n.e(3310).then(n.bind(n,83310));if(e(l))return r(l,t)}if(u){const{isAnimatedPNG:e,parseApng:r}=await n.e(4492).then(n.bind(n,54492));if(e(l))return r(l,t)}return async function(e,t){const n=window.URL.createObjectURL(e);try{const{data:e}=await(0,r.Z)(n,{...t,responseType:"image"});return e}catch(e){if(!(0,o.D_)(e))throw new i.Z("invalid-image",`Could not fetch requested image at ${n}`);throw e}finally{window.URL.revokeObjectURL(n)}}(new Blob([l],{type:c}),t)}},83025:(e,t,n)=>{n.d(t,{JK:()=>a,QZ:()=>o,Rq:()=>s,bg:()=>i,mB:()=>l});var r=n(1533);function i(e,t=!1){return e<=r.c8?t?new Array(e).fill(0):new Array(e):new Float64Array(e)}function o(e){return((0,r.kJ)(e)?e.length:e.byteLength/8)<=r.c8?Array.from(e):new Float64Array(e)}function s(e,t,n){return Array.isArray(e)?e.slice(t,t+n):e.subarray(t,t+n)}function a(e,t){for(let n=0;n<t.length;++n)e[n]=t[n];return e}function l(e){return Array.isArray(e)?new Float64Array(e):e}},24882:(e,t,n)=>{n.d(t,{$z:()=>s,KF:()=>u,mi:()=>i});var r=n(1533);function i(e){return(0,r.kJ)(e)?e.length<r.c8?e:o(e):e.length<r.c8?Array.from(e):e.BYTES_PER_ELEMENT===Uint16Array.BYTES_PER_ELEMENT?e:o(e)}function o(e){let t=!0;for(const n of e){if(n>=65536)return(0,r.kJ)(e)?new Uint32Array(e):e;n>=256&&(t=!1)}return t?new Uint8Array(e):new Uint16Array(e)}function s(e){return e<=r.c8?new Array(e):e<=65536?new Uint16Array(e):new Uint32Array(e)}let a=(()=>{const e=new Uint32Array(131072);for(let t=0;t<e.length;++t)e[t]=t;return e})();const l=[0],c=(()=>{const e=new Uint16Array(65536);for(let t=0;t<e.length;++t)e[t]=t;return e})();function u(e){if(1===e)return l;if(e<r.c8)return Array.from(new Uint16Array(c.buffer,0,e));if(e<c.length)return new Uint16Array(c.buffer,0,e);if(e>a.length){const t=Math.max(2*a.length,e);a=new Uint32Array(t);for(let e=0;e<a.length;e++)a[e]=e}return new Uint32Array(a.buffer,0,e)}new Uint8Array(65536)},62540:(e,t,n)=>{n.d(t,{Z:()=>x});var r,i=n(43697),o=n(96674),s=n(22974),a=n(92604),l=n(5600),c=n(90578),u=n(52011),h=n(75215),f=n(65542),p=n(60746),d=n(71630);const g="esri.geometry.support.MeshComponent",m=a.Z.getLogger(g);let y=r=class extends o.wq{static from(e){return(0,h.TJ)(r,e)}constructor(e){super(e),this.faces=null,this.material=null,this.name=void 0,this.shading="source",this.trustSourceNormals=!1}castFaces(e){return(0,d.X)(e,Uint32Array,[Uint16Array],{loggerTag:".faces=",stride:3},m)}castMaterial(e){return(0,h.TJ)(e&&"object"==typeof e&&("metallic"in e||"roughness"in e||"metallicRoughnessTexture"in e)?p.Z:f.Z,e)}clone(){return new r({faces:(0,s.d9)(this.faces),shading:this.shading,material:(0,s.d9)(this.material),trustSourceNormals:this.trustSourceNormals,name:this.name})}cloneWithDeduplication(e,t){const n={faces:(0,s.d9)(this.faces),shading:this.shading,material:this.material?this.material.cloneWithDeduplication(e,t):null,trustSourceNormals:this.trustSourceNormals,name:this.name};return new r(n)}get memoryUsage(){let e=0;return null!=this.faces&&(e+=this.faces.byteLength),null!=this.material&&(e+=this.material.memoryUsage),e}};(0,i._)([(0,l.Cb)({json:{write:!0}})],y.prototype,"faces",void 0),(0,i._)([(0,c.p)("faces")],y.prototype,"castFaces",null),(0,i._)([(0,l.Cb)({type:f.Z,json:{write:!0}})],y.prototype,"material",void 0),(0,i._)([(0,c.p)("material")],y.prototype,"castMaterial",null),(0,i._)([(0,l.Cb)()],y.prototype,"name",void 0),(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"shading",void 0),(0,i._)([(0,l.Cb)({type:Boolean})],y.prototype,"trustSourceNormals",void 0),y=r=(0,i._)([(0,u.j)(g)],y);const x=y},85872:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(36030)),l=n(52011),c=n(65617),u=n(94139);let h=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.type="georeferenced-relative",this.isRelative=!0,this.isGeoreferenced=!0,this.origin=(0,c.c)()}getOriginPoint(e){const[t,n,r]=this.origin;return new u.Z({x:t,y:n,z:r,spatialReference:e})}setOriginFromPoint({x:e,y:t,z:n}){this.origin=(0,c.f)(e,t,n??0)}};(0,r._)([(0,a.J)({georeferencedRelative:"georeferenced-relative"},{readOnly:!0})],h.prototype,"type",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,r._)([(0,l.j)("esri.geometry.support.MeshGeoreferencedRelativeVertexSpace")],h);const f=h},84555:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(36030)),l=n(52011),c=n(65617),u=n(94139);let h=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.type="local",this.isRelative=!0,this.isGeoreferenced=!1,this.origin=(0,c.c)()}getOriginPoint(e){const[t,n,r]=this.origin;return new u.Z({x:t,y:n,z:r,spatialReference:e})}setOriginFromPoint({x:e,y:t,z:n}){this.origin=(0,c.f)(e,t,n??0)}};(0,r._)([(0,a.J)({local:"local"},{readOnly:!0})],h.prototype,"type",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,r._)([(0,l.j)("esri.geometry.support.MeshLocalVertexSpace")],h);const f=h},65542:(e,t,n)=>{n.d(t,{Z:()=>f});var r,i=n(43697),o=n(22303),s=n(96674),a=n(5600),l=(n(75215),n(67676),n(80442),n(52011)),c=n(85965),u=n(80218);let h=r=class extends s.wq{constructor(e){super(e),this.color=null,this.colorTexture=null,this.colorTextureTransform=null,this.normalTexture=void 0,this.normalTextureTransform=void 0,this.alphaMode="auto",this.alphaCutoff=.5,this.doubleSided=!0}clone(){return this.cloneWithDeduplication(null,new Map)}cloneWithDeduplication(e,t){const n=null!=e?e.get(this):null;if(n)return n;const i=new r(this.clonePropertiesWithDeduplication(t));return null!=e&&e.set(this,i),i}clonePropertiesWithDeduplication(e){return{color:null!=this.color?this.color.clone():null,colorTexture:this.colorTexture?.cloneWithDeduplication(e),normalTexture:this.normalTexture?.cloneWithDeduplication(e),alphaMode:this.alphaMode,alphaCutoff:this.alphaCutoff,doubleSided:this.doubleSided,colorTextureTransform:this.colorTextureTransform?.clone(),normalTextureTransform:this.normalTextureTransform?.clone()}}get memoryUsage(){return this.getMemoryUsage()}getMemoryUsage(){let e=0;return e+=null!=this.color?16:0,null!=this.colorTexture&&(e+=this.colorTexture.memoryUsage),e+=null!=this.colorTextureTransform?20:0,null!=this.normalTexture&&(e+=this.normalTexture.memoryUsage),e+=null!=this.normalTextureTransform?20:0,e}};(0,i._)([(0,a.Cb)({type:o.Z,json:{write:!0}})],h.prototype,"color",void 0),(0,i._)([(0,a.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"colorTexture",void 0),(0,i._)([(0,a.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"colorTextureTransform",void 0),(0,i._)([(0,a.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"normalTexture",void 0),(0,i._)([(0,a.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"normalTextureTransform",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"alphaMode",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"alphaCutoff",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"doubleSided",void 0),h=r=(0,i._)([(0,l.j)("esri.geometry.support.MeshMaterial")],h);const f=h},60746:(e,t,n)=>{n.d(t,{Z:()=>f});var r,i=n(43697),o=n(22303),s=n(5600),a=(n(75215),n(67676),n(80442),n(52011)),l=n(65542),c=n(85965),u=n(80218);let h=r=class extends l.Z{constructor(e){super(e),this.emissiveColor=null,this.emissiveTexture=null,this.emissiveTextureTransform=void 0,this.occlusionTexture=null,this.occlusionTextureTransform=void 0,this.metallic=1,this.roughness=1,this.metallicRoughnessTexture=null,this.metallicRoughnessTextureTransform=void 0}clone(){return this.cloneWithDeduplication(null,new Map)}cloneWithDeduplication(e,t){const n=null!=e?e.get(this):null;if(n)return n;const i=new r(this.clonePropertiesWithDeduplication(t));return null!=e&&e.set(this,i),i}getMemoryUsage(){let e=super.getMemoryUsage();return e+=null!=this.emissiveColor?16:0,null!=this.emissiveTexture&&(e+=this.emissiveTexture.memoryUsage),e+=null!=this.emissiveTextureTransform?20:0,null!=this.occlusionTexture&&(e+=this.occlusionTexture.memoryUsage),e+=null!=this.occlusionTextureTransform?20:0,null!=this.metallicRoughnessTexture&&(e+=this.metallicRoughnessTexture.memoryUsage),e+=null!=this.metallicRoughnessTextureTransform?20:0,e}clonePropertiesWithDeduplication(e){return{...super.clonePropertiesWithDeduplication(e),emissiveColor:this.emissiveColor?.clone(),emissiveTexture:this.emissiveTexture?.cloneWithDeduplication(e),emissiveTextureTransform:this.emissiveTextureTransform?.clone(),occlusionTexture:this.occlusionTexture?.cloneWithDeduplication(e),occlusionTextureTransform:this.occlusionTextureTransform?.clone(),metallic:this.metallic,roughness:this.roughness,metallicRoughnessTexture:this.metallicRoughnessTexture?.cloneWithDeduplication(e),metallicRoughnessTextureTransform:this.metallicRoughnessTextureTransform?.clone()}}};(0,i._)([(0,s.Cb)({type:o.Z,json:{write:!0}})],h.prototype,"emissiveColor",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"emissiveTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"emissiveTextureTransform",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"occlusionTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"occlusionTextureTransform",void 0),(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"metallic",void 0),(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"roughness",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"metallicRoughnessTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"metallicRoughnessTextureTransform",void 0),h=r=(0,i._)([(0,a.j)("esri.geometry.support.MeshMaterialMetallicRoughness")],h);const f=h},85965:(e,t,n)=>{n.d(t,{Z:()=>m});var r,i=n(43697),o=(n(80442),n(70163)),s=n(96674),a=n(5600),l=n(75215),c=(n(67676),n(71715)),u=n(52011),h=n(30556),f=n(25929);const p=new WeakMap;let d=0,g=r=class extends s.wq{constructor(e){super(e),this.wrap="repeat"}get url(){return this._get("url")||null}set url(e){this._set("url",e),e&&this._set("data",null)}get data(){return this._get("data")||null}set data(e){this._set("data",e),e&&this._set("url",null)}writeData(e,t,n,r){if(e instanceof HTMLImageElement){const i={type:"image-element",src:(0,f.t)(e.src,r),crossOrigin:e.crossOrigin};t[n]=i}else if(e instanceof HTMLCanvasElement){const r=e.getContext("2d").getImageData(0,0,e.width,e.height),i={type:"canvas-element",imageData:this._encodeImageData(r)};t[n]=i}else if(e instanceof HTMLVideoElement){const i={type:"video-element",src:(0,f.t)(e.src,r),autoplay:e.autoplay,loop:e.loop,muted:e.muted,crossOrigin:e.crossOrigin,preload:e.preload};t[n]=i}else if(e instanceof ImageData){const r={type:"image-data",imageData:this._encodeImageData(e)};t[n]=r}}readData(e){switch(e.type){case"image-element":{const t=new Image;return t.src=e.src,t.crossOrigin=e.crossOrigin,t}case"canvas-element":{const t=this._decodeImageData(e.imageData),n=document.createElement("canvas");return n.width=t.width,n.height=t.height,n.getContext("2d").putImageData(t,0,0),n}case"image-data":return this._decodeImageData(e.imageData);case"video-element":{const t=document.createElement("video");return t.src=e.src,t.crossOrigin=e.crossOrigin,t.autoplay=e.autoplay,t.loop=e.loop,t.muted=e.muted,t.preload=e.preload,t}default:return}}get transparent(){const e=this.data,t=this.url;if(e instanceof HTMLCanvasElement)return this._imageDataContainsTransparent(e.getContext("2d").getImageData(0,0,e.width,e.height));if(e instanceof ImageData)return this._imageDataContainsTransparent(e);if(t){const e=t.substr(t.length-4,4).toLowerCase(),n=t.substr(0,15).toLocaleLowerCase();if(".png"===e||"data:image/png;"===n)return!0}return!1}set transparent(e){this._overrideIfSome("transparent",e)}get contentHash(){const e="string"==typeof this.wrap?this.wrap:"object"==typeof this.wrap?`${this.wrap.horizontal}/${this.wrap.vertical}`:"",t=(t="")=>`d:${t},t:${this.transparent},w:${e}`;return null!=this.url?t(this.url):null!=this.data?this.data instanceof HTMLImageElement||this.data instanceof HTMLVideoElement?t(this.data.src):(p.has(this.data)||p.set(this.data,++d),t(p.get(this.data))):t()}get memoryUsage(){let e=0;if(e+=null!=this.url?this.url.length:0,null!=this.data){const t=this.data;"data"in t?e+=t.data.byteLength:t instanceof HTMLImageElement?e+=t.naturalWidth*t.naturalHeight*3:t instanceof HTMLCanvasElement&&(e+=t.width*t.height*3)}return e}clone(){const e={url:this.url,data:this.data,wrap:this._cloneWrap()};return new r(e)}cloneWithDeduplication(e){const t=e.get(this);if(t)return t;const n=this.clone();return e.set(this,n),n}_cloneWrap(){return"string"==typeof this.wrap?this.wrap:{horizontal:this.wrap.horizontal,vertical:this.wrap.vertical}}_encodeImageData(e){let t="";for(let n=0;n<e.data.length;n++)t+=String.fromCharCode(e.data[n]);return{data:btoa(t),width:e.width,height:e.height}}_decodeImageData(e){const t=atob(e.data),n=new Uint8ClampedArray(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return(0,o.Jl)(n,e.width,e.height)}_imageDataContainsTransparent(e){for(let t=3;t<e.data.length;t+=4)if(255!==e.data[t])return!0;return!1}static from(e){return"string"==typeof e?new r({url:e}):e instanceof HTMLImageElement||e instanceof HTMLCanvasElement||e instanceof ImageData||e instanceof HTMLVideoElement?new r({data:e}):(0,l.TJ)(r,e)}};(0,i._)([(0,a.Cb)({type:String,json:{write:f.w}})],g.prototype,"url",null),(0,i._)([(0,a.Cb)({json:{write:{overridePolicy(){return{enabled:!this.url}}}}}),(0,a.Cb)()],g.prototype,"data",null),(0,i._)([(0,h.c)("data")],g.prototype,"writeData",null),(0,i._)([(0,c.r)("data")],g.prototype,"readData",null),(0,i._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy(){return{enabled:this._isOverridden("transparent")}}}}})],g.prototype,"transparent",null),(0,i._)([(0,a.Cb)({json:{write:!0}})],g.prototype,"wrap",void 0),(0,i._)([(0,a.Cb)({readOnly:!0})],g.prototype,"contentHash",null),g=r=(0,i._)([(0,u.j)("esri.geometry.support.MeshTexture")],g);const m=g},80218:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(52011));let l=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.offset=[0,0],this.rotation=0,this.scale=[1,1]}};(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],l.prototype,"offset",void 0),(0,r._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0}})],l.prototype,"rotation",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],l.prototype,"scale",void 0),l=(0,r._)([(0,a.j)("esri.geometry.support.MeshTextureTransform")],l);const c=l},71630:(e,t,n)=>{n.d(t,{Q:()=>p,X:()=>g});var r,i=n(43697),o=n(96674),s=n(22974),a=n(92604),l=n(5600),c=n(90578),u=n(52011);const h="esri.geometry.support.MeshVertexAttributes",f=a.Z.getLogger(h);let p=r=class extends o.wq{constructor(e){super(e),this.color=null,this.position=new Float64Array(0),this.uv=null,this.normal=null,this.tangent=null}castColor(e){return g(e,Uint8Array,[Uint8ClampedArray],{loggerTag:".color=",stride:4},f)}castPosition(e){return e&&e instanceof Float32Array&&f.warn(".position=","Setting position attribute from a Float32Array may cause precision problems. Consider storing data in a Float64Array or a regular number array"),g(e,Float64Array,[Float32Array],{loggerTag:".position=",stride:3},f)}castUv(e){return g(e,Float32Array,[Float64Array],{loggerTag:".uv=",stride:2},f)}castNormal(e){return g(e,Float32Array,[Float64Array],{loggerTag:".normal=",stride:3},f)}castTangent(e){return g(e,Float32Array,[Float64Array],{loggerTag:".tangent=",stride:4},f)}clone(){const e={position:(0,s.d9)(this.position),uv:(0,s.d9)(this.uv),normal:(0,s.d9)(this.normal),tangent:(0,s.d9)(this.tangent),color:(0,s.d9)(this.color)};return new r(e)}clonePositional(){const e={position:(0,s.d9)(this.position),normal:(0,s.d9)(this.normal),tangent:(0,s.d9)(this.tangent),uv:this.uv,color:this.color};return new r(e)}get memoryUsage(){let e=0;return e+=this.position.byteLength,null!=this.uv&&(e+=this.uv.byteLength),null!=this.normal&&(e+=this.normal.byteLength),null!=this.tangent&&(e+=this.tangent.byteLength),null!=this.color&&(e+=this.color.byteLength),e}};function d(e,t,n,r){const{loggerTag:i,stride:o}=t;return e.length%o!=0?(r.error(i,`Invalid array length, expected a multiple of ${o}`),new n([])):e}function g(e,t,n,r,i){if(!e)return e;if(e instanceof t)return d(e,r,t,i);for(const o of n)if(e instanceof o)return d(new t(e),r,t,i);if(Array.isArray(e))return d(new t(e),r,t,i);{const r=n.map((e=>`'${e.name}'`));return i.error(`Failed to set property, expected one of ${r}, but got ${e.constructor.name}`),new t([])}}function m(e,t,n){t[n]=function(e){const t=new Array(e.length);for(let n=0;n<e.length;n++)t[n]=e[n];return t}(e)}(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"color",void 0),(0,i._)([(0,c.p)("color")],p.prototype,"castColor",null),(0,i._)([(0,l.Cb)({nonNullable:!0,json:{write:m}})],p.prototype,"position",void 0),(0,i._)([(0,c.p)("position")],p.prototype,"castPosition",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"uv",void 0),(0,i._)([(0,c.p)("uv")],p.prototype,"castUv",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"normal",void 0),(0,i._)([(0,c.p)("normal")],p.prototype,"castNormal",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"tangent",void 0),(0,i._)([(0,c.p)("tangent")],p.prototype,"castTangent",null),p=r=(0,i._)([(0,u.j)(h)],p)},72220:(e,t,n)=>{n.d(t,{c:()=>r});const r=n(92604).Z.getLogger("esri.views.3d.support.buffer.math")},16996:(e,t,n)=>{n.d(t,{Ue:()=>l,nF:()=>u,zk:()=>c});var r=n(22021),i=n(22807),o=n(17896),s=n(65617),a=n(12981);function l(e){return e?{origin:(0,s.g)(e.origin),vector:(0,s.g)(e.vector)}:{origin:(0,s.c)(),vector:(0,s.c)()}}function c(e,t,n=l()){return(0,o.c)(n.origin,e),(0,o.f)(n.vector,t,e),n}function u(e,t,n){return function(e,t,n,i,s){const{vector:l,origin:c}=e,u=(0,o.f)(a.WM.get(),t,c),h=(0,o.j)(l,u)/(0,o.m)(l);return(0,o.i)(s,l,(0,r.uZ)(h,0,1)),(0,o.g)(s,s,e.origin)}(e,t,0,0,n)}(0,s.c)(),(0,s.c)(),new i.x((()=>l()))},84470:(e,t,n)=>{n.d(t,{CP:()=>a,JG:()=>d,LL:()=>l,NZ:()=>c,fV:()=>g,vj:()=>y,yT:()=>v,zE:()=>x});var r=n(3172),i=n(67676),o=n(95330),s=n(2981);class a{constructor(e,t,n){this.assetName=e,this.assetMimeType=t,this.parts=n}equals(e){return this===e||this.assetName===e.assetName&&this.assetMimeType===e.assetMimeType&&(0,i.fS)(this.parts,e.parts,((e,t)=>e.equals(t)))}isOnService(e){return this.parts.every((t=>t.isOnService(e)))}makeHash(){let e="";for(const t of this.parts)e+=t.partHash;return e}async toBlob(e){const{parts:t}=this;if(1===t.length)return t[0].toBlob(e);const n=await Promise.all(t.map((t=>t.toBlob(e))));return(0,o.k_)(e),new Blob(n)}}class l{constructor(e,t){this.partUrl=e,this.partHash=t}equals(e){return this===e||this.partUrl===e.partUrl&&this.partHash===e.partHash}isOnService(e){return this.partUrl.startsWith(`${e.path}/assets/`)}async toBlob(e){const{data:t}=await(0,r.Z)(this.partUrl,{responseType:"blob"});return(0,o.k_)(e),t}}function c(e){return function(e){return!!e&&(Array.isArray(e)?e.some(p):p(e))}(e?.source)}function u(e){return!!Array.isArray(e)&&e.every((e=>e instanceof a))}const h=/^(model\/gltf\+json)|(model\/gltf-binary)$/,f=/\.(gltf|glb)/i;function p(e){if(e instanceof File){const{type:t,name:n}=e;return h.test(t)||f.test(n)}return h.test(e.assetMimeType)||f.test(e.assetName)}function d(e,t){if(!e)return!1;const{source:n}=e;return function(e,t){if(Array.isArray(e)){const n=e;return n.length>0&&n.every((e=>m(e,t)))}return m(e,t)}(n,t)}function g(e,t){if(e===t)return!0;const{source:n}=e,{source:r}=t;if(n===r)return!0;if(u(n)&&u(r)){if(n.length!==r.length)return!1;const e=(e,t)=>e.assetName<t.assetName?-1:e.assetName>t.assetName?1:0,t=[...n].sort(e),i=[...r].sort(e);for(let e=0;e<t.length;++e)if(!t[e].equals(i[e]))return!1;return!0}return!1}function m(e,t){return e instanceof a&&e.isOnService(t)}function y(e,t){return e instanceof File?(0,s.dm)(e,t):(0,s.S0)(e.assetMimeType,t)??(0,s.Ow)(e.assetName,t)}function x(e){return Array.isArray(e)?e:[e]}function v(e){return!!e.original}},47545:(e,t,n)=>{n.d(t,{d:()=>o});var r=n(22021),i=n(24882);function o(e,t,n){const o=Array.isArray(e),u=o?e.length/t:e.byteLength/(4*t),h=o?e:new Uint32Array(e,0,u*t),f=n?.minReduction??0,p=n?.originalIndices||null,d=p?p.length:0,g=n?.componentOffsets||null;let m=0;if(g)for(let e=0;e<g.length-1;e++){const t=g[e+1]-g[e];t>m&&(m=t)}else m=u;const y=Math.floor(1.1*m)+1;(null==c||c.length<2*y)&&(c=new Uint32Array((0,r.Sf)(2*y)));for(let e=0;e<2*y;e++)c[e]=0;let x=0;const v=!!g&&!!p,w=v?d:u;let b=(0,i.$z)(u);const A=new Uint32Array(d),_=1.96;let T=0!==f?Math.ceil(4*_*_/(f*f)*f*(1-f)):w,M=1,C=g?g[1]:w;for(let e=0;e<w;e++){if(e===T){const t=1-x/e;if(t+_*Math.sqrt(t*(1-t)/e)<f)return null;T*=2}if(e===C){for(let e=0;e<2*y;e++)c[e]=0;if(p)for(let e=g[M-1];e<g[M];e++)A[e]=b[p[e]];C=g[++M]}const n=v?p[e]:e,r=n*t,i=l(h,r,t);let o=i%y,a=x;for(;0!==c[2*o+1];){if(c[2*o]===i){const e=c[2*o+1]-1;if(s(h,r,e*t,t)){a=b[e];break}}o++,o>=y&&(o-=y)}a===x&&(c[2*o]=i,c[2*o+1]=n+1,x++),b[n]=a}if(0!==f&&1-x/u<f)return null;if(v){for(let e=g[M-1];e<A.length;e++)A[e]=b[p[e]];b=(0,i.mi)(A)}const Z=o?new Array(x):new Uint32Array(x*t);x=0;for(let e=0;e<w;e++)b[e]===x&&(a(h,(v?p[e]:e)*t,Z,x*t,t),x++);if(p&&!v){const e=new Uint32Array(d);for(let t=0;t<e.length;t++)e[t]=b[p[t]];b=(0,i.mi)(e)}return{buffer:Array.isArray(Z)?Z:Z.buffer,indices:b,uniqueCount:x}}function s(e,t,n,r){for(let i=0;i<r;i++)if(e[t+i]!==e[n+i])return!1;return!0}function a(e,t,n,r,i){for(let o=0;o<i;o++)n[r+o]=e[t+o]}function l(e,t,n){let r=0;for(let i=0;i<n;i++)r=e[t+i]+r|0,r=r+(r<<11)+(r>>>2)|0;return r>>>0}let c=null},25158:(e,t,n)=>{n.r(t),n.d(t,{assetMapFromAssetMapsJSON:()=>lt,extractMesh:()=>ot,meshFeatureSetFromJSON:()=>it});var r=n(38171),i=n(92604),o=n(30175),s=n(65617),a=n(6570),l=n(43697),c=n(20102),u=n(83379),h=n(609),f=n(95330),p=n(17445),d=n(5600),g=(n(75215),n(67676),n(80442),n(52011)),m=n(9361),y=n(94139),x=n(38913),v=n(3709),w=n(62540);class b extends c.Z{constructor(){super("mesh-not-loaded","Mesh must be loaded before applying operations")}}class A extends c.Z{constructor(){super("component-not-found","Provided component is not part of the list of components")}}class _ extends c.Z{constructor(){super("invalid-polygon","expected polygon to be a Polygon instance")}}class T extends c.Z{constructor(){super("invalid-input:location","Expected location to be a Point instance")}}class M extends c.Z{constructor(){super("invalid-input:no-layer","A layer is needed to convert the files")}}class C extends c.Z{constructor(){super("invalid-input:no-model","No supported model found")}}class Z extends c.Z{constructor(){super("invalid-input:multiple-models","Multiple supported models found")}}var S=n(85872),R=n(50567),O=n(84555),L=n(2674),F=n(71630),I=n(95401),E=n(62155),P=n(86662),U=n(83025),N=n(24882),D=n(47545),j=(n(66577),n(22021)),k=n(67900),B=n(17896),z=n(62073);n(4726),n(22631),n(35065);const W=(0,z.Ue)();function H(e,t,n,r,i,o,s){i*=3;for(let a=0;a<o;++a){const o=e[t];r[i++]=o[0],r[i++]=o[1],r[i++]=s?o[2]:0,t+=n}return i/3}function $(e,t,n){if(t){const t=function(e,t,n){const r=function(e,t,n,r){const i=(e=>!Array.isArray(e[0]))(t)?(e,n)=>t[3*e+n]:(e,n)=>t[e][n],o=r?(0,k.c9)(r)/(0,k._R)(r):1;return(0,z.zu)(e,((e,t)=>(0,B.s)(e,i(t,0)*o,i(t,1)*o,i(t,2))),n)}(W,e,t,n)?(0,z.mJ)(W):[0,0,1];return Math.abs(r[2])>Math.cos((0,j.Vl)(80))?E.R.Z:Math.abs(r[1])>Math.abs(r[0])?E.R.Y:E.R.X}(e,e.length-1,n);if(t===E.R.X)return!(0,P.bu)(e,E.R.Y,E.R.Z);if(t===E.R.Y)return!(0,P.bu)(e,E.R.X,E.R.Z)}return!(0,P.bu)(e,E.R.X,E.R.Y)}var V,G;(G=V||(V={}))[G.NONE=0]="NONE",G[G.CCW_IS_HOLE=1]="CCW_IS_HOLE";var q=n(66459);let J=null;function Y(e,t){let n=1/0,r=1/0,i=1/0,o=-1/0,s=-1/0,l=-1/0;const c=e.length;let u=0;for(;u<c;){const t=e[u++],a=e[u++],c=e[u++];n=Math.min(n,t),r=Math.min(r,a),i=Math.min(i,c),o=Math.max(o,t),s=Math.max(s,a),l=Math.max(l,c)}return new a.Z({xmin:n,ymin:r,zmin:i,xmax:o,ymax:s,zmax:l,spatialReference:t})}var X=n(87360);function K(e,t,n,r=0){Q[0]=e.x,Q[1]=e.y;const i=e.z;return Q[2]=void 0!==i?i:r,(0,X.projectBuffer)(Q,e.spatialReference,0,t,n,0,1)}const Q=(0,s.c)();var ee=n(13442);const te="esri.geometry.support.meshUtils.centerAt";const ne=(0,s.c)(),re=(0,s.c)(),ie=(0,s.c)();n(99880),n(3172);var oe=n(17452);function se(e){const t=(0,oe.Yd)(e.url);return n=>{const r=(0,oe.PF)(n,t,t),i=r?r.replace(/^ *\.\//,""):null;return(i?e.files.get(i):null)??n}}function ae(e){return he.fromBlob(e)}n(47026);const le=/^(model\/gltf\+json)|(model\/gltf-binary)$/,ce=/\.(gltf|glb)/i;function ue(e){const t=new Map;let n=null;for(const{name:r,mimeType:i,source:o}of e)(null==n||le.test(i)||ce.test(r))&&(n=o.url),t.set(r,o.url),o.files.forEach(((e,n)=>t.set(n,e)));if(null==n)throw new c.Z("mesh-load-external:missing-files","Missing files to load external mesh source");return new he(n,(()=>e.forEach((({source:e})=>e.dispose()))),t)}class he{constructor(e,t=(()=>{}),n=new Map){this.url=e,this.dispose=t,this.files=n}static fromBlob(e){const t=URL.createObjectURL(e);return new he(t,(()=>URL.revokeObjectURL(t)))}}var fe=n(2368),pe=n(46791),de=n(84470);let ge=class extends fe.j{constructor(){super(),this.externalSources=new pe.Z,this._explicitDisplaySource=null,this.addHandles((0,p.on)((()=>this.externalSources),"after-remove",(({item:e})=>{e===this._explicitDisplaySource&&(this._explicitDisplaySource=null)}),{sync:!0,onListenerRemove:()=>this._explicitDisplaySource=null}))}get displaySource(){return this._explicitDisplaySource??this._implicitDisplaySource}set displaySource(e){if(null!=e&&!(0,de.NZ)(e))throw new Error("Cannot use this source for display: it is not in a supported format.");this._explicitDisplaySource=e,e&&this.externalSources.every((t=>!(0,de.fV)(t,e)))&&this.externalSources.add(e)}clearSources(){this.externalSources.removeAll()}getExternalSourcesOnService(e){return this.externalSources.items.filter((t=>(0,de.JG)(t,e)))}get _implicitDisplaySource(){return this.externalSources.find(de.NZ)}};(0,l._)([(0,d.Cb)()],ge.prototype,"externalSources",void 0),(0,l._)([(0,d.Cb)()],ge.prototype,"displaySource",null),(0,l._)([(0,d.Cb)()],ge.prototype,"_implicitDisplaySource",null),(0,l._)([(0,d.Cb)()],ge.prototype,"_explicitDisplaySource",void 0),ge=(0,l._)([(0,g.j)("esri.geometry.support.meshUtils.Metadata")],ge);var me=n(21787),ye=n(46521),xe=n(13598),ve=n(58995),we=n(83932),be=n(56493);function Ae(e,t){if(e)for(let n=0;n<e.length;n+=3)for(let r=0;r<3;r++)e[n+r]+=t[r]}const _e=(0,s.c)(),Te=(0,xe.a)(),Me=(0,ye.a)(),Ce={position:[-.5,-.5,0,.5,-.5,0,.5,.5,0,-.5,.5,0],normal:[0,0,1,0,0,1,0,0,1,0,0,1],uv:[0,1,1,1,1,0,0,0],faces:[0,1,2,0,2,3],facingAxisOrderSwap:{east:[3,1,2],west:[-3,-1,2],north:[-1,3,2],south:[1,-3,2],up:[1,2,3],down:[1,-2,-3]}};function Ze(e,t,n){e.isPlane||function(e){for(let t=0;t<e.position.length;t+=3)e.position[t+2]+=.5}(e),function(e,t){if(null==t)return;const n="number"==typeof t?[t,t,t]:[null!=t.width?t.width:1,null!=t.depth?t.depth:1,null!=t.height?t.height:1];Le[0]=n[0],Le[4]=n[1],Le[8]=n[2];for(let t=0;t<e.position.length;t+=3){for(let n=0;n<3;n++)Oe[n]=e.position[t+n];(0,B.t)(Oe,Oe,Le);for(let n=0;n<3;n++)e.position[t+n]=Oe[n]}if(n[0]!==n[1]||n[1]!==n[2]){Le[0]=1/n[0],Le[4]=1/n[1],Le[8]=1/n[2];for(let t=0;t<e.normal.length;t+=3){for(let n=0;n<3;n++)Oe[n]=e.normal[t+n];(0,B.t)(Oe,Oe,Le),(0,B.n)(Oe,Oe);for(let n=0;n<3;n++)e.normal[t+n]=Oe[n]}}}(e,n?.size);const{vertexAttributes:r,vertexSpace:i,transform:o}=(0,q.w1)(e,t,n);return{vertexAttributes:new F.Q({...r,uv:e.uv}),vertexSpace:i,transform:o,components:[new w.Z({faces:e.faces,material:n&&n.material||null})],spatialReference:t.spatialReference}}const Se={faceDescriptions:[{axis:[0,-1,0],uvOrigin:[0,.625],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[1,0,0],uvOrigin:[.25,.625],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[0,1,0],uvOrigin:[.5,.625],corners:[[1,-1],[-1,-1],[-1,1],[1,1]]},{axis:[-1,0,0],uvOrigin:[.75,.625],corners:[[1,-1],[-1,-1],[-1,1],[1,1]]},{axis:[0,0,1],uvOrigin:[0,.375],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[0,0,-1],uvOrigin:[0,.875],corners:[[-1,1],[1,1],[1,-1],[-1,-1]]}],uvScales:[[0,0],[1,0],[1,1],[0,1]],faceVertexOffsets:[0,1,2,0,2,3]},Re={south:0,east:1,north:2,west:3,up:4,down:5},Oe=(0,s.c)(),Le=(0,ye.a)();var Fe=n(52138);const Ie="esri.geometry.support.meshUtils.rotate";function Ee(e,t,n,r=s.Z){if(null!=e){(0,Fe.c)(De,(0,v.WH)(t),(0,v.ZZ)(t));for(let t=0;t<e.length;t+=n){for(let n=0;n<3;n++)Pe[n]=e[t+n]-r[n];(0,B.e)(Pe,Pe,De);for(let n=0;n<3;n++)e[t+n]=Pe[n]+r[n]}}}const Pe=(0,s.c)(),Ue=(0,s.c)(),Ne=(0,v.Ue)(),De=(0,xe.a)(),je=(0,ye.a)(),ke=(0,s.c)(),Be="esri.geometry.support.meshUtils.scale";function ze(e,t,n=s.Z){if(e)for(let r=0;r<e.length;r+=3){for(let t=0;t<3;t++)We[t]=e[r+t]-n[t];(0,B.i)(We,We,t);for(let t=0;t<3;t++)e[r+t]=We[t]+n[t]}}const We=(0,s.c)(),He=(0,s.c)(),$e=(0,s.c)();var Ve,Ge=n(2981);async function qe(e){const{BlobReader:t,ZipReader:r,BlobWriter:i}=await Promise.all([n.e(2712),n.e(4041)]).then(n.bind(n,74041)),o=[],s=new r(new t(e));return(await s.getEntries()).forEach((e=>{if(e.directory||/^__MACOS/i.test(e.filename))return;const t=new i,n=e.getData?.(t).then((t=>new File([t],e.filename)));n&&o.push(n)})),Promise.all(o)}const Je="esri.geometry.Mesh",Ye={base:null,key:"type",defaultKeyValue:"georeferenced",typeMap:{georeferenced:R.Z,"georeferenced-relative":S.Z,local:O.Z}};let Xe=Ve=class extends(u.Z.LoadableMixin((0,h.v)(m.Z))){constructor(e){super(e),this.components=null,this.vertexSpace=new R.Z,this.transform=null,this.metadata=new ge,this.hasZ=!0,this.hasM=!1,this.vertexAttributes=new F.Q,this.type="mesh"}initialize(){(0===this.metadata.externalSources.length||this.vertexAttributes.position.length)&&(this.loadStatus="loaded"),this.when((()=>{this.addHandles((0,p.YP)((()=>({vertexAttributes:this.vertexAttributes,components:this.components?.map((e=>e.clone()))})),(()=>this._clearSources()),{once:!0,sync:!0}))}))}get hasExtent(){return this.loaded?this.vertexAttributes.position.length>0&&(!this.components||this.components.length>0):null!=this.metadata.displaySource?.extent}get _transformedExtent(){const{components:e,spatialReference:t,vertexAttributes:n,vertexSpace:r}=this,i=n.position;if(0===i.length||e&&0===e.length)return new a.Z({xmin:0,ymin:0,zmin:0,xmax:0,ymax:0,zmax:0,spatialReference:t});if("local"===r.type){const{_untransformedExtent:e,transform:n}=this;return function({xmin:e,xmax:t,ymin:n,ymax:r,zmin:i,zmax:o},s,a,l){i??=0,o??=0,J??=new Float64Array(24);const c=J;return c[0]=e,c[1]=n,c[2]=i,c[3]=e,c[4]=r,c[5]=i,c[6]=t,c[7]=r,c[8]=i,c[9]=t,c[10]=n,c[11]=i,c[12]=e,c[13]=n,c[14]=o,c[15]=e,c[16]=r,c[17]=o,c[18]=t,c[19]=r,c[20]=o,c[21]=t,c[22]=n,c[23]=o,(0,q.project)({positions:c,transform:s,vertexSpace:a,inSpatialReference:l,outSpatialReference:l,outPositions:c}),Y(c,l)}(e,n,r,t)}if("georeferenced-relative"===r.type){const{transform:e}=this;return Y((0,q.project)({positions:i,transform:e,vertexSpace:r,inSpatialReference:t,outSpatialReference:t}),t)}return Y(i,t)}get _untransformedExtent(){return Y(this.vertexAttributes.position,this.spatialReference)}get anchor(){const{vertexSpace:e}=this;if(e.isRelative)return e.getOriginPoint(this.spatialReference);const{center:t,zmin:n}=this._transformedExtent;return new y.Z({x:t.x,y:t.y,z:n,spatialReference:this.spatialReference})}get origin(){const{vertexSpace:e}=this;return e.isRelative?e.getOriginPoint(this.spatialReference):this._transformedExtent.center}get extent(){return this.loaded||null==this.metadata?.displaySource?.extent?this._transformedExtent:this.metadata.displaySource.extent.clone()}addComponent(e){if(!this.loaded)return i.Z.getLogger(this).error("addComponent()",(new b).message);this.components||(this.components=[]),this.components.push(w.Z.from(e)),this.notifyChange("components")}removeComponent(e){if(!this.loaded)return i.Z.getLogger(this).error("removeComponent()",(new b).message);if(this.components){const t=this.components.indexOf(e);if(-1!==t)return this.components.splice(t,1),void this.notifyChange("components")}i.Z.getLogger(this).error("removeComponent()",(new A).message)}rotate(e,t,n,r){return(0,v.qw)(e,t,n,Qe),function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position||0===t[3])return;const{spatialReference:r,vertexSpace:o}=e;if(o.isRelative){(0,ee.A)(o,Ie,n);const r=n?.origin??e.origin;e.transform??=new L.Z,function(e,t,n,r){const i=t.origin,o=(0,B.s)(Pe,r.x,r.y,r.z??0),a=(0,B.f)(Pe,o,i);e.applyLocalInverse(a,Ue),e.rotation=(0,v.qC)(e.rotation,n,(0,v.Ue)()),e.applyLocalInverse(a,a),(0,B.f)(a,a,Ue),e.translation=(0,B.g)((0,s.c)(),e.translation,a)}(e.transform,o,t,r)}else{const o=n?.origin??e.origin;(0,ee.h)(r,n)?function(e,t,n){const r=e.spatialReference,i=(0,ve.rS)(r),o=ke;K(n,o,i)||K(e.origin,o,i);const s=e.vertexAttributes.position,a=e.vertexAttributes.normal,l=e.vertexAttributes.tangent,c=new Float64Array(s.length),u=null!=a?new Float32Array(a.length):null,h=null!=l?new Float32Array(l.length):null;(0,we.B)(i,o,De,i),(0,me.f)(je,De);const f=Ne;(0,B.t)((0,v.ZZ)(Ne),(0,v.ZZ)(t),je),f[3]=t[3],(0,be.XO)(s,r,c),null!=a&&null!=u&&(0,be.Iz)(a,s,c,r,u),null!=l&&null!=h&&(0,be.wi)(l,s,c,r,h),Ee(c,f,3,o),(0,be.To)(c,s,r),null!=a&&null!=u&&(Ee(u,f,3),(0,be.Yk)(u,s,c,r,a)),null!=l&&null!=h&&(Ee(h,f,4),(0,be.M2)(h,s,c,r,l)),e.vertexAttributesChanged()}(e,t,o):function(e,t,n){const r=ke;if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(Ie).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}Ee(e.vertexAttributes.position,t,3,r),Ee(e.vertexAttributes.normal,t,3),Ee(e.vertexAttributes.tangent,t,4),e.vertexAttributesChanged()}(e,t,o)}}(this,Qe,r),this}offset(e,t,n,r){return this.loaded?(Ke[0]=e,Ke[1]=t,Ke[2]=n,function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{vertexSpace:r}=e;r.isRelative?((0,ee.A)(r,"esri.geometry.support.meshUtils.offset",n),function(e,t){const n=e.origin;e.origin=(0,B.g)((0,s.c)(),n,t)}(r,t)):(0,ee.h)(e.spatialReference,n)?function(e,t){const n=e.spatialReference,r=e.vertexAttributes.position,i=e.vertexAttributes.normal,o=e.vertexAttributes.tangent,s=new Float64Array(r.length),a=null!=i?new Float32Array(i.length):null,l=null!=o?new Float32Array(o.length):null,c=e.extent.center,u=_e;(0,we.B)(n,[c.x,c.y,c.z],Te,(0,ve.rS)(n)),(0,me.f)(Me,Te),(0,B.t)(u,t,Me),(0,be.XO)(r,n,s),null!=i&&null!=a&&(0,be.Iz)(i,r,s,n,a),null!=o&&null!=l&&(0,be.wi)(o,r,s,n,l),Ae(s,u),(0,be.To)(s,r,n),null!=i&&null!=a&&(0,be.Yk)(a,r,s,n,i),null!=o&&null!=l&&(0,be.M2)(l,r,s,n,o),e.vertexAttributesChanged()}(e,t):function(e,t){Ae(e.vertexAttributes.position,t),e.vertexAttributesChanged()}(e,t)}(this,Ke,r),this):(i.Z.getLogger(this).error("offset()",(new b).message),this)}scale(e,t){return this.loaded?(function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{spatialReference:r,vertexSpace:o}=e;if(o.isRelative){(0,ee.A)(o,Be,n);const r=n?.origin??e.origin;e.transform??=new L.Z,function(e,t,n,r){const i=t.origin,o=(0,B.s)(We,r.x,r.y,r.z),a=(0,B.f)(We,o,i);e.applyLocalInverse(a,He);const l=(0,B.i)((0,s.c)(),e.scale,n);e.scale=l,e.applyLocalInverse(a,a),(0,B.f)(a,a,He),e.translation=(0,B.g)((0,s.c)(),e.translation,a)}(e.transform,o,t,r)}else{const o=(0,ee.h)(r,n),s=n?.origin??e.origin;o?function(e,t,n){const r=e.spatialReference,i=(0,ve.rS)(r),o=$e;K(n,o,i)||K(e.origin,o,i);const s=e.vertexAttributes.position,a=e.vertexAttributes.normal,l=e.vertexAttributes.tangent,c=new Float64Array(s.length),u=null!=a?new Float32Array(a.length):null,h=null!=l?new Float32Array(l.length):null;(0,be.XO)(s,r,c),null!=a&&null!=u&&(0,be.Iz)(a,s,c,r,u),null!=l&&null!=h&&(0,be.wi)(l,s,c,r,h),ze(c,t,o),(0,be.To)(c,s,r),null!=a&&null!=u&&(0,be.Yk)(u,s,c,r,a),null!=l&&null!=h&&(0,be.M2)(h,s,c,r,l),e.vertexAttributesChanged()}(e,t,s):function(e,t,n){const r=$e;if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(Be).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}ze(e.vertexAttributes.position,t,r),e.vertexAttributesChanged()}(e,t,s)}}(this,e,t),this):(i.Z.getLogger(this).error("scale()",(new b).message),this)}centerAt(e,t){return this.loaded?(function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{vertexSpace:r}=e,o=n?.origin??e.origin;r.isRelative?((0,ee.A)(r,te,n),function(e,t,n){const{vertexSpace:r}=e;if(!r.isRelative)return;const o=re,a=ne;if(!K(t,a,e.spatialReference))return void i.Z.getLogger(te).error(`Failed to project centerAt location (wkid:${t.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`);if(!K(n,o,e.spatialReference)){const t=e.origin;o[0]=t.x,o[1]=t.y,o[2]=t.z,i.Z.getLogger(te).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}const l=(0,B.f)(ie,a,o),c=r.origin;r.origin=(0,B.g)((0,s.c)(),c,l)}(e,t,o)):(0,ee.h)(e.spatialReference,n)?function(e,t,n){const r=(0,q.FF)(e.vertexAttributes,n,{geographic:!0}),{position:i,normal:o,tangent:s}=(0,q.iv)(r,t,{geographic:!0});e.vertexAttributes.position=i,e.vertexAttributes.normal=o,e.vertexAttributes.tangent=s,e.vertexAttributesChanged()}(e,t,o):function(e,t,n){const r=re,o=ne;if(K(t,o,e.spatialReference)){if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(te).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}(function(e,t,n){if(e)for(let r=0;r<e.length;r+=3)for(let i=0;i<3;i++)e[r+i]+=t[i]-n[i]})(e.vertexAttributes.position,o,r),e.vertexAttributesChanged()}else i.Z.getLogger(te).error(`Failed to project centerAt location (wkid:${t.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}(e,t,o)}(this,e,t),this):(i.Z.getLogger(this).error("centerAt()",(new b).message),this)}load(e){const{metadata:{displaySource:t}}=this;return t&&this.addResolvingPromise(async function(e,t,r){const{source:i}=t,{loadGLTFMesh:o}=await(0,f.Hl)(Promise.all([n.e(8598),n.e(8079)]).then(n.bind(n,78079)),r),s=await async function(e,t){if(Array.isArray(e)){if(!e.length)throw new c.Z("mesh-load-external:missing-assets","There must be at least one file to load");return e[0]instanceof File?function(e){return ue(e.map((e=>({name:e.name,mimeType:e.type,source:ae(e)}))))}(e):async function(e,t){const n=await(0,f.OT)(e.map((async e=>{const n=await async function(e,t){const{parts:n}=e;if(1===n.length)return new he(n[0].partUrl);const r=await e.toBlob(t);return(0,f.k_)(t),he.fromBlob(r)}(e);return(0,f.k_)(t),{name:e.assetName,mimeType:e.assetMimeType,source:n}})));if((0,f.Hc)(t))throw n.forEach((e=>e.source.dispose())),(0,f.zE)();return ue(n)}(e,t)}return ae(e)}(i,r);(0,f.k_)(r);const a=o(new y.Z({x:0,y:0,z:0,spatialReference:e.spatialReference}),s.url,{resolveFile:se(s),requestFile:void 0,useTransform:!0,signal:r?.signal});a.then((()=>s.dispose()),(()=>s.dispose()));const{vertexAttributes:l,components:u}=await a;e.vertexAttributes=l,e.components=u}(this,t,e)),Promise.resolve(this)}addExternalSources(e){this.metadata.externalSources.addMany(e)}updateDisplaySource(e){this.metadata.displaySource=e}clone(){return this.cloneWithVertexSpace(this.vertexSpace.clone())}cloneWithVertexSpace(e){let t=null;if(this.components){const e=new Map,n=new Map;t=this.components.map((t=>t.cloneWithDeduplication(e,n)))}const n={components:t,spatialReference:this.spatialReference,vertexAttributes:this.vertexAttributes.clone(),vertexSpace:e,transform:this.transform?.clone()??null,metadata:this.metadata.clone()};return new Ve(n)}cloneShallow(){return new Ve({components:this.components,spatialReference:this.spatialReference,vertexAttributes:this.vertexAttributes,vertexSpace:this.vertexSpace.clone(),transform:this.transform,metadata:this.metadata})}vertexAttributesChanged(){this.notifyChange("vertexAttributes")}async toBinaryGLTF(e){const t=n.e(7277).then(n.bind(n,7277)),r=this.load(),i=await Promise.all([t,r]),{toBinaryGLTF:o}=i[0];return o(this,e)}get memoryUsage(){let e=0;if(e+=this.vertexAttributes.memoryUsage,null!=this.components)for(const t of this.components)e+=t.memoryUsage;return e}_clearSources(){this.metadata.clearSources()}static createBox(e,t){if(!(e instanceof y.Z))return i.Z.getLogger(Je).error(".createBox()",(new T).message),null;const n=new Ve(Ze(function(){const{faceDescriptions:e,faceVertexOffsets:t,uvScales:n}=Se,r=4*e.length,i=new Float64Array(3*r),o=new Float32Array(3*r),s=new Float32Array(2*r),a=new Uint32Array(2*e.length*3);let l=0,c=0,u=0,h=0;for(let r=0;r<e.length;r++){const f=e[r],p=l/3;for(const e of t)a[h++]=p+e;const d=f.corners;for(let e=0;e<4;e++){const t=d[e];let r=0;s[u++]=.25*n[e][0]+f.uvOrigin[0],s[u++]=f.uvOrigin[1]-.25*n[e][1];for(let e=0;e<3;e++)0!==f.axis[e]?(i[l++]=.5*f.axis[e],o[c++]=f.axis[e]):(i[l++]=.5*t[r++],o[c++]=0)}}return{position:i,normal:o,uv:s,faces:a}}(),e,t));return t&&t.imageFace&&"all"!==t.imageFace?function(e,t){const n=e.components[0],r=n.faces,i=Re[t],o=6*i,s=new Array(6),a=new Array(r.length-6);let l=0,c=0;for(let e=0;e<r.length;e++)e>=o&&e<o+6?s[l++]=r[e]:a[c++]=r[e];if(null!=e.vertexAttributes.uv){const t=new Float32Array(e.vertexAttributes.uv),n=4*i*2,r=[0,1,1,1,1,0,0,0];for(let e=0;e<r.length;e++)t[n+e]=r[e];e.vertexAttributes.uv=t}return e.components=[new w.Z({faces:s,material:n.material}),new w.Z({faces:a})],e}(n,t.imageFace):n}static createSphere(e,t){return e instanceof y.Z?new Ve(Ze(function(e=0){const t=Math.round(8*2**e),n=2*t,r=(t-1)*(n+1)+2*n,i=new Float64Array(3*r),o=new Float32Array(3*r),s=new Float32Array(2*r),a=new Uint32Array((t-1)*n*2*3);let l=0,c=0,u=0,h=0;for(let e=0;e<=t;e++){const r=e/t*Math.PI+.5*Math.PI,f=Math.cos(r),p=Math.sin(r);Oe[2]=p;const d=0===e||e===t,g=d?n-1:n;for(let r=0;r<=g;r++){const p=r/g*2*Math.PI;Oe[0]=-Math.sin(p)*f,Oe[1]=Math.cos(p)*f;for(let e=0;e<3;e++)i[l]=.5*Oe[e],o[l]=Oe[e],++l;s[c++]=(r+(d?.5:0))/n,s[c++]=e/t,0!==e&&r!==n&&(e!==t&&(a[u++]=h,a[u++]=h+1,a[u++]=h-n),1!==e&&(a[u++]=h,a[u++]=h-n,a[u++]=h-n-1)),h++}}return{position:i,normal:o,uv:s,faces:a}}(t&&t.densificationFactor||0),e,t)):(i.Z.getLogger(Je).error(".createSphere()",(new T).message),null)}static createCylinder(e,t){return e instanceof y.Z?new Ve(Ze(function(e=0){const t=Math.round(16*2**e),n=4*(t+1)+2*t,r=new Float64Array(3*n),i=new Float32Array(3*n),o=new Float32Array(2*n),s=new Uint32Array(4*t*3);let a=0,l=0,c=0,u=0,h=0;for(let e=0;e<=5;e++){const n=0===e||5===e,f=e<=1||e>=4,p=2===e||4===e,d=n?t-1:t;for(let g=0;g<=d;g++){const m=g/d*2*Math.PI,y=n?0:.5;Oe[0]=y*Math.sin(m),Oe[1]=y*-Math.cos(m),Oe[2]=e<=2?.5:-.5;for(let t=0;t<3;t++)r[a++]=Oe[t],i[l++]=f?2===t?e<=1?1:-1:0:2===t?0:Oe[t]/y;o[c++]=(g+(n?.5:0))/t,o[c++]=e<=1?1*e/3:e<=3?1*(e-2)/3+1/3:1*(e-4)/3+2/3,p||0===e||g===t||(5!==e&&(s[u++]=h,s[u++]=h+1,s[u++]=h-t),1!==e&&(s[u++]=h,s[u++]=h-t,s[u++]=h-t-1)),h++}}return{position:r,normal:i,uv:o,faces:s}}(t&&t.densificationFactor||0),e,t)):(i.Z.getLogger(Je).error(".createCylinder()",(new T).message),null)}static createPlane(e,t){if(!(e instanceof y.Z))return i.Z.getLogger(Je).error(".createPlane()",(new T).message),null;const n=t?.facing??"up",r=function(e,t){const n="number"==typeof t?t:null!=t?t.width:1,r="number"==typeof t?t:null!=t?t.height:1;switch(e){case"up":case"down":return{width:n,depth:r};case"north":case"south":return{width:n,height:r};case"east":case"west":return{depth:n,height:r}}}(n,t?.size);return new Ve(Ze(function(e){const t=Ce.facingAxisOrderSwap[e],n=Ce.position,r=Ce.normal,i=new Float64Array(n.length),o=new Float32Array(r.length);let s=0;for(let e=0;e<4;e++){const e=s;for(let a=0;a<3;a++){const l=t[a],c=Math.abs(l)-1,u=l>=0?1:-1;i[s]=n[e+c]*u,o[s]=r[e+c]*u,s++}}return{position:i,normal:o,uv:new Float32Array(Ce.uv),faces:new Uint32Array(Ce.faces),isPlane:!0}}(n),e,{...t,size:r}))}static createFromPolygon(e,t){if(!(e instanceof x.Z))return i.Z.getLogger(Je).error(".createFromPolygon()",(new _).message),null;const n=function(e){const t=function(e,t,n,r){const i=e.length,o=new Array(i),s=new Array(i),a=new Array(i);let l=0,c=0,u=0,h=0;for(let t=0;t<i;++t)h+=e[t].length;const f=(0,U.bg)(3*h);let p=0;for(let h=i-1;h>=0;h--){const d=e[h],g=n===V.CCW_IS_HOLE&&$(d,t,r);if(g&&1!==i)o[l++]=d;else{let e=d.length;for(let t=0;t<l;++t)e+=o[t].length;const n={index:p,pathLengths:new Array(l+1),count:e,holeIndices:new Array(l)};n.pathLengths[0]=d.length,d.length>0&&(a[u++]={index:p,count:d.length}),p=g?H(d,d.length-1,-1,f,p,d.length,t):H(d,0,1,f,p,d.length,t);for(let e=0;e<l;++e){const r=o[e];n.holeIndices[e]=p,n.pathLengths[e+1]=r.length,r.length>0&&(a[u++]={index:p,count:r.length}),p=H(r,0,1,f,p,r.length,t)}l=0,n.count>0&&(s[c++]=n)}}for(let e=0;e<l;++e){const n=o[e];n.length>0&&(a[u++]={index:p,count:n.length}),p=H(n,0,1,f,p,n.length,t)}return s.length=c,a.length=u,{position:f,polygons:s,outlines:a}}(e.rings,e.hasZ,V.CCW_IS_HOLE,e.spatialReference),n=new Array;let r=0,i=0;for(const e of t.polygons){const o=e.count,s=e.index,a=(0,U.Rq)(t.position,3*s,3*o),l=e.holeIndices.map((e=>e-s)),c=(0,N.mi)((0,I.e)(a,l,3));n.push({position:a,faces:c}),r+=a.length,i+=c.length}const o=function(e,t,n){if(1===e.length)return e[0];const r=(0,U.bg)(t),i=new Array(n);let o=0,s=0,a=0;for(const t of e){for(let e=0;e<t.position.length;e++)r[o++]=t.position[e];for(const e of t.faces)i[s++]=e+a;a=o/3}return{position:r,faces:(0,N.mi)(i)}}(n,r,i),s=Array.isArray(o.position)?(0,D.d)(o.position,3,{originalIndices:o.faces}):(0,D.d)(o.position.buffer,6,{originalIndices:o.faces});return o.position=(0,U.QZ)(new Float64Array(s.buffer)),o.faces=s.indices,o}(e);return new Ve({vertexAttributes:new F.Q({position:n.position}),components:[new w.Z({faces:n.faces,shading:"flat",material:t?.material??null})],spatialReference:e.spatialReference,vertexSpace:new R.Z})}static async createFromGLTF(e,t,r){if(!(e instanceof y.Z)){const e=new T;throw i.Z.getLogger(Je).error(".createfromGLTF()",e.message),e}const{loadGLTFMesh:o}=await(0,f.Hl)(Promise.all([n.e(8598),n.e(8079)]).then(n.bind(n,78079)),r);return new Ve(await o(e,t,r))}static async createFromFiles(e,t,n){const r=e=>i.Z.getLogger(Je).error(".createFromFiles()",e.message);if(!(e instanceof y.Z)){const e=new T;throw r(e),e}const o=n?.layer;if(!o){const e=new M;throw r(e),e}const s=await Ve.extractAndFilterFiles(t,o),a=s.reduce(((e,t)=>(0,Ge.$z)(o.infoFor3D,t)?e+1:e),0);if(0===a){const e=new C;throw r(e),e}if(a>1){const e=new Z;throw r(e),e}const l=Ve.createWithExternalSource(e,s),[c]=await o.uploadAssets([l],n);return c}static async extractAndFilterFiles(e,t){const n=t?.infoFor3D;return n?(await async function(e){const t=[];for(const n of e)n.name.toLowerCase().endsWith(".zip")?t.push(qe(n)):t.push(Promise.resolve(n));return(await Promise.all(t)).flat()}(e)).filter((e=>(0,Ge.F7)(n,e))):e}static createWithExternalSource(e,t,n){const r=n?.extent??null,{x:i,y:o,z:s,spatialReference:a}=e,l=n?.transform?.clone()??new L.Z,c=n?.vertexSpace??new O.Z({origin:[i,o,s??0]}),u={source:t,extent:r},h=new ge;return h.externalSources.push(u),new Ve({metadata:h,transform:l,vertexSpace:c,spatialReference:a})}static createIncomplete(e,t){const{x:n,y:r,z:i,spatialReference:o}=e,s=t?.transform?.clone()??new L.Z,a=t?.vertexSpace??new O.Z({origin:[n,r,i??0]}),l=new Ve({transform:s,vertexSpace:a,spatialReference:o});return l.addResolvingPromise(Promise.reject(new c.Z("mesh-incomplete","Mesh resources are not complete"))),l}};(0,l._)([(0,d.Cb)({type:[w.Z],json:{write:!0}})],Xe.prototype,"components",void 0),(0,l._)([(0,d.Cb)({nonNullable:!0,types:Ye,constructOnly:!0,json:{write:!0}})],Xe.prototype,"vertexSpace",void 0),(0,l._)([(0,d.Cb)({type:L.Z,json:{write:!0}})],Xe.prototype,"transform",void 0),(0,l._)([(0,d.Cb)({constructOnly:!0})],Xe.prototype,"metadata",void 0),(0,l._)([(0,d.Cb)()],Xe.prototype,"hasExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"_transformedExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"_untransformedExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"anchor",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"origin",null),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1}})],Xe.prototype,"extent",null),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1,write:!0,default:!0}})],Xe.prototype,"hasZ",void 0),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1,write:!0,default:!1}})],Xe.prototype,"hasM",void 0),(0,l._)([(0,d.Cb)({type:F.Q,nonNullable:!0,json:{write:!0}})],Xe.prototype,"vertexAttributes",void 0),Xe=Ve=(0,l._)([(0,g.j)(Je)],Xe);const Ke=(0,s.c)(),Qe=(0,v.Ue)(),et=Xe;var tt=n(82971),nt=n(74889);const rt=()=>i.Z.getLogger("esri.rest.support.meshFeatureSet");function it(e,t,n){const i=n.features;n.features=[],delete n.geometryType;const o=nt.Z.fromJSON(n);if(o.geometryType="mesh",!n.assetMaps)return o;const s=lt(t,n.assetMaps),a=e.sourceSpatialReference??tt.Z.WGS84,l=n.globalIdFieldName,{outFields:c}=e,u=null!=c&&c.length>0?(h=c.includes("*")?null:new Set(c),({attributes:e})=>{if(!e)return{};if(!h)return e;for(const t in e)h.has(t)||delete e[t];return e}):()=>({});var h;for(const e of i){const n=ot(e,l,a,t,s);null!=n&&o.features.push(new r.Z({geometry:n,attributes:u(e)}))}return o}function ot(e,t,n,r,i){const o=e.attributes[t],l=i.get(o);if(null==l)return rt().error("mesh-feature-set:asset-not-found","Service returned a feature which was not found in the asset map",e),null;if(!e.geometry)return rt().error("mesh-feature-set:no-geometry","Service returned a feature without geometry",e),null;const{originPoint:c,originVector:u}=function({attributes:e},t,{transformFieldRoles:n}){const r=e[n.originX],i=e[n.originY],o=e[n.originZ];return{originPoint:new y.Z({x:r,y:i,z:o,spatialReference:t}),originVector:(0,s.f)(r,i,o)}}(e,n,r),h=a.Z.fromJSON(e.geometry);h.spatialReference=n;const f=function(e,{transformFieldRoles:t}){return new L.Z({translation:[e[t.translationX],-e[t.translationZ],e[t.translationY]],rotationAxis:[e[t.rotationX],-e[t.rotationZ],e[t.rotationY]],rotationAngle:e[t.rotationDeg],scale:[e[t.scaleX],e[t.scaleZ],e[t.scaleY]]})}(e.attributes,r),p=l.projectVertices?new S.Z({origin:u}):new O.Z({origin:u}),d=function(e){const t=Array.from(e.files.values()),n=new Array;for(const e of t){if(e.status!==st.COMPLETED)return null;const t=new Array;for(const n of e.parts){if(!n)return null;t.push(new de.LL(n.url,n.hash))}n.push(new de.CP(e.name,e.mimeType,t))}return n}(l);return d?et.createWithExternalSource(c,d,{extent:h,transform:f,vertexSpace:p}):et.createIncomplete(c,{extent:h,transform:f,vertexSpace:p})}var st,at;function lt(e,t){const n=new Map;for(const r of t){const t=r.parentGlobalId;if(null==t)continue;const i=r.assetName,s=r.assetType,a=r.assetHash,l=r.assetURL,c=r.conversionStatus,u=r.seqNo,h=(0,Ge.d1)(s,e.supportedFormats);if(!h){rt().error("mesh-feature-set:unknown-format",`Service returned an asset of type ${s}, but it does not list it as a supported type`);continue}const f=(0,o.s1)(n,t,(()=>({projectVertices:ut(r.flags).projectVertices,files:new Map})));(0,o.s1)(f.files,i,(()=>({name:i,type:s,mimeType:h,status:ct(c),parts:[]}))).parts[u]={hash:a,url:l}}return n}function ct(e){switch(e){case"COMPLETED":case"SUBMITTED":return st.COMPLETED;case"INPROGRESS":return st.PENDING;default:return st.FAILED}}function ut(e){return{projectVertices:e.includes("PROJECT_VERTICES")}}(at=st||(st={}))[at.FAILED=0]="FAILED",at[at.PENDING=1]="PENDING",at[at.COMPLETED=2]="COMPLETED"},17662:(e,t,n)=>{n.d(t,{c:()=>i});var r=n(99001);class i{constructor(){this.id=(0,r.D)()}}},4726:(e,t,n)=>{var r;n.d(t,{U:()=>r}),function(e){e[e.Layer=0]="Layer",e[e.Object=1]="Object",e[e.Mesh=2]="Mesh",e[e.Line=3]="Line",e[e.Point=4]="Point",e[e.Material=5]="Material",e[e.Texture=6]="Texture",e[e.COUNT=7]="COUNT"}(r||(r={}))},22631:(e,t,n)=>{n.d(t,{Z:()=>S});var r=n(13598),i=n(17896),o=n(24882),s=n(1533);function a(e){if(e.length<s.c8)return Array.from(e);if((0,s.kJ)(e))return Float64Array.from(e);if(!("BYTES_PER_ELEMENT"in e))return Array.from(e);switch(e.BYTES_PER_ELEMENT){case 1:return Uint8Array.from(e);case 2:return(0,s.Uc)(e)?Uint16Array.from(e):Int16Array.from(e);case 4:return Float32Array.from(e);default:return Float64Array.from(e)}}var l=n(47026),c=n(44553),u=n(65617),h=n(11726);class f{constructor(e,t,n){this.primitiveIndices=e,this._numIndexPerPrimitive=t,this.position=n,this._children=void 0,(0,h.hu)(e.length>=1),(0,h.hu)(3===n.size||4===n.size);const{data:r,size:o,indices:s}=n;(0,h.hu)(s.length%this._numIndexPerPrimitive==0),(0,h.hu)(s.length>=e.length*this._numIndexPerPrimitive);const a=e.length;let l=o*s[this._numIndexPerPrimitive*e[0]];p.clear(),p.push(l);const c=(0,u.f)(r[l],r[l+1],r[l+2]),f=(0,u.g)(c);for(let t=0;t<a;++t){const n=this._numIndexPerPrimitive*e[t];for(let e=0;e<this._numIndexPerPrimitive;++e){l=o*s[n+e],p.push(l);let t=r[l];c[0]=Math.min(t,c[0]),f[0]=Math.max(t,f[0]),t=r[l+1],c[1]=Math.min(t,c[1]),f[1]=Math.max(t,f[1]),t=r[l+2],c[2]=Math.min(t,c[2]),f[2]=Math.max(t,f[2])}}this.bbMin=c,this.bbMax=f;const d=(0,i.p)((0,u.c)(),this.bbMin,this.bbMax,.5);this.radius=.5*Math.max(Math.max(f[0]-c[0],f[1]-c[1]),f[2]-c[2]);let g=this.radius*this.radius;for(let e=0;e<p.length;++e){l=p.at(e);const t=r[l]-d[0],n=r[l+1]-d[1],i=r[l+2]-d[2],o=t*t+n*n+i*i;if(o<=g)continue;const s=Math.sqrt(o),a=.5*(s-this.radius);this.radius=this.radius+a,g=this.radius*this.radius;const c=a/s;d[0]+=t*c,d[1]+=n*c,d[2]+=i*c}this.center=d,p.clear()}getChildren(){if(this._children||(0,i.a)(this.bbMin,this.bbMax)<=1)return this._children;const e=(0,i.p)((0,u.c)(),this.bbMin,this.bbMax,.5),t=this.primitiveIndices.length,n=new Uint8Array(t),r=new Array(8);for(let e=0;e<8;++e)r[e]=0;const{data:o,size:s,indices:a}=this.position;for(let i=0;i<t;++i){let t=0;const l=this._numIndexPerPrimitive*this.primitiveIndices[i];let c=s*a[l],u=o[c],h=o[c+1],f=o[c+2];for(let e=1;e<this._numIndexPerPrimitive;++e){c=s*a[l+e];const t=o[c],n=o[c+1],r=o[c+2];t<u&&(u=t),n<h&&(h=n),r<f&&(f=r)}u<e[0]&&(t|=1),h<e[1]&&(t|=2),f<e[2]&&(t|=4),n[i]=t,++r[t]}let l=0;for(let e=0;e<8;++e)r[e]>0&&++l;if(l<2)return;const c=new Array(8);for(let e=0;e<8;++e)c[e]=r[e]>0?new Uint32Array(r[e]):void 0;for(let e=0;e<8;++e)r[e]=0;for(let e=0;e<t;++e){const t=n[e];c[t][r[t]++]=this.primitiveIndices[e]}this._children=new Array;for(let e=0;e<8;++e)void 0!==c[e]&&this._children.push(new f(c[e],this._numIndexPerPrimitive,this.position));return this._children}static prune(){p.prune()}}const p=new c.Z({deallocator:null});var d=n(17662),g=n(4726),m=n(22807),y=n(16996);function x(e,t,n){return(0,i.f)(v,t,e),(0,i.f)(w,n,e),(0,i.l)((0,i.b)(v,v,w))/2}n(12981),new m.x(y.Ue),new m.x((()=>{return e?{p0:(0,u.g)(e.p0),p1:(0,u.g)(e.p1),p2:(0,u.g)(e.p2)}:{p0:(0,u.c)(),p1:(0,u.c)(),p2:(0,u.c)()};var e}));const v=(0,u.c)(),w=(0,u.c)(),b=(0,u.c)(),A=(0,u.c)(),_=(0,u.c)(),T=(0,u.c)();var M=n(99001);class C{constructor(e){this.channel=e,this.id=(0,M.D)()}}var Z=n(35065);n(9820),(0,u.c)(),new Float32Array(6);class S extends d.c{constructor(e,t,n=null,r=g.U.Mesh,i=null,s=-1){super(),this.material=e,this.mapPositions=n,this.type=r,this.objectAndLayerIdColor=i,this.edgeIndicesLength=s,this.visible=!0,this._attributes=new Map,this._boundingInfo=null;for(const[e,n]of t)0===n.indices.length&&(n.indices=(0,o.KF)(t[0][1].data.length/3)),this._attributes.set(e,{...n,indices:(0,o.mi)(n.indices)}),e===Z.T.POSITION&&(this.edgeIndicesLength=this.edgeIndicesLength<0?this._attributes.get(e).indices.length:this.edgeIndicesLength)}instantiate(e={}){const t=new S(e.material||this.material,[],this.mapPositions,this.type,this.objectAndLayerIdColor,this.edgeIndicesLength);return this._attributes.forEach(((e,n)=>{e.exclusive=!1,t._attributes.set(n,e)})),t._boundingInfo=this._boundingInfo,t.transformation=e.transformation||this.transformation,t}get attributes(){return this._attributes}getMutableAttribute(e){let t=this._attributes.get(e);return t&&!t.exclusive&&(t={...t,exclusive:!0,data:a(t.data)},this._attributes.set(e,t)),t}setAttributeData(e,t){const n=this._attributes.get(e);n&&this._attributes.set(e,{...n,exclusive:!0,data:t})}get indexCount(){const e=this._attributes.values().next().value.indices;return e?.length??0}get faceCount(){return this.indexCount/3}get boundingInfo(){return null==this._boundingInfo&&(this._boundingInfo=this._calculateBoundingInfo()),this._boundingInfo}computeAttachmentOrigin(e){return!!(this.type===g.U.Mesh?this._computeAttachmentOriginTriangles(e):this.type===g.U.Line?this._computeAttachmentOriginLines(e):this._computeAttachmentOriginPoints(e))&&(null!=this._transformation&&(0,i.e)(e,e,this._transformation),!0)}_computeAttachmentOriginTriangles(e){return function(e,t){if(!e)return!1;const{size:n,data:r,indices:o}=e;(0,i.s)(t,0,0,0),(0,i.s)(T,0,0,0);let s=0,a=0;for(let e=0;e<o.length-2;e+=3){const l=o[e]*n,c=o[e+1]*n,u=o[e+2]*n;(0,i.s)(b,r[l],r[l+1],r[l+2]),(0,i.s)(A,r[c],r[c+1],r[c+2]),(0,i.s)(_,r[u],r[u+1],r[u+2]);const h=x(b,A,_);h?((0,i.g)(b,b,A),(0,i.g)(b,b,_),(0,i.i)(b,b,1/3*h),(0,i.g)(t,t,b),s+=h):((0,i.g)(T,T,b),(0,i.g)(T,T,A),(0,i.g)(T,T,_),a+=3)}return!(0===a&&0===s||(0!==s?((0,i.i)(t,t,1/s),0):0===a||((0,i.i)(t,T,1/a),0)))}(this.attributes.get(Z.T.POSITION),e)}_computeAttachmentOriginLines(e){const t=this.attributes.get(Z.T.POSITION);return function(e,t,n){if(!e)return!1;(0,i.s)(n,0,0,0),(0,i.s)(T,0,0,0);let r=0,o=0;const{size:s,data:a,indices:l}=e,c=l.length-1,u=c+(t?2:0);for(let e=0;e<u;e+=2){const t=e<c?e+1:0,u=l[e<c?e:c]*s,h=l[t]*s;b[0]=a[u],b[1]=a[u+1],b[2]=a[u+2],A[0]=a[h],A[1]=a[h+1],A[2]=a[h+2],(0,i.i)(b,(0,i.g)(b,b,A),.5);const f=(0,i.r)(b,A);f>0?((0,i.g)(n,n,(0,i.i)(b,b,f)),r+=f):0===r&&((0,i.g)(T,T,b),o++)}return 0!==r?((0,i.i)(n,n,1/r),!0):0!==o&&((0,i.i)(n,T,1/o),!0)}(t,function(e,t){return!(!("isClosed"in e)||!e.isClosed)&&t.indices.length>2}(this.material.parameters,t),e)}_computeAttachmentOriginPoints(e){return function(e,t){if(!e)return!1;const{size:n,data:r,indices:o}=e;(0,i.s)(t,0,0,0);let s=-1,a=0;for(let e=0;e<o.length;e++){const i=o[e]*n;s!==i&&(t[0]+=r[i],t[1]+=r[i+1],t[2]+=r[i+2],a++),s=i}return a>1&&(0,i.i)(t,t,1/a),a>0}(this.attributes.get(Z.T.POSITION),e)}invalidateBoundingInfo(){this._boundingInfo=null}_calculateBoundingInfo(){const e=this.attributes.get(Z.T.POSITION);if(!e)return null;const t=this.type===g.U.Mesh?3:1;(0,h.hu)(e.indices.length%t==0,"Indexing error: "+e.indices.length+" not divisible by "+t);const n=(0,o.KF)(e.indices.length/t);return new f(n,t,e)}get transformation(){return this._transformation??r.I}set transformation(e){this._transformation=e&&e!==r.I?(0,r.b)(e):null}addHighlight(){const e=new C(l.V_.Highlight);return this.highlights=function(e,t){return null==e&&(e=[]),e.push(t),e}(this.highlights,e),e}removeHighlight(e){this.highlights=function(e,t){if(null==e)return null;const n=e.filter((e=>e!==t));return 0===n.length?null:n}(this.highlights,e)}}},11726:(e,t,n)=>{n.d(t,{hu:()=>i,yK:()=>o}),n(97323),n(98766),(0,n(88669).c)();class r{constructor(e){this.message=e}toString(){return`AssertException: ${this.message}`}}function i(e,t){if(!e){t=t||"Assertion";const e=new Error(t).stack;throw new r(`${t} at ${e}`)}}function o(e,t,n,r){let i,o=(n[0]-e[0])/t[0],s=(r[0]-e[0])/t[0];o>s&&(i=o,o=s,s=i);let a=(n[1]-e[1])/t[1],l=(r[1]-e[1])/t[1];if(a>l&&(i=a,a=l,l=i),o>l||a>s)return!1;a>o&&(o=a),l<s&&(s=l);let c=(n[2]-e[2])/t[2],u=(r[2]-e[2])/t[2];return c>u&&(i=c,c=u,u=i),!(o>u||c>s||(u<s&&(s=u),s<0))}},47026:(e,t,n)=>{var r,i,o,s,a,l,c,u,h;n.d(t,{Gv:()=>i,Iq:()=>u,JJ:()=>c,Rw:()=>s,Ti:()=>h,V_:()=>l,Vr:()=>r,hU:()=>a}),function(e){e[e.None=0]="None",e[e.Front=1]="Front",e[e.Back=2]="Back",e[e.COUNT=3]="COUNT"}(r||(r={})),function(e){e[e.Less=0]="Less",e[e.Lequal=1]="Lequal",e[e.COUNT=2]="COUNT"}(i||(i={})),function(e){e[e.BACKGROUND=0]="BACKGROUND",e[e.UPDATE=1]="UPDATE"}(o||(o={})),function(e){e[e.NOT_LOADED=0]="NOT_LOADED",e[e.LOADING=1]="LOADING",e[e.LOADED=2]="LOADED"}(s||(s={})),function(e){e[e.IntegratedMeshMaskExcluded=1]="IntegratedMeshMaskExcluded",e[e.OutlineVisualElementMask=2]="OutlineVisualElementMask"}(a||(a={})),function(e){e[e.Highlight=0]="Highlight",e[e.MaskOccludee=1]="MaskOccludee",e[e.COUNT=2]="COUNT"}(l||(l={})),function(e){e[e.Blend=0]="Blend",e[e.Opaque=1]="Opaque",e[e.Mask=2]="Mask",e[e.MaskBlend=3]="MaskBlend",e[e.COUNT=4]="COUNT"}(c||(c={})),function(e){e[e.OFF=0]="OFF",e[e.ON=1]="ON"}(u||(u={})),function(e){e.DDS_ENCODING="image/vnd-ms.dds",e.KTX2_ENCODING="image/ktx2",e.BASIS_ENCODING="image/x.basis"}(h||(h={}))},9820:(e,t,n)=>{function r(e,t){const n=e.length;for(let r=0;r<n;++r)o[0]=e[r],t[r]=o[0];return t}function i(e,t){const n=e.length;for(let r=0;r<n;++r)o[0]=e[r],o[1]=e[r]-o[0],t[r]=o[1];return t}n.d(t,{GB:()=>i,U8:()=>r});const o=new Float32Array(2)}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5613],{95401:(e,t,n)=>{n.d(t,{e:()=>l});var r,i,o,s=n(5732),a={exports:{}};r=a,i=function(){function e(e,n,i){i=i||2;var o,s,a,c,u,h,f,p=n&&n.length,d=p?n[0]*i:e.length,g=t(e,0,d,i,!0),m=[];if(!g||g.next===g.prev)return m;if(p&&(g=l(e,n,g,i)),e.length>80*i){o=a=e[0],s=c=e[1];for(var y=i;y<d;y+=i)(u=e[y])<o&&(o=u),(h=e[y+1])<s&&(s=h),u>a&&(a=u),h>c&&(c=h);f=0!==(f=Math.max(a-o,c-s))?1/f:0}return r(g,m,i,o,s,f),m}function t(e,t,n,r,i){var o,s;if(i===S(e,t,n,r)>0)for(o=t;o<n;o+=r)s=M(o,e[o],e[o+1],s);else for(o=n-r;o>=t;o-=r)s=M(o,e[o],e[o+1],s);if(s&&v(s,s.next)){var a=s.next;C(s),s=a}return s}function n(e,t){if(!e)return e;t||(t=e);var n,r=e;do{if(n=!1,r.steiner||!v(r,r.next)&&0!==x(r.prev,r,r.next))r=r.next;else{var i=r.prev;if(C(r),(r=t=i)===r.next)break;n=!0}}while(n||r!==t);return t}function r(e,t,l,c,u,h,f){if(e){!f&&h&&p(e,c,u,h);for(var d,g,m=e;e.prev!==e.next;)if(d=e.prev,g=e.next,h?o(e,c,u,h):i(e))t.push(d.i/l),t.push(e.i/l),t.push(g.i/l),C(e),e=g.next,m=g.next;else if((e=g)===m){f?1===f?r(e=s(n(e),t,l),t,l,c,u,h,2):2===f&&a(e,t,l,c,u,h):r(n(e),t,l,c,u,h,1);break}}}function i(e){var t=e.prev,n=e,r=e.next;if(x(t,n,r)>=0)return!1;for(var i=e.next.next;i!==e.prev;){if(m(t.x,t.y,n.x,n.y,r.x,r.y,i.x,i.y)&&x(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function o(e,t,n,r){var i=e.prev,o=e,s=e.next;if(x(i,o,s)>=0)return!1;for(var a=i.x<o.x?i.x<s.x?i.x:s.x:o.x<s.x?o.x:s.x,l=i.y<o.y?i.y<s.y?i.y:s.y:o.y<s.y?o.y:s.y,c=i.x>o.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,u=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,h=d(a,l,t,n,r),f=d(c,u,t,n,r),p=e.prevZ,g=e.nextZ;p&&p.z>=h&&g&&g.z<=f;){if(p!==e.prev&&p!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&x(p.prev,p,p.next)>=0)return!1;if(p=p.prevZ,g!==e.prev&&g!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,g.x,g.y)&&x(g.prev,g,g.next)>=0)return!1;g=g.nextZ}for(;p&&p.z>=h;){if(p!==e.prev&&p!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&x(p.prev,p,p.next)>=0)return!1;p=p.prevZ}for(;g&&g.z<=f;){if(g!==e.prev&&g!==e.next&&m(i.x,i.y,o.x,o.y,s.x,s.y,g.x,g.y)&&x(g.prev,g,g.next)>=0)return!1;g=g.nextZ}return!0}function s(e,t,r){var i=e;do{var o=i.prev,s=i.next.next;!v(o,s)&&w(o,i,i.next,s)&&_(o,s)&&_(s,o)&&(t.push(o.i/r),t.push(i.i/r),t.push(s.i/r),C(i),C(i.next),i=e=s),i=i.next}while(i!==e);return n(i)}function a(e,t,i,o,s,a){var l=e;do{for(var c=l.next.next;c!==l.prev;){if(l.i!==c.i&&y(l,c)){var u=T(l,c);return l=n(l,l.next),u=n(u,u.next),r(l,t,i,o,s,a),void r(u,t,i,o,s,a)}c=c.next}l=l.next}while(l!==e)}function l(e,r,i,o){var s,a,l,u=[];for(s=0,a=r.length;s<a;s++)(l=t(e,r[s]*o,s<a-1?r[s+1]*o:e.length,o,!1))===l.next&&(l.steiner=!0),u.push(g(l));for(u.sort(c),s=0;s<u.length;s++)i=n(i=h(u[s],i),i.next);return i}function c(e,t){return e.x-t.x}function u(e){if(e.next.prev===e)return e;let t=e;for(;;){const n=t.next;if(n.prev===t||n===t||n===e)break;t=n}return t}function h(e,t){var r=function(e,t){var n,r=t,i=e.x,o=e.y,s=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var a=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(a<=i&&a>s){if(s=a,a===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==t);if(!n)return null;if(i===s)return n;var l,c=n,u=n.x,h=n.y,p=1/0;r=n;do{i>=r.x&&r.x>=u&&i!==r.x&&m(o<h?i:s,o,u,h,o<h?s:i,o,r.x,r.y)&&(l=Math.abs(o-r.y)/(i-r.x),_(r,e)&&(l<p||l===p&&(r.x>n.x||r.x===n.x&&f(n,r)))&&(n=r,p=l)),r=r.next}while(r!==c);return n}(e,t);if(!r)return t;var i=T(r,e),o=n(r,r.next);let s=u(i);return n(s,s.next),o=u(o),u(t===r?o:t)}function f(e,t){return x(e.prev,e,t.prev)<0&&x(t.next,e,e.next)<0}function p(e,t,n,r){var i=e;do{null===i.z&&(i.z=d(i.x,i.y,t,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==e);i.prevZ.nextZ=null,i.prevZ=null,function(e){var t,n,r,i,o,s,a,l,c=1;do{for(n=e,e=null,o=null,s=0;n;){for(s++,r=n,a=0,t=0;t<c&&(a++,r=r.nextZ);t++);for(l=c;a>0||l>0&&r;)0!==a&&(0===l||!r||n.z<=r.z)?(i=n,n=n.nextZ,a--):(i=r,r=r.nextZ,l--),o?o.nextZ=i:e=i,i.prevZ=o,o=i;n=r}o.nextZ=null,c*=2}while(s>1)}(i)}function d(e,t,n,r,i){return(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)*i)|e<<8))|e<<4))|e<<2))|e<<1))|(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*i)|t<<8))|t<<4))|t<<2))|t<<1))<<1}function g(e){var t=e,n=e;do{(t.x<n.x||t.x===n.x&&t.y<n.y)&&(n=t),t=t.next}while(t!==e);return n}function m(e,t,n,r,i,o,s,a){return(i-s)*(t-a)-(e-s)*(o-a)>=0&&(e-s)*(r-a)-(n-s)*(t-a)>=0&&(n-s)*(o-a)-(i-s)*(r-a)>=0}function y(e,t){return e.next.i!==t.i&&e.prev.i!==t.i&&!function(e,t){var n=e;do{if(n.i!==e.i&&n.next.i!==e.i&&n.i!==t.i&&n.next.i!==t.i&&w(n,n.next,e,t))return!0;n=n.next}while(n!==e);return!1}(e,t)&&(_(e,t)&&_(t,e)&&function(e,t){var n=e,r=!1,i=(e.x+t.x)/2,o=(e.y+t.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==e);return r}(e,t)&&(x(e.prev,e,t.prev)||x(e,t.prev,t))||v(e,t)&&x(e.prev,e,e.next)>0&&x(t.prev,t,t.next)>0)}function x(e,t,n){return(t.y-e.y)*(n.x-t.x)-(t.x-e.x)*(n.y-t.y)}function v(e,t){return e.x===t.x&&e.y===t.y}function w(e,t,n,r){var i=A(x(e,t,n)),o=A(x(e,t,r)),s=A(x(n,r,e)),a=A(x(n,r,t));return i!==o&&s!==a||!(0!==i||!b(e,n,t))||!(0!==o||!b(e,r,t))||!(0!==s||!b(n,e,r))||!(0!==a||!b(n,t,r))}function b(e,t,n){return t.x<=Math.max(e.x,n.x)&&t.x>=Math.min(e.x,n.x)&&t.y<=Math.max(e.y,n.y)&&t.y>=Math.min(e.y,n.y)}function A(e){return e>0?1:e<0?-1:0}function _(e,t){return x(e.prev,e,e.next)<0?x(e,t,e.next)>=0&&x(e,e.prev,t)>=0:x(e,t,e.prev)<0||x(e,e.next,t)<0}function T(e,t){var n=new Z(e.i,e.x,e.y),r=new Z(t.i,t.x,t.y),i=e.next,o=t.prev;return e.next=t,t.prev=e,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function M(e,t,n,r){var i=new Z(e,t,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function C(e){e.next.prev=e.prev,e.prev.next=e.next,e.prevZ&&(e.prevZ.nextZ=e.nextZ),e.nextZ&&(e.nextZ.prevZ=e.prevZ)}function Z(e,t,n){this.i=e,this.x=t,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function S(e,t,n,r){for(var i=0,o=t,s=n-r;o<n;o+=r)i+=(e[s]-e[o])*(e[o+1]+e[s+1]),s=o;return i}return e.deviation=function(e,t,n,r){var i=t&&t.length,o=i?t[0]*n:e.length,s=Math.abs(S(e,0,o,n));if(i)for(var a=0,l=t.length;a<l;a++){var c=t[a]*n,u=a<l-1?t[a+1]*n:e.length;s-=Math.abs(S(e,c,u,n))}var h=0;for(a=0;a<r.length;a+=3){var f=r[a]*n,p=r[a+1]*n,d=r[a+2]*n;h+=Math.abs((e[f]-e[d])*(e[p+1]-e[f+1])-(e[f]-e[p])*(e[d+1]-e[f+1]))}return 0===s&&0===h?0:Math.abs((h-s)/s)},e.flatten=function(e){for(var t=e[0][0].length,n={vertices:[],holes:[],dimensions:t},r=0,i=0;i<e.length;i++){for(var o=0;o<e[i].length;o++)for(var s=0;s<t;s++)n.vertices.push(e[i][o][s]);i>0&&(r+=e[i-1].length,n.holes.push(r))}return n},e},void 0!==(o=i())&&(r.exports=o);const l=(0,s.g)(a.exports)},20773:(e,t,n)=>{n.d(t,{a:()=>a,b:()=>s,c:()=>i,d:()=>u,e:()=>l,n:()=>h,s:()=>c,t:()=>o});var r=n(72220);function i(e,t,n){o(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function o(e,t,n,i=3,o=i){if(e.length/i!==Math.ceil(t.length/o))return r.c.error("source and destination buffers need to have the same number of elements"),e;const s=e.length/i,a=n[0],l=n[1],c=n[2],u=n[4],h=n[5],f=n[6],p=n[8],d=n[9],g=n[10],m=n[12],y=n[13],x=n[14];let v=0,w=0;for(let n=0;n<s;n++){const n=t[v],r=t[v+1],s=t[v+2];e[w]=a*n+u*r+p*s+m,e[w+1]=l*n+h*r+d*s+y,e[w+2]=c*n+f*r+g*s+x,v+=o,w+=i}return e}function s(e,t,n){a(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function a(e,t,n,i=3,o=i){if(e.length/i!==Math.ceil(t.length/o))return void r.c.error("source and destination buffers need to have the same number of elements");const s=e.length/i,a=n[0],l=n[1],c=n[2],u=n[3],h=n[4],f=n[5],p=n[6],d=n[7],g=n[8];let m=0,y=0;for(let n=0;n<s;n++){const n=t[m],r=t[m+1],s=t[m+2];e[y]=a*n+u*r+p*s,e[y+1]=l*n+h*r+d*s,e[y+2]=c*n+f*r+g*s,m+=o,y+=i}}function l(e,t,n){c(e.typedBuffer,t,n,e.typedBufferStride)}function c(e,t,n,r=3){const i=Math.min(e.length/r,t.count),o=t.typedBuffer,s=t.typedBufferStride;let a=0,l=0;for(let t=0;t<i;t++)e[l]=n*o[a],e[l+1]=n*o[a+1],e[l+2]=n*o[a+2],a+=s,l+=r}function u(e,t){h(e.typedBuffer,t.typedBuffer,e.typedBufferStride,t.typedBufferStride)}function h(e,t,n=3,r=n){const i=Math.min(e.length/n,t.length/r);let o=0,s=0;for(let a=0;a<i;a++){const i=t[o],a=t[o+1],l=t[o+2],c=i*i+a*a+l*l;if(c>0){const t=1/Math.sqrt(c);e[s]=t*i,e[s+1]=t*a,e[s+2]=t*l}o+=r,s+=n}}Object.freeze(Object.defineProperty({__proto__:null,normalize:h,normalizeView:u,scale:c,scaleView:l,shiftRight:function(e,t,n){const r=Math.min(e.count,t.count),i=e.typedBuffer,o=e.typedBufferStride,s=t.typedBuffer,a=t.typedBufferStride;let l=0,c=0;for(let e=0;e<r;e++)i[c]=s[l]>>n,i[c+1]=s[l+1]>>n,i[c+2]=s[l+2]>>n,l+=a,c+=o},transformMat3:a,transformMat3View:s,transformMat4:o,transformMat4View:i},Symbol.toStringTag,{value:"Module"}))},70163:(e,t,n)=>{n.d(t,{Jl:()=>u,n$:()=>h});var r=n(3172),i=n(20102),o=n(95330),s=n(17452),a=n(49917);let l=null,c=!0;function u(e,t,n,r){if(!t||!n)throw new Error("Cannot construct image data without dimensions");if(c)try{return new ImageData(e,t,n)}catch(e){c=!1}const i=function(e,t,n){return n||(l||(l=document.createElement("canvas"),l.width=1,l.height=1),n=l),n.getContext("2d").createImageData(e,t)}(t,n,r);return i.data.set(e,0),i}async function h(e,t){const{arrayBuffer:l,mediaType:c}=await async function(e,t){const n=(0,s.sJ)(e);if(n?.isBase64)return{arrayBuffer:(0,a.R)(n.data),mediaType:n.mediaType};const i=await(0,r.Z)(e,{responseType:"array-buffer",...t});return{arrayBuffer:i.data,mediaType:i.getHeader("Content-Type")}}(e,t),u="image/png"===c;if("image/gif"===c){const{isAnimatedGIF:e,parseGif:r}=await n.e(3310).then(n.bind(n,83310));if(e(l))return r(l,t)}if(u){const{isAnimatedPNG:e,parseApng:r}=await n.e(4492).then(n.bind(n,54492));if(e(l))return r(l,t)}return async function(e,t){const n=window.URL.createObjectURL(e);try{const{data:e}=await(0,r.Z)(n,{...t,responseType:"image"});return e}catch(e){if(!(0,o.D_)(e))throw new i.Z("invalid-image",`Could not fetch requested image at ${n}`);throw e}finally{window.URL.revokeObjectURL(n)}}(new Blob([l],{type:c}),t)}},83025:(e,t,n)=>{n.d(t,{JK:()=>a,QZ:()=>o,Rq:()=>s,bg:()=>i,mB:()=>l});var r=n(1533);function i(e,t=!1){return e<=r.c8?t?new Array(e).fill(0):new Array(e):new Float64Array(e)}function o(e){return((0,r.kJ)(e)?e.length:e.byteLength/8)<=r.c8?Array.from(e):new Float64Array(e)}function s(e,t,n){return Array.isArray(e)?e.slice(t,t+n):e.subarray(t,t+n)}function a(e,t){for(let n=0;n<t.length;++n)e[n]=t[n];return e}function l(e){return Array.isArray(e)?new Float64Array(e):e}},24882:(e,t,n)=>{n.d(t,{$z:()=>s,KF:()=>u,mi:()=>i});var r=n(1533);function i(e){return(0,r.kJ)(e)?e.length<r.c8?e:o(e):e.length<r.c8?Array.from(e):e.BYTES_PER_ELEMENT===Uint16Array.BYTES_PER_ELEMENT?e:o(e)}function o(e){let t=!0;for(const n of e){if(n>=65536)return(0,r.kJ)(e)?new Uint32Array(e):e;n>=256&&(t=!1)}return t?new Uint8Array(e):new Uint16Array(e)}function s(e){return e<=r.c8?new Array(e):e<=65536?new Uint16Array(e):new Uint32Array(e)}let a=(()=>{const e=new Uint32Array(131072);for(let t=0;t<e.length;++t)e[t]=t;return e})();const l=[0],c=(()=>{const e=new Uint16Array(65536);for(let t=0;t<e.length;++t)e[t]=t;return e})();function u(e){if(1===e)return l;if(e<r.c8)return Array.from(new Uint16Array(c.buffer,0,e));if(e<c.length)return new Uint16Array(c.buffer,0,e);if(e>a.length){const t=Math.max(2*a.length,e);a=new Uint32Array(t);for(let e=0;e<a.length;e++)a[e]=e}return new Uint32Array(a.buffer,0,e)}new Uint8Array(65536)},62540:(e,t,n)=>{n.d(t,{Z:()=>x});var r,i=n(43697),o=n(96674),s=n(22974),a=n(92604),l=n(5600),c=n(90578),u=n(52011),h=n(75215),f=n(65542),p=n(60746),d=n(71630);const g="esri.geometry.support.MeshComponent",m=a.Z.getLogger(g);let y=r=class extends o.wq{static from(e){return(0,h.TJ)(r,e)}constructor(e){super(e),this.faces=null,this.material=null,this.name=void 0,this.shading="source",this.trustSourceNormals=!1}castFaces(e){return(0,d.X)(e,Uint32Array,[Uint16Array],{loggerTag:".faces=",stride:3},m)}castMaterial(e){return(0,h.TJ)(e&&"object"==typeof e&&("metallic"in e||"roughness"in e||"metallicRoughnessTexture"in e)?p.Z:f.Z,e)}clone(){return new r({faces:(0,s.d9)(this.faces),shading:this.shading,material:(0,s.d9)(this.material),trustSourceNormals:this.trustSourceNormals,name:this.name})}cloneWithDeduplication(e,t){const n={faces:(0,s.d9)(this.faces),shading:this.shading,material:this.material?this.material.cloneWithDeduplication(e,t):null,trustSourceNormals:this.trustSourceNormals,name:this.name};return new r(n)}get memoryUsage(){let e=0;return null!=this.faces&&(e+=this.faces.byteLength),null!=this.material&&(e+=this.material.memoryUsage),e}};(0,i._)([(0,l.Cb)({json:{write:!0}})],y.prototype,"faces",void 0),(0,i._)([(0,c.p)("faces")],y.prototype,"castFaces",null),(0,i._)([(0,l.Cb)({type:f.Z,json:{write:!0}})],y.prototype,"material",void 0),(0,i._)([(0,c.p)("material")],y.prototype,"castMaterial",null),(0,i._)([(0,l.Cb)()],y.prototype,"name",void 0),(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"shading",void 0),(0,i._)([(0,l.Cb)({type:Boolean})],y.prototype,"trustSourceNormals",void 0),y=r=(0,i._)([(0,u.j)(g)],y);const x=y},85872:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(36030)),l=n(52011),c=n(65617),u=n(94139);let h=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.type="georeferenced-relative",this.isRelative=!0,this.isGeoreferenced=!0,this.origin=(0,c.c)()}getOriginPoint(e){const[t,n,r]=this.origin;return new u.Z({x:t,y:n,z:r,spatialReference:e})}setOriginFromPoint({x:e,y:t,z:n}){this.origin=(0,c.f)(e,t,n??0)}};(0,r._)([(0,a.J)({georeferencedRelative:"georeferenced-relative"},{readOnly:!0})],h.prototype,"type",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,r._)([(0,l.j)("esri.geometry.support.MeshGeoreferencedRelativeVertexSpace")],h);const f=h},84555:(e,t,n)=>{n.d(t,{Z:()=>f});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(36030)),l=n(52011),c=n(65617),u=n(94139);let h=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.type="local",this.isRelative=!0,this.isGeoreferenced=!1,this.origin=(0,c.c)()}getOriginPoint(e){const[t,n,r]=this.origin;return new u.Z({x:t,y:n,z:r,spatialReference:e})}setOriginFromPoint({x:e,y:t,z:n}){this.origin=(0,c.f)(e,t,n??0)}};(0,r._)([(0,a.J)({local:"local"},{readOnly:!0})],h.prototype,"type",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,r._)([(0,l.j)("esri.geometry.support.MeshLocalVertexSpace")],h);const f=h},65542:(e,t,n)=>{n.d(t,{Z:()=>f});var r,i=n(43697),o=n(22303),s=n(96674),a=n(5600),l=(n(75215),n(67676),n(80442),n(52011)),c=n(85965),u=n(80218);let h=r=class extends s.wq{constructor(e){super(e),this.color=null,this.colorTexture=null,this.colorTextureTransform=null,this.normalTexture=void 0,this.normalTextureTransform=void 0,this.alphaMode="auto",this.alphaCutoff=.5,this.doubleSided=!0}clone(){return this.cloneWithDeduplication(null,new Map)}cloneWithDeduplication(e,t){const n=null!=e?e.get(this):null;if(n)return n;const i=new r(this.clonePropertiesWithDeduplication(t));return null!=e&&e.set(this,i),i}clonePropertiesWithDeduplication(e){return{color:null!=this.color?this.color.clone():null,colorTexture:this.colorTexture?.cloneWithDeduplication(e),normalTexture:this.normalTexture?.cloneWithDeduplication(e),alphaMode:this.alphaMode,alphaCutoff:this.alphaCutoff,doubleSided:this.doubleSided,colorTextureTransform:this.colorTextureTransform?.clone(),normalTextureTransform:this.normalTextureTransform?.clone()}}get memoryUsage(){return this.getMemoryUsage()}getMemoryUsage(){let e=0;return e+=null!=this.color?16:0,null!=this.colorTexture&&(e+=this.colorTexture.memoryUsage),e+=null!=this.colorTextureTransform?20:0,null!=this.normalTexture&&(e+=this.normalTexture.memoryUsage),e+=null!=this.normalTextureTransform?20:0,e}};(0,i._)([(0,a.Cb)({type:o.Z,json:{write:!0}})],h.prototype,"color",void 0),(0,i._)([(0,a.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"colorTexture",void 0),(0,i._)([(0,a.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"colorTextureTransform",void 0),(0,i._)([(0,a.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"normalTexture",void 0),(0,i._)([(0,a.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"normalTextureTransform",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"alphaMode",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"alphaCutoff",void 0),(0,i._)([(0,a.Cb)({nonNullable:!0,json:{write:!0}})],h.prototype,"doubleSided",void 0),h=r=(0,i._)([(0,l.j)("esri.geometry.support.MeshMaterial")],h);const f=h},60746:(e,t,n)=>{n.d(t,{Z:()=>f});var r,i=n(43697),o=n(22303),s=n(5600),a=(n(75215),n(67676),n(80442),n(52011)),l=n(65542),c=n(85965),u=n(80218);let h=r=class extends l.Z{constructor(e){super(e),this.emissiveColor=null,this.emissiveTexture=null,this.emissiveTextureTransform=void 0,this.occlusionTexture=null,this.occlusionTextureTransform=void 0,this.metallic=1,this.roughness=1,this.metallicRoughnessTexture=null,this.metallicRoughnessTextureTransform=void 0}clone(){return this.cloneWithDeduplication(null,new Map)}cloneWithDeduplication(e,t){const n=null!=e?e.get(this):null;if(n)return n;const i=new r(this.clonePropertiesWithDeduplication(t));return null!=e&&e.set(this,i),i}getMemoryUsage(){let e=super.getMemoryUsage();return e+=null!=this.emissiveColor?16:0,null!=this.emissiveTexture&&(e+=this.emissiveTexture.memoryUsage),e+=null!=this.emissiveTextureTransform?20:0,null!=this.occlusionTexture&&(e+=this.occlusionTexture.memoryUsage),e+=null!=this.occlusionTextureTransform?20:0,null!=this.metallicRoughnessTexture&&(e+=this.metallicRoughnessTexture.memoryUsage),e+=null!=this.metallicRoughnessTextureTransform?20:0,e}clonePropertiesWithDeduplication(e){return{...super.clonePropertiesWithDeduplication(e),emissiveColor:this.emissiveColor?.clone(),emissiveTexture:this.emissiveTexture?.cloneWithDeduplication(e),emissiveTextureTransform:this.emissiveTextureTransform?.clone(),occlusionTexture:this.occlusionTexture?.cloneWithDeduplication(e),occlusionTextureTransform:this.occlusionTextureTransform?.clone(),metallic:this.metallic,roughness:this.roughness,metallicRoughnessTexture:this.metallicRoughnessTexture?.cloneWithDeduplication(e),metallicRoughnessTextureTransform:this.metallicRoughnessTextureTransform?.clone()}}};(0,i._)([(0,s.Cb)({type:o.Z,json:{write:!0}})],h.prototype,"emissiveColor",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"emissiveTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"emissiveTextureTransform",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"occlusionTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"occlusionTextureTransform",void 0),(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"metallic",void 0),(0,i._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"roughness",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],h.prototype,"metallicRoughnessTexture",void 0),(0,i._)([(0,s.Cb)({type:u.Z,json:{write:!0}})],h.prototype,"metallicRoughnessTextureTransform",void 0),h=r=(0,i._)([(0,a.j)("esri.geometry.support.MeshMaterialMetallicRoughness")],h);const f=h},85965:(e,t,n)=>{n.d(t,{Z:()=>m});var r,i=n(43697),o=(n(80442),n(70163)),s=n(96674),a=n(5600),l=n(75215),c=(n(67676),n(71715)),u=n(52011),h=n(30556),f=n(25929);const p=new WeakMap;let d=0,g=r=class extends s.wq{constructor(e){super(e),this.wrap="repeat"}get url(){return this._get("url")||null}set url(e){this._set("url",e),e&&this._set("data",null)}get data(){return this._get("data")||null}set data(e){this._set("data",e),e&&this._set("url",null)}writeData(e,t,n,r){if(e instanceof HTMLImageElement){const i={type:"image-element",src:(0,f.t)(e.src,r),crossOrigin:e.crossOrigin};t[n]=i}else if(e instanceof HTMLCanvasElement){const r=e.getContext("2d").getImageData(0,0,e.width,e.height),i={type:"canvas-element",imageData:this._encodeImageData(r)};t[n]=i}else if(e instanceof HTMLVideoElement){const i={type:"video-element",src:(0,f.t)(e.src,r),autoplay:e.autoplay,loop:e.loop,muted:e.muted,crossOrigin:e.crossOrigin,preload:e.preload};t[n]=i}else if(e instanceof ImageData){const r={type:"image-data",imageData:this._encodeImageData(e)};t[n]=r}}readData(e){switch(e.type){case"image-element":{const t=new Image;return t.src=e.src,t.crossOrigin=e.crossOrigin,t}case"canvas-element":{const t=this._decodeImageData(e.imageData),n=document.createElement("canvas");return n.width=t.width,n.height=t.height,n.getContext("2d").putImageData(t,0,0),n}case"image-data":return this._decodeImageData(e.imageData);case"video-element":{const t=document.createElement("video");return t.src=e.src,t.crossOrigin=e.crossOrigin,t.autoplay=e.autoplay,t.loop=e.loop,t.muted=e.muted,t.preload=e.preload,t}default:return}}get transparent(){const e=this.data,t=this.url;if(e instanceof HTMLCanvasElement)return this._imageDataContainsTransparent(e.getContext("2d").getImageData(0,0,e.width,e.height));if(e instanceof ImageData)return this._imageDataContainsTransparent(e);if(t){const e=t.substr(t.length-4,4).toLowerCase(),n=t.substr(0,15).toLocaleLowerCase();if(".png"===e||"data:image/png;"===n)return!0}return!1}set transparent(e){this._overrideIfSome("transparent",e)}get contentHash(){const e="string"==typeof this.wrap?this.wrap:"object"==typeof this.wrap?`${this.wrap.horizontal}/${this.wrap.vertical}`:"",t=(t="")=>`d:${t},t:${this.transparent},w:${e}`;return null!=this.url?t(this.url):null!=this.data?this.data instanceof HTMLImageElement||this.data instanceof HTMLVideoElement?t(this.data.src):(p.has(this.data)||p.set(this.data,++d),t(p.get(this.data))):t()}get memoryUsage(){let e=0;if(e+=null!=this.url?this.url.length:0,null!=this.data){const t=this.data;"data"in t?e+=t.data.byteLength:t instanceof HTMLImageElement?e+=t.naturalWidth*t.naturalHeight*3:t instanceof HTMLCanvasElement&&(e+=t.width*t.height*3)}return e}clone(){const e={url:this.url,data:this.data,wrap:this._cloneWrap()};return new r(e)}cloneWithDeduplication(e){const t=e.get(this);if(t)return t;const n=this.clone();return e.set(this,n),n}_cloneWrap(){return"string"==typeof this.wrap?this.wrap:{horizontal:this.wrap.horizontal,vertical:this.wrap.vertical}}_encodeImageData(e){let t="";for(let n=0;n<e.data.length;n++)t+=String.fromCharCode(e.data[n]);return{data:btoa(t),width:e.width,height:e.height}}_decodeImageData(e){const t=atob(e.data),n=new Uint8ClampedArray(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return(0,o.Jl)(n,e.width,e.height)}_imageDataContainsTransparent(e){for(let t=3;t<e.data.length;t+=4)if(255!==e.data[t])return!0;return!1}static from(e){return"string"==typeof e?new r({url:e}):e instanceof HTMLImageElement||e instanceof HTMLCanvasElement||e instanceof ImageData||e instanceof HTMLVideoElement?new r({data:e}):(0,l.TJ)(r,e)}};(0,i._)([(0,a.Cb)({type:String,json:{write:f.w}})],g.prototype,"url",null),(0,i._)([(0,a.Cb)({json:{write:{overridePolicy(){return{enabled:!this.url}}}}}),(0,a.Cb)()],g.prototype,"data",null),(0,i._)([(0,h.c)("data")],g.prototype,"writeData",null),(0,i._)([(0,c.r)("data")],g.prototype,"readData",null),(0,i._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy(){return{enabled:this._isOverridden("transparent")}}}}})],g.prototype,"transparent",null),(0,i._)([(0,a.Cb)({json:{write:!0}})],g.prototype,"wrap",void 0),(0,i._)([(0,a.Cb)({readOnly:!0})],g.prototype,"contentHash",null),g=r=(0,i._)([(0,u.j)("esri.geometry.support.MeshTexture")],g);const m=g},80218:(e,t,n)=>{n.d(t,{Z:()=>c});var r=n(43697),i=n(2368),o=n(96674),s=n(5600),a=(n(75215),n(67676),n(80442),n(52011));let l=class extends((0,i.J)(o.wq)){constructor(e){super(e),this.offset=[0,0],this.rotation=0,this.scale=[1,1]}};(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],l.prototype,"offset",void 0),(0,r._)([(0,s.Cb)({type:Number,nonNullable:!0,json:{write:!0}})],l.prototype,"rotation",void 0),(0,r._)([(0,s.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],l.prototype,"scale",void 0),l=(0,r._)([(0,a.j)("esri.geometry.support.MeshTextureTransform")],l);const c=l},71630:(e,t,n)=>{n.d(t,{Q:()=>p,X:()=>g});var r,i=n(43697),o=n(96674),s=n(22974),a=n(92604),l=n(5600),c=n(90578),u=n(52011);const h="esri.geometry.support.MeshVertexAttributes",f=a.Z.getLogger(h);let p=r=class extends o.wq{constructor(e){super(e),this.color=null,this.position=new Float64Array(0),this.uv=null,this.normal=null,this.tangent=null}castColor(e){return g(e,Uint8Array,[Uint8ClampedArray],{loggerTag:".color=",stride:4},f)}castPosition(e){return e&&e instanceof Float32Array&&f.warn(".position=","Setting position attribute from a Float32Array may cause precision problems. Consider storing data in a Float64Array or a regular number array"),g(e,Float64Array,[Float32Array],{loggerTag:".position=",stride:3},f)}castUv(e){return g(e,Float32Array,[Float64Array],{loggerTag:".uv=",stride:2},f)}castNormal(e){return g(e,Float32Array,[Float64Array],{loggerTag:".normal=",stride:3},f)}castTangent(e){return g(e,Float32Array,[Float64Array],{loggerTag:".tangent=",stride:4},f)}clone(){const e={position:(0,s.d9)(this.position),uv:(0,s.d9)(this.uv),normal:(0,s.d9)(this.normal),tangent:(0,s.d9)(this.tangent),color:(0,s.d9)(this.color)};return new r(e)}clonePositional(){const e={position:(0,s.d9)(this.position),normal:(0,s.d9)(this.normal),tangent:(0,s.d9)(this.tangent),uv:this.uv,color:this.color};return new r(e)}get memoryUsage(){let e=0;return e+=this.position.byteLength,null!=this.uv&&(e+=this.uv.byteLength),null!=this.normal&&(e+=this.normal.byteLength),null!=this.tangent&&(e+=this.tangent.byteLength),null!=this.color&&(e+=this.color.byteLength),e}};function d(e,t,n,r){const{loggerTag:i,stride:o}=t;return e.length%o!=0?(r.error(i,`Invalid array length, expected a multiple of ${o}`),new n([])):e}function g(e,t,n,r,i){if(!e)return e;if(e instanceof t)return d(e,r,t,i);for(const o of n)if(e instanceof o)return d(new t(e),r,t,i);if(Array.isArray(e))return d(new t(e),r,t,i);{const r=n.map((e=>`'${e.name}'`));return i.error(`Failed to set property, expected one of ${r}, but got ${e.constructor.name}`),new t([])}}function m(e,t,n){t[n]=function(e){const t=new Array(e.length);for(let n=0;n<e.length;n++)t[n]=e[n];return t}(e)}(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"color",void 0),(0,i._)([(0,c.p)("color")],p.prototype,"castColor",null),(0,i._)([(0,l.Cb)({nonNullable:!0,json:{write:m}})],p.prototype,"position",void 0),(0,i._)([(0,c.p)("position")],p.prototype,"castPosition",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"uv",void 0),(0,i._)([(0,c.p)("uv")],p.prototype,"castUv",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"normal",void 0),(0,i._)([(0,c.p)("normal")],p.prototype,"castNormal",null),(0,i._)([(0,l.Cb)({json:{write:m}})],p.prototype,"tangent",void 0),(0,i._)([(0,c.p)("tangent")],p.prototype,"castTangent",null),p=r=(0,i._)([(0,u.j)(h)],p)},72220:(e,t,n)=>{n.d(t,{c:()=>r});const r=n(92604).Z.getLogger("esri.views.3d.support.buffer.math")},16996:(e,t,n)=>{n.d(t,{Ue:()=>l,nF:()=>u,zk:()=>c});var r=n(22021),i=n(22807),o=n(17896),s=n(65617),a=n(12981);function l(e){return e?{origin:(0,s.g)(e.origin),vector:(0,s.g)(e.vector)}:{origin:(0,s.c)(),vector:(0,s.c)()}}function c(e,t,n=l()){return(0,o.c)(n.origin,e),(0,o.f)(n.vector,t,e),n}function u(e,t,n){return function(e,t,n,i,s){const{vector:l,origin:c}=e,u=(0,o.f)(a.WM.get(),t,c),h=(0,o.j)(l,u)/(0,o.m)(l);return(0,o.i)(s,l,(0,r.uZ)(h,0,1)),(0,o.g)(s,s,e.origin)}(e,t,0,0,n)}(0,s.c)(),(0,s.c)(),new i.x((()=>l()))},84470:(e,t,n)=>{n.d(t,{CP:()=>a,JG:()=>d,LL:()=>l,NZ:()=>c,fV:()=>g,vj:()=>y,yT:()=>v,zE:()=>x});var r=n(3172),i=n(67676),o=n(95330),s=n(2981);class a{constructor(e,t,n){this.assetName=e,this.assetMimeType=t,this.parts=n}equals(e){return this===e||this.assetName===e.assetName&&this.assetMimeType===e.assetMimeType&&(0,i.fS)(this.parts,e.parts,((e,t)=>e.equals(t)))}isOnService(e){return this.parts.every((t=>t.isOnService(e)))}makeHash(){let e="";for(const t of this.parts)e+=t.partHash;return e}async toBlob(e){const{parts:t}=this;if(1===t.length)return t[0].toBlob(e);const n=await Promise.all(t.map((t=>t.toBlob(e))));return(0,o.k_)(e),new Blob(n)}}class l{constructor(e,t){this.partUrl=e,this.partHash=t}equals(e){return this===e||this.partUrl===e.partUrl&&this.partHash===e.partHash}isOnService(e){return this.partUrl.startsWith(`${e.path}/assets/`)}async toBlob(e){const{data:t}=await(0,r.Z)(this.partUrl,{responseType:"blob"});return(0,o.k_)(e),t}}function c(e){return function(e){return!!e&&(Array.isArray(e)?e.some(p):p(e))}(e?.source)}function u(e){return!!Array.isArray(e)&&e.every((e=>e instanceof a))}const h=/^(model\/gltf\+json)|(model\/gltf-binary)$/,f=/\.(gltf|glb)/i;function p(e){if(e instanceof File){const{type:t,name:n}=e;return h.test(t)||f.test(n)}return h.test(e.assetMimeType)||f.test(e.assetName)}function d(e,t){if(!e)return!1;const{source:n}=e;return function(e,t){if(Array.isArray(e)){const n=e;return n.length>0&&n.every((e=>m(e,t)))}return m(e,t)}(n,t)}function g(e,t){if(e===t)return!0;const{source:n}=e,{source:r}=t;if(n===r)return!0;if(u(n)&&u(r)){if(n.length!==r.length)return!1;const e=(e,t)=>e.assetName<t.assetName?-1:e.assetName>t.assetName?1:0,t=[...n].sort(e),i=[...r].sort(e);for(let e=0;e<t.length;++e)if(!t[e].equals(i[e]))return!1;return!0}return!1}function m(e,t){return e instanceof a&&e.isOnService(t)}function y(e,t){return e instanceof File?(0,s.dm)(e,t):(0,s.S0)(e.assetMimeType,t)??(0,s.Ow)(e.assetName,t)}function x(e){return Array.isArray(e)?e:[e]}function v(e){return!!e.original}},47545:(e,t,n)=>{n.d(t,{d:()=>o});var r=n(22021),i=n(24882);function o(e,t,n){const o=Array.isArray(e),u=o?e.length/t:e.byteLength/(4*t),h=o?e:new Uint32Array(e,0,u*t),f=n?.minReduction??0,p=n?.originalIndices||null,d=p?p.length:0,g=n?.componentOffsets||null;let m=0;if(g)for(let e=0;e<g.length-1;e++){const t=g[e+1]-g[e];t>m&&(m=t)}else m=u;const y=Math.floor(1.1*m)+1;(null==c||c.length<2*y)&&(c=new Uint32Array((0,r.Sf)(2*y)));for(let e=0;e<2*y;e++)c[e]=0;let x=0;const v=!!g&&!!p,w=v?d:u;let b=(0,i.$z)(u);const A=new Uint32Array(d),_=1.96;let T=0!==f?Math.ceil(4*_*_/(f*f)*f*(1-f)):w,M=1,C=g?g[1]:w;for(let e=0;e<w;e++){if(e===T){const t=1-x/e;if(t+_*Math.sqrt(t*(1-t)/e)<f)return null;T*=2}if(e===C){for(let e=0;e<2*y;e++)c[e]=0;if(p)for(let e=g[M-1];e<g[M];e++)A[e]=b[p[e]];C=g[++M]}const n=v?p[e]:e,r=n*t,i=l(h,r,t);let o=i%y,a=x;for(;0!==c[2*o+1];){if(c[2*o]===i){const e=c[2*o+1]-1;if(s(h,r,e*t,t)){a=b[e];break}}o++,o>=y&&(o-=y)}a===x&&(c[2*o]=i,c[2*o+1]=n+1,x++),b[n]=a}if(0!==f&&1-x/u<f)return null;if(v){for(let e=g[M-1];e<A.length;e++)A[e]=b[p[e]];b=(0,i.mi)(A)}const Z=o?new Array(x):new Uint32Array(x*t);x=0;for(let e=0;e<w;e++)b[e]===x&&(a(h,(v?p[e]:e)*t,Z,x*t,t),x++);if(p&&!v){const e=new Uint32Array(d);for(let t=0;t<e.length;t++)e[t]=b[p[t]];b=(0,i.mi)(e)}return{buffer:Array.isArray(Z)?Z:Z.buffer,indices:b,uniqueCount:x}}function s(e,t,n,r){for(let i=0;i<r;i++)if(e[t+i]!==e[n+i])return!1;return!0}function a(e,t,n,r,i){for(let o=0;o<i;o++)n[r+o]=e[t+o]}function l(e,t,n){let r=0;for(let i=0;i<n;i++)r=e[t+i]+r|0,r=r+(r<<11)+(r>>>2)|0;return r>>>0}let c=null},25158:(e,t,n)=>{n.r(t),n.d(t,{assetMapFromAssetMapsJSON:()=>lt,extractMesh:()=>ot,meshFeatureSetFromJSON:()=>it});var r=n(38171),i=n(92604),o=n(30175),s=n(65617),a=n(6570),l=n(43697),c=n(20102),u=n(83379),h=n(609),f=n(95330),p=n(17445),d=n(5600),g=(n(75215),n(67676),n(80442),n(52011)),m=n(9361),y=n(94139),x=n(38913),v=n(3709),w=n(62540);class b extends c.Z{constructor(){super("mesh-not-loaded","Mesh must be loaded before applying operations")}}class A extends c.Z{constructor(){super("component-not-found","Provided component is not part of the list of components")}}class _ extends c.Z{constructor(){super("invalid-polygon","expected polygon to be a Polygon instance")}}class T extends c.Z{constructor(){super("invalid-input:location","Expected location to be a Point instance")}}class M extends c.Z{constructor(){super("invalid-input:no-layer","A layer is needed to convert the files")}}class C extends c.Z{constructor(){super("invalid-input:no-model","No supported model found")}}class Z extends c.Z{constructor(){super("invalid-input:multiple-models","Multiple supported models found")}}var S=n(85872),R=n(50567),O=n(84555),L=n(2674),F=n(71630),I=n(95401),E=n(62155),P=n(86662),U=n(83025),N=n(24882),D=n(47545),j=(n(66577),n(22021)),k=n(67900),B=n(17896),z=n(62073);n(4726),n(22631),n(35065);const W=(0,z.Ue)();function H(e,t,n,r,i,o,s){i*=3;for(let a=0;a<o;++a){const o=e[t];r[i++]=o[0],r[i++]=o[1],r[i++]=s?o[2]:0,t+=n}return i/3}function $(e,t,n){if(t){const t=function(e,t,n){const r=function(e,t,n,r){const i=(e=>!Array.isArray(e[0]))(t)?(e,n)=>t[3*e+n]:(e,n)=>t[e][n],o=r?(0,k.c9)(r)/(0,k._R)(r):1;return(0,z.zu)(e,((e,t)=>(0,B.s)(e,i(t,0)*o,i(t,1)*o,i(t,2))),n)}(W,e,t,n)?(0,z.mJ)(W):[0,0,1];return Math.abs(r[2])>Math.cos((0,j.Vl)(80))?E.R.Z:Math.abs(r[1])>Math.abs(r[0])?E.R.Y:E.R.X}(e,e.length-1,n);if(t===E.R.X)return!(0,P.bu)(e,E.R.Y,E.R.Z);if(t===E.R.Y)return!(0,P.bu)(e,E.R.X,E.R.Z)}return!(0,P.bu)(e,E.R.X,E.R.Y)}var V,G;(G=V||(V={}))[G.NONE=0]="NONE",G[G.CCW_IS_HOLE=1]="CCW_IS_HOLE";var q=n(66459);let J=null;function Y(e,t){let n=1/0,r=1/0,i=1/0,o=-1/0,s=-1/0,l=-1/0;const c=e.length;let u=0;for(;u<c;){const t=e[u++],a=e[u++],c=e[u++];n=Math.min(n,t),r=Math.min(r,a),i=Math.min(i,c),o=Math.max(o,t),s=Math.max(s,a),l=Math.max(l,c)}return new a.Z({xmin:n,ymin:r,zmin:i,xmax:o,ymax:s,zmax:l,spatialReference:t})}var X=n(87360);function K(e,t,n,r=0){Q[0]=e.x,Q[1]=e.y;const i=e.z;return Q[2]=void 0!==i?i:r,(0,X.projectBuffer)(Q,e.spatialReference,0,t,n,0,1)}const Q=(0,s.c)();var ee=n(13442);const te="esri.geometry.support.meshUtils.centerAt";const ne=(0,s.c)(),re=(0,s.c)(),ie=(0,s.c)();n(99880),n(3172);var oe=n(17452);function se(e){const t=(0,oe.Yd)(e.url);return n=>{const r=(0,oe.PF)(n,t,t),i=r?r.replace(/^ *\.\//,""):null;return(i?e.files.get(i):null)??n}}function ae(e){return he.fromBlob(e)}n(47026);const le=/^(model\/gltf\+json)|(model\/gltf-binary)$/,ce=/\.(gltf|glb)/i;function ue(e){const t=new Map;let n=null;for(const{name:r,mimeType:i,source:o}of e)(null==n||le.test(i)||ce.test(r))&&(n=o.url),t.set(r,o.url),o.files.forEach(((e,n)=>t.set(n,e)));if(null==n)throw new c.Z("mesh-load-external:missing-files","Missing files to load external mesh source");return new he(n,(()=>e.forEach((({source:e})=>e.dispose()))),t)}class he{constructor(e,t=(()=>{}),n=new Map){this.url=e,this.dispose=t,this.files=n}static fromBlob(e){const t=URL.createObjectURL(e);return new he(t,(()=>URL.revokeObjectURL(t)))}}var fe=n(2368),pe=n(46791),de=n(84470);let ge=class extends fe.j{constructor(){super(),this.externalSources=new pe.Z,this._explicitDisplaySource=null,this.addHandles((0,p.on)((()=>this.externalSources),"after-remove",(({item:e})=>{e===this._explicitDisplaySource&&(this._explicitDisplaySource=null)}),{sync:!0,onListenerRemove:()=>this._explicitDisplaySource=null}))}get displaySource(){return this._explicitDisplaySource??this._implicitDisplaySource}set displaySource(e){if(null!=e&&!(0,de.NZ)(e))throw new Error("Cannot use this source for display: it is not in a supported format.");this._explicitDisplaySource=e,e&&this.externalSources.every((t=>!(0,de.fV)(t,e)))&&this.externalSources.add(e)}clearSources(){this.externalSources.removeAll()}getExternalSourcesOnService(e){return this.externalSources.items.filter((t=>(0,de.JG)(t,e)))}get _implicitDisplaySource(){return this.externalSources.find(de.NZ)}};(0,l._)([(0,d.Cb)()],ge.prototype,"externalSources",void 0),(0,l._)([(0,d.Cb)()],ge.prototype,"displaySource",null),(0,l._)([(0,d.Cb)()],ge.prototype,"_implicitDisplaySource",null),(0,l._)([(0,d.Cb)()],ge.prototype,"_explicitDisplaySource",void 0),ge=(0,l._)([(0,g.j)("esri.geometry.support.meshUtils.Metadata")],ge);var me=n(21787),ye=n(46521),xe=n(13598),ve=n(58995),we=n(83932),be=n(56493);function Ae(e,t){if(e)for(let n=0;n<e.length;n+=3)for(let r=0;r<3;r++)e[n+r]+=t[r]}const _e=(0,s.c)(),Te=(0,xe.a)(),Me=(0,ye.a)(),Ce={position:[-.5,-.5,0,.5,-.5,0,.5,.5,0,-.5,.5,0],normal:[0,0,1,0,0,1,0,0,1,0,0,1],uv:[0,1,1,1,1,0,0,0],faces:[0,1,2,0,2,3],facingAxisOrderSwap:{east:[3,1,2],west:[-3,-1,2],north:[-1,3,2],south:[1,-3,2],up:[1,2,3],down:[1,-2,-3]}};function Ze(e,t,n){e.isPlane||function(e){for(let t=0;t<e.position.length;t+=3)e.position[t+2]+=.5}(e),function(e,t){if(null==t)return;const n="number"==typeof t?[t,t,t]:[null!=t.width?t.width:1,null!=t.depth?t.depth:1,null!=t.height?t.height:1];Le[0]=n[0],Le[4]=n[1],Le[8]=n[2];for(let t=0;t<e.position.length;t+=3){for(let n=0;n<3;n++)Oe[n]=e.position[t+n];(0,B.t)(Oe,Oe,Le);for(let n=0;n<3;n++)e.position[t+n]=Oe[n]}if(n[0]!==n[1]||n[1]!==n[2]){Le[0]=1/n[0],Le[4]=1/n[1],Le[8]=1/n[2];for(let t=0;t<e.normal.length;t+=3){for(let n=0;n<3;n++)Oe[n]=e.normal[t+n];(0,B.t)(Oe,Oe,Le),(0,B.n)(Oe,Oe);for(let n=0;n<3;n++)e.normal[t+n]=Oe[n]}}}(e,n?.size);const{vertexAttributes:r,vertexSpace:i,transform:o}=(0,q.w1)(e,t,n);return{vertexAttributes:new F.Q({...r,uv:e.uv}),vertexSpace:i,transform:o,components:[new w.Z({faces:e.faces,material:n&&n.material||null})],spatialReference:t.spatialReference}}const Se={faceDescriptions:[{axis:[0,-1,0],uvOrigin:[0,.625],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[1,0,0],uvOrigin:[.25,.625],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[0,1,0],uvOrigin:[.5,.625],corners:[[1,-1],[-1,-1],[-1,1],[1,1]]},{axis:[-1,0,0],uvOrigin:[.75,.625],corners:[[1,-1],[-1,-1],[-1,1],[1,1]]},{axis:[0,0,1],uvOrigin:[0,.375],corners:[[-1,-1],[1,-1],[1,1],[-1,1]]},{axis:[0,0,-1],uvOrigin:[0,.875],corners:[[-1,1],[1,1],[1,-1],[-1,-1]]}],uvScales:[[0,0],[1,0],[1,1],[0,1]],faceVertexOffsets:[0,1,2,0,2,3]},Re={south:0,east:1,north:2,west:3,up:4,down:5},Oe=(0,s.c)(),Le=(0,ye.a)();var Fe=n(52138);const Ie="esri.geometry.support.meshUtils.rotate";function Ee(e,t,n,r=s.Z){if(null!=e){(0,Fe.c)(De,(0,v.WH)(t),(0,v.ZZ)(t));for(let t=0;t<e.length;t+=n){for(let n=0;n<3;n++)Pe[n]=e[t+n]-r[n];(0,B.e)(Pe,Pe,De);for(let n=0;n<3;n++)e[t+n]=Pe[n]+r[n]}}}const Pe=(0,s.c)(),Ue=(0,s.c)(),Ne=(0,v.Ue)(),De=(0,xe.a)(),je=(0,ye.a)(),ke=(0,s.c)(),Be="esri.geometry.support.meshUtils.scale";function ze(e,t,n=s.Z){if(e)for(let r=0;r<e.length;r+=3){for(let t=0;t<3;t++)We[t]=e[r+t]-n[t];(0,B.i)(We,We,t);for(let t=0;t<3;t++)e[r+t]=We[t]+n[t]}}const We=(0,s.c)(),He=(0,s.c)(),$e=(0,s.c)();var Ve,Ge=n(2981);async function qe(e){const{BlobReader:t,ZipReader:r,BlobWriter:i}=await Promise.all([n.e(2712),n.e(4041)]).then(n.bind(n,74041)),o=[],s=new r(new t(e));return(await s.getEntries()).forEach((e=>{if(e.directory||/^__MACOS/i.test(e.filename))return;const t=new i,n=e.getData?.(t).then((t=>new File([t],e.filename)));n&&o.push(n)})),Promise.all(o)}const Je="esri.geometry.Mesh",Ye={base:null,key:"type",defaultKeyValue:"georeferenced",typeMap:{georeferenced:R.Z,"georeferenced-relative":S.Z,local:O.Z}};let Xe=Ve=class extends(u.Z.LoadableMixin((0,h.v)(m.Z))){constructor(e){super(e),this.components=null,this.vertexSpace=new R.Z,this.transform=null,this.metadata=new ge,this.hasZ=!0,this.hasM=!1,this.vertexAttributes=new F.Q,this.type="mesh"}initialize(){(0===this.metadata.externalSources.length||this.vertexAttributes.position.length)&&(this.loadStatus="loaded"),this.when((()=>{this.addHandles((0,p.YP)((()=>({vertexAttributes:this.vertexAttributes,components:this.components?.map((e=>e.clone()))})),(()=>this._clearSources()),{once:!0,sync:!0}))}))}get hasExtent(){return this.loaded?this.vertexAttributes.position.length>0&&(!this.components||this.components.length>0):null!=this.metadata.displaySource?.extent}get _transformedExtent(){const{components:e,spatialReference:t,vertexAttributes:n,vertexSpace:r}=this,i=n.position;if(0===i.length||e&&0===e.length)return new a.Z({xmin:0,ymin:0,zmin:0,xmax:0,ymax:0,zmax:0,spatialReference:t});if("local"===r.type){const{_untransformedExtent:e,transform:n}=this;return function({xmin:e,xmax:t,ymin:n,ymax:r,zmin:i,zmax:o},s,a,l){i??=0,o??=0,J??=new Float64Array(24);const c=J;return c[0]=e,c[1]=n,c[2]=i,c[3]=e,c[4]=r,c[5]=i,c[6]=t,c[7]=r,c[8]=i,c[9]=t,c[10]=n,c[11]=i,c[12]=e,c[13]=n,c[14]=o,c[15]=e,c[16]=r,c[17]=o,c[18]=t,c[19]=r,c[20]=o,c[21]=t,c[22]=n,c[23]=o,(0,q.project)({positions:c,transform:s,vertexSpace:a,inSpatialReference:l,outSpatialReference:l,outPositions:c}),Y(c,l)}(e,n,r,t)}if("georeferenced-relative"===r.type){const{transform:e}=this;return Y((0,q.project)({positions:i,transform:e,vertexSpace:r,inSpatialReference:t,outSpatialReference:t}),t)}return Y(i,t)}get _untransformedExtent(){return Y(this.vertexAttributes.position,this.spatialReference)}get anchor(){const{vertexSpace:e}=this;if(e.isRelative)return e.getOriginPoint(this.spatialReference);const{center:t,zmin:n}=this._transformedExtent;return new y.Z({x:t.x,y:t.y,z:n,spatialReference:this.spatialReference})}get origin(){const{vertexSpace:e}=this;return e.isRelative?e.getOriginPoint(this.spatialReference):this._transformedExtent.center}get extent(){return this.loaded||null==this.metadata?.displaySource?.extent?this._transformedExtent:this.metadata.displaySource.extent.clone()}addComponent(e){if(!this.loaded)return i.Z.getLogger(this).error("addComponent()",(new b).message);this.components||(this.components=[]),this.components.push(w.Z.from(e)),this.notifyChange("components")}removeComponent(e){if(!this.loaded)return i.Z.getLogger(this).error("removeComponent()",(new b).message);if(this.components){const t=this.components.indexOf(e);if(-1!==t)return this.components.splice(t,1),void this.notifyChange("components")}i.Z.getLogger(this).error("removeComponent()",(new A).message)}rotate(e,t,n,r){return(0,v.qw)(e,t,n,Qe),function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position||0===t[3])return;const{spatialReference:r,vertexSpace:o}=e;if(o.isRelative){(0,ee.A)(o,Ie,n);const r=n?.origin??e.origin;e.transform??=new L.Z,function(e,t,n,r){const i=t.origin,o=(0,B.s)(Pe,r.x,r.y,r.z??0),a=(0,B.f)(Pe,o,i);e.applyLocalInverse(a,Ue),e.rotation=(0,v.qC)(e.rotation,n,(0,v.Ue)()),e.applyLocalInverse(a,a),(0,B.f)(a,a,Ue),e.translation=(0,B.g)((0,s.c)(),e.translation,a)}(e.transform,o,t,r)}else{const o=n?.origin??e.origin;(0,ee.h)(r,n)?function(e,t,n){const r=e.spatialReference,i=(0,ve.rS)(r),o=ke;K(n,o,i)||K(e.origin,o,i);const s=e.vertexAttributes.position,a=e.vertexAttributes.normal,l=e.vertexAttributes.tangent,c=new Float64Array(s.length),u=null!=a?new Float32Array(a.length):null,h=null!=l?new Float32Array(l.length):null;(0,we.B)(i,o,De,i),(0,me.f)(je,De);const f=Ne;(0,B.t)((0,v.ZZ)(Ne),(0,v.ZZ)(t),je),f[3]=t[3],(0,be.XO)(s,r,c),null!=a&&null!=u&&(0,be.Iz)(a,s,c,r,u),null!=l&&null!=h&&(0,be.wi)(l,s,c,r,h),Ee(c,f,3,o),(0,be.To)(c,s,r),null!=a&&null!=u&&(Ee(u,f,3),(0,be.Yk)(u,s,c,r,a)),null!=l&&null!=h&&(Ee(h,f,4),(0,be.M2)(h,s,c,r,l)),e.vertexAttributesChanged()}(e,t,o):function(e,t,n){const r=ke;if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(Ie).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}Ee(e.vertexAttributes.position,t,3,r),Ee(e.vertexAttributes.normal,t,3),Ee(e.vertexAttributes.tangent,t,4),e.vertexAttributesChanged()}(e,t,o)}}(this,Qe,r),this}offset(e,t,n,r){return this.loaded?(Ke[0]=e,Ke[1]=t,Ke[2]=n,function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{vertexSpace:r}=e;r.isRelative?((0,ee.A)(r,"esri.geometry.support.meshUtils.offset",n),function(e,t){const n=e.origin;e.origin=(0,B.g)((0,s.c)(),n,t)}(r,t)):(0,ee.h)(e.spatialReference,n)?function(e,t){const n=e.spatialReference,r=e.vertexAttributes.position,i=e.vertexAttributes.normal,o=e.vertexAttributes.tangent,s=new Float64Array(r.length),a=null!=i?new Float32Array(i.length):null,l=null!=o?new Float32Array(o.length):null,c=e.extent.center,u=_e;(0,we.B)(n,[c.x,c.y,c.z],Te,(0,ve.rS)(n)),(0,me.f)(Me,Te),(0,B.t)(u,t,Me),(0,be.XO)(r,n,s),null!=i&&null!=a&&(0,be.Iz)(i,r,s,n,a),null!=o&&null!=l&&(0,be.wi)(o,r,s,n,l),Ae(s,u),(0,be.To)(s,r,n),null!=i&&null!=a&&(0,be.Yk)(a,r,s,n,i),null!=o&&null!=l&&(0,be.M2)(l,r,s,n,o),e.vertexAttributesChanged()}(e,t):function(e,t){Ae(e.vertexAttributes.position,t),e.vertexAttributesChanged()}(e,t)}(this,Ke,r),this):(i.Z.getLogger(this).error("offset()",(new b).message),this)}scale(e,t){return this.loaded?(function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{spatialReference:r,vertexSpace:o}=e;if(o.isRelative){(0,ee.A)(o,Be,n);const r=n?.origin??e.origin;e.transform??=new L.Z,function(e,t,n,r){const i=t.origin,o=(0,B.s)(We,r.x,r.y,r.z),a=(0,B.f)(We,o,i);e.applyLocalInverse(a,He);const l=(0,B.i)((0,s.c)(),e.scale,n);e.scale=l,e.applyLocalInverse(a,a),(0,B.f)(a,a,He),e.translation=(0,B.g)((0,s.c)(),e.translation,a)}(e.transform,o,t,r)}else{const o=(0,ee.h)(r,n),s=n?.origin??e.origin;o?function(e,t,n){const r=e.spatialReference,i=(0,ve.rS)(r),o=$e;K(n,o,i)||K(e.origin,o,i);const s=e.vertexAttributes.position,a=e.vertexAttributes.normal,l=e.vertexAttributes.tangent,c=new Float64Array(s.length),u=null!=a?new Float32Array(a.length):null,h=null!=l?new Float32Array(l.length):null;(0,be.XO)(s,r,c),null!=a&&null!=u&&(0,be.Iz)(a,s,c,r,u),null!=l&&null!=h&&(0,be.wi)(l,s,c,r,h),ze(c,t,o),(0,be.To)(c,s,r),null!=a&&null!=u&&(0,be.Yk)(u,s,c,r,a),null!=l&&null!=h&&(0,be.M2)(h,s,c,r,l),e.vertexAttributesChanged()}(e,t,s):function(e,t,n){const r=$e;if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(Be).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}ze(e.vertexAttributes.position,t,r),e.vertexAttributesChanged()}(e,t,s)}}(this,e,t),this):(i.Z.getLogger(this).error("scale()",(new b).message),this)}centerAt(e,t){return this.loaded?(function(e,t,n){if(!e.vertexAttributes||!e.vertexAttributes.position)return;const{vertexSpace:r}=e,o=n?.origin??e.origin;r.isRelative?((0,ee.A)(r,te,n),function(e,t,n){const{vertexSpace:r}=e;if(!r.isRelative)return;const o=re,a=ne;if(!K(t,a,e.spatialReference))return void i.Z.getLogger(te).error(`Failed to project centerAt location (wkid:${t.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`);if(!K(n,o,e.spatialReference)){const t=e.origin;o[0]=t.x,o[1]=t.y,o[2]=t.z,i.Z.getLogger(te).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}const l=(0,B.f)(ie,a,o),c=r.origin;r.origin=(0,B.g)((0,s.c)(),c,l)}(e,t,o)):(0,ee.h)(e.spatialReference,n)?function(e,t,n){const r=(0,q.FF)(e.vertexAttributes,n,{geographic:!0}),{position:i,normal:o,tangent:s}=(0,q.iv)(r,t,{geographic:!0});e.vertexAttributes.position=i,e.vertexAttributes.normal=o,e.vertexAttributes.tangent=s,e.vertexAttributesChanged()}(e,t,o):function(e,t,n){const r=re,o=ne;if(K(t,o,e.spatialReference)){if(!K(n,r,e.spatialReference)){const t=e.origin;r[0]=t.x,r[1]=t.y,r[2]=t.z,i.Z.getLogger(te).error(`Failed to project specified origin (wkid:${n.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}(function(e,t,n){if(e)for(let r=0;r<e.length;r+=3)for(let i=0;i<3;i++)e[r+i]+=t[i]-n[i]})(e.vertexAttributes.position,o,r),e.vertexAttributesChanged()}else i.Z.getLogger(te).error(`Failed to project centerAt location (wkid:${t.spatialReference.wkid}) to mesh spatial reference (wkid:${e.spatialReference.wkid}). Projection may be possible after calling projection.load().`)}(e,t,o)}(this,e,t),this):(i.Z.getLogger(this).error("centerAt()",(new b).message),this)}load(e){const{metadata:{displaySource:t}}=this;return t&&this.addResolvingPromise(async function(e,t,r){const{source:i}=t,{loadGLTFMesh:o}=await(0,f.Hl)(Promise.all([n.e(8598),n.e(8079)]).then(n.bind(n,78079)),r),s=await async function(e,t){if(Array.isArray(e)){if(!e.length)throw new c.Z("mesh-load-external:missing-assets","There must be at least one file to load");return e[0]instanceof File?function(e){return ue(e.map((e=>({name:e.name,mimeType:e.type,source:ae(e)}))))}(e):async function(e,t){const n=await(0,f.OT)(e.map((async e=>{const n=await async function(e,t){const{parts:n}=e;if(1===n.length)return new he(n[0].partUrl);const r=await e.toBlob(t);return(0,f.k_)(t),he.fromBlob(r)}(e);return(0,f.k_)(t),{name:e.assetName,mimeType:e.assetMimeType,source:n}})));if((0,f.Hc)(t))throw n.forEach((e=>e.source.dispose())),(0,f.zE)();return ue(n)}(e,t)}return ae(e)}(i,r);(0,f.k_)(r);const a=o(new y.Z({x:0,y:0,z:0,spatialReference:e.spatialReference}),s.url,{resolveFile:se(s),requestFile:void 0,useTransform:!0,signal:r?.signal});a.then((()=>s.dispose()),(()=>s.dispose()));const{vertexAttributes:l,components:u}=await a;e.vertexAttributes=l,e.components=u}(this,t,e)),Promise.resolve(this)}addExternalSources(e){this.metadata.externalSources.addMany(e)}updateDisplaySource(e){this.metadata.displaySource=e}clone(){return this.cloneWithVertexSpace(this.vertexSpace.clone())}cloneWithVertexSpace(e){let t=null;if(this.components){const e=new Map,n=new Map;t=this.components.map((t=>t.cloneWithDeduplication(e,n)))}const n={components:t,spatialReference:this.spatialReference,vertexAttributes:this.vertexAttributes.clone(),vertexSpace:e,transform:this.transform?.clone()??null,metadata:this.metadata.clone()};return new Ve(n)}cloneShallow(){return new Ve({components:this.components,spatialReference:this.spatialReference,vertexAttributes:this.vertexAttributes,vertexSpace:this.vertexSpace.clone(),transform:this.transform,metadata:this.metadata})}vertexAttributesChanged(){this.notifyChange("vertexAttributes")}async toBinaryGLTF(e){const t=n.e(7277).then(n.bind(n,7277)),r=this.load(),i=await Promise.all([t,r]),{toBinaryGLTF:o}=i[0];return o(this,e)}get memoryUsage(){let e=0;if(e+=this.vertexAttributes.memoryUsage,null!=this.components)for(const t of this.components)e+=t.memoryUsage;return e}_clearSources(){this.metadata.clearSources()}static createBox(e,t){if(!(e instanceof y.Z))return i.Z.getLogger(Je).error(".createBox()",(new T).message),null;const n=new Ve(Ze(function(){const{faceDescriptions:e,faceVertexOffsets:t,uvScales:n}=Se,r=4*e.length,i=new Float64Array(3*r),o=new Float32Array(3*r),s=new Float32Array(2*r),a=new Uint32Array(2*e.length*3);let l=0,c=0,u=0,h=0;for(let r=0;r<e.length;r++){const f=e[r],p=l/3;for(const e of t)a[h++]=p+e;const d=f.corners;for(let e=0;e<4;e++){const t=d[e];let r=0;s[u++]=.25*n[e][0]+f.uvOrigin[0],s[u++]=f.uvOrigin[1]-.25*n[e][1];for(let e=0;e<3;e++)0!==f.axis[e]?(i[l++]=.5*f.axis[e],o[c++]=f.axis[e]):(i[l++]=.5*t[r++],o[c++]=0)}}return{position:i,normal:o,uv:s,faces:a}}(),e,t));return t&&t.imageFace&&"all"!==t.imageFace?function(e,t){const n=e.components[0],r=n.faces,i=Re[t],o=6*i,s=new Array(6),a=new Array(r.length-6);let l=0,c=0;for(let e=0;e<r.length;e++)e>=o&&e<o+6?s[l++]=r[e]:a[c++]=r[e];if(null!=e.vertexAttributes.uv){const t=new Float32Array(e.vertexAttributes.uv),n=4*i*2,r=[0,1,1,1,1,0,0,0];for(let e=0;e<r.length;e++)t[n+e]=r[e];e.vertexAttributes.uv=t}return e.components=[new w.Z({faces:s,material:n.material}),new w.Z({faces:a})],e}(n,t.imageFace):n}static createSphere(e,t){return e instanceof y.Z?new Ve(Ze(function(e=0){const t=Math.round(8*2**e),n=2*t,r=(t-1)*(n+1)+2*n,i=new Float64Array(3*r),o=new Float32Array(3*r),s=new Float32Array(2*r),a=new Uint32Array((t-1)*n*2*3);let l=0,c=0,u=0,h=0;for(let e=0;e<=t;e++){const r=e/t*Math.PI+.5*Math.PI,f=Math.cos(r),p=Math.sin(r);Oe[2]=p;const d=0===e||e===t,g=d?n-1:n;for(let r=0;r<=g;r++){const p=r/g*2*Math.PI;Oe[0]=-Math.sin(p)*f,Oe[1]=Math.cos(p)*f;for(let e=0;e<3;e++)i[l]=.5*Oe[e],o[l]=Oe[e],++l;s[c++]=(r+(d?.5:0))/n,s[c++]=e/t,0!==e&&r!==n&&(e!==t&&(a[u++]=h,a[u++]=h+1,a[u++]=h-n),1!==e&&(a[u++]=h,a[u++]=h-n,a[u++]=h-n-1)),h++}}return{position:i,normal:o,uv:s,faces:a}}(t&&t.densificationFactor||0),e,t)):(i.Z.getLogger(Je).error(".createSphere()",(new T).message),null)}static createCylinder(e,t){return e instanceof y.Z?new Ve(Ze(function(e=0){const t=Math.round(16*2**e),n=4*(t+1)+2*t,r=new Float64Array(3*n),i=new Float32Array(3*n),o=new Float32Array(2*n),s=new Uint32Array(4*t*3);let a=0,l=0,c=0,u=0,h=0;for(let e=0;e<=5;e++){const n=0===e||5===e,f=e<=1||e>=4,p=2===e||4===e,d=n?t-1:t;for(let g=0;g<=d;g++){const m=g/d*2*Math.PI,y=n?0:.5;Oe[0]=y*Math.sin(m),Oe[1]=y*-Math.cos(m),Oe[2]=e<=2?.5:-.5;for(let t=0;t<3;t++)r[a++]=Oe[t],i[l++]=f?2===t?e<=1?1:-1:0:2===t?0:Oe[t]/y;o[c++]=(g+(n?.5:0))/t,o[c++]=e<=1?1*e/3:e<=3?1*(e-2)/3+1/3:1*(e-4)/3+2/3,p||0===e||g===t||(5!==e&&(s[u++]=h,s[u++]=h+1,s[u++]=h-t),1!==e&&(s[u++]=h,s[u++]=h-t,s[u++]=h-t-1)),h++}}return{position:r,normal:i,uv:o,faces:s}}(t&&t.densificationFactor||0),e,t)):(i.Z.getLogger(Je).error(".createCylinder()",(new T).message),null)}static createPlane(e,t){if(!(e instanceof y.Z))return i.Z.getLogger(Je).error(".createPlane()",(new T).message),null;const n=t?.facing??"up",r=function(e,t){const n="number"==typeof t?t:null!=t?t.width:1,r="number"==typeof t?t:null!=t?t.height:1;switch(e){case"up":case"down":return{width:n,depth:r};case"north":case"south":return{width:n,height:r};case"east":case"west":return{depth:n,height:r}}}(n,t?.size);return new Ve(Ze(function(e){const t=Ce.facingAxisOrderSwap[e],n=Ce.position,r=Ce.normal,i=new Float64Array(n.length),o=new Float32Array(r.length);let s=0;for(let e=0;e<4;e++){const e=s;for(let a=0;a<3;a++){const l=t[a],c=Math.abs(l)-1,u=l>=0?1:-1;i[s]=n[e+c]*u,o[s]=r[e+c]*u,s++}}return{position:i,normal:o,uv:new Float32Array(Ce.uv),faces:new Uint32Array(Ce.faces),isPlane:!0}}(n),e,{...t,size:r}))}static createFromPolygon(e,t){if(!(e instanceof x.Z))return i.Z.getLogger(Je).error(".createFromPolygon()",(new _).message),null;const n=function(e){const t=function(e,t,n,r){const i=e.length,o=new Array(i),s=new Array(i),a=new Array(i);let l=0,c=0,u=0,h=0;for(let t=0;t<i;++t)h+=e[t].length;const f=(0,U.bg)(3*h);let p=0;for(let h=i-1;h>=0;h--){const d=e[h],g=n===V.CCW_IS_HOLE&&$(d,t,r);if(g&&1!==i)o[l++]=d;else{let e=d.length;for(let t=0;t<l;++t)e+=o[t].length;const n={index:p,pathLengths:new Array(l+1),count:e,holeIndices:new Array(l)};n.pathLengths[0]=d.length,d.length>0&&(a[u++]={index:p,count:d.length}),p=g?H(d,d.length-1,-1,f,p,d.length,t):H(d,0,1,f,p,d.length,t);for(let e=0;e<l;++e){const r=o[e];n.holeIndices[e]=p,n.pathLengths[e+1]=r.length,r.length>0&&(a[u++]={index:p,count:r.length}),p=H(r,0,1,f,p,r.length,t)}l=0,n.count>0&&(s[c++]=n)}}for(let e=0;e<l;++e){const n=o[e];n.length>0&&(a[u++]={index:p,count:n.length}),p=H(n,0,1,f,p,n.length,t)}return s.length=c,a.length=u,{position:f,polygons:s,outlines:a}}(e.rings,e.hasZ,V.CCW_IS_HOLE,e.spatialReference),n=new Array;let r=0,i=0;for(const e of t.polygons){const o=e.count,s=e.index,a=(0,U.Rq)(t.position,3*s,3*o),l=e.holeIndices.map((e=>e-s)),c=(0,N.mi)((0,I.e)(a,l,3));n.push({position:a,faces:c}),r+=a.length,i+=c.length}const o=function(e,t,n){if(1===e.length)return e[0];const r=(0,U.bg)(t),i=new Array(n);let o=0,s=0,a=0;for(const t of e){for(let e=0;e<t.position.length;e++)r[o++]=t.position[e];for(const e of t.faces)i[s++]=e+a;a=o/3}return{position:r,faces:(0,N.mi)(i)}}(n,r,i),s=Array.isArray(o.position)?(0,D.d)(o.position,3,{originalIndices:o.faces}):(0,D.d)(o.position.buffer,6,{originalIndices:o.faces});return o.position=(0,U.QZ)(new Float64Array(s.buffer)),o.faces=s.indices,o}(e);return new Ve({vertexAttributes:new F.Q({position:n.position}),components:[new w.Z({faces:n.faces,shading:"flat",material:t?.material??null})],spatialReference:e.spatialReference,vertexSpace:new R.Z})}static async createFromGLTF(e,t,r){if(!(e instanceof y.Z)){const e=new T;throw i.Z.getLogger(Je).error(".createfromGLTF()",e.message),e}const{loadGLTFMesh:o}=await(0,f.Hl)(Promise.all([n.e(8598),n.e(8079)]).then(n.bind(n,78079)),r);return new Ve(await o(e,t,r))}static async createFromFiles(e,t,n){const r=e=>i.Z.getLogger(Je).error(".createFromFiles()",e.message);if(!(e instanceof y.Z)){const e=new T;throw r(e),e}const o=n?.layer;if(!o){const e=new M;throw r(e),e}const s=await Ve.extractAndFilterFiles(t,o),a=s.reduce(((e,t)=>(0,Ge.$z)(o.infoFor3D,t)?e+1:e),0);if(0===a){const e=new C;throw r(e),e}if(a>1){const e=new Z;throw r(e),e}const l=Ve.createWithExternalSource(e,s),[c]=await o.uploadAssets([l],n);return c}static async extractAndFilterFiles(e,t){const n=t?.infoFor3D;return n?(await async function(e){const t=[];for(const n of e)n.name.toLowerCase().endsWith(".zip")?t.push(qe(n)):t.push(Promise.resolve(n));return(await Promise.all(t)).flat()}(e)).filter((e=>(0,Ge.F7)(n,e))):e}static createWithExternalSource(e,t,n){const r=n?.extent??null,{x:i,y:o,z:s,spatialReference:a}=e,l=n?.transform?.clone()??new L.Z,c=n?.vertexSpace??new O.Z({origin:[i,o,s??0]}),u={source:t,extent:r},h=new ge;return h.externalSources.push(u),new Ve({metadata:h,transform:l,vertexSpace:c,spatialReference:a})}static createIncomplete(e,t){const{x:n,y:r,z:i,spatialReference:o}=e,s=t?.transform?.clone()??new L.Z,a=t?.vertexSpace??new O.Z({origin:[n,r,i??0]}),l=new Ve({transform:s,vertexSpace:a,spatialReference:o});return l.addResolvingPromise(Promise.reject(new c.Z("mesh-incomplete","Mesh resources are not complete"))),l}};(0,l._)([(0,d.Cb)({type:[w.Z],json:{write:!0}})],Xe.prototype,"components",void 0),(0,l._)([(0,d.Cb)({nonNullable:!0,types:Ye,constructOnly:!0,json:{write:!0}})],Xe.prototype,"vertexSpace",void 0),(0,l._)([(0,d.Cb)({type:L.Z,json:{write:!0}})],Xe.prototype,"transform",void 0),(0,l._)([(0,d.Cb)({constructOnly:!0})],Xe.prototype,"metadata",void 0),(0,l._)([(0,d.Cb)()],Xe.prototype,"hasExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"_transformedExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"_untransformedExtent",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"anchor",null),(0,l._)([(0,d.Cb)()],Xe.prototype,"origin",null),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1}})],Xe.prototype,"extent",null),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1,write:!0,default:!0}})],Xe.prototype,"hasZ",void 0),(0,l._)([(0,d.Cb)({readOnly:!0,json:{read:!1,write:!0,default:!1}})],Xe.prototype,"hasM",void 0),(0,l._)([(0,d.Cb)({type:F.Q,nonNullable:!0,json:{write:!0}})],Xe.prototype,"vertexAttributes",void 0),Xe=Ve=(0,l._)([(0,g.j)(Je)],Xe);const Ke=(0,s.c)(),Qe=(0,v.Ue)(),et=Xe;var tt=n(82971),nt=n(74889);const rt=()=>i.Z.getLogger("esri.rest.support.meshFeatureSet");function it(e,t,n){const i=n.features;n.features=[],delete n.geometryType;const o=nt.Z.fromJSON(n);if(o.geometryType="mesh",!n.assetMaps)return o;const s=lt(t,n.assetMaps),a=e.sourceSpatialReference??tt.Z.WGS84,l=n.globalIdFieldName,{outFields:c}=e,u=null!=c&&c.length>0?(h=c.includes("*")?null:new Set(c),({attributes:e})=>{if(!e)return{};if(!h)return e;for(const t in e)h.has(t)||delete e[t];return e}):()=>({});var h;for(const e of i){const n=ot(e,l,a,t,s);null!=n&&o.features.push(new r.Z({geometry:n,attributes:u(e)}))}return o}function ot(e,t,n,r,i){const o=e.attributes[t],l=i.get(o);if(null==l)return rt().error("mesh-feature-set:asset-not-found","Service returned a feature which was not found in the asset map",e),null;if(!e.geometry)return rt().error("mesh-feature-set:no-geometry","Service returned a feature without geometry",e),null;const{originPoint:c,originVector:u}=function({attributes:e},t,{transformFieldRoles:n}){const r=e[n.originX],i=e[n.originY],o=e[n.originZ];return{originPoint:new y.Z({x:r,y:i,z:o,spatialReference:t}),originVector:(0,s.f)(r,i,o)}}(e,n,r),h=a.Z.fromJSON(e.geometry);h.spatialReference=n;const f=function(e,{transformFieldRoles:t}){return new L.Z({translation:[e[t.translationX],-e[t.translationZ],e[t.translationY]],rotationAxis:[e[t.rotationX],-e[t.rotationZ],e[t.rotationY]],rotationAngle:e[t.rotationDeg],scale:[e[t.scaleX],e[t.scaleZ],e[t.scaleY]]})}(e.attributes,r),p=l.projectVertices?new S.Z({origin:u}):new O.Z({origin:u}),d=function(e){const t=Array.from(e.files.values()),n=new Array;for(const e of t){if(e.status!==st.COMPLETED)return null;const t=new Array;for(const n of e.parts){if(!n)return null;t.push(new de.LL(n.url,n.hash))}n.push(new de.CP(e.name,e.mimeType,t))}return n}(l);return d?et.createWithExternalSource(c,d,{extent:h,transform:f,vertexSpace:p}):et.createIncomplete(c,{extent:h,transform:f,vertexSpace:p})}var st,at;function lt(e,t){const n=new Map;for(const r of t){const t=r.parentGlobalId;if(null==t)continue;const i=r.assetName,s=r.assetType,a=r.assetHash,l=r.assetURL,c=r.conversionStatus,u=r.seqNo,h=(0,Ge.d1)(s,e.supportedFormats);if(!h){rt().error("mesh-feature-set:unknown-format",`Service returned an asset of type ${s}, but it does not list it as a supported type`);continue}const f=(0,o.s1)(n,t,(()=>({projectVertices:ut(r.flags).projectVertices,files:new Map})));(0,o.s1)(f.files,i,(()=>({name:i,type:s,mimeType:h,status:ct(c),parts:[]}))).parts[u]={hash:a,url:l}}return n}function ct(e){switch(e){case"COMPLETED":case"SUBMITTED":return st.COMPLETED;case"INPROGRESS":return st.PENDING;default:return st.FAILED}}function ut(e){return{projectVertices:e.includes("PROJECT_VERTICES")}}(at=st||(st={}))[at.FAILED=0]="FAILED",at[at.PENDING=1]="PENDING",at[at.COMPLETED=2]="COMPLETED"},17662:(e,t,n)=>{n.d(t,{c:()=>i});var r=n(99001);class i{constructor(){this.id=(0,r.D)()}}},4726:(e,t,n)=>{var r;n.d(t,{U:()=>r}),function(e){e[e.Layer=0]="Layer",e[e.Object=1]="Object",e[e.Mesh=2]="Mesh",e[e.Line=3]="Line",e[e.Point=4]="Point",e[e.Material=5]="Material",e[e.Texture=6]="Texture",e[e.COUNT=7]="COUNT"}(r||(r={}))},22631:(e,t,n)=>{n.d(t,{Z:()=>S});var r=n(13598),i=n(17896),o=n(24882),s=n(1533);function a(e){if(e.length<s.c8)return Array.from(e);if((0,s.kJ)(e))return Float64Array.from(e);if(!("BYTES_PER_ELEMENT"in e))return Array.from(e);switch(e.BYTES_PER_ELEMENT){case 1:return Uint8Array.from(e);case 2:return(0,s.Uc)(e)?Uint16Array.from(e):Int16Array.from(e);case 4:return Float32Array.from(e);default:return Float64Array.from(e)}}var l=n(47026),c=n(44553),u=n(65617),h=n(11726);class f{constructor(e,t,n){this.primitiveIndices=e,this._numIndexPerPrimitive=t,this.position=n,this._children=void 0,(0,h.hu)(e.length>=1),(0,h.hu)(3===n.size||4===n.size);const{data:r,size:o,indices:s}=n;(0,h.hu)(s.length%this._numIndexPerPrimitive==0),(0,h.hu)(s.length>=e.length*this._numIndexPerPrimitive);const a=e.length;let l=o*s[this._numIndexPerPrimitive*e[0]];p.clear(),p.push(l);const c=(0,u.f)(r[l],r[l+1],r[l+2]),f=(0,u.g)(c);for(let t=0;t<a;++t){const n=this._numIndexPerPrimitive*e[t];for(let e=0;e<this._numIndexPerPrimitive;++e){l=o*s[n+e],p.push(l);let t=r[l];c[0]=Math.min(t,c[0]),f[0]=Math.max(t,f[0]),t=r[l+1],c[1]=Math.min(t,c[1]),f[1]=Math.max(t,f[1]),t=r[l+2],c[2]=Math.min(t,c[2]),f[2]=Math.max(t,f[2])}}this.bbMin=c,this.bbMax=f;const d=(0,i.p)((0,u.c)(),this.bbMin,this.bbMax,.5);this.radius=.5*Math.max(Math.max(f[0]-c[0],f[1]-c[1]),f[2]-c[2]);let g=this.radius*this.radius;for(let e=0;e<p.length;++e){l=p.at(e);const t=r[l]-d[0],n=r[l+1]-d[1],i=r[l+2]-d[2],o=t*t+n*n+i*i;if(o<=g)continue;const s=Math.sqrt(o),a=.5*(s-this.radius);this.radius=this.radius+a,g=this.radius*this.radius;const c=a/s;d[0]+=t*c,d[1]+=n*c,d[2]+=i*c}this.center=d,p.clear()}getChildren(){if(this._children||(0,i.a)(this.bbMin,this.bbMax)<=1)return this._children;const e=(0,i.p)((0,u.c)(),this.bbMin,this.bbMax,.5),t=this.primitiveIndices.length,n=new Uint8Array(t),r=new Array(8);for(let e=0;e<8;++e)r[e]=0;const{data:o,size:s,indices:a}=this.position;for(let i=0;i<t;++i){let t=0;const l=this._numIndexPerPrimitive*this.primitiveIndices[i];let c=s*a[l],u=o[c],h=o[c+1],f=o[c+2];for(let e=1;e<this._numIndexPerPrimitive;++e){c=s*a[l+e];const t=o[c],n=o[c+1],r=o[c+2];t<u&&(u=t),n<h&&(h=n),r<f&&(f=r)}u<e[0]&&(t|=1),h<e[1]&&(t|=2),f<e[2]&&(t|=4),n[i]=t,++r[t]}let l=0;for(let e=0;e<8;++e)r[e]>0&&++l;if(l<2)return;const c=new Array(8);for(let e=0;e<8;++e)c[e]=r[e]>0?new Uint32Array(r[e]):void 0;for(let e=0;e<8;++e)r[e]=0;for(let e=0;e<t;++e){const t=n[e];c[t][r[t]++]=this.primitiveIndices[e]}this._children=new Array;for(let e=0;e<8;++e)void 0!==c[e]&&this._children.push(new f(c[e],this._numIndexPerPrimitive,this.position));return this._children}static prune(){p.prune()}}const p=new c.Z({deallocator:null});var d=n(17662),g=n(4726),m=n(22807),y=n(16996);function x(e,t,n){return(0,i.f)(v,t,e),(0,i.f)(w,n,e),(0,i.l)((0,i.b)(v,v,w))/2}n(12981),new m.x(y.Ue),new m.x((()=>{return e?{p0:(0,u.g)(e.p0),p1:(0,u.g)(e.p1),p2:(0,u.g)(e.p2)}:{p0:(0,u.c)(),p1:(0,u.c)(),p2:(0,u.c)()};var e}));const v=(0,u.c)(),w=(0,u.c)(),b=(0,u.c)(),A=(0,u.c)(),_=(0,u.c)(),T=(0,u.c)();var M=n(99001);class C{constructor(e){this.channel=e,this.id=(0,M.D)()}}var Z=n(35065);n(9820),(0,u.c)(),new Float32Array(6);class S extends d.c{constructor(e,t,n=null,r=g.U.Mesh,i=null,s=-1){super(),this.material=e,this.mapPositions=n,this.type=r,this.objectAndLayerIdColor=i,this.edgeIndicesLength=s,this.visible=!0,this._attributes=new Map,this._boundingInfo=null;for(const[e,n]of t)this._attributes.set(e,{...n,indices:(0,o.mi)(n.indices)}),e===Z.T.POSITION&&(this.edgeIndicesLength=this.edgeIndicesLength<0?this._attributes.get(e).indices.length:this.edgeIndicesLength)}instantiate(e={}){const t=new S(e.material||this.material,[],this.mapPositions,this.type,this.objectAndLayerIdColor,this.edgeIndicesLength);return this._attributes.forEach(((e,n)=>{e.exclusive=!1,t._attributes.set(n,e)})),t._boundingInfo=this._boundingInfo,t.transformation=e.transformation||this.transformation,t}get attributes(){return this._attributes}getMutableAttribute(e){let t=this._attributes.get(e);return t&&!t.exclusive&&(t={...t,exclusive:!0,data:a(t.data)},this._attributes.set(e,t)),t}setAttributeData(e,t){const n=this._attributes.get(e);n&&this._attributes.set(e,{...n,exclusive:!0,data:t})}get indexCount(){const e=this._attributes.values().next().value.indices;return e?.length??0}get faceCount(){return this.indexCount/3}get boundingInfo(){return null==this._boundingInfo&&(this._boundingInfo=this._calculateBoundingInfo()),this._boundingInfo}computeAttachmentOrigin(e){return!!(this.type===g.U.Mesh?this._computeAttachmentOriginTriangles(e):this.type===g.U.Line?this._computeAttachmentOriginLines(e):this._computeAttachmentOriginPoints(e))&&(null!=this._transformation&&(0,i.e)(e,e,this._transformation),!0)}_computeAttachmentOriginTriangles(e){return function(e,t){if(!e)return!1;const{size:n,data:r,indices:o}=e;(0,i.s)(t,0,0,0),(0,i.s)(T,0,0,0);let s=0,a=0;for(let e=0;e<o.length-2;e+=3){const l=o[e]*n,c=o[e+1]*n,u=o[e+2]*n;(0,i.s)(b,r[l],r[l+1],r[l+2]),(0,i.s)(A,r[c],r[c+1],r[c+2]),(0,i.s)(_,r[u],r[u+1],r[u+2]);const h=x(b,A,_);h?((0,i.g)(b,b,A),(0,i.g)(b,b,_),(0,i.i)(b,b,1/3*h),(0,i.g)(t,t,b),s+=h):((0,i.g)(T,T,b),(0,i.g)(T,T,A),(0,i.g)(T,T,_),a+=3)}return!(0===a&&0===s||(0!==s?((0,i.i)(t,t,1/s),0):0===a||((0,i.i)(t,T,1/a),0)))}(this.attributes.get(Z.T.POSITION),e)}_computeAttachmentOriginLines(e){const t=this.attributes.get(Z.T.POSITION);return function(e,t,n){if(!e)return!1;(0,i.s)(n,0,0,0),(0,i.s)(T,0,0,0);let r=0,o=0;const{size:s,data:a,indices:l}=e,c=l.length-1,u=c+(t?2:0);for(let e=0;e<u;e+=2){const t=e<c?e+1:0,u=l[e<c?e:c]*s,h=l[t]*s;b[0]=a[u],b[1]=a[u+1],b[2]=a[u+2],A[0]=a[h],A[1]=a[h+1],A[2]=a[h+2],(0,i.i)(b,(0,i.g)(b,b,A),.5);const f=(0,i.r)(b,A);f>0?((0,i.g)(n,n,(0,i.i)(b,b,f)),r+=f):0===r&&((0,i.g)(T,T,b),o++)}return 0!==r?((0,i.i)(n,n,1/r),!0):0!==o&&((0,i.i)(n,T,1/o),!0)}(t,function(e,t){return!(!("isClosed"in e)||!e.isClosed)&&t.indices.length>2}(this.material.parameters,t),e)}_computeAttachmentOriginPoints(e){return function(e,t){if(!e)return!1;const{size:n,data:r,indices:o}=e;(0,i.s)(t,0,0,0);let s=-1,a=0;for(let e=0;e<o.length;e++){const i=o[e]*n;s!==i&&(t[0]+=r[i],t[1]+=r[i+1],t[2]+=r[i+2],a++),s=i}return a>1&&(0,i.i)(t,t,1/a),a>0}(this.attributes.get(Z.T.POSITION),e)}invalidateBoundingInfo(){this._boundingInfo=null}_calculateBoundingInfo(){const e=this.attributes.get(Z.T.POSITION);if(!e||0===e.indices.length)return null;const t=this.type===g.U.Mesh?3:1;(0,h.hu)(e.indices.length%t==0,"Indexing error: "+e.indices.length+" not divisible by "+t);const n=(0,o.KF)(e.indices.length/t);return new f(n,t,e)}get transformation(){return this._transformation??r.I}set transformation(e){this._transformation=e&&e!==r.I?(0,r.b)(e):null}addHighlight(){const e=new C(l.V_.Highlight);return this.highlights=function(e,t){return null==e&&(e=[]),e.push(t),e}(this.highlights,e),e}removeHighlight(e){this.highlights=function(e,t){if(null==e)return null;const n=e.filter((e=>e!==t));return 0===n.length?null:n}(this.highlights,e)}}},11726:(e,t,n)=>{n.d(t,{hu:()=>i,yK:()=>o}),n(97323),n(98766),(0,n(88669).c)();class r{constructor(e){this.message=e}toString(){return`AssertException: ${this.message}`}}function i(e,t){if(!e){t=t||"Assertion";const e=new Error(t).stack;throw new r(`${t} at ${e}`)}}function o(e,t,n,r){let i,o=(n[0]-e[0])/t[0],s=(r[0]-e[0])/t[0];o>s&&(i=o,o=s,s=i);let a=(n[1]-e[1])/t[1],l=(r[1]-e[1])/t[1];if(a>l&&(i=a,a=l,l=i),o>l||a>s)return!1;a>o&&(o=a),l<s&&(s=l);let c=(n[2]-e[2])/t[2],u=(r[2]-e[2])/t[2];return c>u&&(i=c,c=u,u=i),!(o>u||c>s||(u<s&&(s=u),s<0))}},47026:(e,t,n)=>{var r,i,o,s,a,l,c,u,h;n.d(t,{Gv:()=>i,Iq:()=>u,JJ:()=>c,Rw:()=>s,Ti:()=>h,V_:()=>l,Vr:()=>r,hU:()=>a}),function(e){e[e.None=0]="None",e[e.Front=1]="Front",e[e.Back=2]="Back",e[e.COUNT=3]="COUNT"}(r||(r={})),function(e){e[e.Less=0]="Less",e[e.Lequal=1]="Lequal",e[e.COUNT=2]="COUNT"}(i||(i={})),function(e){e[e.BACKGROUND=0]="BACKGROUND",e[e.UPDATE=1]="UPDATE"}(o||(o={})),function(e){e[e.NOT_LOADED=0]="NOT_LOADED",e[e.LOADING=1]="LOADING",e[e.LOADED=2]="LOADED"}(s||(s={})),function(e){e[e.IntegratedMeshMaskExcluded=1]="IntegratedMeshMaskExcluded",e[e.OutlineVisualElementMask=2]="OutlineVisualElementMask"}(a||(a={})),function(e){e[e.Highlight=0]="Highlight",e[e.MaskOccludee=1]="MaskOccludee",e[e.COUNT=2]="COUNT"}(l||(l={})),function(e){e[e.Blend=0]="Blend",e[e.Opaque=1]="Opaque",e[e.Mask=2]="Mask",e[e.MaskBlend=3]="MaskBlend",e[e.COUNT=4]="COUNT"}(c||(c={})),function(e){e[e.OFF=0]="OFF",e[e.ON=1]="ON"}(u||(u={})),function(e){e.DDS_ENCODING="image/vnd-ms.dds",e.KTX2_ENCODING="image/ktx2",e.BASIS_ENCODING="image/x.basis"}(h||(h={}))},9820:(e,t,n)=>{function r(e,t){const n=e.length;for(let r=0;r<n;++r)o[0]=e[r],t[r]=o[0];return t}function i(e,t){const n=e.length;for(let r=0;r<n;++r)o[0]=e[r],o[1]=e[r]-o[0],t[r]=o[1];return t}n.d(t,{GB:()=>i,U8:()=>r});const o=new Float32Array(2)}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8758],{48758:(e,n,t)=>{t.r(n),t.d(n,{registerFunctions:()=>$});var a=t(48853),i=t(28228),r=t(33586),l=t(27535),s=t(15274),o=t(28924),f=t(67651),u=t(12384),d=t(61363),c=t(26520),m=t(70409),y=t(84328),h=t(85065),p=t(63991),F=t(75148),w=t(17805),g=t(3823),I=t(90658),D=t(36515),T=t(24240),E=t(95330),x=t(8968),C=t(19238),N=t(1231),S=t(48522);async function b(e,n,t){const a=e.getVariables();if(a.length>0){const i=[];for(let e=0;e<a.length;e++){const r={name:a[e]};i.push(await n.evaluateIdentifier(t,r))}const r={};for(let e=0;e<a.length;e++)r[a[e]]=i[e];return e.parameters=r,e}return e}function A(e,n,t=null){for(const t in e)if(t.toLowerCase()===n.toLowerCase())return e[t];return t}function H(e){if(null===e)return null;const n={type:A(e,"type",""),name:A(e,"name","")};if("range"===n.type)n.range=A(e,"range",[]);else{n.codedValues=[];for(const t of A(e,"codedValues",[]))n.codedValues.push({name:A(t,"name",""),code:A(t,"code",null)})}return n}function R(e){if(null===e)return null;const n={},t=A(e,"wkt",null);null!==t&&(n.wkt=t);const a=A(e,"wkid",null);return null!==a&&(n.wkid=a),n}function Z(e){if(null===e)return null;const n={hasZ:A(e,"hasz",!1),hasM:A(e,"hasm",!1)},t=A(e,"spatialreference",null);t&&(n.spatialReference=R(t));const a=A(e,"x",null);if(null!==a)return n.x=a,n.y=A(e,"y",null),n;const i=A(e,"rings",null);if(null!==i)return n.rings=i,n;const r=A(e,"paths",null);if(null!==r)return n.paths=r,n;const l=A(e,"points",null);if(null!==l)return n.points=l,n;for(const t of["xmin","xmax","ymin","ymax","zmin","zmax","mmin","mmax"]){const a=A(e,t,null);null!==a&&(n[t]=a)}return n}function L(e){return"utc"===e?.toLowerCase()?"UTC":"unknown"===e?.toLowerCase()?"Unknown":e}function $(e){"async"===e.mode&&(e.functions.timezone=function(n,t){return e.standardFunctionAsync(n,t,(async(e,i,s)=>{if((0,d.E)(s,1,2,n,t),(0,d.n)(s[0]))return"Unknown";if((0,d.m)(s[0]))return"Unknown";if((0,d.u)(s[0])){if(await s[0].load(),1===s.length||null===s[1])return L(s[0].dateTimeReferenceFieldIndex.layerDateFieldsTimeZone);if(!(s[1]instanceof r.Z)||!1===s[1].hasField("type"))throw new l.aV(n,l.rH.InvalidParameter,t);const e=s[1].field("type");if(!1===(0,d.c)(e))throw new l.aV(n,l.rH.InvalidParameter,t);switch((0,d.j)(e).toLowerCase()){case"preferredtimezone":return L(s[0].dateTimeReferenceFieldIndex.layerPreferredTimeZone);case"editfieldsinfo":return L(s[0].dateTimeReferenceFieldIndex.layerEditFieldsTimeZone);case"timeinfo":return L(s[0].dateTimeReferenceFieldIndex.layerTimeInfoTimeZone);case"field":if(s[1].hasField("fieldname")&&(0,d.c)(s[1].field("fieldname")))return L(s[0].dateTimeReferenceFieldIndex.fieldTimeZone((0,d.j)(s[1].field("fieldname"))))}throw new l.aV(n,l.rH.InvalidParameter,t)}const o=(0,d.l)(s[0],(0,d.L)(n));if(null===o)return null;const f=o.timeZone;return"system"===f?a.iG.systemTimeZoneCanonicalName:"utc"===f.toLowerCase()?"UTC":"unknown"===f.toLowerCase()?"Unknown":f}))},e.functions.sqltimestamp=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{(0,d.E)(i,1,3,n,t);const r=i[0];if((0,d.k)(r)){if(1===i.length)return r.toSQLWithKeyword();if(2===i.length)return r.changeTimeZone((0,d.j)(i[1])).toSQLWithKeyword();throw new l.aV(n,l.rH.InvalidParameter,t)}if((0,d.m)(r))return r.toSQLWithKeyword();if((0,d.u)(r)){if(3!==i.length)throw new l.aV(n,l.rH.InvalidParameter,t);await r.load();const e=(0,d.j)(i[1]);if((0,d.m)(i[2]))return i[2].toSQLWithKeyword();if(!1===(0,d.k)(i[2]))throw new l.aV(n,l.rH.InvalidParameter,t);const a=r.fieldTimeZone(e);return null===a?i[2].toSQLWithKeyword():i[2].changeTimeZone(a).toSQLWithKeyword()}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"sqltimestamp",min:2,max:4}),e.functions.featuresetbyid=function(n,t){return e.standardFunctionAsync(n,t,((e,a,i)=>{if((0,d.E)(i,2,4,n,t),i[0]instanceof o.Z){const e=(0,d.j)(i[1]);let a=(0,d.H)(i[2],null);const r=(0,d.h)((0,d.H)(i[3],!0));if(null===a&&(a=["*"]),!1===(0,d.o)(a))throw new l.aV(n,l.rH.InvalidParameter,t);return i[0].featureSetById(e,r,a)}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"featuresetbyid",min:2,max:4}),e.functions.getfeatureset=function(n,t){return e.standardFunctionAsync(n,t,((e,a,i)=>{if((0,d.E)(i,1,2,n,t),(0,d.r)(i[0])){let e=(0,d.H)(i[1],"datasource");return null===e&&(e="datasource"),e=(0,d.j)(e).toLowerCase(),(0,f.convertToFeatureSet)(i[0].fullSchema(),e,n.lrucache,n.interceptor,n.spatialReference)}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"getfeatureset",min:1,max:2}),e.functions.featuresetbyportalitem=function(n,t){return e.standardFunctionAsync(n,t,((e,a,r)=>{if((0,d.E)(r,2,5,n,t),null===r[0])throw new l.aV(n,l.rH.PortalRequired,t);if(r[0]instanceof i.Z){const e=(0,d.j)(r[1]),a=(0,d.j)(r[2]);let i=(0,d.H)(r[3],null);const s=(0,d.h)((0,d.H)(r[4],!0));if(null===i&&(i=["*"]),!1===(0,d.o)(i))throw new l.aV(n,l.rH.InvalidParameter,t);let o=null;return o=n.services&&n.services.portal?n.services.portal:S.Z.getDefault(),o=(0,c._)(r[0],o),(0,f.constructFeatureSetFromPortalItem)(e,a,n.spatialReference,i,s,o,n.lrucache,n.interceptor)}if(!1===(0,d.c)(r[0]))throw new l.aV(n,l.rH.PortalRequired,t);const s=(0,d.j)(r[0]),o=(0,d.j)(r[1]);let u=(0,d.H)(r[2],null);const m=(0,d.h)((0,d.H)(r[3],!0));if(null===u&&(u=["*"]),!1===(0,d.o)(u))throw new l.aV(n,l.rH.InvalidParameter,t);return(0,f.constructFeatureSetFromPortalItem)(s,o,n.spatialReference,u,m,n.services?.portal??S.Z.getDefault(),n.lrucache,n.interceptor)}))},e.signatures.push({name:"featuresetbyportalitem",min:2,max:5}),e.functions.featuresetbyname=function(n,t){return e.standardFunctionAsync(n,t,((e,a,i)=>{if((0,d.E)(i,2,4,n,t),i[0]instanceof o.Z){const e=(0,d.j)(i[1]);let a=(0,d.H)(i[2],null);const r=(0,d.h)((0,d.H)(i[3],!0));if(null===a&&(a=["*"]),!1===(0,d.o)(a))throw new l.aV(n,l.rH.InvalidParameter,t);return i[0].featureSetByName(e,r,a)}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"featuresetbyname",min:2,max:4}),e.functions.featureset=function(n,t){return e.standardFunction(n,t,((e,a,i)=>{(0,d.E)(i,1,1,n,t);let s=i[0];const o={layerDefinition:{geometryType:"",objectIdField:"",hasM:!1,hasZ:!1,globalIdField:"",typeIdField:"",fields:[]},featureSet:{geometryType:"",features:[]}};if((0,d.c)(s))s=JSON.parse(s),void 0!==s.layerDefinition?(o.layerDefinition=s.layerDefinition,o.featureSet=s.featureSet,s.layerDefinition.spatialReference&&(o.layerDefinition.spatialReference=s.layerDefinition.spatialReference)):(o.featureSet.features=s.features,o.featureSet.geometryType=s.geometryType,o.layerDefinition.geometryType=o.featureSet.geometryType,o.layerDefinition.objectIdField=s.objectIdFieldName??"",o.layerDefinition.typeIdField=s.typeIdFieldName,o.layerDefinition.globalIdField=s.globalIdFieldName,o.layerDefinition.fields=s.fields,s.spatialReference&&(o.layerDefinition.spatialReference=s.spatialReference));else{if(!(i[0]instanceof r.Z))throw new l.aV(n,l.rH.InvalidParameter,t);{s=JSON.parse(i[0].castToText(!0));const e=A(s,"layerdefinition");if(null!==e){o.layerDefinition.geometryType=A(e,"geometrytype",""),o.featureSet.geometryType=o.layerDefinition.geometryType,o.layerDefinition.globalIdField=A(e,"globalidfield",""),o.layerDefinition.objectIdField=A(e,"objectidfield",""),o.layerDefinition.typeIdField=A(e,"typeidfield",""),o.layerDefinition.hasZ=!0===A(e,"hasz",!1),o.layerDefinition.hasM=!0===A(e,"hasm",!1);const n=A(e,"spatialreference",null);n&&(o.layerDefinition.spatialReference=R(n));for(const n of A(e,"fields",[])){const e={name:A(n,"name",""),alias:A(n,"alias",""),type:A(n,"type",""),nullable:A(n,"nullable",!0),editable:A(n,"editable",!0),length:A(n,"length",null),domain:H(A(n,"domain"))};o.layerDefinition.fields.push(e)}const t=A(s,"featureset",null);if(t){const e={};for(const n of o.layerDefinition.fields)e[n.name.toLowerCase()]=n.name;for(const n of A(t,"features",[])){const t={},a=A(n,"attributes",{});for(const n in a)t[e[n.toLowerCase()]]=a[n];o.featureSet.features.push({attributes:t,geometry:Z(A(n,"geometry",null))})}}}else{o.layerDefinition.hasZ=!0===A(s,"hasz",!1),o.layerDefinition.hasM=!0===A(s,"hasm",!1),o.layerDefinition.geometryType=A(s,"geometrytype",""),o.featureSet.geometryType=o.layerDefinition.geometryType,o.layerDefinition.objectIdField=A(s,"objectidfieldname",""),o.layerDefinition.typeIdField=A(s,"typeidfieldname","");const e=A(s,"spatialreference",null);e&&(o.layerDefinition.spatialReference=R(e));let n=A(s,"fields",null);if((0,d.o)(n))for(const e of n){const n={name:A(e,"name",""),alias:A(e,"alias",""),type:A(e,"type",""),nullable:A(e,"nullable",!0),editable:A(e,"editable",!0),length:A(e,"length",null),domain:H(A(e,"domain"))};o.layerDefinition.fields.push(n)}else n=null,o.layerDefinition.fields=n;const t={};for(const e of o.layerDefinition.fields)t[e.name.toLowerCase()]=e.name;let a=A(s,"features",null);if((0,d.o)(a))for(const e of a){const n={},a=A(e,"attributes",{});for(const e in a)n[t[e.toLowerCase()]]=a[e];o.featureSet.features.push({attributes:n,geometry:Z(A(e,"geometry",null))})}else a=null,o.featureSet.features=a}}}if(!1===function(e){return!!e.layerDefinition&&!!e.featureSet&&!1!==function(e,n){for(const n of["",null,"esriGeometryNull","esriGeometryPoint","esriGeometryPolyline","esriGeometryPolygon","esriGeometryMultipoint","esriGeometryEnvelope"])if(n===e)return!0;return!1}(e.layerDefinition.geometryType)&&!1!==(0,d.o)(e.layerDefinition.fields)&&!1!==(0,d.o)(e.featureSet.features)}(o))throw new l.aV(n,l.rH.InvalidParameter,t);return""===(o?.layerDefinition?.geometryType||"")&&(o.layerDefinition.geometryType="esriGeometryNull"),w.Z.create(o,n.spatialReference)}))},e.signatures.push({name:"featureset",min:1,max:1}),e.functions.filter=function(n,t){return e.standardFunctionAsync(n,t,(async(a,i,r)=>{if((0,d.E)(r,2,2,n,t),(0,d.o)(r[0])||(0,d.q)(r[0])){const e=[];let a=r[0];a instanceof u.Z&&(a=a.toArray());let i=null;if(!(0,d.i)(r[1]))throw new l.aV(n,l.rH.InvalidParameter,t);i=r[1].createFunction(n);for(const n of a){const t=i(n);(0,E.y8)(t)?!0===await t&&e.push(n):!0===t&&e.push(n)}return e}if((0,d.u)(r[0])){const t=await r[0].load(),a=x.WhereClause.create(r[1],t.getFieldsIndex(),t.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC),i=a.getVariables();if(i.length>0){const t=[];for(let a=0;a<i.length;a++){const r={name:i[a]};t.push(await e.evaluateIdentifier(n,r))}const l={};for(let e=0;e<i.length;e++)l[i[e]]=t[e];return a.parameters=l,new y.Z({parentfeatureset:r[0],whereclause:a})}return new y.Z({parentfeatureset:r[0],whereclause:a})}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"filter",min:2,max:2}),e.functions.orderby=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{if((0,d.E)(i,2,2,n,t),(0,d.u)(i[0])){const e=new g.Z(i[1]);return new h.Z({parentfeatureset:i[0],orderbyclause:e})}throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"orderby",min:2,max:2}),e.functions.top=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{if((0,d.E)(i,2,2,n,t),(0,d.u)(i[0]))return new p.Z({parentfeatureset:i[0],topnum:i[1]});if((0,d.o)(i[0]))return(0,d.g)(i[1])>=i[0].length?i[0].slice(0):i[0].slice(0,(0,d.g)(i[1]));if((0,d.q)(i[0]))return(0,d.g)(i[1])>=i[0].length()?i[0].slice(0):i[0].slice(0,(0,d.g)(i[1]));throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"top",min:2,max:2}),e.functions.first=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{if((0,d.E)(i,1,1,n,t),(0,d.u)(i[0])){const t=await i[0].first(e.abortSignal);if(null!==t){const e=s.Z.createFromGraphicLikeObject(t.geometry,t.attributes,i[0],n.timeReference);return e._underlyingGraphic=t,e}return t}return(0,d.o)(i[0])?0===i[0].length?null:i[0][0]:(0,d.q)(i[0])?0===i[0].length()?null:i[0].get(0):null}))},e.signatures.push({name:"first",min:1,max:1}),e.functions.attachments=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{(0,d.E)(i,1,2,n,t);const s={minsize:-1,maxsize:-1,types:null,returnMetadata:!1};if(i.length>1)if(i[1]instanceof r.Z){if(i[1].hasField("minsize")&&(s.minsize=(0,d.g)(i[1].field("minsize"))),i[1].hasField("metadata")&&(s.returnMetadata=(0,d.h)(i[1].field("metadata"))),i[1].hasField("maxsize")&&(s.maxsize=(0,d.g)(i[1].field("maxsize"))),i[1].hasField("types")){const e=(0,d.a2)(i[1].field("types"),!1);e.length>0&&(s.types=e)}}else if(null!==i[1])throw new l.aV(n,l.rH.InvalidParameter,t);if((0,d.r)(i[0])){let e=i[0]._layer;return e instanceof C.default&&(e=(0,f.constructFeatureSet)(e,n.spatialReference,["*"],!0,n.lrucache,n.interceptor)),null===e||!1===(0,d.u)(e)?[]:(await e.load(),e.queryAttachments(i[0].field(e.objectIdField),s.minsize,s.maxsize,s.types,s.returnMetadata))}if(null===i[0])return[];throw new l.aV(n,l.rH.InvalidParameter,t)}))},e.signatures.push({name:"attachments",min:1,max:2}),e.functions.featuresetbyrelationshipname=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{(0,d.E)(i,2,4,n,t);const r=i[0],s=(0,d.j)(i[1]);let o=(0,d.H)(i[2],null);const u=(0,d.h)((0,d.H)(i[3],!0));if(null===o&&(o=["*"]),!1===(0,d.o)(o))throw new l.aV(n,l.rH.InvalidParameter,t);if(null===i[0])return null;if(!(0,d.r)(i[0]))throw new l.aV(n,l.rH.InvalidParameter,t);let c=r._layer;if(c instanceof C.default&&(c=(0,f.constructFeatureSet)(c,n.spatialReference,["*"],!0,n.lrucache,n.interceptor)),null===c)return null;if(!1===(0,d.u)(c))return null;c=await c.load();const m=c.relationshipMetaData().filter((e=>e.name===s));if(0===m.length)return null;if(void 0!==m[0].relationshipTableId&&null!==m[0].relationshipTableId&&m[0].relationshipTableId>-1)return(0,f.constructFeatureSetFromRelationship)(c,m[0],r.field(c.objectIdField),c.spatialReference,o,u,n.lrucache,n.interceptor);let y=c.serviceUrl();if(!y)return null;y="/"===y.charAt(y.length-1)?y+m[0].relatedTableId.toString():y+"/"+m[0].relatedTableId.toString();const h=await(0,f.constructFeatureSetFromUrl)(y,c.spatialReference,o,u,n.lrucache,n.interceptor);await h.load();let p=h.relationshipMetaData();if(p=p.filter((e=>e.id===m[0].id)),!1===r.hasField(m[0].keyField)||null===r.field(m[0].keyField)){const e=await c.getFeatureByObjectId(r.field(c.objectIdField),[m[0].keyField]);if(e){const n=x.WhereClause.create(p[0].keyField+"= @id",h.getFieldsIndex(),h.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC);return n.parameters={id:e.attributes[m[0].keyField]},h.filter(n)}return new F.Z({parentfeatureset:h})}const w=x.WhereClause.create(p[0].keyField+"= @id",h.getFieldsIndex(),h.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC);return w.parameters={id:r.field(m[0].keyField)},h.filter(w)}))},e.signatures.push({name:"featuresetbyrelationshipname",min:2,max:4}),e.functions.featuresetbyassociation=function(n,t){return e.standardFunctionAsync(n,t,(async(e,a,i)=>{(0,d.E)(i,2,3,n,t);const r=i[0],s=(0,d.j)((0,d.H)(i[1],"")).toLowerCase(),o=(0,d.c)(i[2])?(0,d.j)(i[2]):null;if(null===i[0])return null;if(!(0,d.r)(i[0]))throw new l.aV(n,l.rH.InvalidParameter,t);let u=r._layer;if(u instanceof C.default&&(u=(0,f.constructFeatureSet)(u,n.spatialReference,["*"],!0,n.lrucache,n.interceptor)),null===u)return null;if(!1===(0,d.u)(u))return null;await u.load();const c=u.serviceUrl(),y=await(0,f.constructAssociationMetaDataFeatureSetFromUrl)(c,n.spatialReference);let h=null,p=null,F=!1;if(null!==o&&""!==o&&void 0!==o){for(const e of y.terminals)e.terminalName===o&&(p=e.terminalId);null===p&&(F=!0)}const w=y.associations.getFieldsIndex(),g=w.get("TOGLOBALID").name,D=w.get("FROMGLOBALID").name,T=w.get("TOTERMINALID").name,E=w.get("FROMTERMINALID").name,S=w.get("FROMNETWORKSOURCEID").name,b=w.get("TONETWORKSOURCEID").name,A=w.get("ASSOCIATIONTYPE").name,H=w.get("ISCONTENTVISIBLE").name,R=w.get("OBJECTID").name;for(const e of u.fields)if("global-id"===e.type){h=r.field(e.name);break}let Z=null,L=new m.yN(new N.Z({name:"percentalong",alias:"percentalong",type:"double"}),x.WhereClause.create("0",y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)),$=new m.yN(new N.Z({name:"side",alias:"side",type:"string"}),x.WhereClause.create("''",y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC));const v="globalid",P="globalId",V={};for(const e in y.lkp)V[e]=y.lkp[e].sourceId;const W=new m.TO(new N.Z({name:"classname",alias:"classname",type:"string"}),null,V);let k="";switch(s){case"midspan":{k=`((${g}='${h}') OR ( ${D}='${h}')) AND (${A} IN (5))`,W.codefield=x.WhereClause.create(`CASE WHEN (${g}='${h}') THEN ${S} ELSE ${b} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC);const e=(0,I.JW)(m.Xx.findField(y.associations.fields,D));e.name=v,e.alias=v,Z=new m.yN(e,x.WhereClause.create(`CASE WHEN (${D}='${h}') THEN ${g} ELSE ${D} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)),L=y.unVersion>=4?new m.$X(m.Xx.findField(y.associations.fields,w.get("PERCENTALONG").name)):new m.yN(new N.Z({name:"percentalong",alias:"percentalong",type:"double"}),x.WhereClause.create("0",y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC));break}case"junctionedge":{k=`((${g}='${h}') OR ( ${D}='${h}')) AND (${A} IN (4,6))`,W.codefield=x.WhereClause.create(`CASE WHEN (${g}='${h}') THEN ${S} ELSE ${b} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC);const e=(0,I.JW)(m.Xx.findField(y.associations.fields,D));e.name=v,e.alias=v,Z=new m.yN(e,x.WhereClause.create(`CASE WHEN (${D}='${h}') THEN ${g} ELSE ${D} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)),$=new m.yN(new N.Z({name:"side",alias:"side",type:"string"}),x.WhereClause.create(`CASE WHEN (${A}=4) THEN 'from' ELSE 'to' END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC));break}case"connected":{let e=`${g}='@T'`,n=`${D}='@T'`;null!==p&&(e+=` AND ${T}=@A`,n+=` AND ${E}=@A`),k="(("+e+") OR ("+n+"))",k=(0,d.S)(k,"@T",h??""),e=(0,d.S)(e,"@T",h??""),null!==p&&(e=(0,d.S)(e,"@A",p.toString()),k=(0,d.S)(k,"@A",p.toString())),W.codefield=x.WhereClause.create("CASE WHEN "+e+` THEN ${S} ELSE ${b} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC);const t=(0,I.JW)(m.Xx.findField(y.associations.fields,D));t.name=v,t.alias=v,Z=new m.yN(t,x.WhereClause.create("CASE WHEN "+e+` THEN ${D} ELSE ${g} END`,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC));break}case"container":k=`${g}='${h}' AND ${A} = 2`,null!==p&&(k+=` AND ${T} = `+p.toString()),W.codefield=S,k="( "+k+" )",Z=new m.QP(m.Xx.findField(y.associations.fields,D),v,v);break;case"content":k=`(${D}='${h}' AND ${A} = 2)`,null!==p&&(k+=` AND ${E} = `+p.toString()),W.codefield=b,k="( "+k+" )",Z=new m.QP(m.Xx.findField(y.associations.fields,g),v,v);break;case"structure":k=`(${g}='${h}' AND ${A} = 3)`,null!==p&&(k+=` AND ${T} = `+p.toString()),W.codefield=S,k="( "+k+" )",Z=new m.QP(m.Xx.findField(y.associations.fields,D),v,P);break;case"attached":k=`(${D}='${h}' AND ${A} = 3)`,null!==p&&(k+=` AND ${E} = `+p.toString()),W.codefield=b,k="( "+k+" )",Z=new m.QP(m.Xx.findField(y.associations.fields,g),v,P);break;default:throw new l.aV(n,l.rH.InvalidParameter,t)}return F&&(k="1 <> 1"),new m.Xx({parentfeatureset:y.associations,adaptedFields:[new m.$X(m.Xx.findField(y.associations.fields,R)),new m.$X(m.Xx.findField(y.associations.fields,H)),Z,$,W,L],extraFilter:k?x.WhereClause.create(k,y.associations.getFieldsIndex(),y.associations.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC):null})}))},e.signatures.push({name:"featuresetbyassociation",min:2,max:6}),e.functions.groupby=function(n,t){return e.standardFunctionAsync(n,t,(async(a,i,s)=>{if((0,d.E)(s,3,3,n,t),!(0,d.u)(s[0]))throw new l.aV(n,l.rH.InvalidParameter,t);const o=await s[0].load(),f=[],u=[];let c=!1,m=[];if((0,d.c)(s[1]))m.push(s[1]);else if(s[1]instanceof r.Z)m.push(s[1]);else if((0,d.o)(s[1]))m=s[1];else{if(!(0,d.q)(s[1]))throw new l.aV(n,l.rH.InvalidParameter,t);m=s[1].toArray()}for(const e of m)if((0,d.c)(e)){const n=x.WhereClause.create((0,d.j)(e),o.getFieldsIndex(),o.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC),t=!0===(0,D.y5)(n)?(0,d.j)(e):"%%%%FIELDNAME";f.push({name:t,expression:n}),"%%%%FIELDNAME"===t&&(c=!0)}else{if(!(e instanceof r.Z))throw new l.aV(n,l.rH.InvalidParameter,t);{const a=e.hasField("name")?e.field("name"):"%%%%FIELDNAME",i=e.hasField("expression")?e.field("expression"):"";if("%%%%FIELDNAME"===a&&(c=!0),!a)throw new l.aV(n,l.rH.InvalidParameter,t);f.push({name:a,expression:x.WhereClause.create(i||a,o.getFieldsIndex(),o.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)})}}if(m=[],(0,d.c)(s[2]))m.push(s[2]);else if((0,d.o)(s[2]))m=s[2];else if((0,d.q)(s[2]))m=s[2].toArray();else{if(!(s[2]instanceof r.Z))throw new l.aV(n,l.rH.InvalidParameter,t);m.push(s[2])}for(const e of m){if(!(e instanceof r.Z))throw new l.aV(n,l.rH.InvalidParameter,t);{const a=e.hasField("name")?e.field("name"):"",i=e.hasField("statistic")?e.field("statistic"):"",r=e.hasField("expression")?e.field("expression"):"";if(!a||!i||!r)throw new l.aV(n,l.rH.InvalidParameter,t);u.push({name:a,statistic:i.toLowerCase(),expression:x.WhereClause.create(r,o.getFieldsIndex(),o.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)})}}if(c){const e={};for(const n of o.fields)e[n.name.toLowerCase()]=1;for(const n of f)"%%%%FIELDNAME"!==n.name&&(e[n.name.toLowerCase()]=1);for(const n of u)"%%%%FIELDNAME"!==n.name&&(e[n.name.toLowerCase()]=1);let n=0;for(const t of f)if("%%%%FIELDNAME"===t.name){for(;1===e["field_"+n.toString()];)n++;e["field_"+n.toString()]=1,t.name="FIELD_"+n.toString()}}for(const t of f)await b(t.expression,e,n);for(const t of u)await b(t.expression,e,n);return s[0].groupby(f,u)}))},e.signatures.push({name:"groupby",min:3,max:3}),e.functions.distinct=function(n,t){return e.standardFunctionAsync(n,t,(async(a,i,s)=>{if((0,d.u)(s[0])){(0,d.E)(s,2,2,n,t);const a=await s[0].load(),i=[];let o=[];if((0,d.c)(s[1]))o.push(s[1]);else if(s[1]instanceof r.Z)o.push(s[1]);else if((0,d.o)(s[1]))o=s[1];else{if(!(0,d.q)(s[1]))throw new l.aV(n,l.rH.InvalidParameter,t);o=s[1].toArray()}let f=!1;for(const e of o)if((0,d.c)(e)){const n=x.WhereClause.create((0,d.j)(e),a.getFieldsIndex(),a.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC),t=!0===(0,D.y5)(n)?(0,d.j)(e):"%%%%FIELDNAME";i.push({name:t,expression:n}),"%%%%FIELDNAME"===t&&(f=!0)}else{if(!(e instanceof r.Z))throw new l.aV(n,l.rH.InvalidParameter,t);{const r=e.hasField("name")?e.field("name"):"%%%%FIELDNAME",s=e.hasField("expression")?e.field("expression"):"";if("%%%%FIELDNAME"===r&&(f=!0),!r)throw new l.aV(n,l.rH.InvalidParameter,t);i.push({name:r,expression:x.WhereClause.create(s||r,a.getFieldsIndex(),a.dateTimeReferenceFieldIndex.layerDateFieldsTimeZoneDefaultUTC)})}}if(f){const e={};for(const n of a.fields)e[n.name.toLowerCase()]=1;for(const n of i)"%%%%FIELDNAME"!==n.name&&(e[n.name.toLowerCase()]=1);let n=0;for(const t of i)if("%%%%FIELDNAME"===t.name){for(;1===e["field_"+n.toString()];)n++;e["field_"+n.toString()]=1,t.name="FIELD_"+n.toString()}}for(const t of i)await b(t.expression,e,n);return s[0].groupby(i,[])}return function(e,n,t,a){if(1===a.length){if((0,d.o)(a[0]))return(0,T.t)(e,a[0],-1);if((0,d.q)(a[0]))return(0,T.t)(e,a[0].toArray(),-1)}return(0,T.t)(e,a,-1)}("distinct",0,0,s)}))})}},26520:(e,n,t)=>{t.d(n,{_:()=>i});var a=t(48522);function i(e,n){return null===e?n:new a.Z({url:e.field("url")})}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8767],{48853:(e,t,s)=>{s.d(t,{Qn:()=>d,iG:()=>u});var i,n=s(19153),r=s(17126);class o{}o.instance=new r.vF("Etc/UTC"),(i||(i={})).TimeZoneNotRecognized="TimeZoneNotRecognized";const a={[i.TimeZoneNotRecognized]:"Timezone identifier has not been recognized."};class h extends Error{constructor(e,t){super((0,n.gx)(a[e],t)),this.declaredRootClass="esri.arcade.arcadedate.dateerror",Error.captureStackTrace&&Error.captureStackTrace(this,h)}}function c(e,t,s){return e<t?e-t:e>s?e-s:0}function l(e,t,s){return e<t?t:e>s?s:e}class u{constructor(e){this._date=e,this.declaredRootClass="esri.arcade.arcadedate"}static fromParts(e=0,t=1,s=1,i=0,n=0,o=0,a=0,h){if(isNaN(e)||isNaN(t)||isNaN(s)||isNaN(i)||isNaN(n)||isNaN(o)||isNaN(a))return null;const m=r.ou.local(e,t).daysInMonth;let f=r.ou.fromObject({day:l(s,1,m),year:e,month:l(t,1,12),hour:l(i,0,23),minute:l(n,0,59),second:l(o,0,59),millisecond:l(a,0,999)},{zone:d(h)});return f=f.plus({months:c(t,1,12),days:c(s,1,m),hours:c(i,0,23),minutes:c(n,0,59),seconds:c(o,0,59),milliseconds:c(a,0,999)}),new u(f)}static get systemTimeZoneCanonicalName(){return Intl.DateTimeFormat().resolvedOptions().timeZone??"system"}static arcadeDateAndZoneToArcadeDate(e,t){const s=d(t);return e.isUnknownTimeZone||s===o.instance?u.fromParts(e.year,e.monthJS+1,e.day,e.hour,e.minute,e.second,e.millisecond,s):new u(e._date.setZone(s))}static dateJSToArcadeDate(e){return new u(r.ou.fromJSDate(e,{zone:"system"}))}static dateJSAndZoneToArcadeDate(e,t="system"){const s=d(t);return new u(r.ou.fromJSDate(e,{zone:s}))}static unknownEpochToArcadeDate(e){return new u(r.ou.fromMillis(e,{zone:o.instance}))}static unknownDateJSToArcadeDate(e){return new u(r.ou.fromMillis(e.getTime(),{zone:o.instance}))}static epochToArcadeDate(e,t="system"){const s=d(t);return new u(r.ou.fromMillis(e,{zone:s}))}static dateTimeToArcadeDate(e){return new u(e)}clone(){return new u(this._date)}changeTimeZone(e){const t=d(e);return u.dateTimeToArcadeDate(this._date.setZone(t))}static dateTimeAndZoneToArcadeDate(e,t){const s=d(t);return e.zone===o.instance||s===o.instance?u.fromParts(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond,s):new u(e.setZone(s))}static nowToArcadeDate(e){const t=d(e);return new u(r.ou.fromJSDate(new Date,{zone:t}))}static nowUTCToArcadeDate(){return new u(r.ou.utc())}get isSystem(){return"system"===this.timeZone||this.timeZone===u.systemTimeZoneCanonicalName}equals(e){return this.isSystem&&e.isSystem?this.toNumber()===e.toNumber():this.isUnknownTimeZone===e.isUnknownTimeZone&&this._date.equals(e._date)}get isUnknownTimeZone(){return this._date.zone===o.instance}get isValid(){return this._date.isValid}get hour(){return this._date.hour}get second(){return this._date.second}get day(){return this._date.day}get dayOfWeekISO(){return this._date.weekday}get dayOfWeekJS(){let e=this._date.weekday;return e>6&&(e=0),e}get millisecond(){return this._date.millisecond}get monthISO(){return this._date.month}get weekISO(){return this._date.weekNumber}get yearISO(){return this._date.weekYear}get monthJS(){return this._date.month-1}get year(){return this._date.year}get minute(){return this._date.minute}get zone(){return this._date.zone}get timeZoneOffset(){return this.isUnknownTimeZone?0:this._date.offset}get timeZone(){if(this.isUnknownTimeZone)return"unknown";if("system"===this._date.zone.type)return"system";const e=this.zone;return"fixed"===e.type?0===e.fixed?"UTC":e.formatOffset(0,"short"):e.name}stringify(){return JSON.stringify(this.toJSDate())}plus(e){return new u(this._date.plus(e))}diff(e,t="milliseconds"){return this._date.diff(e._date,t)[t]}toISOString(e){return e?this._date.toISO({suppressMilliseconds:!0,includeOffset:!this.isUnknownTimeZone}):this._date.toISO({includeOffset:!this.isUnknownTimeZone})}toFormat(e,t){return this.isUnknownTimeZone&&(e=e.replaceAll("Z","")),this._date.toFormat(e,t)}toJSDate(){return this._date.toJSDate()}toSQLValue(){return this._date.toFormat("yyyy-LL-dd HH:mm:ss")}toSQLWithKeyword(){return`timestamp '${this.toSQLValue()}'`}toDateTime(){return this._date}toNumber(){return this._date.toMillis()}getTime(){return this._date.toMillis()}toUTC(){return new u(this._date.toUTC())}toLocal(){return new u(this._date.toLocal())}toString(){return this.toISOString(!0)}static fromReaderAsTimeStampOffset(e){if(!e)return null;const t=r.ou.fromISO(e,{setZone:!0});return new u(t)}}function d(e,t=!0){if(e instanceof r.ld)return e;if("system"===e.toLowerCase())return"system";if("utc"===e.toLowerCase())return"UTC";if("unknown"===e.toLowerCase())return o.instance;if(/^[\+\-]?[0-9]{1,2}([:][0-9]{2})?$/.test(e)){const t=r.Qf.parseSpecifier("UTC"+(e.startsWith("+")||e.startsWith("-")?"":"+")+e);if(t)return t}const s=r.vF.create(e);if(!s.isValid){if(t)throw new h(i.TimeZoneNotRecognized);return null}return s}},77286:(e,t,s)=>{s.d(t,{EI:()=>n,Lz:()=>o,SV:()=>r,U:()=>h,r1:()=>a});var i=s(6570);function n(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 109404;case"miles":case"mile":case"squaremile":case"squaremiles":return 109439;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 109414;case"acres":case"acre":case"ac":return 109402;case"hectares":case"hectare":case"ha":return 109401;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 109442;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 109405;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 109409}return null}function r(e){if(null==e)return null;switch(e.type){case"polygon":case"multipoint":case"polyline":return e.extent;case"point":return new i.Z({xmin:e.x,ymin:e.y,xmax:e.x,ymax:e.y,spatialReference:e.spatialReference});case"extent":return e}return null}function o(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 9001;case"miles":case"mile":case"squaremile":case"squaremiles":return 9093;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 9036;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 9096;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 9002;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 9030}return null}function a(e){if(null==e)return null;const t=e.clone();return void 0!==e.cache._geVersion&&(t.cache._geVersion=e.cache._geVersion),t}function h(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e}},46791:(e,t,s)=>{s.d(t,{Z:()=>A});var i,n=s(43697),r=s(3894),o=s(32448),a=s(50758),h=s(22974),c=s(71143);!function(e){e[e.ADD=1]="ADD",e[e.REMOVE=2]="REMOVE",e[e.MOVE=4]="MOVE"}(i||(i={}));var l,u=s(1654),d=s(75215),m=s(58971),f=s(5600),_=s(52421),g=s(52011),p=s(10661);class y{constructor(e,t,s,i,n){this.target=e,this.added=t,this.removed=s,this.start=i,this.deleteCount=n}}const b=new c.Z(class{constructor(){this.target=null,this.cancellable=!1,this.defaultPrevented=!1,this.item=void 0,this.type=void 0}preventDefault(){this.cancellable&&(this.defaultPrevented=!0)}reset(e){this.defaultPrevented=!1,this.item=e}},void 0,(e=>{e.item=null,e.target=null,e.defaultPrevented=!1,e.cancellable=!1}));function v(e){return e?e instanceof C?e.toArray():e.length?Array.prototype.slice.apply(e):[]:[]}function S(e){if(e&&e.length)return e[0]}function x(e,t,s,i){const n=Math.min(e.length-s,t.length-i);let r=0;for(;r<n&&e[s+r]===t[i+r];)r++;return r}function T(e,t,s,i){t&&t.forEach(((t,n,r)=>{e.push(t),T(e,s.call(i,t,n,r),s,i)}))}const I=new Set,w=new Set,M=new Set,E=new Map;let D=0,C=l=class extends o.Z.EventedAccessor{static isCollection(e){return null!=e&&e instanceof l}constructor(e){super(e),this._chgListeners=[],this._notifications=null,this._timer=null,this._observable=new p.s,this.length=0,this._items=[],Object.defineProperty(this,"uid",{value:D++})}normalizeCtorArgs(e){return e?Array.isArray(e)||e instanceof l?{items:e}:e:{}}destroy(){this._removeAllRaw()}*[Symbol.iterator](){yield*this.items}get items(){return(0,m.it)(this._observable),this._items}set items(e){this._emitBeforeChanges(i.ADD)||(this._splice(0,this.length,v(e)),this._emitAfterChanges(i.ADD))}hasEventListener(e){return"change"===e?this._chgListeners.length>0:this._emitter.hasEventListener(e)}on(e,t){if("change"===e){const e=this._chgListeners,s={removed:!1,callback:t};return e.push(s),this._notifications&&this._notifications.push({listeners:e.slice(),items:this._items.slice(),changes:[]}),(0,a.kB)((()=>{s.removed=!0,e.splice(e.indexOf(s),1)}))}return this._emitter.on(e,t)}once(e,t){const s="deref"in t?()=>t.deref():()=>t,i=this.on(e,(e=>{s()?.call(null,e),i.remove()}));return i}add(e,t){if((0,m.it)(this._observable),this._emitBeforeChanges(i.ADD))return this;const s=this.getNextIndex(t??null);return this._splice(s,0,[e]),this._emitAfterChanges(i.ADD),this}addMany(e,t=this._items.length){if((0,m.it)(this._observable),!e||!e.length)return this;if(this._emitBeforeChanges(i.ADD))return this;const s=this.getNextIndex(t);return this._splice(s,0,v(e)),this._emitAfterChanges(i.ADD),this}at(e){if((0,m.it)(this._observable),(e=Math.trunc(e)||0)<0&&(e+=this.length),!(e<0||e>=this.length))return this._items[e]}removeAll(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(i.REMOVE))return[];const e=this._removeAllRaw();return this._emitAfterChanges(i.REMOVE),e}_removeAllRaw(){return 0===this.length?[]:this._splice(0,this.length)||[]}clone(){return(0,m.it)(this._observable),this._createNewInstance({items:this._items.map(h.d9)})}concat(...e){(0,m.it)(this._observable);const t=e.map(v);return this._createNewInstance({items:this._items.concat(...t)})}drain(e,t){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(i.REMOVE))return;const s=this._splice(0,this.length),n=s.length;for(let i=0;i<n;i++)e.call(t,s[i],i,s);this._emitAfterChanges(i.REMOVE)}every(e,t){return(0,m.it)(this._observable),this._items.every(e,t)}filter(e,t){let s;return(0,m.it)(this._observable),s=2===arguments.length?this._items.filter(e,t):this._items.filter(e),this._createNewInstance({items:s})}find(e,t){return(0,m.it)(this._observable),this._items.find(e,t)}findIndex(e,t){return(0,m.it)(this._observable),this._items.findIndex(e,t)}flatten(e,t){(0,m.it)(this._observable);const s=[];return T(s,this,e,t),new l(s)}forEach(e,t){return(0,m.it)(this._observable),this._items.forEach(e,t)}getItemAt(e){return(0,m.it)(this._observable),this._items[e]}getNextIndex(e){(0,m.it)(this._observable);const t=this.length;return(e=e??t)<0?e=0:e>t&&(e=t),e}includes(e,t=0){return(0,m.it)(this._observable),this._items.includes(e,t)}indexOf(e,t=0){return(0,m.it)(this._observable),this._items.indexOf(e,t)}join(e=","){return(0,m.it)(this._observable),this._items.join(e)}lastIndexOf(e,t=this.length-1){return(0,m.it)(this._observable),this._items.lastIndexOf(e,t)}map(e,t){(0,m.it)(this._observable);const s=this._items.map(e,t);return new l({items:s})}reorder(e,t=this.length-1){(0,m.it)(this._observable);const s=this.indexOf(e);if(-1!==s){if(t<0?t=0:t>=this.length&&(t=this.length-1),s!==t){if(this._emitBeforeChanges(i.MOVE))return e;this._splice(s,1),this._splice(t,0,[e]),this._emitAfterChanges(i.MOVE)}return e}}pop(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(i.REMOVE))return;const e=S(this._splice(this.length-1,1));return this._emitAfterChanges(i.REMOVE),e}push(...e){return(0,m.it)(this._observable),this._emitBeforeChanges(i.ADD)||(this._splice(this.length,0,e),this._emitAfterChanges(i.ADD)),this.length}reduce(e,t){(0,m.it)(this._observable);const s=this._items;return 2===arguments.length?s.reduce(e,t):s.reduce(e)}reduceRight(e,t){(0,m.it)(this._observable);const s=this._items;return 2===arguments.length?s.reduceRight(e,t):s.reduceRight(e)}remove(e){return(0,m.it)(this._observable),this.removeAt(this.indexOf(e))}removeAt(e){if((0,m.it)(this._observable),e<0||e>=this.length||this._emitBeforeChanges(i.REMOVE))return;const t=S(this._splice(e,1));return this._emitAfterChanges(i.REMOVE),t}removeMany(e){if((0,m.it)(this._observable),!e||!e.length||this._emitBeforeChanges(i.REMOVE))return[];const t=e instanceof l?e.toArray():e,s=this._items,n=[],r=t.length;for(let e=0;e<r;e++){const i=t[e],r=s.indexOf(i);if(r>-1){const i=1+x(t,s,e+1,r+1),o=this._splice(r,i);o&&o.length>0&&n.push.apply(n,o),e+=i-1}}return this._emitAfterChanges(i.REMOVE),n}reverse(){if((0,m.it)(this._observable),this._emitBeforeChanges(i.MOVE))return this;const e=this._splice(0,this.length);return e&&(e.reverse(),this._splice(0,0,e)),this._emitAfterChanges(i.MOVE),this}shift(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(i.REMOVE))return;const e=S(this._splice(0,1));return this._emitAfterChanges(i.REMOVE),e}slice(e=0,t=this.length){return(0,m.it)(this._observable),this._createNewInstance({items:this._items.slice(e,t)})}some(e,t){return(0,m.it)(this._observable),this._items.some(e,t)}sort(e){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(i.MOVE))return this;const t=this._splice(0,this.length);return arguments.length?t.sort(e):t.sort(),this._splice(0,0,t),this._emitAfterChanges(i.MOVE),this}splice(e,t,...s){(0,m.it)(this._observable);const n=(t?i.REMOVE:0)|(s.length?i.ADD:0);if(this._emitBeforeChanges(n))return[];const r=this._splice(e,t,s)||[];return this._emitAfterChanges(n),r}toArray(){return(0,m.it)(this._observable),this._items.slice()}toJSON(){return(0,m.it)(this._observable),this.toArray()}toLocaleString(){return(0,m.it)(this._observable),this._items.toLocaleString()}toString(){return(0,m.it)(this._observable),this._items.toString()}unshift(...e){return(0,m.it)(this._observable),!e.length||this._emitBeforeChanges(i.ADD)||(this._splice(0,0,e),this._emitAfterChanges(i.ADD)),this.length}_createNewInstance(e){return new this.constructor(e)}_splice(e,t,s){const i=this._items,n=this.itemType;let r,o;if(!this._notifications&&this.hasEventListener("change")&&(this._notifications=[{listeners:this._chgListeners.slice(),items:this._items.slice(),changes:[]}],this._timer&&this._timer.remove(),this._timer=(0,u.Os)((()=>this._dispatchChange()))),e<0&&(e+=this.length),t){if(o=i.splice(e,t),this.hasEventListener("before-remove")){const t=b.acquire();t.target=this,t.cancellable=!0;for(let s=0,n=o.length;s<n;s++)r=o[s],t.reset(r),this.emit("before-remove",t),t.defaultPrevented&&(o.splice(s,1),i.splice(e,0,r),e+=1,s-=1,n-=1);b.release(t)}if(this.length=this._items.length,this.hasEventListener("after-remove")){const e=b.acquire();e.target=this,e.cancellable=!1;const t=o.length;for(let s=0;s<t;s++)e.reset(o[s]),this.emit("after-remove",e);b.release(e)}}if(s&&s.length){if(n){const e=[];for(const t of s){const s=n.ensureType(t);null==s&&null!=t||e.push(s)}s=e}const t=this.hasEventListener("before-add"),r=this.hasEventListener("after-add"),o=e===this.length;if(t||r){const n=b.acquire();n.target=this,n.cancellable=!0;const a=b.acquire();a.target=this,a.cancellable=!1;for(const h of s)t?(n.reset(h),this.emit("before-add",n),n.defaultPrevented||(o?i.push(h):i.splice(e++,0,h),this._set("length",i.length),r&&(a.reset(h),this.emit("after-add",a)))):(o?i.push(h):i.splice(e++,0,h),this._set("length",i.length),a.reset(h),this.emit("after-add",a));b.release(a),b.release(n)}else{if(o)for(const e of s)i.push(e);else i.splice(e,0,...s);this._set("length",i.length)}}if((s&&s.length||o&&o.length)&&this._notifyChangeEvent(s,o),this.hasEventListener("after-splice")){const i=new y(this,s,o,e,t);this.emit("after-splice",i)}return o}_emitBeforeChanges(e){let t=!1;if(this.hasEventListener("before-changes")){const s=b.acquire();s.target=this,s.cancellable=!0,s.type=e,this.emit("before-changes",s),t=s.defaultPrevented,b.release(s)}return t}_emitAfterChanges(e){if(this.hasEventListener("after-changes")){const t=b.acquire();t.target=this,t.cancellable=!1,t.type=e,this.emit("after-changes",t),b.release(t)}this._observable.notify()}_notifyChangeEvent(e,t){this.hasEventListener("change")&&this._notifications&&this._notifications[this._notifications.length-1].changes.push({added:e,removed:t})}_dispatchChange(){if(this._timer&&(this._timer.remove(),this._timer=null),!this._notifications)return;const e=this._notifications;this._notifications=null;for(const t of e){const e=t.changes;I.clear(),w.clear(),M.clear();for(const{added:t,removed:s}of e){if(t)if(0===M.size&&0===w.size)for(const e of t)I.add(e);else for(const e of t)w.has(e)?(M.add(e),w.delete(e)):M.has(e)||I.add(e);if(s)if(0===M.size&&0===I.size)for(const e of s)w.add(e);else for(const e of s)I.has(e)?I.delete(e):(M.delete(e),w.add(e))}const s=r.Z.acquire();I.forEach((e=>{s.push(e)}));const i=r.Z.acquire();w.forEach((e=>{i.push(e)}));const n=this._items,o=t.items,a=r.Z.acquire();if(M.forEach((e=>{o.indexOf(e)!==n.indexOf(e)&&a.push(e)})),t.listeners&&(s.length||i.length||a.length)){const e={target:this,added:s,removed:i,moved:a},n=t.listeners.length;for(let s=0;s<n;s++){const i=t.listeners[s];i.removed||i.callback.call(this,e)}}r.Z.release(s),r.Z.release(i),r.Z.release(a)}I.clear(),w.clear(),M.clear()}};C.ofType=e=>{if(!e)return l;if(E.has(e))return E.get(e);let t=null;if("function"==typeof e)t=e.prototype.declaredClass;else if(e.base)t=e.base.prototype.declaredClass;else for(const s in e.typeMap){const i=e.typeMap[s].prototype.declaredClass;t?t+=` | ${i}`:t=i}let s=class extends l{};return(0,n._)([(0,_.c)({Type:e,ensureType:"function"==typeof e?(0,d.se)(e):(0,d.N7)(e)})],s.prototype,"itemType",void 0),s=(0,n._)([(0,g.j)(`esri.core.Collection<${t}>`)],s),E.set(e,s),s},(0,n._)([(0,f.Cb)()],C.prototype,"length",void 0),(0,n._)([(0,f.Cb)()],C.prototype,"items",null),C=l=(0,n._)([(0,g.j)("esri.core.Collection")],C);const A=C},32448:(e,t,s)=>{s.d(t,{Z:()=>h});var i=s(43697),n=s(92036),r=s(50758),o=s(52011);class a{constructor(){this._emitter=new a.EventEmitter(this)}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}}!function(e){class t{constructor(e=null){this._target=e,this._listenersMap=null}clear(){this._listenersMap?.clear(),this._listenersMap=null}destroy(){this.clear()}emit(e,t){let s=this._listenersMap?.get(e);if(!s)return!1;const i=this._target||this;let n=!1;for(const e of s.slice()){const s="deref"in e?e.deref():e;s?s?.call(i,t):n=!0}return n&&(s=s.filter((e=>!("deref"in e)||null!=e.deref())),this._listenersMap.set(e,s)),s.length>0}on(e,t){if(Array.isArray(e)){const s=e.map((e=>this.on(e,t)));return(0,r.AL)(s)}if(e.includes(","))throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap??=new Map;const s=this._listenersMap.get(e)||[];return s.push(t),this._listenersMap.set(e,s),(0,r.kB)((()=>{const s=this._listenersMap?.get(e),i=s?.indexOf(t)??-1;i>=0&&s.splice(i,1)}))}once(e,t){const s=this.on(e,(e=>{s.remove();const i="deref"in t?t.deref():t;i?.call(null,e)}));return s}hasEventListener(e){const t=this._listenersMap&&this._listenersMap.get(e);return null!=t&&t.length>0}}e.EventEmitter=t,e.EventedMixin=e=>{let s=class extends e{constructor(){super(...arguments),this._emitter=new t}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};return s=(0,i._)([(0,o.j)("esri.core.Evented")],s),s};let s=class extends n.Z{constructor(){super(...arguments),this._emitter=new a.EventEmitter(this)}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};s=(0,i._)([(0,o.j)("esri.core.Evented")],s),e.EventedAccessor=s}(a||(a={}));const h=a},13867:(e,t,s)=>{s.d(t,{z:()=>n});var i=s(69801);class n{constructor(e,t){this._storage=new i.WJ,this.id="",this.name="",this.size=0,this._storage.maxSize=e,this._storage.register(this),t&&this._storage.registerRemoveFunc("",t)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,s=1){this._storage.put(this,e,t,s,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},69801:(e,t,s)=>{s.d(t,{WJ:()=>a,Xq:()=>o});var i,n,r=s(44553);(n=i||(i={}))[n.ALL=0]="ALL",n[n.SOME=1]="SOME";class o{constructor(e,t,s){this.name=e,this._storage=t,this.id=h+++":",this.size=0,this.maxSize=0,this._removeFunc=!1,this._hit=0,this._miss=0,this._storage.register(this),s&&(this._storage.registerRemoveFunc(this.id,s),this._removeFunc=!0)}destroy(){this._storage.clear(this),this._removeFunc&&this._storage.deregisterRemoveFunc(this.id),this._storage.deregister(this),this._storage=null}get hitRate(){return this._hit/(this._hit+this._miss)}get sizeAll(){return this._storage.size}resetHitRate(){this._hit=this._miss=0}put(e,t,s,i=0){this._storage.put(this,e,t,s,i)}get(e){const t=this._storage.get(this,e);return void 0===t?++this._miss:++this._hit,t}peek(e){return this._storage.peek(this,e)}pop(e){const t=this._storage.pop(this,e);return void 0===t?++this._miss:++this._hit,t}updateSize(e,t,s){this._storage.updateSize(this,e,t,s)}clear(){this._storage.clear(this)}clearAll(){this._storage.clearAll()}get performanceInfo(){return this._storage.performanceInfo}resetStats(){this._storage.resetStats()}}class a{get size(){return this._size}constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._removeFuncs=new r.Z,this._users=new r.Z}destroy(){this.clearAll(),this._removeFuncs.clear(),this._users.clear(),this._db=null}register(e){this._users.push(e)}deregister(e){this._users.removeUnordered(e)}registerRemoveFunc(e,t){this._removeFuncs.push([e,t])}deregisterRemoveFunc(e){this._removeFuncs.filterInPlace((t=>t[0]!==e))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,0),this._checkSizeLimits()}put(e,t,s,n,r){t=e.id+t;const o=this._db.get(t);if(o&&(this._size-=o.size,e.size-=o.size,this._db.delete(t),o.entry!==s&&this._notifyRemove(t,o.entry,i.ALL)),n>this._maxSize)return void this._notifyRemove(t,s,i.ALL);if(void 0===s)return void console.warn("Refusing to cache undefined entry ");if(!n||n<0)return void console.warn(`Refusing to cache entry with size ${n} for key ${t}`);const a=1+Math.max(r,-3)- -3;this._db.set(t,{entry:s,size:n,lifetime:a,lives:a}),this._size+=n,e.size+=n,this._checkSizeLimits()}updateSize(e,t,s,n){t=e.id+t;const r=this._db.get(t);if(r&&r.entry===s){for(this._size-=r.size,e.size-=r.size;n>this._maxSize;){const e=this._notifyRemove(t,s,i.SOME);if(!(null!=e&&e>0))return void this._db.delete(t);n=e}r.size=n,this._size+=n,e.size+=n,this._checkSizeLimits()}}pop(e,t){t=e.id+t;const s=this._db.get(t);if(s)return this._size-=s.size,e.size-=s.size,this._db.delete(t),++this._hit,s.entry;++this._miss}get(e,t){t=e.id+t;const s=this._db.get(t);if(void 0!==s)return this._db.delete(t),s.lives=s.lifetime,this._db.set(t,s),++this._hit,s.entry;++this._miss}peek(e,t){const s=this._db.get(e.id+t);return s?++this._hit:++this._miss,s?.entry}get performanceInfo(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},s=new Array;this._db.forEach(((e,i)=>{const n=e.lifetime;s[n]=(s[n]||0)+e.size,this._users.forAll((s=>{const{id:n,name:r}=s;if(i.startsWith(n)){const s=t[r]||0;t[r]=s+e.size}}))}));const i={};this._users.forAll((e=>{const s=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){const n=t[s]||0;t[s]=n,i[s]=Math.round(100*e.hitRate)+"%"}else i[s]="0%"}));const n=Object.keys(t);n.sort(((e,s)=>t[s]-t[e])),n.forEach((s=>e[s]=Math.round(t[s]/2**20)+"MB / "+i[s]));for(let t=s.length-1;t>=0;--t){const i=s[t];i&&(e["Priority "+(t+-3-1)]=Math.round(i/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forAll((e=>e.resetHitRate()))}clear(e){const t=e.id;this._db.forEach(((e,s)=>{s.startsWith(t)&&(this._size-=e.size,this._db.delete(s),this._notifyRemove(s,e.entry,i.ALL))})),e.size=0}clearAll(){this._db.forEach(((e,t)=>this._notifyRemove(t,e.entry,i.ALL))),this._users.forEach((e=>e.size=0)),this._size=0,this._db.clear()}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,s){let i;return this._removeFuncs.some((n=>{if(e.startsWith(n[0])){const e=n[1](t,s);return"number"==typeof e&&(i=e),!0}return!1})),i}_checkSizeLimits(){if(this._size>this._maxSize)for(const[e,t]of this._db)if(this._purgeItem(e,t),this._size<=.9*this.maxSize)return;this._users.forEach((e=>{if(e.maxSize>0&&e.size>e.maxSize)for(const[t,s]of this._db)if(t.startsWith(e.id)&&(this._purgeItem(t,s,e),e.size<=.9*e.maxSize))return}))}_purgeItem(e,t,s=this._users.find((t=>e.startsWith(t.id)))){if(this._db.delete(e),t.lives<=1){this._size-=t.size,s&&(s.size-=t.size);const n=this._notifyRemove(e,t.entry,i.SOME);null!=n&&n>0&&(this._size+=n,s&&(s.size+=n),t.lives=t.lifetime,t.size=n,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}let h=0},52421:(e,t,s)=>{function i(e){return(t,s)=>{t[s]=e}}s.d(t,{c:()=>i})},24133:(e,t,s)=>{s.d(t,{Q:()=>o});var i=s(67676),n=s(44553),r=s(88764);class o{constructor(e=9,t){this._compareMinX=l,this._compareMinY=u,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),b.prune(),v.prune(),S.prune(),x.prune()}all(e){this._all(this._data,e)}search(e,t){let s=this._data;const i=this._toBBox;if(p(e,s))for(b.clear();s;){for(let n=0,r=s.children.length;n<r;n++){const r=s.children[n],o=s.leaf?i(r):r;p(e,o)&&(s.leaf?t(r):g(e,o)?this._all(r,t):b.push(r))}s=b.pop()}}collides(e){let t=this._data;const s=this._toBBox;if(!p(e,t))return!1;for(b.clear();t;){for(let i=0,n=t.children.length;i<n;i++){const n=t.children[i],r=t.leaf?s(n):n;if(p(e,r)){if(t.leaf||g(e,r))return!0;b.push(n)}}t=b.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,s=e.length;t<s;t++)this.insert(e[t]);return this}let t=this._build(e.slice(0,e.length),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new w([]),this}remove(e){if(!e)return this;let t,s=this._data,n=null,r=0,o=!1;const a=this._toBBox(e);for(S.clear(),x.clear();s||S.length>0;){if(s||(s=S.pop(),n=S.data[S.length-1],r=x.pop()??0,o=!0),s.leaf&&(t=(0,i.cq)(s.children,e,s.children.length,s.indexHint),-1!==t))return s.children.splice(t,1),S.push(s),this._condense(S),this;o||s.leaf||!g(s,a)?n?(r++,s=n.children[r],o=!1):s=null:(S.push(s),x.push(r),r=0,n=s,s=s.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_all(e,t){let s=e;for(v.clear();s;){if(!0===s.leaf)for(const e of s.children)t(e);else v.pushArray(s.children);s=v.pop()??null}}_build(e,t,s,i){const n=s-t+1;let r=this._maxEntries;if(n<=r){const i=new w(e.slice(t,s+1));return a(i,this._toBBox),i}i||(i=Math.ceil(Math.log(n)/Math.log(r)),r=Math.ceil(n/r**(i-1)));const o=new M([]);o.height=i;const h=Math.ceil(n/r),c=h*Math.ceil(Math.sqrt(r));y(e,t,s,c,this._compareMinX);for(let n=t;n<=s;n+=c){const t=Math.min(n+c-1,s);y(e,n,t,h,this._compareMinY);for(let s=n;s<=t;s+=h){const n=Math.min(s+h-1,t);o.children.push(this._build(e,s,n,i-1))}}return a(o,this._toBBox),o}_chooseSubtree(e,t,s,i){for(;i.push(t),!0!==t.leaf&&i.length-1!==s;){let s,i=1/0,n=1/0;for(let r=0,o=t.children.length;r<o;r++){const o=t.children[r],a=d(o),h=f(e,o)-a;h<n?(n=h,i=a<i?a:i,s=o):h===n&&a<i&&(i=a,s=o)}t=s||t.children[0]}return t}_insert(e,t,s){const i=this._toBBox,n=s?e:i(e);S.clear();const r=this._chooseSubtree(n,this._data,t,S);for(r.children.push(e),c(r,n);t>=0&&S.data[t].children.length>this._maxEntries;)this._split(S,t),t--;this._adjustParentBBoxes(n,S,t)}_split(e,t){const s=e.data[t],i=s.children.length,n=this._minEntries;this._chooseSplitAxis(s,n,i);const r=this._chooseSplitIndex(s,n,i);if(!r)return void console.log(" Error: assertion failed at PooledRBush._split: no valid split index");const o=s.children.splice(r,s.children.length-r),h=s.leaf?new w(o):new M(o);h.height=s.height,a(s,this._toBBox),a(h,this._toBBox),t?e.data[t-1].children.push(h):this._splitRoot(s,h)}_splitRoot(e,t){this._data=new M([e,t]),this._data.height=e.height+1,a(this._data,this._toBBox)}_chooseSplitIndex(e,t,s){let i,n,r;i=n=1/0;for(let o=t;o<=s-t;o++){const t=h(e,0,o,this._toBBox),a=h(e,o,s,this._toBBox),c=_(t,a),l=d(t)+d(a);c<i?(i=c,r=o,n=l<n?l:n):c===i&&l<n&&(n=l,r=o)}return r}_chooseSplitAxis(e,t,s){const i=e.leaf?this._compareMinX:l,n=e.leaf?this._compareMinY:u;this._allDistMargin(e,t,s,i)<this._allDistMargin(e,t,s,n)&&e.children.sort(i)}_allDistMargin(e,t,s,i){e.children.sort(i);const n=this._toBBox,r=h(e,0,t,n),o=h(e,s-t,s,n);let a=m(r)+m(o);for(let i=t;i<s-t;i++){const t=e.children[i];c(r,e.leaf?n(t):t),a+=m(r)}for(let i=s-t-1;i>=t;i--){const t=e.children[i];c(o,e.leaf?n(t):t),a+=m(o)}return a}_adjustParentBBoxes(e,t,s){for(let i=s;i>=0;i--)c(t.data[i],e)}_condense(e){for(let t=e.length-1;t>=0;t--){const s=e.data[t];if(0===s.children.length)if(t>0){const n=e.data[t-1],r=n.children;r.splice((0,i.cq)(r,s,r.length,n.indexHint),1)}else this.clear();else a(s,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){h(e,0,e.children.length,t,e)}function h(e,t,s,i,n){n||(n=new w([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let r,o=t;o<s;o++)r=e.children[o],c(n,e.leaf?i(r):r);return n}function c(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function l(e,t){return e.minX-t.minX}function u(e,t){return e.minY-t.minY}function d(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function m(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function _(e,t){const s=Math.max(e.minX,t.minX),i=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),r=Math.min(e.maxY,t.maxY);return Math.max(0,n-s)*Math.max(0,r-i)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function p(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function y(e,t,s,i,n){const o=[t,s];for(;o.length;){const t=o.pop(),s=o.pop();if(t-s<=i)continue;const a=s+Math.ceil((t-s)/i/2)*i;(0,r.q)(e,a,s,t,n),o.push(s,a,a,t)}}const b=new n.Z,v=new n.Z,S=new n.Z,x=new n.Z({deallocator:void 0});class T{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class I extends T{constructor(){super(...arguments),this.height=1,this.indexHint=new i.SO}}class w extends I{constructor(e){super(),this.children=e,this.leaf=!0}}class M extends I{constructor(e){super(),this.children=e,this.leaf=!1}}},17445:(e,t,s)=>{s.d(t,{N1:()=>d,YP:()=>h,Z_:()=>_,gx:()=>c,nn:()=>g,on:()=>u,tX:()=>p}),s(66643),s(46791);var i=s(91460),n=s(50758),r=s(70586),o=s(95330),a=s(26258);function h(e,t,s={}){return l(e,t,s,m)}function c(e,t,s={}){return l(e,t,s,f)}function l(e,t,s={},i){let n=null;const o=s.once?(e,s)=>{i(e)&&((0,r.hw)(n),t(e,s))}:(e,s)=>{i(e)&&t(e,s)};if(n=(0,a.aQ)(e,o,s.sync,s.equals),s.initial){const t=e();o(t,t)}return n}function u(e,t,s,o={}){let a=null,c=null,l=null;function u(){a&&c&&(c.remove(),o.onListenerRemove?.(a),a=null,c=null)}function d(e){o.once&&o.once&&(0,r.hw)(l),s(e)}const m=h(e,((e,s)=>{u(),(0,i.vT)(e)&&(a=e,c=(0,i.on)(e,t,d),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return l=(0,n.kB)((()=>{m.remove(),u()})),l}function d(e,t){return function(e,t,s){if((0,o.Hc)(s))return Promise.reject((0,o.zE)());const i=e();if(t?.(i))return Promise.resolve(i);let a=null;function h(){a=(0,r.hw)(a)}return new Promise(((i,r)=>{a=(0,n.AL)([(0,o.fu)(s,(()=>{h(),r((0,o.zE)())})),l(e,(e=>{h(),i(e)}),{sync:!1,once:!0},t??m)])}))}(e,f,t)}function m(e){return!0}function f(e){return!!e}s(87538);const _={sync:!0},g={initial:!0},p={sync:!0,initial:!0}},22641:(e,t,s)=>{s.d(t,{u:()=>a});var i=s(48853),n=s(70171),r=s(17126);function o(e){e=e.replaceAll(/LTS|LT|LL?L?L?|l{1,4}/g,"[$&]");let t="";const s=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g;for(const i of e.match(s)||[])switch(i){case"D":t+="d";break;case"DD":t+="dd";break;case"DDD":t+="o";break;case"d":t+="c";break;case"ddd":t+="ccc";break;case"dddd":t+="cccc";break;case"M":t+="L";break;case"MM":t+="LL";break;case"MMM":t+="LLL";break;case"MMMM":t+="LLLL";break;case"YY":t+="yy";break;case"Y":case"YYYY":t+="yyyy";break;case"Q":t+="q";break;case"X":case"x":t+=i;break;default:i.length>=2&&"["===i.slice(0,1)&&"]"===i.slice(-1)?t+=`'${i.slice(1,-1)}'`:t+=`'${i}'`}return t}class a{constructor(e,t,s){this._year=e,this._month=t,this._day=s,this.declaredRootClass="esri.core.sql.dateonly"}get month(){return this._month}get monthJS(){return this._month-1}get year(){return this._year}get day(){return this._day}get isValid(){return this.toDateTime("unknown").isValid}equals(e){return e instanceof a&&e.day===this.day&&e.month===this.month&&e.year===this.year}clone(){return new a(this._year,this._month,this._day)}toDateTime(e){return r.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toDateTimeLuxon(e){return r.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toString(){return`${this.year.toString().padStart(4,"0")}-${this.month.toString().padStart(2,"0")}-${this.day.toString().padStart(2,"0")}`}toFormat(e=null){if(null===e||""===e)return this.toString();if(!(e=o(e)))return"";const t=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(t).toFormat(e,{locale:(0,n.Kd)(),numberingSystem:"latn"})}toArcadeDate(){const e=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(e)}toNumber(){return this.toDateTime("unknown").toMillis()}toJSDate(){return this.toDateTime("unknown").toJSDate()}toStorageFormat(){return this.toFormat("yyyy-LL-dd")}toSQLValue(){return this.toFormat("yyyy-LL-dd")}toSQLWithKeyword(){return"date '"+this.toFormat("yyyy-LL-dd")+"'"}plus(e,t){return a.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}toUTCDateTime(){return r.ou.utc(this.year,this.month,this.day,0,0,0,0)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}static fromMilliseconds(e){const t=r.ou.fromMillis(e,{zone:r.Qf.utcInstance});return t.isValid?a.fromParts(t.year,t.month,t.day):null}static fromSeconds(e){const t=r.ou.fromSeconds(e,{zone:r.Qf.utcInstance});return t.isValid?a.fromParts(t.year,t.month,t.day):null}static fromReader(e){if(!e)return null;const t=e.split("-");return 3!==t.length?null:new a(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10))}static fromParts(e,t,s){const i=new a(e,t,s);return!1===i.isValid?null:i}static fromDateJS(e){return a.fromParts(e.getFullYear(),e.getMonth()+1,e.getDay())}static fromDateTime(e){return a.fromParts(e.year,e.month,e.day)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];if(t)(t=o(t))&&s.push(t);else if(null===t||""===t){const t=r.ou.fromISO(e,{setZone:!0});return t.isValid?a.fromParts(t.year,t.month,t.day):null}for(const i of s){const s=r.ou.fromFormat(e,t??i);if(s.isValid)return new a(s.year,s.month,s.day)}return null}static fromNow(e="system"){const t=r.ou.fromJSDate(new Date).setZone((0,i.Qn)(e));return new a(t.year,t.month,t.day)}}},53970:(e,t,s)=>{s.d(t,{n:()=>a});var i=s(77286),n=s(70171),r=s(17126);function o(e){if(!e)return"";const t=/(a|A|hh?|HH?|mm?|ss?|SSS|S|.)/g;let s="";for(const i of e.match(t)||[])switch(i){case"SSS":case"m":case"mm":case"h":case"hh":case"H":case"HH":case"s":case"ss":s+=i;break;case"A":case"a":s+="a";break;default:s+=`'${i}'`}return s}class a{constructor(e,t,s,i){this._hour=e,this._minute=t,this._second=s,this._millisecond=i,this.declaredRootClass="esri.core.sql.timeonly"}get hour(){return this._hour}get minute(){return this._minute}get second(){return this._second}get millisecond(){return this._millisecond}equals(e){return e instanceof a&&e.hour===this.hour&&e.minute===this.minute&&e.second===this.second&&e.millisecond===this.millisecond}clone(){return new a(this.hour,this.minute,this.second,this.millisecond)}isValid(){return(0,i.U)(this.hour)&&(0,i.U)(this.minute)&&(0,i.U)(this.second)&&(0,i.U)(this.millisecond)&&this.hour>=0&&this.hour<24&&this.minute>=0&&this.minute<60&&this.second>=0&&this.second<60&&this.millisecond>=0&&this.millisecond<1e3}toString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`+(this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):"")}toSQLValue(){return this.toString()}toSQLWithKeyword(){return`time '${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}${this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):""}'`}toStorageString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`}toFormat(e=null){return null===e||""===e?this.toString():(e=o(e))?r.ou.local(1970,1,1,this._hour,this._minute,this._second,this._millisecond).toFormat(e,{locale:(0,n.Kd)(),numberingSystem:"latn"}):""}toNumber(){return this.millisecond+1e3*this.second+1e3*this.minute*60+60*this.hour*60*1e3}static fromParts(e,t,s,i){const n=new a(e,t,s,i);return n.isValid()?n:null}static fromReader(e){if(!e)return null;const t=e.split(":");return 3!==t.length?null:new a(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10),0)}static fromMilliseconds(e){if(e>864e5||e<0)return null;const t=Math.floor(e/1e3%60),s=Math.floor(e/6e4%60),i=Math.floor(e/36e5%24),n=Math.floor(e%1e3);return new a(i,s,t,n)}static fromDateJS(e){return new a(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}static fromDateTime(e){return new a(e.hour,e.minute,e.second,e.millisecond)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];t?(t=o(t))&&s.push(t):null!==t&&""!==t||(s.push("HH:mm:ss"),s.push("HH:mm:ss.SSS"),s.push("hh:mm:ss a"),s.push("hh:mm:ss.SSS a"),s.push("HH:mm"),s.push("hh:mm a"),s.push("H:mm"),s.push("h:mm a"),s.push("H:mm:ss"),s.push("h:mm:ss a"),s.push("H:mm:ss.SSS"),s.push("h:mm:ss.SSS a"));for(const t of s){const s=r.ou.fromFormat(e,t);if(s.isValid)return new a(s.hour,s.minute,s.second,s.millisecond)}return null}plus(e,t){switch(e){case"days":case"years":case"months":return this.clone();case"hours":case"minutes":case"seconds":case"milliseconds":return a.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}return null}toUTCDateTime(){return r.ou.utc(1970,1,1,this.hour,this.minute,this.second,this.millisecond)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}}},16306:(e,t,s)=>{s.d(t,{aX:()=>x});var i=s(68773),n=s(20102),r=s(92604),o=s(38913),a=s(58901),h=s(73913),c=s(8744),l=s(40488),u=(s(66577),s(3172)),d=s(33955),m=s(11282),f=s(17452);async function _(e,t,s){const i="string"==typeof e?(0,f.mN)(e):e,n=t[0].spatialReference,r=(0,d.Ji)(t[0]),o={...s,query:{...i.query,f:"json",sr:(0,c.B9)(n),geometries:JSON.stringify((h=t,{geometryType:(0,d.Ji)(h[0]),geometries:h.map((e=>e.toJSON()))}))}},{data:a}=await(0,u.Z)(i.path+"/simplify",o);var h;return function(e,t,s){const i=(0,d.q9)(t);return e.map((e=>{const t=i.fromJSON(e);return t.spatialReference=s,t}))}(a.geometries,r,n)}const g=r.Z.getLogger("esri.geometry.support.normalizeUtils");function p(e){return"polygon"===e[0].type}function y(e){return"polyline"===e[0].type}function b(e,t,s){if(t){const t=function(e,t){if(!(e instanceof a.Z||e instanceof o.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw g.error(e),new n.Z(e)}const s=(0,h.x3)(e),i=[];for(const e of s){const s=[];i.push(s),s.push([e[0][0],e[0][1]]);for(let i=0;i<e.length-1;i++){const n=e[i][0],r=e[i][1],o=e[i+1][0],a=e[i+1][1],h=Math.sqrt((o-n)*(o-n)+(a-r)*(a-r)),c=(a-r)/h,l=(o-n)/h,u=h/t;if(u>1){for(let e=1;e<=u-1;e++){const i=e*t,o=l*i+n,a=c*i+r;s.push([o,a])}const e=(h+Math.floor(u-1)*t)/2,i=l*e+n,o=c*e+r;s.push([i,o])}s.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new o.Z({rings:i,spatialReference:e.spatialReference}):new a.Z({paths:i,spatialReference:e.spatialReference})}(e,1e6);e=(0,l.Sx)(t,!0)}return s&&(e=(0,h.Sy)(e,s)),e}function v(e,t,s){if(Array.isArray(e)){const i=e[0];if(i>t){const s=(0,h.XZ)(i,t);e[0]=i+s*(-2*t)}else if(i<s){const t=(0,h.XZ)(i,s);e[0]=i+t*(-2*s)}}else{const i=e.x;if(i>t){const s=(0,h.XZ)(i,t);e=e.clone().offset(s*(-2*t),0)}else if(i<s){const t=(0,h.XZ)(i,s);e=e.clone().offset(t*(-2*s),0)}}return e}function S(e,t){let s=-1;for(let i=0;i<t.cutIndexes.length;i++){const n=t.cutIndexes[i],r=t.geometries[i],o=(0,h.x3)(r);for(let e=0;e<o.length;e++){const t=o[e];t.some((s=>{if(s[0]<180)return!0;{let s=0;for(let e=0;e<t.length;e++){const i=t[e][0];s=i>s?i:s}s=Number(s.toFixed(9));const i=-360*(0,h.XZ)(s,180);for(let s=0;s<t.length;s++){const t=r.getPoint(e,s);r.setPoint(e,s,t.clone().offset(i,0))}return!0}}))}if(n===s){if(p(e))for(const t of(0,h.x3)(r))e[n]=e[n].addRing(t);else if(y(e))for(const t of(0,h.x3)(r))e[n]=e[n].addPath(t)}else s=n,e[n]=r}return e}async function x(e,t,s){if(!Array.isArray(e))return x([e],t);t&&"string"!=typeof t&&g.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const n="string"==typeof t?t:t?.url??i.default.geometryServiceUrl;let r,f,p,y,T,I,w,M,E=0;const D=[],C=[];for(const t of e)if(null!=t)if(r||(r=t.spatialReference,f=(0,c.C5)(r),p=r.isWebMercator,I=p?102100:4326,y=h.UZ[I].maxX,T=h.UZ[I].minX,w=h.UZ[I].plus180Line,M=h.UZ[I].minus180Line),f)if("mesh"===t.type)C.push(t);else if("point"===t.type)C.push(v(t.clone(),y,T));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>v(e,y,T))),C.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,f);C.push(e.rings?new o.Z(e):e)}else if(t.extent){const e=t.extent,s=(0,h.XZ)(e.xmin,T)*(2*y);let i=0===s?t.clone():(0,h.Sy)(t.clone(),s);e.offset(s,0),e.intersects(w)&&e.xmax!==y?(E=e.xmax>E?e.xmax:E,i=b(i,p),D.push(i),C.push("cut")):e.intersects(M)&&e.xmin!==T?(E=e.xmax*(2*y)>E?e.xmax*(2*y):E,i=b(i,p,360),D.push(i),C.push("cut")):C.push(i)}else C.push(t.clone());else C.push(t);else C.push(t);let A=(0,h.XZ)(E,y),B=-90;const z=A,L=new a.Z;for(;A>0;){const e=360*A-180;L.addPath([[e,B],[e,-1*B]]),B*=-1,A--}if(D.length>0&&z>0){const t=S(D,await async function(e,t,s,i){const n=(0,m.en)(e),r=t[0].spatialReference,o={...i,responseType:"json",query:{...n.query,f:"json",sr:(0,c.B9)(r),target:JSON.stringify({geometryType:(0,d.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(s)}},a=await(0,u.Z)(n.path+"/cut",o),{cutIndexes:h,geometries:l=[]}=a.data;return{cutIndexes:h,geometries:l.map((e=>{const t=(0,d.im)(e);return t.spatialReference=r,t}))}}(n,D,L,s)),i=[],r=[];for(let s=0;s<C.length;s++){const n=C[s];if("cut"!==n)r.push(n);else{const n=t.shift(),o=e[s];null!=o&&"polygon"===o.type&&o.rings&&o.rings.length>1&&n.rings.length>=o.rings.length?(i.push(n),r.push("simplify")):r.push(p?(0,l.$)(n):n)}}if(!i.length)return r;const o=await _(n,i,s),a=[];for(let e=0;e<r.length;e++){const t=r[e];"simplify"!==t?a.push(t):a.push(p?(0,l.$)(o.shift()):o.shift())}return a}const Z=[];for(let e=0;e<C.length;e++){const t=C[e];if("cut"!==t)Z.push(t);else{const e=D.shift();Z.push(!0===p?(0,l.$)(e):e)}}return Z}},73913:(e,t,s)=>{s.d(t,{Sy:()=>h,UZ:()=>o,XZ:()=>a,x3:()=>c});var i=s(58901),n=s(82971),r=s(33955);const o={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new i.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:n.Z.WebMercator}),minus180Line:new i.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:n.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new i.Z({paths:[[[180,-180],[180,180]]],spatialReference:n.Z.WGS84}),minus180Line:new i.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:n.Z.WGS84})}};function a(e,t){return Math.ceil((e-t)/(2*t))}function h(e,t){const s=c(e);for(const e of s)for(const s of e)s[0]+=t;return e}function c(e){return(0,r.oU)(e)?e.rings:e.paths}},37549:(e,t,s)=>{s.d(t,{H:()=>a});var i=s(80442),n=s(24133),r=s(24470);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.Q(9,(0,i.Z)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((s,i)=>{e[t++]=i})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.cS)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,s){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,s)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},28972:(e,t,s)=>{s.d(t,{Z:()=>I});var i=s(67676),n=s(20102),r=s(32448),o=s(92604),a=s(60437),h=s(24470),c=s(98732),l=s(37549);function u(e,t){return e?t?4:3:t?3:2}function d(e,t,s,i,n){if(null==t||!t.lengths.length)return null;const r="upperLeft"===n?.originPosition?-1:1;e.lengths.length&&(e.lengths.length=0),e.coords.length&&(e.coords.length=0);const o=e.coords,a=[],h=s?[Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY]:[Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY],{lengths:c,coords:l}=t,d=u(s,i);let _=0;for(const e of c){const t=m(h,l,_,e,s,i,r);t&&a.push(t),_+=e*d}if(a.sort(((e,t)=>{let i=r*e[2]-r*t[2];return 0===i&&s&&(i=e[4]-t[4]),i})),a.length){let e=6*a[0][2];o[0]=a[0][0]/e,o[1]=a[0][1]/e,s&&(e=6*a[0][4],o[2]=0!==e?a[0][3]/e:0),(o[0]<h[0]||o[0]>h[1]||o[1]<h[2]||o[1]>h[3]||s&&(o[2]<h[4]||o[2]>h[5]))&&(o.length=0)}if(!o.length){const e=t.lengths[0]?f(l,0,c[0],s,i):null;if(!e)return null;o[0]=e[0],o[1]=e[1],s&&e.length>2&&(o[2]=e[2])}return e}function m(e,t,s,i,n,r,o=1){const a=u(n,r);let h=s,c=s+a,l=0,d=0,m=0,f=0,_=0;for(let s=0,r=i-1;s<r;s++,h+=a,c+=a){const s=t[h],i=t[h+1],r=t[h+2],o=t[c],a=t[c+1],u=t[c+2];let g=s*a-o*i;f+=g,l+=(s+o)*g,d+=(i+a)*g,n&&(g=s*u-o*r,m+=(r+u)*g,_+=g),s<e[0]&&(e[0]=s),s>e[1]&&(e[1]=s),i<e[2]&&(e[2]=i),i>e[3]&&(e[3]=i),n&&(r<e[4]&&(e[4]=r),r>e[5]&&(e[5]=r))}if(f*o>0&&(f*=-1),_*o>0&&(_*=-1),!f)return null;const g=[l,d,.5*f];return n&&(g[3]=m,g[4]=.5*_),g}function f(e,t,s,i,n){const r=u(i,n);let o=t,a=t+r,h=0,c=0,l=0,d=0;for(let t=0,n=s-1;t<n;t++,o+=r,a+=r){const t=e[o],s=e[o+1],n=e[o+2],r=e[a],u=e[a+1],m=e[a+2],f=i?g(t,s,n,r,u,m):_(t,s,r,u);if(f)if(h+=f,i){const e=y(t,s,n,r,u,m);c+=f*e[0],l+=f*e[1],d+=f*e[2]}else{const e=p(t,s,r,u);c+=f*e[0],l+=f*e[1]}}return h>0?i?[c/h,l/h,d/h]:[c/h,l/h]:s>0?i?[e[t],e[t+1],e[t+2]]:[e[t],e[t+1]]:null}function _(e,t,s,i){const n=s-e,r=i-t;return Math.sqrt(n*n+r*r)}function g(e,t,s,i,n,r){const o=i-e,a=n-t,h=r-s;return Math.sqrt(o*o+a*a+h*h)}function p(e,t,s,i){return[e+.5*(s-e),t+.5*(i-t)]}function y(e,t,s,i,n,r){return[e+.5*(i-e),t+.5*(n-t),s+.5*(r-s)]}var b=s(70272),v=s(5428);const S={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new b.u_(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>(null==e.centroid&&(e.centroid=d(new v.Z,e.geometry,t.hasZ,t.hasM)),e.centroid)};var x=s(11490);const T=(0,a.Ue)();class I{constructor(e){this.geometryInfo=e,this._boundsStore=new l.H,this._featuresById=new Map,this._markedIds=new Set,this.events=new r.Z,this.featureAdapter=S}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,s,i,n]=this.fullBounds;return{xmin:t,ymin:s,xmax:i,ymax:n,spatialReference:(0,x.S2)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(i.pC)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const s of e){const e=this._boundsStore.get(s.objectId);e&&t((0,a.JR)(T,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,s)=>{this._markedIds.has(s)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e}));const s=this._featuresById.get(t);let i;if(this._markedIds.add(t),s?(e.displayId=s.displayId,i=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),null==e.geometry||!e.geometry.coords||!e.geometry.coords.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);i=(0,c.$)(null!=i?i:(0,h.Ue)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=i&&this._boundsStore.set(t,i),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const s=this._featuresById.get(t);if(!s)return this._add(e),e;this._markedIds.add(t);const{geometry:i,attributes:r}=e;for(const e in r)s.attributes[e]=r[e];return i&&(s.geometry=i,this._boundsStore.set(t,(0,c.$)((0,h.Ue)(),i,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),s}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._markedIds.delete(t),this._boundsStore.delete(t),this._featuresById.delete(t),e}}},3922:(e,t,s)=>{s.r(t),s.d(t,{FeatureStore:()=>n.Z,QueryEngine:()=>i.q});var i=s(11028),n=s(28972)},11282:(e,t,s)=>{s.d(t,{cv:()=>a,en:()=>o,lA:()=>r}),s(68773),s(40330);var i=s(22974),n=s(17452);function r(e,t){return t?{...t,query:{...e??{},...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,n.mN)(e):(0,i.d9)(e)}function a(e,t,s){const i={};for(const n in e){if("declaredClass"===n)continue;const r=e[n];if(null!=r&&"function"!=typeof r)if(Array.isArray(r)){i[n]=[];for(let e=0;e<r.length;e++)i[n][e]=a(r[e])}else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(s&&s[n]);i[n]=t?e:JSON.stringify(e)}else i[n]=t?r:JSON.stringify(r);else i[n]=r}return i}s(71058)}}]);
|