@arcgis/core 5.2.0-next.47 → 5.2.0-next.49
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/applications/Components/OrientedImageryViewer/PanoramicViewer/utils.d.ts +33 -0
- package/applications/Components/OrientedImageryViewer/PanoramicViewer/utils.js +2 -0
- package/arcgisGlobal.d.ts +2 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/003a87b16f8a4b476e14.js +1 -0
- package/assets/esri/core/workers/chunks/031ccf2e1583beebdf24.js +1 -0
- package/assets/esri/core/workers/chunks/0474af7687466d8befd2.js +1 -0
- package/assets/esri/core/workers/chunks/{2a4868acd546312aa6d8.js → 05f6887805d92da03122.js} +1 -1
- package/assets/esri/core/workers/chunks/069b6d8bdb34ee88d437.js +1 -0
- package/assets/esri/core/workers/chunks/{f9b2727b41943d83d4ca.js → 0a413d917f3d19440fc1.js} +1 -1
- package/assets/esri/core/workers/chunks/0b2ca406761c63529a6a.js +1 -0
- package/assets/esri/core/workers/chunks/{68f7eaa3122de7c00adb.js → 0ea374f7b16745b9bbc7.js} +1 -1
- package/assets/esri/core/workers/chunks/{c369d4266f38e9ea6592.js → 1119a33245138e7b3914.js} +1 -1
- package/assets/esri/core/workers/chunks/12e0c5b7cc5c3f9e6f0f.js +1 -0
- package/assets/esri/core/workers/chunks/172571397c66f992d08c.js +1 -0
- package/assets/esri/core/workers/chunks/18edf2846d7546285e5e.js +1 -0
- package/assets/esri/core/workers/chunks/1b0557fcb058fc450230.js +1 -0
- package/assets/esri/core/workers/chunks/{98f575c038da74ced2a6.js → 1bc45872d22d61dbd7d1.js} +1 -1
- package/assets/esri/core/workers/chunks/{835643f716f7058a2722.js → 1cf8fb704c48ac3d3b15.js} +1 -1
- package/assets/esri/core/workers/chunks/25cb56c3b538d00e7693.js +1 -0
- package/assets/esri/core/workers/chunks/{4d4710d57c72ec75cccc.js → 26f1fd3f2be5102aae1d.js} +1 -1
- package/assets/esri/core/workers/chunks/285a5bd708f0fe1c620c.js +1 -0
- package/assets/esri/core/workers/chunks/{7777a79f26a06a6c5240.js → 304a22c580ce103480cb.js} +1 -1
- package/assets/esri/core/workers/chunks/{383392c63202ac044b6c.js → 33bd9785bd0b6ccef21b.js} +1 -1
- package/assets/esri/core/workers/chunks/{2c0d92c0e3511775401a.js → 35cbf00f0c37a86517af.js} +1 -1
- package/assets/esri/core/workers/chunks/{0f19bc532be24ca64755.js → 36fe6adf6517d8f80125.js} +1 -1
- package/assets/esri/core/workers/chunks/382d9491c2a56c1925fe.js +1 -0
- package/assets/esri/core/workers/chunks/3af2b9d6d5466cb2b957.js +256 -0
- package/assets/esri/core/workers/chunks/{b3cd17daf5a297b96705.js → 3bc2943035391b44d4cf.js} +1 -1
- package/assets/esri/core/workers/chunks/{d36f17d32c654b1ac7fa.js → 3f1a7f8a9ead64bf0b7b.js} +1 -1
- package/assets/esri/core/workers/chunks/40f7bb0ebd918d76f078.js +1 -0
- package/assets/esri/core/workers/chunks/43b39abd49c4a8ce891f.js +1 -0
- package/assets/esri/core/workers/chunks/{821176ee3be724621bb0.js → 461c2de938bf4c9b1442.js} +1 -1
- package/assets/esri/core/workers/chunks/{cc637aec16918052548e.js → 47af3525396f890f2a6b.js} +1 -1
- package/assets/esri/core/workers/chunks/4ee7232ea41fa41c5ed4.js +29 -0
- package/assets/esri/core/workers/chunks/4ee900e5dbb130fa0c7b.js +1 -0
- package/assets/esri/core/workers/chunks/50674ba5f24129d61d89.js +1 -0
- package/assets/esri/core/workers/chunks/547a2fe53139f705f95e.js +1 -0
- package/assets/esri/core/workers/chunks/5ce09c4d06e98b1e9251.js +1 -0
- package/assets/esri/core/workers/chunks/5dbd28fce73751d2d1aa.js +1 -0
- package/assets/esri/core/workers/chunks/5ec8b02e097cf6718462.js +1 -0
- package/assets/esri/core/workers/chunks/5f54d927dc77e92cf145.js +1 -0
- package/assets/esri/core/workers/chunks/63e3d338751240479335.js +1 -0
- package/assets/esri/core/workers/chunks/69b9a327f23e052fced7.js +1 -0
- package/assets/esri/core/workers/chunks/6c2b5087a9df65267f4e.js +1 -0
- package/assets/esri/core/workers/chunks/6ccd5fa5e35dc70fcd5d.js +1 -0
- package/assets/esri/core/workers/chunks/6e520ef645c5edcd499a.js +1 -0
- package/assets/esri/core/workers/chunks/7659391f952d134164cf.js +1 -0
- package/assets/esri/core/workers/chunks/78add8e6b54b51eaa299.js +1 -0
- package/assets/esri/core/workers/chunks/{2b669473aa2c7cfb63c7.js → 7b0ed52363704cfce129.js} +1 -1
- package/assets/esri/core/workers/chunks/7b61f56d0f766421eaef.js +1 -0
- package/assets/esri/core/workers/chunks/7f2f2a92dce3f68e579b.js +1 -0
- package/assets/esri/core/workers/chunks/801a664f21e0218bc705.js +1 -0
- package/assets/esri/core/workers/chunks/{8f9fb4e8a7d73db41664.js → 851bcc75acac4a2f199b.js} +1 -1
- package/assets/esri/core/workers/chunks/{6010b7be978698a642d0.js → 8977c85aecc7e08ab13c.js} +1 -1
- package/assets/esri/core/workers/chunks/8c5726c7ce40a92901e6.js +1 -0
- package/assets/esri/core/workers/chunks/8d21e2dabc5165f1c8ca.js +1 -0
- package/assets/esri/core/workers/chunks/9008090a5d8431ddfa22.js +1 -0
- package/assets/esri/core/workers/chunks/{f2adf1227a795604d3b8.js → 90ae80b797642bff0efa.js} +1 -1
- package/assets/esri/core/workers/chunks/{71ce1009dadcae8f8094.js → 95b3b8fe45ef4ac6b277.js} +1 -1
- package/assets/esri/core/workers/chunks/96cec8a02ca96175d602.js +1 -0
- package/assets/esri/core/workers/chunks/99eccf9ce53582cfa5b5.js +1 -0
- package/assets/esri/core/workers/chunks/9b7cb96acea388d86fa4.js +1 -0
- package/assets/esri/core/workers/chunks/{dee4019338a79c1ecd26.js → 9d0a9d465ec3a8ba1ed2.js} +1 -1
- package/assets/esri/core/workers/chunks/9e474465d069cb9e94f5.js +1 -0
- package/assets/esri/core/workers/chunks/aa3abc07de2921ef6ca1.js +1 -0
- package/assets/esri/core/workers/chunks/{ae9f9e975d7a9d442fa5.js → ab5aa4280ed0cb7fcbe9.js} +1 -1
- package/assets/esri/core/workers/chunks/b03f09ee2224f0cc526a.js +1 -0
- package/assets/esri/core/workers/chunks/{ee58f4bbc0a1f7d03df0.js → b32ede7805c7c6644e4c.js} +1 -1
- package/assets/esri/core/workers/chunks/b49952541d189b4b9f7e.js +1 -0
- package/assets/esri/core/workers/chunks/b8bdacebd4d24ba90f3f.js +1 -0
- package/assets/esri/core/workers/chunks/{85cd0cd721b27c497b18.js → baac90da0703891d59c4.js} +1 -1
- package/assets/esri/core/workers/chunks/bb552089b34d6811fb03.js +1 -0
- package/assets/esri/core/workers/chunks/cd1f1a72483b7c80bd9a.js +1 -0
- package/assets/esri/core/workers/chunks/{744f34e379484e63277c.js → cdb331b58e22f8c1c988.js} +2 -2
- package/assets/esri/core/workers/chunks/{b23d1e10fc4161d1f3eb.js → d021775cf747556660a5.js} +1 -1
- package/assets/esri/core/workers/chunks/{728ea88e7d4733230e1f.js → d1af0bd611a3dc549858.js} +85 -81
- package/assets/esri/core/workers/chunks/d2cb3d5ef0a9285afb78.js +1 -0
- package/assets/esri/core/workers/chunks/d49e42f36bc3dc256b9f.js +1 -0
- package/assets/esri/core/workers/chunks/d560ed96dde5ca3a5583.js +1 -0
- package/assets/esri/core/workers/chunks/dc1787d88b11ed985159.js +1 -0
- package/assets/esri/core/workers/chunks/{399e23d777a043efa9f1.js → dd95f50dac3f33cdb6d2.js} +1 -1
- package/assets/esri/core/workers/chunks/ddb92c815d17c67a45e6.js +1 -0
- package/assets/esri/core/workers/chunks/{7c2784ebbe17d79f669c.js → de50a19944617cd426b8.js} +1 -1
- package/assets/esri/core/workers/chunks/{52efa4ded11c1e71f04f.js → e2e2162adbfb9b46bede.js} +1 -1
- package/assets/esri/core/workers/chunks/e4353f0792f45aa6a62f.js +1 -0
- package/assets/esri/core/workers/chunks/eac8cae89da9ce2f4946.js +1 -0
- package/assets/esri/core/workers/chunks/edf87407dd20685c82ab.js +1 -0
- package/assets/esri/core/workers/chunks/ee7c8a7f384ea6393487.js +705 -0
- package/assets/esri/core/workers/chunks/f1299b4fc760ccca1518.js +1 -0
- package/assets/esri/core/workers/chunks/f244632f7934a4b72c91.js +1 -0
- package/assets/esri/core/workers/chunks/fc639c730115e07a4a1a.js +1 -0
- package/assets/esri/libs/basisu/basis_encoder.wasm +0 -0
- package/assets/esri/libs/basisu/basis_transcoder.wasm +0 -0
- package/assets/esri/libs/dxtEncoder/dxt_encoder.wasm +0 -0
- package/chunks/Component.glsl.js +104 -67
- package/chunks/DefaultMaterial.glsl.js +1 -1
- package/chunks/LineMarker.glsl.js +31 -31
- package/chunks/RibbonLine.glsl.js +60 -49
- package/chunks/basis_encoder.js +1 -1
- package/chunks/basis_transcoder.js +1 -1
- package/chunks/dxt_encoder.js +1 -1
- package/chunks/vec3.js +1 -1
- package/config.js +1 -1
- package/core/has.js +1 -1
- package/core/libs/gl-matrix-2/math/vec3.js +1 -1
- package/core/promiseUtils.js +1 -1
- package/core/workers/workerFactory.js +1 -1
- package/geometry/Mesh.d.ts +4 -4
- package/geometry/support/MeshMaterialMetallicRoughness.d.ts +13 -1
- package/geometry/support/MeshMaterialMetallicRoughness.js +1 -1
- package/geometry/support/aaBoundingBox.js +1 -1
- package/geometry/support/buffer/math/vec3.js +1 -1
- package/geometry/support/frustum.js +1 -1
- package/geometry/support/meshUtils/exporters/gltf/gltf.js +1 -1
- package/geometry/support/meshUtils/extent.js +1 -1
- package/geometry/support/meshUtils/loadGLTFMesh.js +1 -1
- package/geometry/support/meshUtils/vertexSpaceConversion.js +1 -1
- package/geometry/support/meshUtils.d.ts +33 -5
- package/geometry/support/plane.js +1 -1
- package/kernel.js +1 -1
- package/layers/orientedImagery/transformations/imageToWorld.js +1 -1
- package/layers/orientedImagery/transformations/utils.js +1 -1
- package/layers/raster/formats/ImageCanvasDecoder.js +1 -1
- package/layers/raster/formats/JpgPlus.js +1 -1
- package/layers/raster/formats/RasterCodec.js +1 -1
- package/layers/raster/formats/TiffDecoder.js +1 -1
- package/layers/raster/formats/Zlib.js +2 -0
- package/package.json +2 -2
- package/rest/featureService/FeatureService.d.ts +74 -1
- package/rest/featureService/FeatureService.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/ObjectSymbol3DLayer.d.ts +10 -8
- package/symbols/cim/CIMSymbolDrawHelper.js +1 -1
- package/symbols/cim/CIMSymbolHelper.js +1 -1
- package/symbols/cim/TextRasterizer.js +1 -1
- package/symbols/cim/cimAnalyzer.js +1 -1
- package/symbols/cim/richTextUtils.js +2 -0
- package/symbols/support/ObjectSymbol3DLayerResource.d.ts +9 -4
- package/views/2d/analysis/AreaMeasurement/AreaMeasurementAreaVisualization.js +1 -1
- package/views/2d/analysis/AreaMeasurement/AreaMeasurementTool.js +1 -1
- package/views/2d/analysis/DistanceMeasurement/DistanceMeasurementTool.js +1 -1
- package/views/2d/engine/webgl/TextureManager.js +1 -1
- package/views/2d/engine/webgl/definitions.js +1 -1
- package/views/2d/engine/webgl/mesh/MultiTileMeshData.js +1 -1
- package/views/2d/engine/webgl/mesh/templates/shapingUtils.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/text/TextMeshWriter.js +1 -1
- package/views/2d/engine/webgl/util/DimensionMatcher.js +1 -1
- package/views/2d/layers/FeatureLikeLayerView2D.js +1 -1
- package/views/2d/layers/features/Processor.js +1 -1
- package/views/2d/layers/features/processor/AProcessorStrategy.js +1 -1
- package/views/2d/layers/features/processor/AggregateStrategy.js +2 -0
- package/views/2d/layers/features/processor/bins/BinAdapter.js +2 -0
- package/views/2d/layers/features/processor/bins/BinLevelState.js +2 -0
- package/views/2d/layers/features/processor/bins/BinState.js +2 -0
- package/views/2d/layers/features/processor/bins/createBinningStrategy.js +2 -0
- package/views/2d/layers/features/processor/clusters/ClusterAdapter.js +2 -0
- package/views/2d/layers/features/processor/clusters/ClusterLevelState.js +2 -0
- package/views/2d/layers/features/processor/clusters/ClusterSendState.js +2 -0
- package/views/2d/layers/features/processor/clusters/createClusterStrategy.js +2 -0
- package/views/2d/layers/features/processor/createAggregateStrategy.js +2 -0
- package/views/2d/layers/features/processor/tracks/Track.js +2 -0
- package/views/2d/layers/features/processor/tracks/TrackAdapter.js +2 -0
- package/views/2d/layers/features/processor/tracks/TrackLevelState.js +2 -0
- package/views/2d/layers/features/processor/tracks/TrackSendState.js +2 -0
- package/views/2d/layers/features/processor/tracks/createTrackStrategy.js +2 -0
- package/views/2d/layers/features/schema/processor/symbols/SymbolSchema.js +1 -1
- package/views/2d/layers/features/support/FeatureSetReaderIndirect.js +1 -1
- package/views/2d/layers/support/annodime/DimensionInfo.js +1 -1
- package/views/2d/layers/support/annodime/dimensionUtils.js +1 -1
- package/views/3d/analysis/LineOfSight/LineOfSightReshapeTool3D.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedConfiguration.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedEditTool.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedSubVisualization.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedTool.js +1 -1
- package/views/3d/analysis/ViewshedAnalysisView3D.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
- package/views/3d/focusAreaUtils.js +1 -1
- package/views/3d/glTF/LoaderResult.js +1 -1
- package/views/3d/glTF/internal/Resource.js +1 -1
- package/views/3d/glTF/loader.js +1 -1
- package/views/3d/interactive/editingTools/transform/extentTransform/ExtentScale.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/objectResourceUtils.js +1 -1
- package/views/3d/layers/graphics/wosrLoader.js +1 -1
- package/views/3d/layers/i3s/meshUtils.js +1 -1
- package/views/3d/state/helpers/SceneIntersectionHelper.js +1 -1
- package/views/3d/webgl/RenderCamera.js +1 -1
- package/views/3d/webgl/RenderNode.js +1 -1
- package/views/3d/webgl-engine/collections/Component/Material/Component.glsl.js +1 -1
- package/views/3d/webgl-engine/collections/Component/Material/ComponentTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/TextureBackedBuffer.glsl.js +2 -2
- package/views/3d/webgl-engine/core/shaderLibrary/TextureBackedBufferFields.glsl.js +2 -2
- package/views/3d/webgl-engine/core/shaderLibrary/attributes/RibbonVertexPosition.glsl.js +36 -25
- package/views/3d/webgl-engine/core/shaderLibrary/shading/PhysicallyBasedRenderingParameters.glsl.js +19 -20
- package/views/3d/webgl-engine/core/shaderLibrary/terrain/Overlay.glsl.js +17 -10
- package/views/3d/webgl-engine/lib/BoundingInfo.js +1 -1
- package/views/3d/webgl-engine/lib/Intersector.js +1 -1
- package/views/3d/webgl-engine/lib/NavigationDepthCache.js +1 -1
- package/views/3d/webgl-engine/lib/NavigationDepthCacheStore.js +2 -0
- package/views/3d/webgl-engine/lib/Object3D.js +1 -1
- package/views/3d/webgl-engine/lib/PolygonIntersections2D.js +1 -1
- package/views/3d/webgl-engine/lib/RayIntersections.js +1 -1
- package/views/3d/webgl-engine/lib/RenderGeometry.js +1 -1
- package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/depthRangeUtils.js +1 -1
- package/views/3d/webgl-engine/lib/intersectorUtils.js +1 -1
- package/views/3d/webgl-engine/lib/lodRendering/LodLevel.js +1 -1
- package/views/3d/webgl-engine/lib/screenPolygonOverlapUtils.js +1 -1
- package/views/3d/webgl-engine/lib/screenPolygonTriangleIntersections.js +1 -1
- package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/PathTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
- package/views/3d/webgl-engine/shaders/AnimatedLine.glsl.js +8 -5
- package/views/3d/webgl-engine/shaders/DefaultMaterialTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/shaders/RibbonLine.glsl.js +1 -1
- package/views/3d/webgl-engine/shaders/RibbonLineLayouts.js +1 -1
- package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
- package/views/3d/webgl-engine/shaders/RibbonLineTextureBuffer.glsl.js +1 -1
- package/views/3d/webgl-engine/shaders/TerrainTechniqueConfiguration.js +1 -1
- package/views/PopupView.js +1 -1
- package/views/SceneView.js +1 -1
- package/views/interactive/snapping/RightAngleTriangleSnapper.js +1 -1
- package/views/interactive/snapping/SnappingAlgorithm.js +1 -1
- package/views/interactive/snapping/featureSources/FeatureServiceSnappingSource.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorkerHandle.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTiledFetcher.js +1 -1
- package/views/selection/SelectionOperation.js +1 -1
- package/views/support/AnalysisViewManager.js +1 -1
- package/views/support/DefaultsFromMap.js +1 -1
- package/views/support/LayerViewManager.js +1 -1
- package/views/support/TextureCompressionWorker.js +1 -1
- package/views/webgl/RenderingContext.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/services/SuperimposeService.js +1 -1
- package/widgets/OrientedImageryViewer/support/superimposeUtils.js +1 -1
- package/widgets/PanoramicViewer/support/PanoramicTileNode.d.ts +63 -0
- package/widgets/PanoramicViewer/support/PanoramicTileNode.js +1 -1
- package/widgets/PanoramicViewer/support/PanoramicTilePyramid.d.ts +66 -0
- package/widgets/PanoramicViewer/support/PanoramicTilePyramid.js +1 -1
- package/widgets/PanoramicViewer/utils.js +1 -1
- package/widgets/Sketch/VisibleElements.d.ts +0 -10
- package/widgets/Sketch.js +1 -1
- package/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js +1 -1
- package/widgets/support/SelectionToolbar.js +1 -1
- package/widgets/support/Selector3D/selectorUtils.js +2 -0
- package/assets/esri/core/workers/chunks/0115681a3de6df0aebdf.js +0 -1
- package/assets/esri/core/workers/chunks/025caafc70ac26f0a4ed.js +0 -1
- package/assets/esri/core/workers/chunks/08e18fb12533fc76e49c.js +0 -1
- package/assets/esri/core/workers/chunks/0e64e20fedfe01a1985f.js +0 -1
- package/assets/esri/core/workers/chunks/0f674c625f24ac73e25a.js +0 -1
- package/assets/esri/core/workers/chunks/15351354afcbf840a23d.js +0 -29
- package/assets/esri/core/workers/chunks/176c5eaaa23a479c88e0.js +0 -1
- package/assets/esri/core/workers/chunks/1d1f5578c7d8619f7a46.js +0 -1
- package/assets/esri/core/workers/chunks/1f118d85d8271ad7690b.js +0 -1
- package/assets/esri/core/workers/chunks/2015f4def2ef201bdab8.js +0 -1
- package/assets/esri/core/workers/chunks/268637fd6c50264acfc3.js +0 -1
- package/assets/esri/core/workers/chunks/272c8ab189217240d05f.js +0 -1
- package/assets/esri/core/workers/chunks/296fa9fb80e521c30cb1.js +0 -1
- package/assets/esri/core/workers/chunks/354199a41de44902de84.js +0 -1
- package/assets/esri/core/workers/chunks/384b619854ef8a3f6e94.js +0 -1
- package/assets/esri/core/workers/chunks/3af923abeb6e65c4468f.js +0 -1
- package/assets/esri/core/workers/chunks/46d3ddf62fa7a76dd57d.js +0 -1
- package/assets/esri/core/workers/chunks/4b24f72b56edc28bb15e.js +0 -1
- package/assets/esri/core/workers/chunks/4f09f208ece2ec1db727.js +0 -1
- package/assets/esri/core/workers/chunks/57374213084bef59b776.js +0 -1
- package/assets/esri/core/workers/chunks/5f9c4dad6952c4c58ebf.js +0 -1
- package/assets/esri/core/workers/chunks/706230b70a36d2e038f7.js +0 -1
- package/assets/esri/core/workers/chunks/7cc729b57a6a52c8ac68.js +0 -1
- package/assets/esri/core/workers/chunks/8026cc0065f6520c4161.js +0 -1
- package/assets/esri/core/workers/chunks/804ab5f614efa12a131b.js +0 -1
- package/assets/esri/core/workers/chunks/81d55594cee124040565.js +0 -1
- package/assets/esri/core/workers/chunks/8d21f3d6edbcd7b335d0.js +0 -1
- package/assets/esri/core/workers/chunks/8d90bef1091204fba0f1.js +0 -1
- package/assets/esri/core/workers/chunks/8ec5e470583b75fceae1.js +0 -1
- package/assets/esri/core/workers/chunks/9114a575b78a7ea18d0f.js +0 -1
- package/assets/esri/core/workers/chunks/93e705c1147cc8ceca02.js +0 -1
- package/assets/esri/core/workers/chunks/9a97f6cda2f36941efae.js +0 -1
- package/assets/esri/core/workers/chunks/9ceeae787dc7c194d60e.js +0 -1
- package/assets/esri/core/workers/chunks/a8033e606b2db1ee332d.js +0 -1
- package/assets/esri/core/workers/chunks/a90f7b1c6c69b6033b4c.js +0 -1
- package/assets/esri/core/workers/chunks/a9c641bcdef161c754bf.js +0 -1
- package/assets/esri/core/workers/chunks/ad5c2b0de6713d0a93a4.js +0 -680
- package/assets/esri/core/workers/chunks/ae50b2d5e63f62c088d2.js +0 -1
- package/assets/esri/core/workers/chunks/aea247138617e12b699b.js +0 -1
- package/assets/esri/core/workers/chunks/b03dcf3d55266745f3d1.js +0 -1
- package/assets/esri/core/workers/chunks/b32bdf5730953c2fb16b.js +0 -1
- package/assets/esri/core/workers/chunks/bf287f0e2ecb4532dc00.js +0 -1
- package/assets/esri/core/workers/chunks/c01a121ebe571a848452.js +0 -1
- package/assets/esri/core/workers/chunks/c3cd38ca8690286d40d7.js +0 -1
- package/assets/esri/core/workers/chunks/c4b13124a9cfc78c42a6.js +0 -261
- package/assets/esri/core/workers/chunks/c5e36544b2d1792e4c5f.js +0 -1
- package/assets/esri/core/workers/chunks/c6042825f61cd70d54d8.js +0 -1
- package/assets/esri/core/workers/chunks/cba3316910ff088f4d77.js +0 -1
- package/assets/esri/core/workers/chunks/d8b67ca02cdc1e8191e3.js +0 -1
- package/assets/esri/core/workers/chunks/dadefe369f49e89a2610.js +0 -1
- package/assets/esri/core/workers/chunks/db416ba3132034e20642.js +0 -1
- package/assets/esri/core/workers/chunks/de9573871f64c01e9f01.js +0 -1
- package/assets/esri/core/workers/chunks/dfbdc72c7ea137e3841d.js +0 -1
- package/assets/esri/core/workers/chunks/e3e966777f18164afcd8.js +0 -1
- package/assets/esri/core/workers/chunks/e9c48630757bea465b7e.js +0 -1
- package/assets/esri/core/workers/chunks/f2c8122d31aedc2604ee.js +0 -1
- package/assets/esri/core/workers/chunks/f8f0de841be17cd05c8f.js +0 -1
- package/assets/esri/core/workers/chunks/ff089723a27859fe18d1.js +0 -1
- package/chunks/Zlib.js +0 -2
- package/views/2d/layers/features/processor/AAggregateStrategy.js +0 -2
- package/views/2d/layers/features/processor/BinningStrategy.js +0 -2
- package/views/2d/layers/features/processor/ClusterStrategy.js +0 -2
- package/views/2d/layers/features/processor/TrackStrategy.js +0 -2
- package/views/3d/analysis/Viewshed/ViewshedTool2.js +0 -2
- /package/assets/esri/core/workers/chunks/{744f34e379484e63277c.js.LICENSE.txt → cdb331b58e22f8c1c988.js.LICENSE.txt} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3202,6008],{52106(e,t,n){n.d(t,{A:()=>_});var r,i,s=n(5482),o=n(37838),a=n(69540),l=n(51447),u=n(25482),c=n(53966),d=n(36708),p=n(24326),h=n(91429),f=n(12195),y=n(65864),g=n(50498),m=n(55156),b=n(60950),M=n(54339),v=n(94128),w=n(33910);function I(e){if(null==e)return null;const t={};for(const n in e){const r=e[n];r&&(t[n]=r.toJSON())}return 0!==Object.keys(t).length?t:null}let _=class extends((0,a.OU)(u.o)){static{r=v.Z}static{i=this}constructor(e){super(e),this[r]=!0,this.distance=null,this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this.statisticsAggregatedIds=void 0,this._version=0,Object.defineProperty(this,"uid",{value:(0,p.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,l.eF)(c.A.getLogger(this),"Graphic",{version:"4.30"})}initialize(){this._watchMeshGeometryChanges()}set aggregateGeometries(e){const t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){const t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){const t=this._get("geometry");t!==e&&(this._set("geometry",e),"mesh"!==e?.type&&this._notifyLayer("geometry",t,e))}set popupTemplate(e){const t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){const t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){const t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new i({aggregateGeometries:this.aggregateGeometries,statisticsAggregatedIds:this.statisticsAggregatedIds,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;const t=(0,b.E_)(this.origin);if(t)return t.popupTemplate??(e?t.defaultPopupTemplate:null)??null;const n=this.origin&&"layer"in this.origin?this.origin.layer:null;for(const t of[n,this.sourceLayer,this.layer])if(t&&"object"==typeof t){if("popupTemplate"in t&&t.popupTemplate)return t.popupTemplate;if(e&&"defaultPopupTemplate"in t&&null!=t.defaultPopupTemplate)return t.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){const n=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",n,t,e)}else this.attributes={[e]:t}}getObjectId(){const e=(0,m.I)(this.origin);if(e)return(0,M.r)(this,e);const t=this.sourceLayer??this.layer;return t?(0,M.r)(this,t):null}getGlobalId(){const e=(0,m.I)(this.origin);if(e?.globalIdField)return this.getAttribute(e.globalIdField);const t=this.sourceLayer??this.layer;return t&&"globalIdField"in t&&t.globalIdField?this.getAttribute(t.globalIdField):null}toJSON(){const e={aggregateGeometries:I(this.aggregateGeometries),geometry:this.geometry?.toJSON()??null,symbol:this.symbol?.toJSON()??null,attributes:(0,f.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null};return this.statisticsAggregatedIds?.length&&(e.aggregateIds=[...this.statisticsAggregatedIds]),null!=this.distance&&(e.distance=this.distance),e}notifyMeshTransformChanged(e={}){const{geometry:t}=this;if("mesh"===t?.type){const n={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",n,n,e.action)}}_notifyLayer(e,t,n,r){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;const i={graphic:this,property:e,oldValue:t,newValue:n};"origin-transform"===e&&(i.action=r),"attributes"===e&&(i.attributeName=r),this.layer.graphicChanged(i)}_watchMeshGeometryChanges(){this.addHandles([(0,d.z7)(()=>"mesh"===this.geometry?.type&&this.geometry.vertexSpace.origin?{localMatrix:this.geometry.transform?.localMatrix,origin:this.geometry.vertexSpace.origin}:void 0,({localMatrix:e,origin:t})=>{this._lastMeshTransform.localMatrix===e&&this._lastMeshTransform.origin===t||(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())}),(0,d.z7)(()=>"mesh"===this.geometry?.type?{vertexAttributes:this.geometry.vertexAttributes}:void 0,()=>{const e=this.geometry;"mesh"===e?.type&&e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",this.geometry,this.geometry)},{equals:(e,t)=>e===t,sync:!0})])}};(0,s.Cg)([(0,h.MZ)({value:null,json:{read:function(e){if(!e)return null;const t={};for(const n in e){const r=(0,y.rS)(e[n]);r&&(t[n]=r)}return 0!==Object.keys(t).length?t:null}}})],_.prototype,"aggregateGeometries",null),(0,s.Cg)([(0,h.MZ)({value:null})],_.prototype,"attributes",null),(0,s.Cg)([(0,h.MZ)({value:null,types:g.yR,json:{read:y.rS}})],_.prototype,"geometry",null),(0,s.Cg)([(0,h.MZ)()],_.prototype,"distance",void 0),(0,s.Cg)([(0,h.MZ)({type:Boolean})],_.prototype,"isAggregate",void 0),(0,s.Cg)([(0,h.MZ)({clonable:!1})],_.prototype,"layer",void 0),(0,s.Cg)([(0,h.MZ)({clonable:"reference"})],_.prototype,"origin",void 0),(0,s.Cg)([(0,h.MZ)({type:o.A,value:null})],_.prototype,"popupTemplate",null),(0,s.Cg)([(0,h.MZ)({clonable:"reference"})],_.prototype,"sourceLayer",void 0),(0,s.Cg)([(0,h.MZ)({json:{name:"aggregateIds",read:e=>e?.map(e=>Array.isArray(e)?JSON.stringify(e):e)}})],_.prototype,"statisticsAggregatedIds",void 0),(0,s.Cg)([(0,h.MZ)({value:null,types:w.Es})],_.prototype,"symbol",null),(0,s.Cg)([(0,h.MZ)({clonable:!1,json:{read:!1,write:!1}})],_.prototype,"_version",void 0),(0,s.Cg)([(0,h.MZ)({type:Boolean,value:!0})],_.prototype,"visible",null),_=i=(0,s.Cg)([(0,h.$K)("esri.Graphic")],_)},66344(e,t,n){n.d(t,{q:()=>a});const r=!!(0,n(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class i{get size(){return this._size}constructor(e=10485760,t=.3){this._maxSize=e,this._maxClientSizeRatio=t,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._clients=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._clients.clear(),this._db.clear()}register(e){this._clients.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._clients.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}get _maxClientSize(){return this._maxSize*this._maxClientSizeRatio}getSize(e,t){const n=this._db.get(e.id+t);return n?.size??0}put(e,t,n,i,o){t=e.id+t;const a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==n&&this._notifyRemove(t,a.entry,a.size,0)),i>this._maxSize)return void this._notifyRemove(t,n,i,0);if(void 0===n)return void console.warn("Refusing to cache undefined entry ");if(!i||i<0)return r||console.warn(`Refusing to cache entry with size ${i} for key ${t}`),void this._notifyRemove(t,n,0,0);const l=1+Math.max(o,-4)- -3;this._db.set(t,new s(n,i,l)),this._size+=i,e.size+=i,this._checkSize()}updateSize(e,t){t=e.id+t;const n=this._db.get(t);if(!n)return;this._size-=n.size,e.size-=n.size;let r=n.entry.usedMemory;for(;r>this._maxSize;){const e=this._notifyRemove(t,n.entry,r,1);if(!(null!=e&&e>0))return void this._db.delete(t);r=e}n.size=r,this._size+=r,e.size+=r,this._checkSize()}pop(e,t){t=e.id+t;const n=this._db.get(t);if(n)return this._size-=n.size,e.size-=n.size,this._db.delete(t),++this._hit,n.entry;++this._miss}get(e,t){t=e.id+t;const n=this._db.get(t);if(void 0!==n)return this._db.delete(t),n.lives=n.lifetime,this._db.set(t,n),++this._hit,n.entry;++this._miss}peek(e,t){const n=this._db.get(e.id+t);return n?++this._hit:++this._miss,n?.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={},n=new Array;this._db.forEach((e,r)=>{const i=e.lifetime;n[i]=(n[i]||0)+e.size,this._clients.forEach(n=>{const{id:i,name:s}=n;if(r.startsWith(i)){const n=t[s]||0;t[s]=n+e.size}})});const r={};this._clients.forEach(e=>{const n=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){const i=t[n]||0;t[n]=i,r[n]=Math.round(100*e.hitRate)+"%"}else r[n]="0%"});const i=Object.keys(t);i.sort((e,n)=>t[n]-t[e]),i.forEach(n=>e[n]=Math.round(t[n]/2**20)+"MB / "+r[n]);for(let t=n.length-1;t>=0;--t){const r=n[t];r&&(e["Priority "+(t+-3-1)]=Math.round(r/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._clients.forEach(e=>e.resetHitRate())}clear(e){const t=e.id;this._db.forEach((e,n)=>{n.startsWith(t)&&(this._size-=e.size,this._db.delete(n),this._notifyRemove(n,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._clients.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(const[t,n]of this._db)t.startsWith(e.id)&&(yield n.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,n,r){const i=this._clients.get(e.split(o)[0])?.removeFunc,s=i?.(t,r,n);return"number"==typeof s?s:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._clients.forEach(e=>this._checkSizeLimits(this._maxClientSize,e)),this._checkSizeLimits(this.maxSize)}setMaxClientSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){const n=t??this;if(n.size<=e)return;const r=t?.id;let i=!0;for(;i;){i=!1;for(const[s,a]of this._db)if(0===a.lifetime&&(!r||s.startsWith(r))){const r=t??this._clients.get(s.split(o)[0]);if(this._purgeItem(s,a,r),n.size<=.9*e)return;i||=this._db.has(s)}}for(const[i,s]of this._db)if(!r||i.startsWith(r)){const r=t??this._clients.get(i.split(o)[0]);if(this._purgeItem(i,s,r),n.size<=.9*e)return}}_purgeItem(e,t,n){if(this._db.delete(e),t.lives<=1){this._size-=t.size,n&&(n.size-=t.size);const r=this._notifyRemove(e,t.entry,t.size,1);null!=r&&r>0&&(this._size+=r,n&&(n.size+=r),t.lives=t.lifetime,t.size=r,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new i(0);class s{constructor(e,t,n){this.entry=e,this.size=t,this.lifetime=n,this.lives=n}}const o=":";class a{constructor(e,t){this.removeFunc=t,this.id="",this.name="",this.size=0,this._storage=new i(e,1),this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,n=1){this._storage.put(this,e,t,n,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(){}}},6797(e,t,n){n.d(t,{Ui:()=>p});var r=n(69622),i=n(7762),s=n(88620);const o=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof r.A}function l(e){return e instanceof i.A?Object.keys(e.items):a(e)?(0,s.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof i.A?e.items[t]:e[t]}function c(e){return e?e.declaredClass:null}function d(e,t){const n=e.diff;if(n&&"function"==typeof n)return n(e,t);const r=l(e),i=l(t);if(0===r.length&&0===i.length)return;if(!r.length||!i.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const s=i.filter(e=>!r.includes(e)),p=r.filter(e=>!i.includes(e)),h=r.filter(n=>i.includes(n)&&u(e,n)!==u(t,n)).concat(s,p).sort(),f=c(e);if(f&&o.has(f)&&h.length)return{type:"complete",oldValue:e,newValue:t};let y;const g=a(e)&&a(t);for(const r of h){const i=u(e,r),s=u(t,r);let o;if((g||"function"!=typeof i&&"function"!=typeof s)&&i!==s&&(null!=i||null!=s)){if(n&&n[r]&&"function"==typeof n[r])o=n[r]?.(i,s);else if(i instanceof Date&&s instanceof Date){if(i.getTime()===s.getTime())continue;o={type:"complete",oldValue:i,newValue:s}}else o="object"==typeof i&&"object"==typeof s&&c(i)===c(s)?d(i,s):{type:"complete",oldValue:i,newValue:s};null!=o&&(null!=y?y.diff[r]=o:y={type:"partial",diff:{[r]:o}})}}return y}function p(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&c(e)!==c(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},85334(e,t,n){n.d(t,{$:()=>m,IB:()=>o,Iy:()=>w,N2:()=>b,RH:()=>v,ZD:()=>M});var r=n(68197),i=n(4576),s=n(4718);function o(e){return"r"in e&&"g"in e&&"b"in e}function a(e){return"h"in e&&"s"in e&&"v"in e}function l(e){return"l"in e&&"a"in e&&"b"in e}function u(e){return"l"in e&&"c"in e&&"h"in e}n(34727),n(78955),n(91829);const c=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],d=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]];function p(e,t){const n=[];let r,i;if(e[0].length!==t.length)throw new Error("dimensions do not match");const s=e.length,o=e[0].length;let a=0;for(r=0;r<s;r++){for(a=0,i=0;i<o;i++)a+=e[r][i]*t[i];n.push(a)}return n}function h(e){const t=[e.r/255,e.g/255,e.b/255].map(e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4),n=p(c,t);return{x:100*n[0],y:100*n[1],z:100*n[2]}}function f(e){const t=p(d,[e.x/100,e.y/100,e.z/100]).map(e=>{const t=e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055;return Math.min(1,Math.max(t,0))});return{r:Math.round(255*t[0]),g:Math.round(255*t[1]),b:Math.round(255*t[2])}}function y(e){const t=[e.x/95.047,e.y/100,e.z/108.883].map(e=>e>(6/29)**3?e**(1/3):1/3*(29/6)**2*e+4/29);return{l:116*t[1]-16,a:500*(t[0]-t[1]),b:200*(t[1]-t[2])}}function g(e){const t=e.l,n=[(t+16)/116+e.a/500,(t+16)/116,(t+16)/116-e.b/200].map(e=>e>6/29?e**3:3*(6/29)**2*(e-4/29));return{x:95.047*n[0],y:100*n[1],z:108.883*n[2]}}function m(e){return o(e)?e:u(e)?function(e){return f(g(function(e){const t=e.l,n=e.c,r=e.h;return{l:t,a:n*Math.cos(r),b:n*Math.sin(r)}}(e)))}(e):l(e)?function(e){return f(g(e))}(e):function(e){return"x"in e&&"y"in e&&"z"in e}(e)?f(e):a(e)?function(e){const t=(e.h+360)%360/60,n=e.s/100,r=e.v/100*255,i=r*n,s=i*(1-Math.abs(t%2-1));let o;switch(Math.floor(t)){case 0:o={r:i,g:s,b:0};break;case 1:o={r:s,g:i,b:0};break;case 2:o={r:0,g:i,b:s};break;case 3:o={r:0,g:s,b:i};break;case 4:o={r:s,g:0,b:i};break;case 5:case 6:o={r:i,g:0,b:s};break;default:o={r:0,g:0,b:0}}return o.r=Math.round(o.r+r-i),o.g=Math.round(o.g+r-i),o.b=Math.round(o.b+r-i),o}(e):e}function b(e){return a(e)?e:function(e){const{r:t,g:n,b:r}=e,i=Math.max(t,n,r),s=i-Math.min(t,n,r);let o=i,a=0===s?0:i===t?(n-r)/s%6:i===n?(r-t)/s+2:(t-n)/s+4,l=0===s?0:s/o;return a<0&&(a+=6),a*=60,l*=100,o*=100/255,{h:a,s:l,v:o}}(m(e))}function M(e){return l(e)?e:function(e){return y(h(e))}(m(e))}function v(e){return u(e)?e:function(e){return function(e){const t=e.l,n=e.a,r=e.b,i=Math.sqrt(n*n+r*r);let s=Math.atan2(r,n);return s=s>0?s:s+2*Math.PI,{l:t,c:i,h:s}}(y(h(e)))}(m(e))}function w(e,t,n={}){if(0===e.length||t<=0)return[];if(1===(e=e.map(e=>"string"==typeof e?new r.A(e):e)).length||1===t){const n=[],r=e[0];for(let e=0;e<t;e++)n.push(r.clone());return n}if(n.shuffle&&(e=(0,i.k4)((0,s.o8)(e),n.seed)),e.length>=t){const n=[],r=(e.length-1)/(t-1);for(let i=0;i<t;i++){const t=Math.round(i*r);n.push(e[t].clone())}return n}return function(e,t,n={}){const r=[],s=e.length-1,o=Math.ceil((t-e.length)/s);e:for(let i=0;i<s;i++){const s=e[i],a=e[i+1];for(let i=1;i<=o;i++){const l=i/(o+1);if(r.push(_(s,a,l,n)),r.length+e.length===t)break e}}return[...e.map(e=>e.clone()),...(0,i.k4)(r,n.seed??1)]}(e,t,n)}const I=(e,t)=>{const n=Math.floor(10*t())-5;return Math.min(255,Math.max(0,e+n))};function _(e,t,n,s={}){const o=e.r,a=e.g,l=e.b,u=t.r,c=t.g,d=t.b,p=Math.round(o+(u-o)*n),h=Math.round(a+(c-a)*n),f=Math.round(l+(d-l)*n);if(!s.offset)return new r.A([p,h,f]);const y=(0,i.Mo)(s.seed);return new r.A([I(p,y),I(h,y),I(f,y)])}},9093(e,t,n){function r(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function i(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]]}n.d(t,{o8:()=>i,vt:()=>r});const s=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:i,create:r,fromValues:function(e,t,n,r,i,s,o,a,l,u,c,d,p,h,f,y){return[e,t,n,r,i,s,o,a,l,u,c,d,p,h,f,y]}},Symbol.toStringTag,{value:"Module"})),n.d(t,["zK",0,s])},91829(e,t,n){function r(){return[0,0,0,0]}function i(e,t,n,r){return[e,t,n,r]}function s(e,t,n,r){return[e,t,n,r]}function o(){return i(1,1,1,1)}function a(){return i(1,0,0,0)}function l(){return i(0,1,0,0)}function u(){return i(0,0,1,0)}function c(){return i(0,0,0,1)}n.d(t,{CN:()=>s,_Y:()=>c,fA:()=>i,vt:()=>r});const d=[0,0,0,0],p=o(),h=a(),f=l(),y=u(),g=c();Object.freeze(Object.defineProperty({__proto__:null,ONES:p,UNIT_W:g,UNIT_X:h,UNIT_Y:f,UNIT_Z:y,ZEROS:d,clone:function(e){return[e[0],e[1],e[2],e[3]]},create:r,freeze:s,fromArray:function(e,t=[0,0,0,0]){const n=Math.min(4,e.length);for(let r=0;r<n;++r)t[r]=e[r];return t},fromValues:i,ones:o,unitW:c,unitX:a,unitY:l,unitZ:u,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"})),n.d(t,["Un",0,p,"uY",0,d])},35522(e,t,n){n.d(t,{$A:()=>C,Bw:()=>s,C:()=>o,Cc:()=>x,DI:()=>I,Io:()=>b,Ln:()=>m,Om:()=>F,Qr:()=>d,Re:()=>u,S8:()=>_,T9:()=>y,WQ:()=>l,Z0:()=>T,_S:()=>h,aI:()=>E,ei:()=>A,fw:()=>j,g7:()=>O,gL:()=>S,hG:()=>M,hZ:()=>a,hs:()=>g,jk:()=>f,lw:()=>c,m3:()=>v,oW:()=>k,t2:()=>R,tn:()=>p,ze:()=>w});var r=n(51850),i=n(34304);function s(e){const t=e[0],n=e[1],r=e[2];return Math.sqrt(t*t+n*n+r*r)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function a(e,t,n,r){return e[0]=t,e[1]=n,e[2]=r,e}function l(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e}function u(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e}function c(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e}function d(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e}function p(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function h(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function f(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e[2]=Math.min(t[2],n[2]),e}function y(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e[2]=Math.max(t[2],n[2]),e}function g(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e}function m(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e}function b(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return Math.sqrt(n*n+r*r+i*i)}function M(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return n*n+r*r+i*i}function v(e){const t=e[0],n=e[1],r=e[2];return t*t+n*n+r*r}function w(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function I(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function _(e,t){const n=t[0],r=t[1],i=t[2];let s=n*n+r*r+i*i;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function F(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function C(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],l=n[2];return e[0]=i*l-s*a,e[1]=s*o-r*l,e[2]=r*a-i*o,e}function x(e,t,n,r){const i=t[0],s=t[1],o=t[2];return e[0]=i+r*(n[0]-i),e[1]=s+r*(n[1]-s),e[2]=o+r*(n[2]-o),e}function T(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=n[0]*r+n[4]*i+n[8]*s+n[12],e[1]=n[1]*r+n[5]*i+n[9]*s+n[13],e[2]=n[2]*r+n[6]*i+n[10]*s+n[14],e}function A(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=r*n[0]+i*n[3]+s*n[6],e[1]=r*n[1]+i*n[4]+s*n[7],e[2]=r*n[2]+i*n[5]+s*n[8],e}function S(e,t,n){return j(e,t,n[0],n[1],n[2],n[3])}function j(e,t,n,r,i,s){const o=t[0],a=t[1],l=t[2],u=r*l-i*a,c=i*o-n*l,d=n*a-r*o,p=r*d-i*c,h=i*u-n*d,f=n*c-r*u,y=2*s;return e[0]=o+u*y+2*p,e[1]=a+c*y+2*h,e[2]=l+d*y+2*f,e}function O(e,t){_(Z,e),_(z,t);const n=F(Z,z);return n>1?0:n<-1?Math.PI:Math.acos(n)}const Z=(0,r.vt)(),z=(0,r.vt)();function R(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function E(e,t){if(e===t)return!0;const n=e[0],r=e[1],s=e[2],o=t[0],a=t[1],l=t[2],u=(0,i.FD)();return Math.abs(n-o)<=u*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(r-a)<=u*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(s-l)<=u*Math.max(1,Math.abs(s),Math.abs(l))}function k(e,t,n){const r=n[0]-t[0],i=n[1]-t[1],s=n[2]-t[2];let o=r*r+i*i+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=r*o,e[1]=i*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const L=u,P=c,q=d,N=b,U=M,$=s,D=v;Object.freeze(Object.defineProperty({__proto__:null,abs:p,add:l,angle:O,bezier:function(e,t,n,r,i,s){const o=1-s,a=o*o,l=s*s,u=a*o,c=3*s*a,d=3*l*o,p=l*s;return e[0]=t[0]*u+n[0]*c+r[0]*d+i[0]*p,e[1]=t[1]*u+n[1]*c+r[1]*d+i[1]*p,e[2]=t[2]*u+n[2]*c+r[2]*d+i[2]*p,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,n=1){return e[0]=Math.min(Math.max(e[0],t),n),e[1]=Math.min(Math.max(e[1],t),n),e[2]=Math.min(Math.max(e[2],t),n),e},copy:o,cross:C,crossAndNormalize:function(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],l=n[2],u=i*l-s*a,c=s*o-r*l,d=r*a-i*o,p=Math.sqrt(u*u+c*c+d*d);return e[0]=u/p,e[1]=c/p,e[2]=d/p,e},direction:k,dist:N,distance:b,div:q,divide:d,dot:F,equals:E,exactEquals:R,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,n,r,i,s){const o=s*s,a=o*(2*s-3)+1,l=o*(s-2)+s,u=o*(s-1),c=o*(3-2*s);return e[0]=t[0]*a+n[0]*l+r[0]*u+i[0]*c,e[1]=t[1]*a+n[1]*l+r[1]*u+i[1]*c,e[2]=t[2]*a+n[2]*l+r[2]*u+i[2]*c,e},inverse:I,len:$,length:s,lerp:x,max:y,min:f,mul:P,multiply:c,negate:w,normalize:_,random:function(e,t=1){const n=i.Ov,r=2*n()*Math.PI,s=2*n()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(r)*o,e[1]=Math.sin(r)*o,e[2]=s*t,e},rotateX:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0],s[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),s[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateY:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),s[1]=i[1],s[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateZ:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),s[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),s[2]=i[2],e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:g,scaleAndAdd:m,set:a,sign:h,sqrDist:U,sqrLen:D,squaredDistance:M,squaredLength:v,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:L,subtract:u,transformMat3:A,transformMat4:T,transformMat4Z:function(e,t){return t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]},transformQuat:S,transformQuatValues:j},Symbol.toStringTag,{value:"Module"})),n.d(t,["Il",0,$,"jb",0,L,"lo",0,U,"uE",0,D,"xg",0,N])},78955(e,t,n){n.d(t,{Bw:()=>g,C:()=>i,Cc:()=>v,LI:()=>p,Om:()=>M,S8:()=>b,T9:()=>d,WQ:()=>o,Z0:()=>w,aI:()=>_,hG:()=>y,hZ:()=>s,hs:()=>h,jk:()=>c,m3:()=>m,t2:()=>I});var r=n(34304);function i(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function s(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}function o(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e[3]=t[3]+n[3],e}function a(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e[3]=t[3]-n[3],e}function l(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e[3]=t[3]*n[3],e}function u(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e[3]=t[3]/n[3],e}function c(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e[2]=Math.min(t[2],n[2]),e[3]=Math.min(t[3],n[3]),e}function d(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e[2]=Math.max(t[2],n[2]),e[3]=Math.max(t[3],n[3]),e}function p(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e[3]=Math.round(t[3]),e}function h(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e}function f(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2],s=t[3]-e[3];return Math.sqrt(n*n+r*r+i*i+s*s)}function y(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2],s=t[3]-e[3];return n*n+r*r+i*i+s*s}function g(e){const t=e[0],n=e[1],r=e[2],i=e[3];return Math.sqrt(t*t+n*n+r*r+i*i)}function m(e){const t=e[0],n=e[1],r=e[2],i=e[3];return t*t+n*n+r*r+i*i}function b(e,t){const n=t[0],r=t[1],i=t[2],s=t[3];let o=n*n+r*r+i*i+s*s;return o>0&&(o=1/Math.sqrt(o),e[0]=n*o,e[1]=r*o,e[2]=i*o,e[3]=s*o),e}function M(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function v(e,t,n,r){const i=t[0],s=t[1],o=t[2],a=t[3];return e[0]=i+r*(n[0]-i),e[1]=s+r*(n[1]-s),e[2]=o+r*(n[2]-o),e[3]=a+r*(n[3]-a),e}function w(e,t,n){const r=t[0],i=t[1],s=t[2],o=t[3];return e[0]=n[0]*r+n[4]*i+n[8]*s+n[12]*o,e[1]=n[1]*r+n[5]*i+n[9]*s+n[13]*o,e[2]=n[2]*r+n[6]*i+n[10]*s+n[14]*o,e[3]=n[3]*r+n[7]*i+n[11]*s+n[15]*o,e}function I(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]}function _(e,t){const n=e[0],i=e[1],s=e[2],o=e[3],a=t[0],l=t[1],u=t[2],c=t[3],d=(0,r.FD)();return Math.abs(n-a)<=d*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(i-l)<=d*Math.max(1,Math.abs(i),Math.abs(l))&&Math.abs(s-u)<=d*Math.max(1,Math.abs(s),Math.abs(u))&&Math.abs(o-c)<=d*Math.max(1,Math.abs(o),Math.abs(c))}const F=a,C=l,x=u,T=f,A=y,S=g,j=m;Object.freeze(Object.defineProperty({__proto__:null,add:o,ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e[3]=Math.ceil(t[3]),e},copy:i,copyVec3:function(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},dist:T,distance:f,div:x,divide:u,dot:M,equals:_,exactEquals:I,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e[3]=Math.floor(t[3]),e},inverse:function(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e[3]=1/t[3],e},len:S,length:g,lerp:v,max:d,min:c,mul:C,multiply:l,negate:function(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=-t[3],e},normalize:b,random:function(e,t=1){const n=r.Ov;let i,s,o,a,l,u;do{i=2*n()-1,s=2*n()-1,l=i*i+s*s}while(l>=1);do{o=2*n()-1,a=2*n()-1,u=o*o+a*a}while(u>=1);const c=Math.sqrt((1-l)/u);return e[0]=t*i,e[1]=t*s,e[2]=t*o*c,e[3]=t*a*c,e},round:p,scale:h,scaleAndAdd:function(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e[3]=t[3]+n[3]*r,e},set:s,sqrDist:A,sqrLen:j,squaredDistance:y,squaredLength:m,str:function(e){return"vec4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"},sub:F,subtract:a,transformMat4:w,transformQuat:function(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],l=n[2],u=n[3],c=u*r+a*s-l*i,d=u*i+l*r-o*s,p=u*s+o*i-a*r,h=-o*r-a*i-l*s;return e[0]=c*u+h*-o+d*-l-p*-a,e[1]=d*u+h*-a+p*-o-c*-l,e[2]=p*u+h*-l+c*-a-d*-o,e[3]=t[3],e}},Symbol.toStringTag,{value:"Module"}))},81583(e,t,n){n.d(t,{L:()=>a,g:()=>o});var r=n(60999),i=n(7762),s=n(92474);async function o(e,t){return await e.load(),a(e,t)}async function a(e,t){const n=[],o=(...e)=>{for(const t of e)null!=t&&(Array.isArray(t)?o(...t):i.A.isCollection(t)?t.forEach(e=>o(e)):(0,s.Zm)(t)&&n.push(t))};t(o);let a=null;if(await(0,r.Tj)(n,async e=>{const t=await(0,r.Ke)(function(e){return"loadAll"in e&&"function"==typeof e.loadAll}(e)?e.loadAll():e.load());!1!==t.ok||a||(a=t)}),a)throw a.error;return e}},16494(e,t,n){var r=n(17632);const i=["dd","dl","dt","h1","h2","h3","h4","h5","h6","sub","sup","animate","animatetransform","circle","clippath","defs","ellipse","g","image","line","lineargradient","marker","mask","path","pattern","polygon","polyline","radialgradient","rect","stop","svg","switch","symbol","text","textpath","tspan","use"].reduce((e,t)=>(e[t]=[],e),{}),s=["align","alink","alt","bgcolor","border","cellpadding","cellspacing","class","color","cols","colspan","coords","d","dir","face","height","hspace","ismap","lang","marginheight","marginwidth","multiple","nohref","noresize","noshade","nowrap","ref","rel","rev","rows","rowspan","scrolling","shape","span","summary","tabindex","title","usemap","valign","value","vlink","vspace","width"],o=new r.I({whiteList:i,onTagAttr:(e,t,n)=>{const r=`${t}="${n}"`;if(s.includes(t))return r},stripIgnoreTag:!0,stripIgnoreTagBody:["script","style"]},!0),a=new r.I({whiteList:{br:[]},stripIgnoreTag:!0,escapeHtml:e=>e},!1);n.d(t,["Nd",0,a,"W5",0,o])},13069(e,t,n){n.d(t,{AG:()=>a,lk:()=>i,vD:()=>o,yS:()=>s});const r="randomUUID"in crypto;function i(){if(r)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function s(){return`{${i().toUpperCase()}}`}function o(){return`{${i()}}`}function a(e){const t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},159(e,t,n){n.d(t,{A:()=>u});var r,i=n(5482),s=n(69540),o=n(25482),a=n(91429),l=n(99157);let u=r=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.steps=[]}getInverse(){const e=new r;for(let t=this.steps.length-1;t>=0;t--){const n=this.steps[t];e.steps.push(n.getInverse())}return e}};(0,i.Cg)([(0,a.MZ)({type:[l.A],nonNullable:!0,json:{name:"geoTransforms"}})],u.prototype,"steps",void 0),u=r=(0,i.Cg)([(0,a.$K)("esri.geometry.operators.support.GeographicTransformation")],u)},99157(e,t,n){n.d(t,{A:()=>l});var r,i=n(5482),s=n(69540),o=n(25482),a=n(91429);let l=r=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.isInverse=!1,this.wkt=null,this.wkid=null}getInverse(){return new r({isInverse:!this.isInverse,wkid:this.wkid,wkt:this.wkt})}};(0,i.Cg)([(0,a.MZ)({json:{name:"transformForward",read:e=>!e,write:(e,t,n)=>{t[n]=!e}}})],l.prototype,"isInverse",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],l.prototype,"wkt",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],l.prototype,"wkid",void 0),l=r=(0,i.Cg)([(0,a.$K)("esri.geometry.operators.support.GeographicTransformationStep")],l)},9762(e,t,n){n.r(t),n.d(t,{projectBuffer:()=>i});var r=n(49208);function i(e,t,n,i,s,o,a=Math.floor(e.length/3)){const l=(0,r.jd)(t,s);if(null==l)return!1;if(l===r.pO){if(e===i&&n===o)return!0;const t=n+3*a;for(let r=n,s=o;r<t;r++,s++)i[s]=e[r]??0;return!0}const u=n+3*a;for(let t=n,r=o;t<u;t+=3,r+=3)l(e,t,i,r);return!0}},49208(e,t,n){n.d(t,{Tp:()=>d,jd:()=>c,pO:()=>h});var r=n(34727),i=n(86211),s=n(73941),o=n(79258),a=n(34403),l=n(21325);const u={2:{5:h,7:null,9:null,10:h,1:w,6:null,8:null,0:null,3:y,11:g,2:h,4:x},5:{5:h,7:null,9:null,10:h,1:w,6:null,8:null,0:null,3:y,11:g,2:h,4:x},7:{5:null,7:h,9:null,10:h,1:null,6:v,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:h,10:h,1:null,6:null,8:M,0:null,3:null,11:null,2:null,4:null},3:{5:f,7:null,9:null,10:f,1:function(e,t,n,r){const i=e[t]/Z,s=O-2*Math.atan(Math.exp(-e[t+1]/Z)),o=Z+(e[t+2]??0),a=Math.cos(s)*o;n[r]=Math.cos(i)*a,n[r+1]=Math.sin(i)*a,n[r+2]=Math.sin(s)*o},6:null,8:null,0:null,3:h,11:function(e,t,n,r){f(e,t,n,r),g(n,r,n,r)},2:f,4:function(e,t,n,r){f(e,t,n,r),x(n,r,n,r)}},4:{5:T,7:null,9:null,10:T,1:function(e,t,n,r){T(e,t,n,r),w(n,r,n,r)},6:null,8:null,0:null,3:function(e,t,n,r){T(e,t,n,r),y(n,r,n,r)},11:function(e,t,n,r){T(e,t,n,r),g(n,r,n,r)},2:T,4:h},1:{5:C,7:null,9:null,10:C,1:h,6:null,8:null,0:null,3:function(e,t,n,r){C(e,t,n,r),y(n,r,n,r)},11:function(e,t,n,r){C(e,t,n,r),g(n,r,n,r)},2:C,4:function(e,t,n,r){C(e,t,n,r),x(n,r,n,r)}},6:{5:null,7:F,9:null,10:F,1:null,6:h,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:_,10:_,1:null,6:null,8:h,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:h,3:null,11:null,2:null,4:null},10:{5:h,7:h,9:h,10:h,1:w,6:v,8:M,0:null,3:y,11:g,2:h,4:x},11:{5:m,7:null,9:null,10:m,1:function(e,t,n,r){m(e,t,n,r),w(n,r,n,r)},6:null,8:null,0:null,3:function(e,t,n,r){m(e,t,n,r),y(n,r,n,r)},11:h,2:m,4:function(e,t,n,r){m(e,t,n,r),x(n,r,n,r)}}};function c(e,t){return d(e,t)?.projector}function d(e,t){if(null==e||null==t)return null;if(A.source.spatialReference===e&&A.dest.spatialReference===t)return A;const n=p(e,A.source),r=p(t,A.dest);return 0===n&&0===r?(0,l.aI)(e,t)?A.projector=h:A.projector=null:A.projector=u[n][r],A}function p(e,t){return e?t.spatialReference===e?t.spatialReferenceId:(t.spatialReference=e,"metersPerUnit"in t&&(t.metersPerUnit=(0,i.GA)(e,1)),(0,s.jA)(e)?t.spatialReferenceId=1:(0,l.oT)(e)?t.spatialReferenceId=2:(0,l.K8)(e)?t.spatialReferenceId=3:(0,l.r1)(e)?t.spatialReferenceId=11:e.wkt===s.Ro.wkt?t.spatialReferenceId=4:4490===e.wkid?t.spatialReferenceId=5:e.wkt===s.FY.wkt?t.spatialReferenceId=6:e.wkt===s.LJ.wkt?t.spatialReferenceId=8:(0,s.q8)(e)?t.spatialReferenceId=7:(0,s.KQ)(e)?t.spatialReferenceId=9:t.spatialReferenceId=0):0}function h(e,t,n,r){e!==n&&(n[r++]=e[t++],n[r++]=e[t++],n[r]=e[t]??0)}function f(e,t,n,r){n[r]=j*(e[t]/Z),n[r+1]=j*(O-2*Math.atan(Math.exp(-e[t+1]/Z))),n[r+2]=e[t+2]??0}function y(e,t,n,i){!function(e,t,n,i,s){const o=.4999999*Math.PI,a=(0,r.qE)(S*e[t+1],-o,o),l=Math.sin(a);n[i++]=S*e[t]*s.radius,n[i++]=s.halfSemiMajorAxis*Math.log((1+l)/(1-l)),n[i]=e[t+2]??0}(e,t,n,i,o.$O)}function g(e,t,n,r){n[r]=e[t]*z,n[r+1]=e[t+1]*z,n[r+2]=e[t+2]??0}function m(e,t,n,r){n[r]=e[t]*R,n[r+1]=e[t+1]*R,n[r+2]=e[t+2]??0}function b(e,t,n,r,i){const s=i+(e[t+2]??0),o=S*e[t],a=S*e[t+1],l=Math.cos(a)*s;n[r]=Math.cos(o)*l,n[r+1]=Math.sin(o)*l,n[r+2]=Math.sin(a)*s}function M(e,t,n,r){b(e,t,n,r,o.Sw.radius)}function v(e,t,n,r){b(e,t,n,r,o.sH.radius)}function w(e,t,n,r){b(e,t,n,r,o.$O.radius)}function I(e,t,n,i,s){const o=e[t],a=e[t+1],l=e[t+2]??0,u=Math.sqrt(o*o+a*a+l*l),c=(0,r.YN)(l/(0===u?1:u)),d=Math.atan2(a,o);n[i++]=j*d,n[i++]=j*c,n[i]=u-s}function _(e,t,n,r){I(e,t,n,r,o.Sw.radius)}function F(e,t,n,r){I(e,t,n,r,o.sH.radius)}function C(e,t,n,r){I(e,t,n,r,o.$O.radius)}function x(e,t,n,r){!function(e,t,n,r,i){const s=S*e[t],o=S*e[t+1],a=e[t+2]??0,l=Math.sin(o),u=Math.cos(o),c=i.radius/Math.sqrt(1-i.eccentricitySquared*l*l);n[r++]=(c+a)*u*Math.cos(s),n[r++]=(c+a)*u*Math.sin(s),n[r++]=(c*(1-i.eccentricitySquared)+a)*l}(e,t,n,r,o.$O)}function T(e,t,n,r){const i=a.TP,s=e[t],l=e[t+1],u=e[t+2]??0;let c,d,p,h,f,y,g,m,b,M,v,w,I,_,F,C,x,T,A,S,O;c=Math.abs(u),d=s*s+l*l,p=Math.sqrt(d),h=d+u*u,f=Math.sqrt(h),S=Math.atan2(l,s),y=u*u/h,g=d/h,_=i.a2/f,F=i.a3-i.a4/f,g>.3?(m=c/f*(1+g*(i.a1+_+y*F)/f),A=Math.asin(m),M=m*m,b=Math.sqrt(1-M)):(b=p/f*(1-y*(i.a5-_-g*F)/f),A=Math.acos(b),M=1-b*b,m=Math.sqrt(M)),v=1-o.$O.eccentricitySquared*M,w=o.$O.radius/Math.sqrt(v),I=i.a6*w,_=p-w*b,F=c-I*m,x=b*_+m*F,C=b*F-m*_,T=C/(I/v+x),A+=T,O=x+C*T/2,u<0&&(A=-A),n[r++]=j*S,n[r++]=j*A,n[r]=O}const A={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:h},S=(0,r.kU)(1),j=(0,r.KJ)(1),O=.5*Math.PI,Z=o.$O.radius,z=Z*Math.PI/180,R=180/(Z*Math.PI);n.d(t,["w5",0,u])},91218(e,t,n){n.r(t),n.d(t,{canProjectWithoutEngine:()=>K,initializeProjection:()=>B,isEqualBaseGCS:()=>H,isLoaded:()=>Z,isLoadedOrLoad:()=>z,isLoadedOrLoadFor:()=>R,load:()=>k,project:()=>L,projectAsync:()=>G,projectExtent:()=>ie,projectMany:()=>P,projectMultipoint:()=>Q,projectOrLoad:()=>N,projectOrLoadMany:()=>U,projectPoint:()=>J,projectPolygon:()=>ne,projectPolyline:()=>ee,projectWithoutEngine:()=>W,requiresLoad:()=>E,test:()=>V,tryProject:()=>q,unload:()=>D});var r=n(49186),i=n(17676),s=n(62788),o=n(95488),a=n(51850),l=n(21276),u=n(73941),c=n(5443),d=n(91075),p=n(48526),h=n(86738),f=n(39829),y=n(82799),g=n(16930),m=n(98764),b=n(159),M=n(9762),v=n(49208);function w(e,t,n,r,i,s){return I[0]=e,I[1]=t,I[2]=n,(0,M.projectBuffer)(I,r,0,i,s,0)}const I=(0,a.vt)();var _=n(60408),F=n(21325),C=n(52006);let x=null,T=null,A=null,S=null,j={};const O=new o.I;function Z(){return!!(T?.isLoaded()&&A?.isLoaded()&&S?.isLoaded())}function z(){return!!Z()||((0,s.gc)(O),k(),!1)}function R(e,t){return!e||!t||K(e,t)||z()}function E(e,t){return!K(e,t)&&!Z()}async function k(e){null==x&&(x=Promise.all([n.e(3276).then(n.bind(n,83276)).then(e=>(T=e,T.load())),n.e(8377).then(n.bind(n,8377)).then(e=>(A=e,A.load())),n.e(2158).then(n.bind(n,12158)).then(e=>(S=e,S.load()))])),await x,(0,i.Te)(e),O.notify()}function L(e,t,n){return Array.isArray(e)?0===e.length?[]:((0,l.H)(e),P(e,e[0].spatialReference,t,n)):((0,l.f)(e),P([e],e.spatialReference,t,n)[0])}function P(e,t,n,r){if(null==t||null==n)return e;if(K(t,n,r))return e.map(e=>W(e,t,n));if(null==r?.geographicTransformation&&(0,u.jA)(t))return P(e.map(e=>W(e,t,g.A.WGS84)),g.A.WGS84,n,{zConversionDisabled:r?.zConversionDisabled});if(null==r?.geographicTransformation&&(0,u.jA)(n))return P(e,t,g.A.WGS84).map(e=>W(e,g.A.WGS84,n));if(!Z())throw new $;if(!r?.geographicTransformation)if(r?.extendedParams)r={...r,geographicTransformation:S.getTransformation(t,n,r.areaOfInterestExtent)||new b.A};else if(!r?.areaOfInterestExtent){const e=function(e,t){return[e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??"",t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??""].join()}(t,n);let i=j[e];i||(i=S.getTransformation(t,n)||new b.A,j[e]=i),r={geographicTransformation:i,zConversionDisabled:r?.zConversionDisabled}}return e[0].spatialReference||(e[0].spatialReference=t),e[0]instanceof d.A?T.executeMany(e,n,r):A.executeMany(e,n,r)}function q(e,t,n){try{return L(e,t,n)}catch(e){return null}}function N(e,t){const n=U([e],t);return null!=n.pending?{pending:n.pending,geometry:null}:null!=n.geometries?{pending:null,geometry:n.geometries[0]}:{pending:null,geometry:null}}function U(e,t,n){if(!Z())for(const n of e)if(null!=n&&!(0,F.aI)(n.spatialReference,t)&&(0,F.fn)(n.spatialReference)&&(0,F.fn)(t)&&!K(n.spatialReference,t))return(0,s.gc)(O),{pending:k(),geometries:null};return{pending:null,geometries:e.map(e=>null==e?null:(0,F.aI)(e.spatialReference,t)?e:(0,F.fn)(e.spatialReference)&&(0,F.fn)(t)?L(e,t,n):null)}}class $ extends r.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function D(){x=null,T=null,A=null,S=null,j={}}const V={get loadPromise(){return x}};async function G(e,t,n){if((0,i.Te)(n),!e)return e;const r=U(Array.isArray(e)?e:[e],t,n);if(r.pending)return await r.pending,(0,i.Te)(n),G(e,t,n);const s=r.geometries??[];return Array.isArray(e)?s:s[0]}function K(e,t,n){return!(n?.areaOfInterestExtent||n?.extendedParams||n?.geographicTransformation)&&(!!(0,F.aI)(e,t)||(0,F.fn)(e)&&(0,F.fn)(t)&&!!(0,v.jd)(e,t))}function H(e,t){if((0,F.aI)(e,t))return!0;if(!(0,F.fn)(e)||!(0,F.fn)(t))return!1;const n=(0,F.oT)(e)||(0,F.K8)(e)||(0,F.x1)(e),r=(0,F.oT)(t)||(0,F.K8)(t)||(0,F.x1)(t);return n&&r}async function B(e,t,n,r){if(Z())return(0,i.NO)(r);if(Array.isArray(e)){for(const{source:t,dest:n,options:i}of e)if(t&&n&&!K(t,n,i))return k(r)}else if(e&&t&&!K(e,t,n))return k(r);return(0,i.NO)(r)}function W(e,t,n){return e?(0,_.fT)(e)?Y(e,t,new h.A,n,0):(0,_.ZC)(e)?se(e,t,new c.A,n,0):(0,_.Bi)(e)?re(e,t,new f.A,n,0):(0,_.Rg)(e)?te(e,t,new y.A,n,0):(0,_.U9)(e)?X(e,t,new p.A,n,0):null:null}function J(e,t,n=t.spatialReference,r=0){return null!=n&&null!=e.spatialReference&&null!=Y(e,e.spatialReference,t,n,r)}function Y(e,t,n,r,i){ue[0]=e.x,ue[1]=e.y;const s=e.z;return ue[2]=void 0!==s?s:i,(0,M.projectBuffer)(ue,t,0,ue,r,0)?(n.x=ue[0],n.y=ue[1],n.spatialReference=r,void 0!==s||(0,u.xP)(r)?(n.z=ue[2],n.hasZ=!0):(n.z=void 0,n.hasZ=!1),void 0===e.m?(n.m=void 0,n.hasM=!1):(n.m=e.m,n.hasM=!0),n):null}function Q(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=X(e,e.spatialReference,t,n,r)}function X(e,t,n,r,i){const{points:s,hasZ:o,hasM:a}=e,l=[],u=s.length,c=[];for(const e of s)c.push(e[0],e[1],o?e[2]:i);if(!(0,M.projectBuffer)(c,t,0,c,r,0,u))return null;const d=le(o,r);for(let e=0;e<u;++e){const t=3*e,n=c[t],r=c[t+1];d&&a?l.push([n,r,c[t+2],s[e][3]]):d?l.push([n,r,c[t+2]]):a?l.push([n,r,s[e][2]]):l.push([n,r])}return n.points=l,n.spatialReference=r,n.hasZ=o,n.hasM=a,n}function ee(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=te(e,e.spatialReference,t,n,r)}function te(e,t,n,r,i){const{curvePaths:s,paths:o,hasZ:a,hasM:l}=e;if(!(s?ae(s,a??!1,l??!1,t,n.curvePaths=[],r,i):oe(o,a??!1,l??!1,t,n.paths,r,i)))return null;const u=le(a,r);return n.spatialReference=r,n.hasZ=u,n.hasM=l,n}function ne(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=re(e,e.spatialReference,t,n,r)}function re(e,t,n,r,i){const{curveRings:s,rings:o,hasZ:a,hasM:l}=e;return(s?ae(s,a??!1,l??!1,t,n.curveRings=[],r,i):oe(o,a??!1,l??!1,t,n.rings,r,i))?(n.spatialReference=r,n.hasZ=le(a,r),n.hasM=l,n):null}function ie(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=se(e,e.spatialReference,t,n,r)}function se(e,t,n,r,i){const{xmin:s,ymin:o,xmax:a,ymax:l,hasZ:u,hasM:c}=e;if(!w(s,o,u?e.zmin:i,t,ue,r))return null;const d=le(u,r);return n.xmin=ue[0],n.ymin=ue[1],d&&(n.zmin=ue[2]),w(a,l,u?e.zmax:i,t,ue,r)?(n.xmax=ue[0],n.ymax=ue[1],d&&(n.zmax=ue[2]),c&&(n.mmin=e.mmin,n.mmax=e.mmax),n.spatialReference=r,n):null}function oe(e,t,n,r,i,s,o=0){const a=new Array;for(const n of e)for(const e of n)a.push(e[0],e[1],t?e[2]:o);if(!(0,M.projectBuffer)(a,r,0,a,s,0))return!1;let l=0;i.length=0;const u=t?3:2,c=le(t,s);for(const t of e){const e=new Array;for(const r of t){const t=a.slice(l,l+=3);c||t.pop(),n&&t.push(r[u]),e.push(t)}i.push(e)}return!0}function ae(e,t,n,r,i,s,o=0){const a=new Array;for(const n of e)for(const e of n){if((0,C.FG)(e))return!1;if((0,C.aO)(e)){const[n,r]=e.c;a.push(n[0],n[1],t?n[2]:o,r[0],r[1],o);continue}if((0,C.n1)(e)){const[n,r,i]=e.b;a.push(n[0],n[1],t?n[2]:o,r[0],r[1],o,i[0],i[1],o);continue}const n=e;a.push(n[0],n[1],t?n[2]:o)}if(!(0,M.projectBuffer)(a,r,0,a,s,0))return!1;let l=0;i.length=0;const u=t?3:2,c=le(t,s);for(const t of e){const e=new Array;for(const r of t){const t=a.slice(l,l+=3);if(c||t.pop(),n&&t.push((0,C.yP)(r)[u]),(0,C.FG)(r))return!1;if((0,C.aO)(r)){const n=a[l++],r=a[l++];++l,e.push({c:[t,[n,r]]});continue}if((0,C.n1)(r)){const n=a[l++],r=a[l++];++l;const i=a[l++],s=a[l++];++l,e.push({b:[t,[n,r],[i,s]]});continue}e.push(t)}i.push(e)}return!0}function le(e,t){return e||(0,u.xP)(t)||(0,F.aI)(t,m.Y0)}const ue=(0,a.vt)()},98764(e,t,n){n.d(t,{lO:()=>c});var r=n(73941),i=n(16930),s=n(21325);const o=new i.A(r.fv),a=new i.A(r.FY),l=new i.A(r.LJ),u=new i.A(r.Ro);function c(e){const t=d.get(e);if(t)return t;let n=o;if(e)if(e===a)n=a;else if(e===l)n=l;else{const t=e.wkid,r=e.latestWkid;if(null!=t||null!=r)(0,s.tl)(t)||(0,s.tl)(r)?n=a:((0,s.ZL)(t)||(0,s.ZL)(r))&&(n=l);else{const t=e.wkt2??e.wkt;if(t){const e=t.toUpperCase();e===p?n=a:e===h&&(n=l)}}}return d.set(e,n),n}const d=new Map,p=a.wkt.toUpperCase(),h=l.wkt.toUpperCase();n.d(t,["GD",0,o,"Y0",0,u])},4197(e,t,n){n.d(t,{Vj:()=>c,cj:()=>u,jh:()=>s,l5:()=>a,yH:()=>l});var r=n(34275),i=n(9093);function s(e){return e<=1024?new Array(e).fill(0):new Float64Array(e)}function o(e){return((0,r.iu)(e)?e.byteLength/8:e.length)<=1024?Array.from(e):new Float64Array(e)}function a(e,t,n){return Array.isArray(e)?e.slice(t,t+n):e.subarray(t,t+n)}function l(e,t){if(0===t.length)return o(e);if(0===e.length)return o(t);const n=s(e.length+t.length);for(let t=0;t<e.length;++t)n[t]=e[t];for(let r=0;r<t.length;++r)n[e.length+r]=t[r];return n}function u(e){return[...e]}function c(e){const t=(0,i.vt)();for(let n=0;n<16;++n)t[n]=e[n];return t}},70328(e,t,n){n.d(t,{BI:()=>A,C:()=>o,DC:()=>p,Dg:()=>f,Ej:()=>v,Ie:()=>x,Jt:()=>T,Lu:()=>I,Ne:()=>_,RF:()=>d,TF:()=>b,VL:()=>y,aI:()=>j,fA:()=>a,gE:()=>u,gX:()=>M,hZ:()=>C,iT:()=>h,is:()=>S,pg:()=>w,uJ:()=>m,vI:()=>F,vY:()=>l,vt:()=>s,w1:()=>c,yr:()=>g}),n(35522);var r=n(5443),i=(n(19419),n(4197));function s(e=Z){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t){for(let n=0;n<6;n++)e[n]=t[n];return e}function a(e,t,n,r,i,o,a=s()){return a[0]=e,a[1]=t,a[2]=n,a[3]=r,a[4]=i,a[5]=o,a}function l(e,t=s()){return function(e,t,n,r=s()){return C(r,O),function(e,t,n=0,r=t.length/3){let i=e[0],s=e[1],o=e[2],a=e[3],l=e[4],u=e[5];for(let e=0;e<r;e++)i=Math.min(i,t[n+3*e]),s=Math.min(s,t[n+3*e+1]),o=Math.min(o,t[n+3*e+2]),a=Math.max(a,t[n+3*e]),l=Math.max(l,t[n+3*e+1]),u=Math.max(u,t[n+3*e+2]);e[0]=i,e[1]=s,e[2]=o,e[3]=a,e[4]=l,e[5]=u}(r,e,t,n),r}(e,0,e.length/3,t)}function u(e,t=(0,i.jh)(24)){const[n,r,s,o,a,l]=e;return t[0]=n,t[1]=r,t[2]=s,t[3]=n,t[4]=r,t[5]=l,t[6]=n,t[7]=a,t[8]=s,t[9]=n,t[10]=a,t[11]=l,t[12]=o,t[13]=r,t[14]=s,t[15]=o,t[16]=r,t[17]=l,t[18]=o,t[19]=a,t[20]=s,t[21]=o,t[22]=a,t[23]=l,t}function c(e,t){const n=isFinite(e[2])||isFinite(e[5]);return new r.A(n?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function d(e,t,n=e){n[0]=Math.min(e[0],t[0]),n[1]=Math.min(e[1],t[1]),n[2]=Math.min(e[2],t[2]),n[3]=Math.max(e[3],t[3]),n[4]=Math.max(e[4],t[4]),n[5]=Math.max(e[5],t[5])}function p(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[3]=Math.max(e[3],t[2]),e[4]=Math.max(e[4],t[3])}function h(e,[t,n,r]){f(e,t,n,r)}function f(e,t,n,r){e[0]=Math.min(e[0],t),e[1]=Math.min(e[1],n),e[2]=Math.min(e[2],r),e[3]=Math.max(e[3],t),e[4]=Math.max(e[4],n),e[5]=Math.max(e[5],r)}function y(e){return e[0]>=e[3]?0:e[3]-e[0]}function g(e){return e[1]>=e[4]?0:e[4]-e[1]}function m(e){return e[2]>=e[5]?0:e[5]-e[2]}function b(e){const t=y(e),n=m(e),r=g(e);return t*t+n*n+r*r}function M(e,t=[0,0,0]){return t[0]=e[0]+y(e)/2,t[1]=e[1]+g(e)/2,t[2]=e[2]+m(e)/2,t}function v(e,t=[0,0,0]){return t[0]=y(e),t[1]=g(e),t[2]=m(e),t}function w(e,t){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function I(e,t){return t[0]=e[3],t[1]=e[4],t[2]=e[5],t}function _(e,t,n=e){return n[0]=t[0],n[1]=t[1],n[2]=t[2],n!==e&&(n[3]=e[3],n[4]=e[4],n[5]=e[5]),n}function F(e,t,n=e){return n[3]=t[0],n[4]=t[1],n[5]=t[2],n!==e&&(n[0]=e[0],n[1]=e[1],n[2]=e[2]),e}function C(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function x(e){return e?C(e,O):s(O)}function T(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function A(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=Number.NEGATIVE_INFINITY,e[3]=r,e[4]=i,e[5]=Number.POSITIVE_INFINITY,e}function S(e){return 6===e.length}function j(e,t,n){if(null==e||null==t)return e===t;if(!S(e)||!S(t))return!1;if(n){for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!1}else for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}const O=[1/0,1/0,1/0,-1/0,-1/0,-1/0],Z=[0,0,0,0,0,0];s(),n.d(t,["qv",0,O,"v_",0,Z])},34403(e,t,n){var r=n(79258);Math.PI;const i=r.$O.radius,s=r.$O.eccentricitySquared,o={a1:i*s,a2:i*s*i*s,a3:i*s*s/2,a4:i*s*i*s*2.5,a5:i*s+i*s*s/2,a6:1-s};r.$O.radius,r.$O.flattening,r.Sw.radius,r.Sw.flattening,r.sH.radius,r.sH.flattening,r.sH.radius,n.d(t,["TP",0,o])},55156(e,t,n){n.d(t,{I:()=>i});const r=Symbol("idFieldsProviderSymbol");function i(e){return(t=e)&&r in t?e[r]:void 0;var t}n.d(t,["e",0,r])},97483(e,t,n){n.r(t),n.d(t,{default:()=>Ue});var r=n(5482),i=n(69540),s=n(7762),o=n(49186),a=n(81583),l=n(91869),u=n(25728),c=n(17676),d=n(36708),p=n(39516),h=n(91429),f=n(4146),y=n(52136),g=n(18768),m=n(63074),b=n(69208),M=n(6455),v=n(47685),w=n(10086),I=n(34287),_=n(8303),F=n(54310),C=n(25036),x=n(82935),T=n(60694),A=n(10873),S=n(15426),j=n(17036),O=n(30524),Z=n(85334),z=n(90360),R=n(86162),E=n(92438),k=n(96576),L=n(93618),P=n(62046),q=n(37531);const N={key:"type",base:E.A,errorContext:"renderer",typeMap:{simple:k.A,"unique-value":L.A,"class-breaks":R.A}},U=(0,z.C)({types:N}),$=["#ed5151","#149ece","#a7c636","#9e559c","#fc921f","#ffde3e","#f789d8","#b7814a","#3caf99","#6b6bd6","#b54779","#7f7f7f"];var D=n(37838),V=n(4902),G=n(4718),K=n(92474),H=n(53966),B=n(97768),W=n(93637),J=n(89317),Y=n(78247),Q=n(16930),X=n(55156),ee=n(60950),te=n(89808),ne=n(99959);const re=Symbol("isSubtypeGroupGraphicOriginSymbol");var ie;class se extends ne.A{get[(ie=re,ee.ym)](){return this.sublayer}get[X.e](){return this.sublayer}get[te.Q](){return this.layer}constructor(e){super(),this[ie]=!0,this.type="subtype-group",this.sublayer=e}get layer(){return this.sublayer.parent}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}var oe=n(29005),ae=n(30279),le=n(16194),ue=n(46499),ce=n(39383),de=n(17311),pe=n(54546),he=n(97552),fe=n(30291),ye=n(59868),ge=n(43440),me=n(43937),be=n(36005);const Me=(0,j.p)();let ve=0;function we(e,t){let n=e.json.write;return"object"!=typeof n&&(n=e.json.write={}),n.ignoreOrigin=!0,t?.spatialOnly&&(n.layerContainerTypes=J.K),e}function Ie(e){const t={write:{ignoreOrigin:!0}};return e?.name&&(t.name=e.name),"object"==typeof t.write&&(e?.spatialOnly&&(t.write.layerContainerTypes=J.K),e?.target&&(t.write.target=e.target)),t}function _e(e){switch(e){case"point":case"multipoint":return ye.UK.clone();case"polyline":return ye.A7.clone();case"polygon":case"multipatch":return ye.Cx.clone();default:return null}}function Fe(e){return xe(e,"user")===e}function Ce(e){return xe(e,"service")}function xe(e,t){const n=e.parent?.getAtOrigin("sublayers",t);return n?.find(({subtypeCode:t})=>t===e.subtypeCode)}function Te(e,t){return null==e?null:t.subtypes?.find(t=>t.code===e)}function Ae(e,t){let n=null;switch(t.geometryType){case"esriGeometryPoint":case"esriGeometryMultipoint":n="point";break;case"esriGeometryPolyline":n="line";break;case"esriGeometryPolygon":case"esriGeometryMultiPatch":n="polygon";break;default:t.type,n=null}const r={},i=Te(e,t);if(null!=i){const{defaultValues:e}=i;for(const t in e)r[t]=e[t]}return r[t.subtypeField]=e,new oe.A({name:"New Feature",drawingTool:n,prototype:{attributes:r}})}let Se=class extends((0,u.M)((0,i.OU)((0,V.s)(K.x_)))){constructor(e){super(e),this.attributeTableTemplate=null,this.charts=null,this.editingEnabled=!0,this.fieldOverrides=null,this.fieldsIndex=null,this.formTemplate=null,this.graphicOrigin=new se(this),this.id=`${Date.now().toString(16)}-subtype-sublayer-${ve++}`,this.type="subtype-sublayer",this.labelsVisible=!0,this.labelingInfo=null,this.layerType="ArcGISFeatureLayer",this.legendEnabled=!0,this.listMode="show",this.minScale=0,this.maxScale=0,this.opacity=1,this.parent=null,this.popupEnabled=!0,this.popupTemplate=null,this.subtypeCode=null,this.visible=!0}load(e){return(0,O.yp)(this.renderer,this.fieldsIndex),Promise.resolve(this)}get _titleCreator(){const e=this._get("_titleCreator");return(0,B.pR)(e),new de.A({fieldsIndex:this.fieldsIndex,objectIdField:this.objectIdField,displayField:this.parent?.displayField??"",fields:this.fields,effectivePopupTemplate:this.popupTemplate??this.defaultPopupTemplate})}get capabilities(){return this.parent?.capabilities}get effectiveCapabilities(){return this.parent?.effectiveCapabilities}get effectiveEditingEnabled(){const{parent:e}=this;return e?e.effectiveEditingEnabled&&this.editingEnabled:this.editingEnabled}get elevationInfo(){return this.parent?.elevationInfo}get featureTitleFields(){return[...this._titleCreator.requiredFields]}set fieldConfigurations(e){if(this._override("fieldConfigurations",e),!this.parent?.loaded)return;const t=(0,le.sS)(this,e);t&&this._set("popupTemplate",t)}get fieldConfigurations(){return this._isOverridden("fieldConfigurations")?this._get("fieldConfigurations"):(0,le.QX)(this)||null}writeFieldOverrides(e,t,n){const{fields:r,parent:i}=this;let s;if(r){s=[];let e=0;r.forEach(({name:t,alias:n,editable:r,visible:o})=>{if(!o)return;const a=i?.fields?.find(e=>e.name===t);if(!a)return;const l={name:t};let u=!1;n!==a.alias&&(l.alias=n,u=!0),r!==a.editable&&(l.editable=r,u=!0),s.push(l),u&&e++}),0===e&&s.length===r.length&&(s=null)}else s=(0,G.o8)(e);s?.length&&(0,W.sM)(n,s,t)}get fields(){const{parent:e,fieldOverrides:t,subtypeCode:n}=this,r=e?.fields;if(!e||!r?.length)return null;const{subtypes:i,subtypeField:s}=e,o=i?.find(e=>e.code===n),a=o?.defaultValues,l=o?.domains,u=[];for(const e of r){const r=e.clone(),{name:i}=r,o=t?.find(e=>e.name===i);if(r.visible=!t?.length||!!o,o){const{alias:e,editable:t}=o;e&&(r.alias=e),!1===t&&(r.editable=!1)}const c=a?.[i]??null;r.defaultValue=i===s?n:c;const d=l?.[i]??null;r.domain=i===s?null:d?"inherited"===d.type?r.domain:d.clone():null,u.push(r)}return u}get floorInfo(){return this.parent?.floorInfo}get isTable(){return!!this.parent?.isTable}get geometryType(){return this.parent?.geometryType}get globalIdField(){return this.parent?this.parent.globalIdField:(H.A.getLogger(this).error(Ze("globalIdField")),null)}get effectiveScaleRange(){const{minScale:e,maxScale:t}=this;return{minScale:e,maxScale:t}}get objectIdField(){return this.parent||H.A.getLogger(this).error(Ze("objectIdField")),this.parent?.objectIdField}writePopupTemplate(e,t,n,r){e&&(t[n]=e.toJSON({...r,writeFieldFormat:!0}))}get defaultPopupTemplate(){return this.createPopupTemplate()}get relationships(){return this.parent?.relationships}set renderer(e){(0,O.yp)(e,this.fieldsIndex),this._override("renderer",e)}get renderer(){if(this._isOverridden("renderer"))return this._get("renderer");const{parent:e}=this;return e&&!e.isTable&&"mesh"!==e.geometryType?(Fe(this)?(0,G.o8)(Ce(this)?.renderer):null)??function(e){return new k.A({symbol:_e(e)})}(e.geometryType):null}readRendererFromService(e,t,n){if("Table"===t.type)return null;const r=t.drawingInfo?.renderer,i=U(r,t,n);let s;const{subtypeCode:o}=this;if(null!=o&&function(e,t){return!(!t||"unique-value"!==e?.type||null==e.field||e.field.toLowerCase()!==t.toLowerCase()||e.field2||e.field3||e.valueExpression)}(i,t.subtypeField)){const e=i.uniqueValueInfos?.find(({value:e})=>(e="number"==typeof e?String(e):e)===String(o));e&&(s=new k.A({symbol:e.symbol}))}else"simple"!==i?.type||i.visualVariables?.length||(s=i);return s}readRenderer(e,t,n){const r=t?.layerDefinition?.drawingInfo?.renderer;if(r)return U(r,t,n)||void 0}get spatialReference(){return this.parent?.spatialReference??Q.A.WGS84}get subtypeField(){return this.parent?.subtypeField}get templates(){return this._isOverridden("templates")?this._get("templates"):(0,G.o8)(Fe(this)?Ce(this)?.templates:xe(this,"portal-item")?.templates||Ce(this)?.templates)}set templates(e){this._override("templates",e)}readTemplatesFromService(e,t){return[Ae(this.subtypeCode,t)]}get title(){if(this._isOverridden("title"))return this._get("title");const e=Fe(this)?Ce(this):null;return e?.title}set title(e){this._override("title",e)}readTitleFromService(e,t){const n=Te(this.subtypeCode,t);return null!=n?n.name:null}get url(){return this.parent?.url}get userHasUpdateItemPrivileges(){return!!this.parent?.userHasUpdateItemPrivileges}async addAttachment(e,t,n){const{parent:r}=this;if(!r)throw Ze("addAttachment");if(e.getAttribute(r.subtypeField)!==this.subtypeCode)throw new o.A("subtype-sublayer:addAttachment","The feature provided does not belong to this SubtypeSublayer");return r.addAttachment(e,t,n)}async updateAttachment(e,t,n,r){const{parent:i}=this;if(!i)throw Ze("updateAttachment");if(e.getAttribute(i.subtypeField)!==this.subtypeCode)throw new o.A("subtype-sublayer:updateAttachment","The feature provided does not belong to this SubtypeSublayer");return i.updateAttachment(e,t,n,r)}async deleteAttachments(e,t,n){const{parent:r}=this;if(!r)throw Ze("deleteAttachments");if(e.getAttribute(r.subtypeField)!==this.subtypeCode)throw new o.A("subtype-sublayer:deleteAttachments","The feature provided does not belong to this SubtypeSublayer");return r.deleteAttachments(e,t,n)}async applyEdits(e,t){if(!this.parent)throw Ze("applyEdits");return this.parent.applyEdits(e,t)}createFieldConfigurations(){return(0,le.xY)(this)}createPopupTemplate(e){let t=this;const{parent:n,fields:r,title:i}=this;if(n){const{displayField:e,editFieldsInfo:s,objectIdField:o}=n;t={displayField:e,editFieldsInfo:s,fields:r,objectIdField:o,title:i}}return(0,fe.tn)(t,e)}createQuery(){if(!this.parent)throw Ze("createQuery");const e=(0,S.VZ)(this.parent),t=`${this.parent.subtypeField}=${this.subtypeCode}`;return e.where=(0,p.mA)(t,this.parent.definitionExpression),e}getFeatureTitle(e,t){return this._titleCreator.getTitle(this,e,t)}getFeatureTitles(e,t){return this._titleCreator.getTitles(this,e,t)}getField(e){return this.fieldsIndex.get(e)}getFieldAlias(e){const t=this.getField(e);if(t)return this.getFieldConfiguration(t.name)?.alias||t.alias}getFieldConfiguration(e){return e=e.toLowerCase(),this.fieldConfigurations?.find(t=>t.name.toLowerCase()===e)}getFieldDomain(e,t){if(!t?.excludeImpliedDomains&&this.parent){const t=(0,S.pc)(this.parent,e);if(t)return t}return this._getLayerDomain(e)}async queryAttachments(e,t){const n=await this.load();if(!n.parent)throw Ze("queryAttachments");const r=e instanceof pe.A?e.clone():new pe.A(e);return r.where=Oe(r.where,n.parent.subtypeField,n.subtypeCode),n.parent.queryAttachments(r,t)}async queryFeatureCount(e,t){const n=await this.load();if(!n.parent)throw Ze("queryFeatureCount");return n.parent.queryFeatureCount(je(n.parent,n,e),t)}async queryFeatures(e,t){const n=await this.load();if(!n.parent)throw Ze("queryFeatures");return n.parent.queryFeatures(je(n.parent,n,e),t)}async queryObjectIds(e,t){const n=await this.load();if(!n.parent)throw Ze("queryObjectIds");return n.parent.queryObjectIds(je(n.parent,n,e),t)}async queryRelatedFeatures(e,t){const n=await this.load();if(!n.parent)throw Ze("queryRelatedFeatures");return n.parent.queryRelatedFeatures(e,t)}async queryRelatedFeaturesCount(e,t){const n=await this.load();if(!n.parent)throw Ze("queryRelatedFeaturesCount");return n.parent.queryRelatedFeaturesCount(e,t)}_getLayerDomain(e){const t=this.fieldsIndex.get(e);return t?t.domain:null}};(0,r.Cg)([(0,h.MZ)({clonable:!1,readOnly:!0})],Se.prototype,"_titleCreator",null),(0,r.Cg)([(0,h.MZ)({type:ge.A,json:Ie({name:"attributeTableInfo"})})],Se.prototype,"attributeTableTemplate",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"capabilities",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"effectiveCapabilities",null),(0,r.Cg)([(0,h.MZ)({json:Ie()})],Se.prototype,"charts",void 0),(0,r.Cg)([(0,h.MZ)({type:Boolean,nonNullable:!0,json:Ie({name:"enableEditing"})})],Se.prototype,"editingEnabled",void 0),(0,r.Cg)([(0,h.MZ)({type:Boolean,readOnly:!0})],Se.prototype,"effectiveEditingEnabled",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"elevationInfo",null),(0,r.Cg)([(0,h.MZ)({clonable:!1,readOnly:!0})],Se.prototype,"featureTitleFields",null),(0,r.Cg)([(0,h.MZ)({type:[ae.A],json:{name:"layerDefinition.fieldConfigurations",write:{ignoreOrigin:!0}}})],Se.prototype,"fieldConfigurations",null),(0,r.Cg)([(0,h.MZ)({json:{name:"layerDefinition.fieldOverrides",origins:{service:{read:!1}},write:{ignoreOrigin:!0,allowNull:!0}}})],Se.prototype,"fieldOverrides",void 0),(0,r.Cg)([(0,me.K)("fieldOverrides")],Se.prototype,"writeFieldOverrides",null),(0,r.Cg)([(0,h.MZ)({...Me.fields,readOnly:!0,json:{read:!1}})],Se.prototype,"fields",null),(0,r.Cg)([(0,h.MZ)(Me.fieldsIndex)],Se.prototype,"fieldsIndex",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"floorInfo",null),(0,r.Cg)([(0,h.MZ)({type:Y.A,json:Ie({name:"formInfo"})})],Se.prototype,"formTemplate",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,clonable:!1})],Se.prototype,"graphicOrigin",void 0),(0,r.Cg)([(0,h.MZ)({type:String,clonable:!1,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],Se.prototype,"id",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"isTable",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"geometryType",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"globalIdField",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"type",void 0),(0,r.Cg)([(0,h.MZ)(we((0,G.o8)(A.kF)))],Se.prototype,"labelsVisible",void 0),(0,r.Cg)([(0,h.MZ)({type:[ue.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",origins:{service:{read:!1}},read:{reader:ce.w},write:{ignoreOrigin:!0,layerContainerTypes:J.K}}})],Se.prototype,"labelingInfo",void 0),(0,r.Cg)([(0,h.MZ)({type:["ArcGISFeatureLayer"],readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,layerContainerTypes:J.K}}})],Se.prototype,"layerType",void 0),(0,r.Cg)([(0,h.MZ)(we((0,G.o8)(A.fV)))],Se.prototype,"legendEnabled",void 0),(0,r.Cg)([(0,h.MZ)({type:["show","hide"]})],Se.prototype,"listMode",void 0),(0,r.Cg)([(0,h.MZ)((()=>{const e=(0,G.o8)(A.hn);return e.json.origins.service.read=!1,we(e,{spatialOnly:!0})})())],Se.prototype,"minScale",void 0),(0,r.Cg)([(0,h.MZ)((()=>{const e=(0,G.o8)(A.hG);return e.json.origins.service.read=!1,we(e,{spatialOnly:!0})})())],Se.prototype,"maxScale",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Se.prototype,"effectiveScaleRange",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"objectIdField",null),(0,r.Cg)([(0,h.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0,json:Ie({spatialOnly:!0})})],Se.prototype,"opacity",void 0),(0,r.Cg)([(0,h.MZ)({clonable:!1})],Se.prototype,"parent",void 0),(0,r.Cg)([(0,h.MZ)(we((0,G.o8)(A.M6)))],Se.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,h.MZ)({type:D.A,json:Ie({name:"popupInfo"})})],Se.prototype,"popupTemplate",void 0),(0,r.Cg)([(0,me.K)("popupTemplate")],Se.prototype,"writePopupTemplate",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Se.prototype,"defaultPopupTemplate",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"relationships",null),(0,r.Cg)([(0,h.MZ)({types:N,json:Ie({target:"layerDefinition.drawingInfo.renderer",spatialOnly:!0})})],Se.prototype,"renderer",null),(0,r.Cg)([(0,be.w)("service","renderer",["drawingInfo.renderer","subtypeField","type"])],Se.prototype,"readRendererFromService",null),(0,r.Cg)([(0,be.w)("renderer",["layerDefinition.drawingInfo.renderer"])],Se.prototype,"readRenderer",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"spatialReference",null),(0,r.Cg)([(0,h.MZ)({type:Number,json:{origins:{service:{read:!1}},write:{ignoreOrigin:!0}}})],Se.prototype,"subtypeCode",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"subtypeField",null),(0,r.Cg)([(0,h.MZ)({type:[oe.A],json:Ie({name:"layerDefinition.templates"})})],Se.prototype,"templates",null),(0,r.Cg)([(0,be.w)("service","templates",["geometryType","subtypeField","subtypes","type"])],Se.prototype,"readTemplatesFromService",null),(0,r.Cg)([(0,h.MZ)({type:String,json:Ie()})],Se.prototype,"title",null),(0,r.Cg)([(0,be.w)("service","title",["subtypes"])],Se.prototype,"readTitleFromService",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Se.prototype,"url",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Se.prototype,"userHasUpdateItemPrivileges",null),(0,r.Cg)([(0,h.MZ)({type:Boolean,nonNullable:!0,json:Ie({name:"visibility",spatialOnly:!0})})],Se.prototype,"visible",void 0),Se=(0,r.Cg)([(0,h.$K)("esri.layers.support.SubtypeSublayer")],Se);const je=(e,t,n)=>{if(!n)return t.createQuery();const r=he.A.from(n);return r.where=Oe(r.where,e.subtypeField,t.subtypeCode),r},Oe=(e,t,n)=>{const r=new RegExp(`${t}\\s*=\\s*\\d+`),i=`${t}=${n}`,s=e??"";return r.test(s)?s.replace(r,i):(0,p.mA)(i,s)},Ze=e=>new o.A("subtype-sublayer:parent-missing",`This sublayer must have a parent SubtypeGroupLayer in order to use ${e}`);var ze=n(96184),Re=n(91908),Ee=n(54218),ke=n(59923);const Le="SubtypeGroupLayer";function Pe(e,t){const n=[];for(const r of e){const e=new Se;e.read(r,t),n.push(e)}return n}const qe=(0,j.p)();let Ne=class extends((0,w.j)((0,M.FJ)((0,v.w6)((0,m.dM)((0,x.e)((0,C.j)((0,F.J)((0,g.b)((0,I.q)((0,_.A)((0,u.M)((0,b.d)((0,y.p)((0,i.OU)(f.A))))))))))))))){constructor(...e){super(...e),this._sublayerLookup=new Map,this.fields=null,this.fieldsIndex=null,this.outFields=null,this.sublayers=new(s.A.ofType(Se)),this.useUniqueColorsForSublayers=!0,this.supportedSourceTypes=new Set(["Feature Layer","Table"]),this.timeInfo=null,this.title="Layer",this.type="subtype-group",this._debouncedSaveOperations=(0,c.sg)(async(e,t,r)=>{const{save:i,saveAs:s}=await n.e(5740).then(n.bind(n,33359));switch(e){case 0:return i(this,t);case 1:return s(this,r,t)}}),this.addHandles((0,d.wB)(()=>this.sublayers,(e,t)=>this._handleSublayersChange(e,t),d.OH))}destroy(){this.source?.destroy()}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=null!=e?e.signal:null,n=this.loadFromPortal({supportedTypes:["Feature Service"]},e).catch(c.QP).then(async()=>{if(!this.url)throw new o.A("subtype-grouplayer:missing-url-or-source","SubtypeGroupLayer must be created with either a url or a portal item");if(null==this.layerId)throw new o.A("subtype-grouplayer:missing-layerid","layerId is required for a SubtypeGroupLayer created with url");this._initLayerProperties(await this.createGraphicsSource(t))}).then(()=>(0,S.VA)(this,"load",e));return this.addResolvingPromise(n),Promise.resolve(this)}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("timeExtent"),this.commitProperty("timeOffset"),this.commitProperty("geometryType"),this.commitProperty("gdbVersion"),this.commitProperty("historicMoment"),this.commitProperty("returnZ"),this.commitProperty("capabilities"),this.commitProperty("returnM"),(this._get("createQueryVersion")??0)+1}get editingEnabled(){return this.loaded&&null!=this.capabilities&&this.capabilities.operations.supportsEditing&&this.userHasEditingPrivileges}get effectiveEditingEnabled(){return(0,S.C$)(this)}get operationalLayerType(){return this.isTable?"SubtypeGroupTable":"SubtypeGroupLayer"}set source(e){this._get("source")!==e&&this._set("source",e)}readTitleFromService(e,{name:t}){return this.url?(0,T.yG)(this.url,t):t}async addAttachment(e,t,n){const r=await(0,S.Xl)(this,e,t,Le,n);return this.lastEditsEventDate=new Date,r}async updateAttachment(e,t,n,r){const i=await(0,S.bt)(this,e,t,n,Le,r);return this.lastEditsEventDate=new Date,i}async applyEdits(e,t){return(0,S.ct)(this,e,t)}async createGraphicsSource(e){const{default:t}=await(0,c.qr)(Promise.all([n.e(893),n.e(3636),n.e(8548)]).then(n.bind(n,65515)),e);return new t({layer:this,supportedSourceTypes:this.supportedSourceTypes}).load({signal:e})}createQuery(){const e=(0,S.VZ)(this),t=this.sublayers.map(e=>e.subtypeCode);return e.where=(0,p.mA)(`${this.subtypeField} IN (${t.join(",")})`,this.definitionExpression),e}async deleteAttachments(e,t,n){const r=await(0,S.mm)(this,e,t,Le,n);return this.lastEditsEventDate=new Date,r}async fetchRecomputedExtents(e){return(0,S.WP)(this,e,Le)}findSublayerForFeature(e){const t=this.fieldsIndex.get(this.subtypeField),n=e.attributes[t.name];return this.findSublayerForSubtypeCode(n)}findSublayerForSubtypeCode(e){return this._sublayerLookup.get(e)}getFieldDomain(e,t){if(!t?.excludeImpliedDomains){const t=(0,S.pc)(this,e);if(t)return t}const n=(0,S.Nv)(this,t?.feature);if(n){const t=n.domains?.[e];return"inherited"===t?.type?this._getLayerDomain(e):t}return this._getLayerDomain(e)}loadAll(){return(0,a.g)(this,e=>{e(this.sublayers)})}async queryAttachments(e,t){return(0,S.lV)(this,e,t,Le)}async queryFeatures(e,t){const n=await this.load(),r=he.A.from(e)??n.createQuery(),i=r.outFields??[];i.includes(this.subtypeField)||(i.push(this.subtypeField),r.outFields=i);const s=await n.source.queryFeatures(r,t);if(s?.features)for(const e of s.features){const t=this.findSublayerForFeature(e);e.origin=t?.graphicOrigin,e.layer=e.sourceLayer=this.findSublayerForFeature(e)}return s}async queryObjectIds(e,t){return(await(0,S.sg)(this,e,t,Le)).filter(Ee.Et)}async queryFeatureCount(e,t){return(0,S.Ye)(this,e,t,Le)}async queryExtent(e,t){return(0,S.B5)(this,e,t,Le)}async queryRelatedFeatures(e,t){return(0,S.hM)(this,e,t,Le)}async queryRelatedFeaturesCount(e,t){return(0,S.S2)(this,e,t,Le)}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}write(e,t){const{origin:n,layerContainerType:r,messages:i}=t;if(this.isTable){if("web-scene"===n||"web-map"===n&&"tables"!==r)return(0,ke.U4)(t,this,"a table source cannot be written to web scenes and web maps"),null}else if(this.loaded&&"web-map"===n&&"tables"===r)return(0,ke.U4)(t,this,"a non-table source cannot be written to tables in web maps"),null;return this.sublayers?.length?super.write(e,t):(i?.push(new o.A("web-document-write:invalid-property",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' has invalid value for 'sublayers' property. 'sublayers' collection should contain at least one sublayer`,{layer:this})),null)}serviceSupportsSpatialReference(e){return!!this.loaded&&(0,Re.D)(this,e)}async getFeatureTitle(e,t){const n=this.findSublayerForFeature(e);return n?await n.getFeatureTitle(e,t):this._getFeatureTitleForUnknownSublayer(e)}async getFeatureTitles(e,t){const n=new Map,r=new Map,i=[],s=[r];if(e.forEach(e=>{const s=this.findSublayerForFeature(e);if(s)(0,l.tE)(n,s,()=>[]).push(e);else{const n=e.getObjectId()??e.attributes[this.objectIdField];t?.fetchMissingFields?i.push(e):r.set(n,this._getFeatureTitleForUnknownSublayer(e))}}),i.length>0){const e=new Set(this.featureTitleFields);e.add(this.objectIdField),e.add(this.subtypeField);const t=await this.queryFeatures({outFields:[...e],returnGeometry:!1,objectIds:i.map(e=>e.getObjectId()??e.attributes[this.objectIdField])}),s=new Set;for(const e of t.features??[]){const t=e.getObjectId()??e.attributes[this.objectIdField];s.add(t);const i=this.findSublayerForFeature(e);i?(0,l.tE)(n,i,()=>[]).push(e):r.set(t,this._getFeatureTitleForUnknownSublayer(e))}for(const e of i){const t=e.getObjectId()??e.attributes[this.objectIdField];s.has(t)||r.set(t,this._getFeatureTitleForUnknownSublayer(e))}}const o=await Promise.all(Array.from(n).map(([e,n])=>e.getFeatureTitles(n,t)));o.forEach(e=>s.push(e));const a=new Map(s.flatMap(e=>[...e]));return r.forEach((e,t)=>{a.set(t,e)}),a}get featureTitleFields(){const e=new Set;for(const t of this.sublayers){const n=t.featureTitleFields;for(const t of n)e.add(t)}return[...e]}_getLayerDomain(e){const t=this.fieldsIndex.get(e);return t?t.domain:null}_initLayerProperties(e){this._set("source",e);const{sourceJSON:t}=e;if(t&&(this.sourceJSON=t,this.read(t,{origin:"service",url:this.parsedUrl})),!this.subtypes?.length)throw new o.A("subtype-grouplayer:missing-subtypes","SubtypeGroupLayer must be created using a layer with subtypes");this._verifyFields(),(0,O.sv)(this.timeInfo,this.fieldsIndex)}async hasDataChanged(){return(0,S.jp)(this)}_verifyFields(){const e=this.parsedUrl?.path??"undefined";this.objectIdField||console.log("SubtypeGroupLayer: 'objectIdField' property is not defined (url: "+e+")"),this.isTable||-1!==e.search(/\/FeatureServer\//i)||this.fields?.some(e=>"geometry"===e.type)||console.log("SubtypeGroupLayer: unable to find field of type 'geometry' in the layer 'fields' list. If you are using a map service layer, features will not have geometry (url: "+e+")")}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null}),this.removeHandles("sublayers-owner"),this._sublayerLookup.clear()),e&&(e.forEach(e=>{e.parent=this,this._sublayerLookup.set(e.subtypeCode,e)}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this,this._sublayerLookup.set(e.subtypeCode,e)}),e.on("after-remove",({item:e})=>{e.parent=null,this._sublayerLookup.delete(e.subtypeCode)})],"sublayers-owner"))}_getFeatureTitleForUnknownSublayer(e){const{displayField:t,fieldsIndex:n,objectIdField:r}=this;if(t&&n.has(t))return e.attributes[n.get(t).name]??"";const i=e.getObjectId();return null!=i?i.toString():r&&n.has(r)?e.attributes[n.get(r).name]??"":""}};(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ne.prototype,"createQueryVersion",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ne.prototype,"editingEnabled",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ne.prototype,"effectiveEditingEnabled",null),(0,r.Cg)([(0,h.MZ)({...qe.fields,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}})],Ne.prototype,"fields",void 0),(0,r.Cg)([(0,h.MZ)(qe.fieldsIndex)],Ne.prototype,"fieldsIndex",void 0),(0,r.Cg)([(0,h.MZ)(A.id)],Ne.prototype,"id",void 0),(0,r.Cg)([(0,h.MZ)({type:["show","hide","hide-children"],json:{origins:{"portal-item":{read:!1,write:!1}}}})],Ne.prototype,"listMode",void 0),(0,r.Cg)([(0,h.MZ)({type:["SubtypeGroupLayer","SubtypeGroupTable"],json:{name:"layerType",read:{enabled:!0},write:{enabled:!0,ignoreOrigin:!0,isRequired:!0},origins:{"web-document":{name:"layerType",read:{enabled:!0},write:{enabled:!0,ignoreOrigin:!0,isRequired:!0}},"portal-item":{name:"layerType",read:{enabled:!0},write:{enabled:!0,ignoreOrigin:!0,isRequired:!0}}}}})],Ne.prototype,"operationalLayerType",null),(0,r.Cg)([(0,h.MZ)(qe.outFields)],Ne.prototype,"outFields",void 0),(0,r.Cg)([(0,h.MZ)({clonable:!1})],Ne.prototype,"source",null),(0,r.Cg)([(0,h.MZ)({type:s.A.ofType(Se),json:{origins:{service:{read:{source:"subtypes",reader(e,t,n){let r=null;if(this.useUniqueColorsForSublayers){const i=function(e,t){const n=e.drawingInfo?.renderer,r=n?U(n,e,t):null;if("simple"===r?.type)return(0,q.Sx)(r.symbol,null)?r.symbol.clone():null}(t,n);r=i?function(e,t){return(0,Z.Iy)($,e,{offset:!0,shuffle:!0}).reverse().map(e=>{const n=t.clone();return"cim"===n.type?(0,P.Fe)(n,e):(0,q.dt)(n,e),new k.A({symbol:n})})}(e.length,i):null}const i=e.map(({code:e},i)=>{const s=new Se({subtypeCode:e});s.read(t,n);const o=r?.[i];return o&&s.read({drawingInfo:{renderer:o.toJSON()}},n),s});return new(s.A.ofType(Se))(i)}}}},read:{source:["layers","tables"],reader(e,t,n){let r;return"SubtypeGroupLayer"===t.layerType&&t.layers?.length?r=Pe(t.layers,n):"SubtypeGroupTable"===t.layerType&&t.tables?.length&&(r=Pe(t.tables,n)),new(s.A.ofType(Se))(r)}},write:{ignoreOrigin:!0,writer(e,t,n,r){const i=[];for(const t of e){const e=t.write({},r);i.push(e)}this.isTable?t.tables=i:t.layers=i}}}})],Ne.prototype,"sublayers",void 0),(0,r.Cg)([(0,h.MZ)()],Ne.prototype,"useUniqueColorsForSublayers",void 0),(0,r.Cg)([(0,h.MZ)({type:ze.A})],Ne.prototype,"timeInfo",void 0),(0,r.Cg)([(0,h.MZ)({json:{origins:{"portal-item":{write:{enabled:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}}}})],Ne.prototype,"title",void 0),(0,r.Cg)([(0,be.w)("service","title",["name"])],Ne.prototype,"readTitleFromService",null),(0,r.Cg)([(0,h.MZ)({json:{read:!1}})],Ne.prototype,"type",void 0),(0,r.Cg)([(0,h.MZ)({clonable:!1,readOnly:!0})],Ne.prototype,"featureTitleFields",null),Ne=(0,r.Cg)([(0,h.$K)("esri.layers.SubtypeGroupLayer")],Ne);const Ue=Ne},54339(e,t,n){function r(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{const n=[];for(const r of t.fieldNames)n.push(e.attributes[r]??null);return JSON.stringify(n)}}}function i(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];const n=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(n)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}n.d(t,{W:()=>r,r:()=>i})},52136(e,t,n){var r=n(5482),i=n(91429);n.d(t,["p",0,e=>{const t=e;let n=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,r.Cg)([(0,i.MZ)({type:String})],n.prototype,"apiKey",null),n=(0,r.Cg)([(0,i.$K)("esri.layers.mixins.APIKeyMixin")],n),n}])},47685(e,t,n){n.d(t,{Mk:()=>h,Zk:()=>d});var r=n(5482),i=n(65529),s=n(4718),o=n(91429),a=n(20816);const l=new i.bk;function u(e){return l.on("apply-edits",new WeakRef(e))}function c(e){return l.on("update-moment",new WeakRef(e))}function d(e,t,n=null,r=!1){const i=Promise.withResolvers();return r=null==t||r,l.emit("apply-edits",{serviceUrl:e,layerId:t,gdbVersion:n,mayReceiveServiceEdits:r,result:i.promise}),i}const p=Symbol();function h(e){return null!=e&&"object"==typeof e&&p in e}function f(e){return null!=e&&"object"==typeof e&&"gdbVersion"in e}function y(e,t,n){const r=new URL(e).host,i=a.Z3.get(r),s=e=>!e||e===i;return s(t)&&s(n)||t===n}n.d(t,["w6",0,e=>{var t;const n=e;let i=class extends n{static{t=p}constructor(...e){super(...e),this[t]=!0,this._applyEditsHandler=e=>{const{serviceUrl:t,layerId:n,gdbVersion:r,mayReceiveServiceEdits:i,result:o}=e,a=t===this.url,l=null!=n&&null!=this.layerId&&n===this.layerId,u=null!=n&&this.relationships?.some(e=>e.relatedTableId===n),c=f(this),d=f(this)&&y(t,r,this.gdbVersion);if(!a||c&&!d||!l&&!u&&!i)return;const p=o.then(e=>{if(this.lastEditsEventDate=new Date,l&&(e.addedFeatures.length||e.updatedFeatures.length||e.deletedFeatures.length||e.addedAttachments.length||e.updatedAttachments.length||e.deletedAttachments.length))return this.emit("edits",(0,s.o8)(e)),e;const n=e.editedFeatures?.find(({layerId:e})=>e===this.layerId);if(n){const{adds:t,updates:r,deletes:i}=n.editedFeatures,o={edits:null,addedAttachments:[],deletedAttachments:[],updatedAttachments:[],addedFeatures:t?t.map(({attributes:e})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]})):[],deletedFeatures:i?i.map(({attributes:e})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]})):[],updatedFeatures:r?r.map(({current:{attributes:e}})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]})):[],editedFeatures:(0,s.o8)(e.editedFeatures),exceededTransferLimit:!1,historicMoment:(0,s.o8)(e.historicMoment)};return this.emit("edits",o),o}const i={edits:null,addedAttachments:[],deletedAttachments:[],updatedAttachments:[],addedFeatures:[],deletedFeatures:[],updatedFeatures:[],editedFeatures:(0,s.o8)(e.editedFeatures),exceededTransferLimit:!1,historicMoment:(0,s.o8)(e.historicMoment)};return"historicMoment"in this&&this._shouldUpdateHistoricMoment(t,r,i.historicMoment)&&this.emit("edits",i),i}).then(e=>("historicMoment"in this&&this._shouldUpdateHistoricMoment(t,r,e.historicMoment)&&(this.historicMoment=e.historicMoment),e));p.catch(()=>{}),this.emit("apply-edits",{result:p})},this._updateMomentHandler=e=>{const{serviceUrl:t,gdbVersion:n,moment:r}=e,i=t===this.url,s=f(this),o=f(this)&&y(t,n,this.gdbVersion),a=f(this)&&!y(t,this.gdbVersion,null);i&&s&&o&&a&&"historicMoment"in this&&this.historicMoment!==r&&(this.historicMoment=r)},this.when().then(()=>{this.addHandles(u(this._applyEditsHandler)),"historicMoment"in this&&this.addHandles(c(this._updateMomentHandler))},()=>{})}_shouldUpdateHistoricMoment(e,t,n){return"historicMoment"in this&&this.historicMoment!==n&&(0,a.w5)(e,t)}};return(0,r.Cg)([(0,o.MZ)()],i.prototype,"lastEditsEventDate",void 0),i=(0,r.Cg)([(0,o.$K)("esri.layers.mixins.EditBusLayer")],i),i}])},28032(e,t,n){n.d(t,{A:()=>l});var r=n(5482),i=n(69540),s=n(25482),o=n(91429),a=n(56400);let l=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.creatorField=null,this.creationDateField=null,this.editorField=null,this.editDateField=null,this.realm=null,this.timeZone=null}};(0,r.Cg)([(0,o.MZ)()],l.prototype,"creatorField",void 0),(0,r.Cg)([(0,o.MZ)()],l.prototype,"creationDateField",void 0),(0,r.Cg)([(0,o.MZ)()],l.prototype,"editorField",void 0),(0,r.Cg)([(0,o.MZ)()],l.prototype,"editDateField",void 0),(0,r.Cg)([(0,o.MZ)()],l.prototype,"realm",void 0),(0,r.Cg)([(0,o.MZ)((0,a.P6)("dateFieldsTimeReference",!0))],l.prototype,"timeZone",void 0),l=(0,r.Cg)([(0,o.$K)("esri.layers.support.EditFieldsInfo")],l)},37352(e,t,n){n.d(t,{A:()=>l});var r,i=n(5482),s=n(7762),o=n(25482),a=n(91429);let l=r=class extends o.o{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new s.A}clone(){return new r({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,i.Cg)([(0,a.MZ)({type:String,json:{write:{isRequired:!0}}})],l.prototype,"floorField",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],l.prototype,"viewAllMode",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],l.prototype,"viewAllLevelIds",void 0),l=r=(0,i.Cg)([(0,a.$K)("esri.layers.support.LayerFloorInfo")],l)},45067(e,t,n){n.d(t,{A:()=>c});var r=n(5482),i=n(69540),s=n(66552),o=n(25482),a=n(91429);const l=new s.J({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),u=new s.J({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let c=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.cardinality=null,this.catalogId=null,this.composite=null,this.id=null,this.keyField=null,this.keyFieldInRelationshipTable=null,this.name=null,this.relatedTableId=null,this.relationshipTableId=null,this.role=null}};(0,r.Cg)([(0,a.MZ)({json:{read:l.read,write:l.write}})],c.prototype,"cardinality",void 0),(0,r.Cg)([(0,a.MZ)({json:{name:"catalogID"}})],c.prototype,"catalogId",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"composite",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"id",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"keyField",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"keyFieldInRelationshipTable",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"name",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"relatedTableId",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],c.prototype,"relationshipTableId",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:u.read,write:u.write}})],c.prototype,"role",void 0),c=(0,r.Cg)([(0,a.$K)("esri.layers.support.Relationship")],c)},17311(e,t,n){n.d(t,{A:()=>h});var r=n(5482),i=n(69622),s=n(4576),o=n(60999),a=n(7762),l=n(16494),u=n(91429),c=n(30524),d=n(43668);const p=/<br\s*\/*>/gi;let h=class extends i.A{constructor(e){super(e),this._featureUtils=null,this.effectivePopupTemplate=null}get _arcadeTask(){return this.expressionsUsedInTitle.length>0?this._get("_arcadeTask")||(0,o.UT)(()=>(0,d.l)()):null}get featureUtilsPromise(){return this._get("featureUtilsPromise")??Promise.all([n.e(4560),n.e(9301)]).then(n.bind(n,99301)).then(e=>this._featureUtils=e)}get calculatedExpressions(){const e=new a.A;if(!this.expressionsUsedInTitle.length)return e;if(!this._arcadeTask?.value){for(const t of this.expressionsUsedInTitle??[])e.push({name:t.name,invalid:!0});return e}for(const t of this.expressionsUsedInTitle)try{const n=this._arcadeTask.value.arcade.parseScript(t.expression,["$layer","$map","$datastore"]);if(n.isAsync){e.push({name:t.name,invalid:!0});break}e.push({name:t.name,syntax:n,invalid:!1,func:this._arcadeTask.value.arcade.compileScript(n,{vars:{$feature:"any"}})})}catch{e.push({name:t.name,invalid:!0});break}return e}get expressionsUsedInTitle(){let e=this.effectivePopupTemplate?.title??"";return"string"!=typeof e?[]:(e=e.toLowerCase(),this.effectivePopupTemplate?.expressionInfos?.filter(t=>e.includes(`{expression/${t.name.toLowerCase()}}`))??[])}get fieldInfoMap(){return this._featureUtils?this._createFieldInfoMap(this._featureUtils.getAllFieldInfos(this.effectivePopupTemplate)):null}get hasBadExpressions(){return this.calculatedExpressions.some(e=>!0===e.invalid)}get requiredFields(){const e=new Set;if(this._arcadeTask?.value&&!this.hasBadExpressions)for(const t of this.calculatedExpressions?.toArray()??[])try{const n=this._arcadeTask.value.arcade.extractFieldLiterals(t.syntax);for(const t of n){const n=t.split("."),r=this.fieldsIndex.get(n.at(-1)??"");r&&e.add(r.name)}}catch{}const t=this._extractFieldNames(this.workingTitle);for(const n of t){const t=this.fieldsIndex.get(n);t&&e.add(t.name)}return null!=this.objectIdField&&e.add(this.objectIdField),e}get titleFromDisplayField(){let e="";return this.displayField&&(e=this.fieldsIndex.get(this.displayField)?.name??""),e||(e=this.fieldsIndex.get(this.objectIdField)?.name??""),e?`{${e}}`:""}get workingTitle(){const e=this.effectivePopupTemplate?this.effectivePopupTemplate.title:"";return""===e||null==e||this.hasBadExpressions||"string"!=typeof e?this.titleFromDisplayField:e}async getTitle(e,t,n){const r=t.getObjectId()??t.attributes?.[e.objectIdField];return(await this.getTitles(e,[t],n)).get(r)??""}async getTitles(e,t,n){const r=new Map,i=n?.timeZone??"system";try{const[{substituteFieldsInLinksAndAttributes:s}]=await Promise.all([this.featureUtilsPromise,this._arcadeTask?.promise]);n?.fetchMissingFields&&(t=await this._checkAndReQueryGraphics(e,t));const{fieldInfoMap:o,workingTitle:a}=this,u=a&&o;t.forEach(t=>{const c=t.getObjectId()??t.attributes[e.objectIdField];let d=u?s({attributes:t.attributes,expressionAttributes:null,fieldInfoMap:o,globalAttributes:this._createFormattedAttributes(e,t,i).global,layer:e,text:a}):"";n?.removeHTML&&(d=l.Nd.sanitize(d).replaceAll(p," ")),r.set(c,d)})}catch{}return r}async _checkAndReQueryGraphics(e,t){const n=t.map(t=>t.getObjectId()??t.attributes[e.objectIdField]).filter(s.Ru);if(n.length!==t.length)return t;if(t.some(e=>!(0,c.Kl)(e,this.requiredFields))){const r=e.createQuery();r.where="1=1",r.outFields=[...this.requiredFields],r.objectIds=n;const i=await e.queryFeatures(r);if(i?.features.length===t.length)return i.features}return t}_createFieldInfoMap(e){const t=new Map;if(!e)return t;for(const n of e){if(!n.fieldName)continue;const e=this.fieldsIndex.get(n.fieldName),r=e?.name??n.fieldName;n.fieldName=r,t.set(r.toLowerCase(),n)}return t}_createFormattedAttributes(e,t,n="system"){const r=this.effectivePopupTemplate?.fieldInfos??[],i={};if(!this._featureUtils)return{};if(!this.hasBadExpressions&&this.calculatedExpressions.length>0&&this._arcadeTask?.value){const n=this._arcadeTask.value.Feature.createFromGraphicLikeObject(t.geometry,t.attributes,e,null);for(const e of this.calculatedExpressions)try{i[`expression/${e.name}`]=e.func({vars:{$feature:n}})}catch{}}const s={...t.attributes,...i};return{global:this._featureUtils.formatAttributes({fieldInfos:r,attributes:s,graphic:t,timeZone:n,layer:e,fieldInfoMap:this.fieldInfoMap}),content:[]}}_extractFieldNames(e){return(0,c.nw)(e).filter(e=>!(e.startsWith("relationships/")||e.startsWith("expression/")))}};(0,r.Cg)([(0,u.MZ)({readOnly:!0})],h.prototype,"_arcadeTask",null),(0,r.Cg)([(0,u.MZ)()],h.prototype,"_featureUtils",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],h.prototype,"featureUtilsPromise",null),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],h.prototype,"calculatedExpressions",null),(0,r.Cg)([(0,u.MZ)()],h.prototype,"displayField",void 0),(0,r.Cg)([(0,u.MZ)()],h.prototype,"effectivePopupTemplate",void 0),(0,r.Cg)([(0,u.MZ)()],h.prototype,"expressionsUsedInTitle",null),(0,r.Cg)([(0,u.MZ)()],h.prototype,"fieldsIndex",void 0),(0,r.Cg)([(0,u.MZ)()],h.prototype,"fieldInfoMap",null),(0,r.Cg)([(0,u.MZ)()],h.prototype,"fields",void 0),(0,r.Cg)([(0,u.MZ)()],h.prototype,"objectIdField",void 0),(0,r.Cg)([(0,u.MZ)()],h.prototype,"requiredFields",null),h=(0,r.Cg)([(0,u.$K)("esri.layers.support.TitleCreator")],h)},41560(e,t,n){n.d(t,{Ch:()=>o,mW:()=>s});var r=n(34727),i=n(39516);function s(e,t){return{...t,filterMode:e.mode}}function o(e,t,n){const s=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:n,maxScale:r}of e.filters)t[0]=Math.max(t[0],c(n)),t[1]=Math.min(t[1],d(r));return t}(e);if(s&&((0,r.gg)(t,s[0])||(0,r.ZH)(n,s[1])))return"";const o=Array.from(a(e,t,n)),l=function(e,t,n){if(0===e.length)return!0;const i=c(e.at(0)?.minScale),s=d(e.at(-1)?.maxScale);if((0,r.ZH)(i,t)||(0,r.gg)(s,n))return!0;for(let t=0;t<e.length-1;t++){const n=e[t],i=e[t+1];if((0,r.ZH)(c(i.minScale),d(n.maxScale)))return!0}return!1}(o,t,n)?"1=1":o.map(e=>e.where||"1=1").reduce((e,t)=>(0,i.IW)(e,t),"");return l&&"1=1"!==l?l:""}function*a(e,t,n){if("manual"===u(e)){const t=e.filters.find(t=>t.id===e.activeFilterId);t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const r of e.filters)l(r.minScale,r.maxScale,t,n)&&(yield r)}}function l(e,t,n,i){return e=c(e),n=c(n),t=d(t),!(!(0,r.Sp)(n,e)&&(i??n)>e||(0,r.Hx)(t,n)||void 0!==i&&(0,r.Sp)(i,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function c(e){return e||Number.POSITIVE_INFINITY}function d(e){return e||0}},32730(e,t,n){n.d(t,{BI:()=>h,D3:()=>d,XJ:()=>p,lc:()=>c,mX:()=>y,rU:()=>f,tH:()=>v,zA:()=>I});var r=n(799);const i="__begin__",s="__end__",o=new RegExp(i,"ig"),a=new RegExp(s,"ig"),l=new RegExp("^"+i,"i"),u=new RegExp(s+"$","i");function c(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function d(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function p(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=c(e.labelExpression),t.type="conventional"),t}function h(e){const t=p(e);if(!t)return null;switch(t.type){case"conventional":return y(t.expression);case"arcade":return t.expression}return null}function f(e){const t=p(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(g);return t?.[1].trim()||null}(t.expression);case"arcade":return v(t.expression)}return null}function y(e){let t;return e?(t=(0,r.HC)(e,e=>i+'$feature["'+e+'"]'+s),t=l.test(t)?t.replace(l,""):'"'+t,t=u.test(t)?t.replace(u,""):t+'"',t=t.replaceAll(o,'" + ').replaceAll(a,' + "')):t='""',t}const g=/^\s*\{([^}]+)\}\s*$/i,m=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,M=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function v(e){if(!e)return null;let t=m.exec(e)||b.exec(e);return t?t[1]||t[3]:(t=M.exec(e),t?t[2]:null)}const w=Symbol("LabelClassInstance");function I(e){return null!=e&&"object"==typeof e&&w in e}n.d(t,["vK",0,w])},5757(e,t,n){n.d(t,{B:()=>i});const r=Symbol("PopupTemplateInstance");function i(e){return null!=e&&"object"==typeof e&&r in e}n.d(t,["P",0,r])},98205(e,t,n){n.d(t,{KZ:()=>a,eh:()=>o,gf:()=>s,of:()=>i});const r=Symbol("SizeVariableInstance");function i(e){return null!=e&&"object"==typeof e&&r in e}function s(e){return null!=e&&!isNaN(e)&&isFinite(e)}function o(e){return e.valueExpression?"expression":e.field&&"string"==typeof e.field?"field":"unknown"}function a(e,t){const n=t||o(e),r=e.valueUnit||"unknown";return"unknown"===n?"constant":e.stops?"stops":null!=e.minSize&&null!=e.maxSize&&null!=e.minDataValue&&null!=e.maxDataValue?"clamped-linear":"unknown"===r?null!=e.minSize&&null!=e.minDataValue?e.minSize&&e.minDataValue?"proportional":"additive":"identity":"real-world-size"}n.d(t,["uY",0,r])},41366(e,t,n){var r=n(5482),i=n(66552),s=n(53966),o=n(91429),a=n(93223);const l=(0,i.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",c="field";n.d(t,["K",0,e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,n=null!=this.normalizationTotal;return t||n?(e=t&&c||n&&u||null,t&&n&&s.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==c&&e!==u||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,r.Cg)([(0,o.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],n.prototype,"normalizationField",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],n.prototype,"normalizationMaxValue",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],n.prototype,"normalizationMinValue",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],n.prototype,"normalizationTotal",void 0),(0,r.Cg)([(0,a.e)(l,{name:"parameters.normalizationType"})],n.prototype,"normalizationType",null),n=(0,r.Cg)([(0,o.$K)("esri.rest.support.NormalizationBinParametersMixin")],n),n},"Q",0,l])},20816(e,t,n){n.d(t,{We:()=>a,ZJ:()=>l,w5:()=>u});var r=n(11254);const i=(0,n(13069).vD)(),s=new Map,o=new Map;async function a(e,t,n){if(!e||!n)return!1;if(!t)return!0;const i=new URL(e).host;let o=s.get(i);if(!o){const t=e.replace(/\/FeatureServer/i,"/VersionManagementServer").replace(/\/\d*$/,"");o=(await(0,r.A)(t,{responseType:"json",query:{f:"json"}})).data.defaultVersionName}return o===t}async function l(e,t,r=!1){if(!e||!t)return!0;const s=e.replace(/\/FeatureServer/i,"/VersionManagementServer").replace(/\/\d*$/,""),a=o.get(s)?.entries();if(a)for(const[e,o]of a)if(o.name===t){const t=!o.stack?.hasForwardEdits();if(!t&&r){const[{deleteForwardEdits:t},{default:r}]=await Promise.all([n.e(2186).then(n.bind(n,32186)),n.e(2558).then(n.bind(n,32558))]),a=await t(s,e,new r({sessionId:i,moment:o.moment}));return a.success&&o.stack?.clearForwardEdits(),a.success}return t}return!0}function u(e,t){if(!e)return!1;const n=e.replace(/\/FeatureServer/i,"/VersionManagementServer").replace(/\/\d*$/,""),r=o.get(n)?.entries();if(r)for(const[e,n]of r)if(n.name===t)return"edit"===n.lockType;return!1}new Map,n.d(t,["TA",0,i,"Z3",0,s])}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2372],{62372(r,e,t){t.d(e,{default:()=>o});var n,o=(n="undefined"!=typeof document?document.currentScript?.src:void 0,function(r={}){var e,t,o=r,a=new Promise((r,n)=>{e=r,t=n}),i="object"==typeof window,s="undefined"!=typeof WorkerGlobalScope;"object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node&&process.type;var l,u,d=Object.assign({},o),c="./this.program",h="";(i||s)&&(s?h=self.location.href:"undefined"!=typeof document&&document.currentScript&&(h=document.currentScript.src),n&&(h=n),h=h.startsWith("blob:")?"":h.substr(0,h.replace(/[?#].*/,"").lastIndexOf("/")+1),s&&(u=r=>{var e=new XMLHttpRequest;return e.open("GET",r,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),l=async r=>{var e=await fetch(r,{credentials:"same-origin"});if(e.ok)return e.arrayBuffer();throw new Error(e.status+" : "+e.url)});var f=o.print||console.log.bind(console),p=o.printErr||console.error.bind(console);Object.assign(o,d),d=null,o.arguments&&o.arguments,o.thisProgram&&(c=o.thisProgram);var m,v,y,w,g,E,b,_,k,$=o.wasmBinary,C=!1;function P(){var r=m.buffer;o.HEAP8=v=new Int8Array(r),o.HEAP16=w=new Int16Array(r),o.HEAPU8=y=new Uint8Array(r),o.HEAPU16=g=new Uint16Array(r),o.HEAP32=E=new Int32Array(r),o.HEAPU32=b=new Uint32Array(r),o.HEAPF32=_=new Float32Array(r),o.HEAPF64=k=new Float64Array(r)}var T=[],A=[],S=[];function D(r){T.unshift(r)}function F(r){S.unshift(r)}var j=0,M=null;function R(r){j++,o.monitorRunDependencies?.(j)}function x(r){if(j--,o.monitorRunDependencies?.(j),0==j&&M){var e=M;M=null,e()}}function O(r){o.onAbort?.(r),p(r="Aborted("+r+")"),C=!0,r+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(r);throw t(e),e}var N,W,z,U=r=>r.startsWith("data:application/octet-stream;base64,");async function B(r,e,t){if(!r&&"function"==typeof WebAssembly.instantiateStreaming&&!U(e)&&"function"==typeof fetch)try{var n=fetch(e,{credentials:"same-origin"});return await WebAssembly.instantiateStreaming(n,t)}catch(r){p(`wasm streaming compile failed: ${r}`),p("falling back to ArrayBuffer instantiation")}return async function(r,e){try{var t=await async function(r){if(!$)try{var e=await l(r);return new Uint8Array(e)}catch{}return function(r){if(r==N&&$)return new Uint8Array($);if(u)return u(r);throw"both async and sync fetching of the wasm failed"}(r)}(r);return await WebAssembly.instantiate(t,e)}catch(r){p(`failed to asynchronously prepare wasm: ${r}`),O(r)}}(e,t)}var L=r=>{for(;r.length>0;)r.shift()(o)};o.noExitRuntime;var H=r=>Be(r),I=()=>Le();class V{constructor(r){this.excPtr=r,this.ptr=r-24}set_type(r){b[this.ptr+4>>2]=r}get_type(){return b[this.ptr+4>>2]}set_destructor(r){b[this.ptr+8>>2]=r}get_destructor(){return b[this.ptr+8>>2]}set_caught(r){r=r?1:0,v[this.ptr+12]=r}get_caught(){return 0!=v[this.ptr+12]}set_rethrown(r){r=r?1:0,v[this.ptr+13]=r}get_rethrown(){return 0!=v[this.ptr+13]}init(r,e){this.set_adjusted_ptr(0),this.set_type(r),this.set_destructor(e)}set_adjusted_ptr(r){b[this.ptr+16>>2]=r}get_adjusted_ptr(){return b[this.ptr+16>>2]}}var q=()=>{var r=E[+hr.varargs>>2];return hr.varargs+=4,r},G=q,X={isAbs:r=>"/"===r.charAt(0),splitPath:r=>/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(r).slice(1),normalizeArray:(r,e)=>{for(var t=0,n=r.length-1;n>=0;n--){var o=r[n];"."===o?r.splice(n,1):".."===o?(r.splice(n,1),t++):t&&(r.splice(n,1),t--)}if(e)for(;t;t--)r.unshift("..");return r},normalize:r=>{var e=X.isAbs(r),t="/"===r.substr(-1);return(r=X.normalizeArray(r.split("/").filter(r=>!!r),!e).join("/"))||e||(r="."),r&&t&&(r+="/"),(e?"/":"")+r},dirname:r=>{var e=X.splitPath(r),t=e[0],n=e[1];return t||n?(n&&(n=n.substr(0,n.length-1)),t+n):"."},basename:r=>{if("/"===r)return"/";var e=(r=(r=X.normalize(r)).replace(/\/$/,"")).lastIndexOf("/");return-1===e?r:r.substr(e+1)},join:(...r)=>X.normalize(r.join("/")),join2:(r,e)=>X.normalize(r+"/"+e)},K=r=>(K=(()=>{if("object"==typeof crypto&&"function"==typeof crypto.getRandomValues)return r=>crypto.getRandomValues(r);O("initRandomDevice")})())(r),Y={resolve:(...r)=>{for(var e="",t=!1,n=r.length-1;n>=-1&&!t;n--){var o=n>=0?r[n]:dr.cwd();if("string"!=typeof o)throw new TypeError("Arguments to path.resolve must be strings");if(!o)return"";e=o+"/"+e,t=X.isAbs(o)}return(t?"/":"")+(e=X.normalizeArray(e.split("/").filter(r=>!!r),!t).join("/"))||"."},relative:(r,e)=>{function t(r){for(var e=0;e<r.length&&""===r[e];e++);for(var t=r.length-1;t>=0&&""===r[t];t--);return e>t?[]:r.slice(e,t-e+1)}r=Y.resolve(r).substr(1),e=Y.resolve(e).substr(1);for(var n=t(r.split("/")),o=t(e.split("/")),a=Math.min(n.length,o.length),i=a,s=0;s<a;s++)if(n[s]!==o[s]){i=s;break}var l=[];for(s=i;s<n.length;s++)l.push("..");return(l=l.concat(o.slice(i))).join("/")}},Z="undefined"!=typeof TextDecoder?new TextDecoder:void 0,J=(r,e=0,t=NaN)=>{for(var n=e+t,o=e;r[o]&&!(o>=n);)++o;if(o-e>16&&r.buffer&&Z)return Z.decode(r.subarray(e,o));for(var a="";e<o;){var i=r[e++];if(128&i){var s=63&r[e++];if(192!=(224&i)){var l=63&r[e++];if((i=224==(240&i)?(15&i)<<12|s<<6|l:(7&i)<<18|s<<12|l<<6|63&r[e++])<65536)a+=String.fromCharCode(i);else{var u=i-65536;a+=String.fromCharCode(55296|u>>10,56320|1023&u)}}else a+=String.fromCharCode((31&i)<<6|s)}else a+=String.fromCharCode(i)}return a},Q=[],rr=r=>{for(var e=0,t=0;t<r.length;++t){var n=r.charCodeAt(t);n<=127?e++:n<=2047?e+=2:n>=55296&&n<=57343?(e+=4,++t):e+=3}return e},er=(r,e,t,n)=>{if(!(n>0))return 0;for(var o=t,a=t+n-1,i=0;i<r.length;++i){var s=r.charCodeAt(i);if(s>=55296&&s<=57343&&(s=65536+((1023&s)<<10)|1023&r.charCodeAt(++i)),s<=127){if(t>=a)break;e[t++]=s}else if(s<=2047){if(t+1>=a)break;e[t++]=192|s>>6,e[t++]=128|63&s}else if(s<=65535){if(t+2>=a)break;e[t++]=224|s>>12,e[t++]=128|s>>6&63,e[t++]=128|63&s}else{if(t+3>=a)break;e[t++]=240|s>>18,e[t++]=128|s>>12&63,e[t++]=128|s>>6&63,e[t++]=128|63&s}}return e[t]=0,t-o};function tr(r,e,t){var n=rr(r)+1,o=new Array(n),a=er(r,o,0,o.length);return o.length=a,o}var nr={ttys:[],init(){},shutdown(){},register(r,e){nr.ttys[r]={input:[],output:[],ops:e},dr.registerDevice(r,nr.stream_ops)},stream_ops:{open(r){var e=nr.ttys[r.node.rdev];if(!e)throw new dr.ErrnoError(43);r.tty=e,r.seekable=!1},close(r){r.tty.ops.fsync(r.tty)},fsync(r){r.tty.ops.fsync(r.tty)},read(r,e,t,n,o){if(!r.tty||!r.tty.ops.get_char)throw new dr.ErrnoError(60);for(var a=0,i=0;i<n;i++){var s;try{s=r.tty.ops.get_char(r.tty)}catch(r){throw new dr.ErrnoError(29)}if(void 0===s&&0===a)throw new dr.ErrnoError(6);if(null==s)break;a++,e[t+i]=s}return a&&(r.node.atime=Date.now()),a},write(r,e,t,n,o){if(!r.tty||!r.tty.ops.put_char)throw new dr.ErrnoError(60);try{for(var a=0;a<n;a++)r.tty.ops.put_char(r.tty,e[t+a])}catch(r){throw new dr.ErrnoError(29)}return n&&(r.node.mtime=r.node.ctime=Date.now()),a}},default_tty_ops:{get_char:r=>(()=>{if(!Q.length){var r=null;if("undefined"!=typeof window&&"function"==typeof window.prompt&&null!==(r=window.prompt("Input: "))&&(r+="\n"),!r)return null;Q=tr(r)}return Q.shift()})(),put_char(r,e){null===e||10===e?(f(J(r.output)),r.output=[]):0!=e&&r.output.push(e)},fsync(r){r.output&&r.output.length>0&&(f(J(r.output)),r.output=[])},ioctl_tcgets:r=>({c_iflag:25856,c_oflag:5,c_cflag:191,c_lflag:35387,c_cc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}),ioctl_tcsets:(r,e,t)=>0,ioctl_tiocgwinsz:r=>[24,80]},default_tty1_ops:{put_char(r,e){null===e||10===e?(p(J(r.output)),r.output=[]):0!=e&&r.output.push(e)},fsync(r){r.output&&r.output.length>0&&(p(J(r.output)),r.output=[])}}},or=(r,e)=>Math.ceil(r/e)*e,ar=r=>{r=or(r,65536);var e=ze(65536,r);return e&&((r,e)=>{y.fill(0,r,r+e)})(e,r),e},ir={ops_table:null,mount:r=>ir.createNode(null,"/",16895,0),createNode(r,e,t,n){if(dr.isBlkdev(t)||dr.isFIFO(t))throw new dr.ErrnoError(63);ir.ops_table||={dir:{node:{getattr:ir.node_ops.getattr,setattr:ir.node_ops.setattr,lookup:ir.node_ops.lookup,mknod:ir.node_ops.mknod,rename:ir.node_ops.rename,unlink:ir.node_ops.unlink,rmdir:ir.node_ops.rmdir,readdir:ir.node_ops.readdir,symlink:ir.node_ops.symlink},stream:{llseek:ir.stream_ops.llseek}},file:{node:{getattr:ir.node_ops.getattr,setattr:ir.node_ops.setattr},stream:{llseek:ir.stream_ops.llseek,read:ir.stream_ops.read,write:ir.stream_ops.write,allocate:ir.stream_ops.allocate,mmap:ir.stream_ops.mmap,msync:ir.stream_ops.msync}},link:{node:{getattr:ir.node_ops.getattr,setattr:ir.node_ops.setattr,readlink:ir.node_ops.readlink},stream:{}},chrdev:{node:{getattr:ir.node_ops.getattr,setattr:ir.node_ops.setattr},stream:dr.chrdev_stream_ops}};var o=dr.createNode(r,e,t,n);return dr.isDir(o.mode)?(o.node_ops=ir.ops_table.dir.node,o.stream_ops=ir.ops_table.dir.stream,o.contents={}):dr.isFile(o.mode)?(o.node_ops=ir.ops_table.file.node,o.stream_ops=ir.ops_table.file.stream,o.usedBytes=0,o.contents=null):dr.isLink(o.mode)?(o.node_ops=ir.ops_table.link.node,o.stream_ops=ir.ops_table.link.stream):dr.isChrdev(o.mode)&&(o.node_ops=ir.ops_table.chrdev.node,o.stream_ops=ir.ops_table.chrdev.stream),o.atime=o.mtime=o.ctime=Date.now(),r&&(r.contents[e]=o,r.atime=r.mtime=r.ctime=o.atime),o},getFileDataAsTypedArray:r=>r.contents?r.contents.subarray?r.contents.subarray(0,r.usedBytes):new Uint8Array(r.contents):new Uint8Array(0),expandFileStorage(r,e){var t=r.contents?r.contents.length:0;if(!(t>=e)){e=Math.max(e,t*(t<1048576?2:1.125)>>>0),0!=t&&(e=Math.max(e,256));var n=r.contents;r.contents=new Uint8Array(e),r.usedBytes>0&&r.contents.set(n.subarray(0,r.usedBytes),0)}},resizeFileStorage(r,e){if(r.usedBytes!=e)if(0==e)r.contents=null,r.usedBytes=0;else{var t=r.contents;r.contents=new Uint8Array(e),t&&r.contents.set(t.subarray(0,Math.min(e,r.usedBytes))),r.usedBytes=e}},node_ops:{getattr(r){var e={};return e.dev=dr.isChrdev(r.mode)?r.id:1,e.ino=r.id,e.mode=r.mode,e.nlink=1,e.uid=0,e.gid=0,e.rdev=r.rdev,dr.isDir(r.mode)?e.size=4096:dr.isFile(r.mode)?e.size=r.usedBytes:dr.isLink(r.mode)?e.size=r.link.length:e.size=0,e.atime=new Date(r.atime),e.mtime=new Date(r.mtime),e.ctime=new Date(r.ctime),e.blksize=4096,e.blocks=Math.ceil(e.size/e.blksize),e},setattr(r,e){for(const t of["mode","atime","mtime","ctime"])e[t]&&(r[t]=e[t]);void 0!==e.size&&ir.resizeFileStorage(r,e.size)},lookup(r,e){throw ir.doesNotExistError},mknod:(r,e,t,n)=>ir.createNode(r,e,t,n),rename(r,e,t){var n;try{n=dr.lookupNode(e,t)}catch(r){}if(n){if(dr.isDir(r.mode))for(var o in n.contents)throw new dr.ErrnoError(55);dr.hashRemoveNode(n)}delete r.parent.contents[r.name],e.contents[t]=r,r.name=t,e.ctime=e.mtime=r.parent.ctime=r.parent.mtime=Date.now()},unlink(r,e){delete r.contents[e],r.ctime=r.mtime=Date.now()},rmdir(r,e){var t=dr.lookupNode(r,e);for(var n in t.contents)throw new dr.ErrnoError(55);delete r.contents[e],r.ctime=r.mtime=Date.now()},readdir:r=>[".","..",...Object.keys(r.contents)],symlink(r,e,t){var n=ir.createNode(r,e,41471,0);return n.link=t,n},readlink(r){if(!dr.isLink(r.mode))throw new dr.ErrnoError(28);return r.link}},stream_ops:{read(r,e,t,n,o){var a=r.node.contents;if(o>=r.node.usedBytes)return 0;var i=Math.min(r.node.usedBytes-o,n);if(i>8&&a.subarray)e.set(a.subarray(o,o+i),t);else for(var s=0;s<i;s++)e[t+s]=a[o+s];return i},write(r,e,t,n,o,a){if(e.buffer===v.buffer&&(a=!1),!n)return 0;var i=r.node;if(i.mtime=i.ctime=Date.now(),e.subarray&&(!i.contents||i.contents.subarray)){if(a)return i.contents=e.subarray(t,t+n),i.usedBytes=n,n;if(0===i.usedBytes&&0===o)return i.contents=e.slice(t,t+n),i.usedBytes=n,n;if(o+n<=i.usedBytes)return i.contents.set(e.subarray(t,t+n),o),n}if(ir.expandFileStorage(i,o+n),i.contents.subarray&&e.subarray)i.contents.set(e.subarray(t,t+n),o);else for(var s=0;s<n;s++)i.contents[o+s]=e[t+s];return i.usedBytes=Math.max(i.usedBytes,o+n),n},llseek(r,e,t){var n=e;if(1===t?n+=r.position:2===t&&dr.isFile(r.node.mode)&&(n+=r.node.usedBytes),n<0)throw new dr.ErrnoError(28);return n},allocate(r,e,t){ir.expandFileStorage(r.node,e+t),r.node.usedBytes=Math.max(r.node.usedBytes,e+t)},mmap(r,e,t,n,o){if(!dr.isFile(r.node.mode))throw new dr.ErrnoError(43);var a,i,s=r.node.contents;if(2&o||!s||s.buffer!==v.buffer){if(i=!0,!(a=ar(e)))throw new dr.ErrnoError(48);s&&((t>0||t+e<s.length)&&(s=s.subarray?s.subarray(t,t+e):Array.prototype.slice.call(s,t,t+e)),v.set(s,a))}else i=!1,a=s.byteOffset;return{ptr:a,allocated:i}},msync:(r,e,t,n,o)=>(ir.stream_ops.write(r,e,0,n,t,!1),0)}},sr=async r=>{var e=await l(r);return new Uint8Array(e)},lr=o.preloadPlugins||[],ur=(r,e)=>{var t=0;return r&&(t|=365),e&&(t|=146),t},dr={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,ErrnoError:class{name="ErrnoError";constructor(r){this.errno=r}},filesystems:null,syncFSRequests:0,readFiles:{},FSStream:class{shared={};get object(){return this.node}set object(r){this.node=r}get isRead(){return 1!=(2097155&this.flags)}get isWrite(){return!!(2097155&this.flags)}get isAppend(){return 1024&this.flags}get flags(){return this.shared.flags}set flags(r){this.shared.flags=r}get position(){return this.shared.position}set position(r){this.shared.position=r}},FSNode:class{node_ops={};stream_ops={};readMode=365;writeMode=146;mounted=null;constructor(r,e,t,n){r||(r=this),this.parent=r,this.mount=r.mount,this.id=dr.nextInode++,this.name=e,this.mode=t,this.rdev=n,this.atime=this.mtime=this.ctime=Date.now()}get read(){return(this.mode&this.readMode)===this.readMode}set read(r){r?this.mode|=this.readMode:this.mode&=~this.readMode}get write(){return(this.mode&this.writeMode)===this.writeMode}set write(r){r?this.mode|=this.writeMode:this.mode&=~this.writeMode}get isFolder(){return dr.isDir(this.mode)}get isDevice(){return dr.isChrdev(this.mode)}},lookupPath(r,e={}){if(!r)return{path:"",node:null};e.follow_mount??=!0,X.isAbs(r)||(r=dr.cwd()+"/"+r);r:for(var t=0;t<40;t++){for(var n=r.split("/").filter(r=>!!r&&"."!==r),o=dr.root,a="/",i=0;i<n.length;i++){var s=i===n.length-1;if(s&&e.parent)break;if(".."!==n[i]){a=X.join2(a,n[i]);try{o=dr.lookupNode(o,n[i])}catch(r){if(44===r?.errno&&s&&e.noent_okay)return{path:a};throw r}if(!dr.isMountpoint(o)||s&&!e.follow_mount||(o=o.mounted.root),dr.isLink(o.mode)&&(!s||e.follow)){if(!o.node_ops.readlink)throw new dr.ErrnoError(52);var l=o.node_ops.readlink(o);X.isAbs(l)||(l=X.dirname(a)+"/"+l),r=l+"/"+n.slice(i+1).join("/");continue r}}else a=X.dirname(a),o=o.parent}return{path:a,node:o}}throw new dr.ErrnoError(32)},getPath(r){for(var e;;){if(dr.isRoot(r)){var t=r.mount.mountpoint;return e?"/"!==t[t.length-1]?`${t}/${e}`:t+e:t}e=e?`${r.name}/${e}`:r.name,r=r.parent}},hashName(r,e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n)|0;return(r+t>>>0)%dr.nameTable.length},hashAddNode(r){var e=dr.hashName(r.parent.id,r.name);r.name_next=dr.nameTable[e],dr.nameTable[e]=r},hashRemoveNode(r){var e=dr.hashName(r.parent.id,r.name);if(dr.nameTable[e]===r)dr.nameTable[e]=r.name_next;else for(var t=dr.nameTable[e];t;){if(t.name_next===r){t.name_next=r.name_next;break}t=t.name_next}},lookupNode(r,e){var t=dr.mayLookup(r);if(t)throw new dr.ErrnoError(t);for(var n=dr.hashName(r.id,e),o=dr.nameTable[n];o;o=o.name_next){var a=o.name;if(o.parent.id===r.id&&a===e)return o}return dr.lookup(r,e)},createNode(r,e,t,n){var o=new dr.FSNode(r,e,t,n);return dr.hashAddNode(o),o},destroyNode(r){dr.hashRemoveNode(r)},isRoot:r=>r===r.parent,isMountpoint:r=>!!r.mounted,isFile:r=>32768==(61440&r),isDir:r=>16384==(61440&r),isLink:r=>40960==(61440&r),isChrdev:r=>8192==(61440&r),isBlkdev:r=>24576==(61440&r),isFIFO:r=>4096==(61440&r),isSocket:r=>!(49152&~r),flagsToPermissionString(r){var e=["r","w","rw"][3&r];return 512&r&&(e+="w"),e},nodePermissions:(r,e)=>dr.ignorePermissions||(!e.includes("r")||292&r.mode)&&(!e.includes("w")||146&r.mode)&&(!e.includes("x")||73&r.mode)?0:2,mayLookup:r=>dr.isDir(r.mode)?dr.nodePermissions(r,"x")||(r.node_ops.lookup?0:2):54,mayCreate(r,e){if(!dr.isDir(r.mode))return 54;try{return dr.lookupNode(r,e),20}catch(r){}return dr.nodePermissions(r,"wx")},mayDelete(r,e,t){var n;try{n=dr.lookupNode(r,e)}catch(r){return r.errno}var o=dr.nodePermissions(r,"wx");if(o)return o;if(t){if(!dr.isDir(n.mode))return 54;if(dr.isRoot(n)||dr.getPath(n)===dr.cwd())return 10}else if(dr.isDir(n.mode))return 31;return 0},mayOpen:(r,e)=>r?dr.isLink(r.mode)?32:dr.isDir(r.mode)&&("r"!==dr.flagsToPermissionString(e)||512&e)?31:dr.nodePermissions(r,dr.flagsToPermissionString(e)):44,MAX_OPEN_FDS:4096,nextfd(){for(var r=0;r<=dr.MAX_OPEN_FDS;r++)if(!dr.streams[r])return r;throw new dr.ErrnoError(33)},getStreamChecked(r){var e=dr.getStream(r);if(!e)throw new dr.ErrnoError(8);return e},getStream:r=>dr.streams[r],createStream:(r,e=-1)=>(r=Object.assign(new dr.FSStream,r),-1==e&&(e=dr.nextfd()),r.fd=e,dr.streams[e]=r,r),closeStream(r){dr.streams[r]=null},dupStream(r,e=-1){var t=dr.createStream(r,e);return t.stream_ops?.dup?.(t),t},chrdev_stream_ops:{open(r){var e=dr.getDevice(r.node.rdev);r.stream_ops=e.stream_ops,r.stream_ops.open?.(r)},llseek(){throw new dr.ErrnoError(70)}},major:r=>r>>8,minor:r=>255&r,makedev:(r,e)=>r<<8|e,registerDevice(r,e){dr.devices[r]={stream_ops:e}},getDevice:r=>dr.devices[r],getMounts(r){for(var e=[],t=[r];t.length;){var n=t.pop();e.push(n),t.push(...n.mounts)}return e},syncfs(r,e){"function"==typeof r&&(e=r,r=!1),dr.syncFSRequests++,dr.syncFSRequests>1&&p(`warning: ${dr.syncFSRequests} FS.syncfs operations in flight at once, probably just doing extra work`);var t=dr.getMounts(dr.root.mount),n=0;function o(r){return dr.syncFSRequests--,e(r)}function a(r){if(r)return a.errored?void 0:(a.errored=!0,o(r));++n>=t.length&&o(null)}t.forEach(e=>{if(!e.type.syncfs)return a(null);e.type.syncfs(e,r,a)})},mount(r,e,t){var n,o="/"===t,a=!t;if(o&&dr.root)throw new dr.ErrnoError(10);if(!o&&!a){var i=dr.lookupPath(t,{follow_mount:!1});if(t=i.path,n=i.node,dr.isMountpoint(n))throw new dr.ErrnoError(10);if(!dr.isDir(n.mode))throw new dr.ErrnoError(54)}var s={type:r,opts:e,mountpoint:t,mounts:[]},l=r.mount(s);return l.mount=s,s.root=l,o?dr.root=l:n&&(n.mounted=s,n.mount&&n.mount.mounts.push(s)),l},unmount(r){var e=dr.lookupPath(r,{follow_mount:!1});if(!dr.isMountpoint(e.node))throw new dr.ErrnoError(28);var t=e.node,n=t.mounted,o=dr.getMounts(n);Object.keys(dr.nameTable).forEach(r=>{for(var e=dr.nameTable[r];e;){var t=e.name_next;o.includes(e.mount)&&dr.destroyNode(e),e=t}}),t.mounted=null;var a=t.mount.mounts.indexOf(n);t.mount.mounts.splice(a,1)},lookup:(r,e)=>r.node_ops.lookup(r,e),mknod(r,e,t){var n=dr.lookupPath(r,{parent:!0}).node,o=X.basename(r);if(!o||"."===o||".."===o)throw new dr.ErrnoError(28);var a=dr.mayCreate(n,o);if(a)throw new dr.ErrnoError(a);if(!n.node_ops.mknod)throw new dr.ErrnoError(63);return n.node_ops.mknod(n,o,e,t)},statfs(r){var e={bsize:4096,frsize:4096,blocks:1e6,bfree:5e5,bavail:5e5,files:dr.nextInode,ffree:dr.nextInode-1,fsid:42,flags:2,namelen:255},t=dr.lookupPath(r,{follow:!0}).node;return t?.node_ops.statfs&&Object.assign(e,t.node_ops.statfs(t.mount.opts.root)),e},create:(r,e=438)=>(e&=4095,e|=32768,dr.mknod(r,e,0)),mkdir:(r,e=511)=>(e&=1023,e|=16384,dr.mknod(r,e,0)),mkdirTree(r,e){for(var t=r.split("/"),n="",o=0;o<t.length;++o)if(t[o]){n+="/"+t[o];try{dr.mkdir(n,e)}catch(r){if(20!=r.errno)throw r}}},mkdev:(r,e,t)=>(void 0===t&&(t=e,e=438),e|=8192,dr.mknod(r,e,t)),symlink(r,e){if(!Y.resolve(r))throw new dr.ErrnoError(44);var t=dr.lookupPath(e,{parent:!0}).node;if(!t)throw new dr.ErrnoError(44);var n=X.basename(e),o=dr.mayCreate(t,n);if(o)throw new dr.ErrnoError(o);if(!t.node_ops.symlink)throw new dr.ErrnoError(63);return t.node_ops.symlink(t,n,r)},rename(r,e){var t,n,o=X.dirname(r),a=X.dirname(e),i=X.basename(r),s=X.basename(e);if(t=dr.lookupPath(r,{parent:!0}).node,n=dr.lookupPath(e,{parent:!0}).node,!t||!n)throw new dr.ErrnoError(44);if(t.mount!==n.mount)throw new dr.ErrnoError(75);var l,u=dr.lookupNode(t,i),d=Y.relative(r,a);if("."!==d.charAt(0))throw new dr.ErrnoError(28);if("."!==(d=Y.relative(e,o)).charAt(0))throw new dr.ErrnoError(55);try{l=dr.lookupNode(n,s)}catch(r){}if(u!==l){var c=dr.isDir(u.mode),h=dr.mayDelete(t,i,c);if(h)throw new dr.ErrnoError(h);if(h=l?dr.mayDelete(n,s,c):dr.mayCreate(n,s))throw new dr.ErrnoError(h);if(!t.node_ops.rename)throw new dr.ErrnoError(63);if(dr.isMountpoint(u)||l&&dr.isMountpoint(l))throw new dr.ErrnoError(10);if(n!==t&&(h=dr.nodePermissions(t,"w")))throw new dr.ErrnoError(h);dr.hashRemoveNode(u);try{t.node_ops.rename(u,n,s),u.parent=n}catch(r){throw r}finally{dr.hashAddNode(u)}}},rmdir(r){var e=dr.lookupPath(r,{parent:!0}).node,t=X.basename(r),n=dr.lookupNode(e,t),o=dr.mayDelete(e,t,!0);if(o)throw new dr.ErrnoError(o);if(!e.node_ops.rmdir)throw new dr.ErrnoError(63);if(dr.isMountpoint(n))throw new dr.ErrnoError(10);e.node_ops.rmdir(e,t),dr.destroyNode(n)},readdir(r){var e=dr.lookupPath(r,{follow:!0}).node;if(!e.node_ops.readdir)throw new dr.ErrnoError(54);return e.node_ops.readdir(e)},unlink(r){var e=dr.lookupPath(r,{parent:!0}).node;if(!e)throw new dr.ErrnoError(44);var t=X.basename(r),n=dr.lookupNode(e,t),o=dr.mayDelete(e,t,!1);if(o)throw new dr.ErrnoError(o);if(!e.node_ops.unlink)throw new dr.ErrnoError(63);if(dr.isMountpoint(n))throw new dr.ErrnoError(10);e.node_ops.unlink(e,t),dr.destroyNode(n)},readlink(r){var e=dr.lookupPath(r).node;if(!e)throw new dr.ErrnoError(44);if(!e.node_ops.readlink)throw new dr.ErrnoError(28);return e.node_ops.readlink(e)},stat(r,e){var t=dr.lookupPath(r,{follow:!e}).node;if(!t)throw new dr.ErrnoError(44);if(!t.node_ops.getattr)throw new dr.ErrnoError(63);return t.node_ops.getattr(t)},lstat:r=>dr.stat(r,!0),chmod(r,e,t){var n;if(!(n="string"==typeof r?dr.lookupPath(r,{follow:!t}).node:r).node_ops.setattr)throw new dr.ErrnoError(63);n.node_ops.setattr(n,{mode:4095&e|-4096&n.mode,ctime:Date.now()})},lchmod(r,e){dr.chmod(r,e,!0)},fchmod(r,e){var t=dr.getStreamChecked(r);dr.chmod(t.node,e)},chown(r,e,t,n){var o;if(!(o="string"==typeof r?dr.lookupPath(r,{follow:!n}).node:r).node_ops.setattr)throw new dr.ErrnoError(63);o.node_ops.setattr(o,{timestamp:Date.now()})},lchown(r,e,t){dr.chown(r,e,t,!0)},fchown(r,e,t){var n=dr.getStreamChecked(r);dr.chown(n.node,e,t)},truncate(r,e){if(e<0)throw new dr.ErrnoError(28);var t;if(!(t="string"==typeof r?dr.lookupPath(r,{follow:!0}).node:r).node_ops.setattr)throw new dr.ErrnoError(63);if(dr.isDir(t.mode))throw new dr.ErrnoError(31);if(!dr.isFile(t.mode))throw new dr.ErrnoError(28);var n=dr.nodePermissions(t,"w");if(n)throw new dr.ErrnoError(n);t.node_ops.setattr(t,{size:e,timestamp:Date.now()})},ftruncate(r,e){var t=dr.getStreamChecked(r);if(!(2097155&t.flags))throw new dr.ErrnoError(28);dr.truncate(t.node,e)},utime(r,e,t){var n=dr.lookupPath(r,{follow:!0}).node;n.node_ops.setattr(n,{atime:e,mtime:t})},open(r,e,t=438){if(""===r)throw new dr.ErrnoError(44);var n;if(t=64&(e="string"==typeof e?(r=>{var e={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090}[r];if(void 0===e)throw new Error(`Unknown file open mode: ${r}`);return e})(e):e)?4095&t|32768:0,"object"==typeof r)n=r;else{var a=dr.lookupPath(r,{follow:!(131072&e),noent_okay:!0});n=a.node,r=a.path}var i=!1;if(64&e)if(n){if(128&e)throw new dr.ErrnoError(20)}else n=dr.mknod(r,t,0),i=!0;if(!n)throw new dr.ErrnoError(44);if(dr.isChrdev(n.mode)&&(e&=-513),65536&e&&!dr.isDir(n.mode))throw new dr.ErrnoError(54);if(!i){var s=dr.mayOpen(n,e);if(s)throw new dr.ErrnoError(s)}512&e&&!i&&dr.truncate(n,0),e&=-131713;var l=dr.createStream({node:n,path:dr.getPath(n),flags:e,seekable:!0,position:0,stream_ops:n.stream_ops,ungotten:[],error:!1});return l.stream_ops.open&&l.stream_ops.open(l),!o.logReadFiles||1&e||r in dr.readFiles||(dr.readFiles[r]=1),l},close(r){if(dr.isClosed(r))throw new dr.ErrnoError(8);r.getdents&&(r.getdents=null);try{r.stream_ops.close&&r.stream_ops.close(r)}catch(r){throw r}finally{dr.closeStream(r.fd)}r.fd=null},isClosed:r=>null===r.fd,llseek(r,e,t){if(dr.isClosed(r))throw new dr.ErrnoError(8);if(!r.seekable||!r.stream_ops.llseek)throw new dr.ErrnoError(70);if(0!=t&&1!=t&&2!=t)throw new dr.ErrnoError(28);return r.position=r.stream_ops.llseek(r,e,t),r.ungotten=[],r.position},read(r,e,t,n,o){if(n<0||o<0)throw new dr.ErrnoError(28);if(dr.isClosed(r))throw new dr.ErrnoError(8);if(1==(2097155&r.flags))throw new dr.ErrnoError(8);if(dr.isDir(r.node.mode))throw new dr.ErrnoError(31);if(!r.stream_ops.read)throw new dr.ErrnoError(28);var a=void 0!==o;if(a){if(!r.seekable)throw new dr.ErrnoError(70)}else o=r.position;var i=r.stream_ops.read(r,e,t,n,o);return a||(r.position+=i),i},write(r,e,t,n,o,a){if(n<0||o<0)throw new dr.ErrnoError(28);if(dr.isClosed(r))throw new dr.ErrnoError(8);if(!(2097155&r.flags))throw new dr.ErrnoError(8);if(dr.isDir(r.node.mode))throw new dr.ErrnoError(31);if(!r.stream_ops.write)throw new dr.ErrnoError(28);r.seekable&&1024&r.flags&&dr.llseek(r,0,2);var i=void 0!==o;if(i){if(!r.seekable)throw new dr.ErrnoError(70)}else o=r.position;var s=r.stream_ops.write(r,e,t,n,o,a);return i||(r.position+=s),s},allocate(r,e,t){if(dr.isClosed(r))throw new dr.ErrnoError(8);if(e<0||t<=0)throw new dr.ErrnoError(28);if(!(2097155&r.flags))throw new dr.ErrnoError(8);if(!dr.isFile(r.node.mode)&&!dr.isDir(r.node.mode))throw new dr.ErrnoError(43);if(!r.stream_ops.allocate)throw new dr.ErrnoError(138);r.stream_ops.allocate(r,e,t)},mmap(r,e,t,n,o){if(2&n&&!(2&o)&&2!=(2097155&r.flags))throw new dr.ErrnoError(2);if(1==(2097155&r.flags))throw new dr.ErrnoError(2);if(!r.stream_ops.mmap)throw new dr.ErrnoError(43);if(!e)throw new dr.ErrnoError(28);return r.stream_ops.mmap(r,e,t,n,o)},msync:(r,e,t,n,o)=>r.stream_ops.msync?r.stream_ops.msync(r,e,t,n,o):0,ioctl(r,e,t){if(!r.stream_ops.ioctl)throw new dr.ErrnoError(59);return r.stream_ops.ioctl(r,e,t)},readFile(r,e={}){if(e.flags=e.flags||0,e.encoding=e.encoding||"binary","utf8"!==e.encoding&&"binary"!==e.encoding)throw new Error(`Invalid encoding type "${e.encoding}"`);var t,n=dr.open(r,e.flags),o=dr.stat(r).size,a=new Uint8Array(o);return dr.read(n,a,0,o,0),"utf8"===e.encoding?t=J(a):"binary"===e.encoding&&(t=a),dr.close(n),t},writeFile(r,e,t={}){t.flags=t.flags||577;var n=dr.open(r,t.flags,t.mode);if("string"==typeof e){var o=new Uint8Array(rr(e)+1),a=er(e,o,0,o.length);dr.write(n,o,0,a,void 0,t.canOwn)}else{if(!ArrayBuffer.isView(e))throw new Error("Unsupported data type");dr.write(n,e,0,e.byteLength,void 0,t.canOwn)}dr.close(n)},cwd:()=>dr.currentPath,chdir(r){var e=dr.lookupPath(r,{follow:!0});if(null===e.node)throw new dr.ErrnoError(44);if(!dr.isDir(e.node.mode))throw new dr.ErrnoError(54);var t=dr.nodePermissions(e.node,"x");if(t)throw new dr.ErrnoError(t);dr.currentPath=e.path},createDefaultDirectories(){dr.mkdir("/tmp"),dr.mkdir("/home"),dr.mkdir("/home/web_user")},createDefaultDevices(){dr.mkdir("/dev"),dr.registerDevice(dr.makedev(1,3),{read:()=>0,write:(r,e,t,n,o)=>n,llseek:()=>0}),dr.mkdev("/dev/null",dr.makedev(1,3)),nr.register(dr.makedev(5,0),nr.default_tty_ops),nr.register(dr.makedev(6,0),nr.default_tty1_ops),dr.mkdev("/dev/tty",dr.makedev(5,0)),dr.mkdev("/dev/tty1",dr.makedev(6,0));var r=new Uint8Array(1024),e=0,t=()=>(0===e&&(e=K(r).byteLength),r[--e]);dr.createDevice("/dev","random",t),dr.createDevice("/dev","urandom",t),dr.mkdir("/dev/shm"),dr.mkdir("/dev/shm/tmp")},createSpecialDirectories(){dr.mkdir("/proc");var r=dr.mkdir("/proc/self");dr.mkdir("/proc/self/fd"),dr.mount({mount(){var e=dr.createNode(r,"fd",16895,73);return e.stream_ops={llseek:ir.stream_ops.llseek},e.node_ops={lookup(r,e){var t=+e,n=dr.getStreamChecked(t),o={parent:null,mount:{mountpoint:"fake"},node_ops:{readlink:()=>n.path},id:t+1};return o.parent=o,o},readdir:()=>Array.from(dr.streams.entries()).filter(([r,e])=>e).map(([r,e])=>r.toString())},e}},{},"/proc/self/fd")},createStandardStreams(r,e,t){r?dr.createDevice("/dev","stdin",r):dr.symlink("/dev/tty","/dev/stdin"),e?dr.createDevice("/dev","stdout",null,e):dr.symlink("/dev/tty","/dev/stdout"),t?dr.createDevice("/dev","stderr",null,t):dr.symlink("/dev/tty1","/dev/stderr"),dr.open("/dev/stdin",0),dr.open("/dev/stdout",1),dr.open("/dev/stderr",1)},staticInit(){dr.nameTable=new Array(4096),dr.mount(ir,{},"/"),dr.createDefaultDirectories(),dr.createDefaultDevices(),dr.createSpecialDirectories(),dr.filesystems={MEMFS:ir}},init(r,e,t){dr.initialized=!0,r??=o.stdin,e??=o.stdout,t??=o.stderr,dr.createStandardStreams(r,e,t)},quit(){dr.initialized=!1;for(var r=0;r<dr.streams.length;r++){var e=dr.streams[r];e&&dr.close(e)}},findObject(r,e){var t=dr.analyzePath(r,e);return t.exists?t.object:null},analyzePath(r,e){try{r=(n=dr.lookupPath(r,{follow:!e})).path}catch(r){}var t={isRoot:!1,exists:!1,error:0,name:null,path:null,object:null,parentExists:!1,parentPath:null,parentObject:null};try{var n=dr.lookupPath(r,{parent:!0});t.parentExists=!0,t.parentPath=n.path,t.parentObject=n.node,t.name=X.basename(r),n=dr.lookupPath(r,{follow:!e}),t.exists=!0,t.path=n.path,t.object=n.node,t.name=n.node.name,t.isRoot="/"===n.path}catch(r){t.error=r.errno}return t},createPath(r,e,t,n){r="string"==typeof r?r:dr.getPath(r);for(var o=e.split("/").reverse();o.length;){var a=o.pop();if(a){var i=X.join2(r,a);try{dr.mkdir(i)}catch(r){}r=i}}return i},createFile(r,e,t,n,o){var a=X.join2("string"==typeof r?r:dr.getPath(r),e),i=ur(n,o);return dr.create(a,i)},createDataFile(r,e,t,n,o,a){var i=e;r&&(r="string"==typeof r?r:dr.getPath(r),i=e?X.join2(r,e):r);var s=ur(n,o),l=dr.create(i,s);if(t){if("string"==typeof t){for(var u=new Array(t.length),d=0,c=t.length;d<c;++d)u[d]=t.charCodeAt(d);t=u}dr.chmod(l,146|s);var h=dr.open(l,577);dr.write(h,t,0,t.length,0,a),dr.close(h),dr.chmod(l,s)}},createDevice(r,e,t,n){var o=X.join2("string"==typeof r?r:dr.getPath(r),e),a=ur(!!t,!!n);dr.createDevice.major??=64;var i=dr.makedev(dr.createDevice.major++,0);return dr.registerDevice(i,{open(r){r.seekable=!1},close(r){n?.buffer?.length&&n(10)},read(r,e,n,o,a){for(var i=0,s=0;s<o;s++){var l;try{l=t()}catch(r){throw new dr.ErrnoError(29)}if(void 0===l&&0===i)throw new dr.ErrnoError(6);if(null==l)break;i++,e[n+s]=l}return i&&(r.node.atime=Date.now()),i},write(r,e,t,o,a){for(var i=0;i<o;i++)try{n(e[t+i])}catch(r){throw new dr.ErrnoError(29)}return o&&(r.node.mtime=r.node.ctime=Date.now()),i}}),dr.mkdev(o,a,i)},forceLoadFile(r){if(r.isDevice||r.isFolder||r.link||r.contents)return!0;if("undefined"!=typeof XMLHttpRequest)throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");try{r.contents=u(r.url),r.usedBytes=r.contents.length}catch(r){throw new dr.ErrnoError(29)}},createLazyFile(r,e,t,n,o){class a{lengthKnown=!1;chunks=[];get(r){if(!(r>this.length-1||r<0)){var e=r%this.chunkSize,t=r/this.chunkSize|0;return this.getter(t)[e]}}setDataGetter(r){this.getter=r}cacheLength(){var r=new XMLHttpRequest;if(r.open("HEAD",t,!1),r.send(null),!(r.status>=200&&r.status<300||304===r.status))throw new Error("Couldn't load "+t+". Status: "+r.status);var e,n=Number(r.getResponseHeader("Content-length")),o=(e=r.getResponseHeader("Accept-Ranges"))&&"bytes"===e,a=(e=r.getResponseHeader("Content-Encoding"))&&"gzip"===e,i=1048576;o||(i=n);var s=(r,e)=>{if(r>e)throw new Error("invalid range ("+r+", "+e+") or no bytes requested!");if(e>n-1)throw new Error("only "+n+" bytes available! programmer error!");var o=new XMLHttpRequest;if(o.open("GET",t,!1),n!==i&&o.setRequestHeader("Range","bytes="+r+"-"+e),o.responseType="arraybuffer",o.overrideMimeType&&o.overrideMimeType("text/plain; charset=x-user-defined"),o.send(null),!(o.status>=200&&o.status<300||304===o.status))throw new Error("Couldn't load "+t+". Status: "+o.status);return void 0!==o.response?new Uint8Array(o.response||[]):tr(o.responseText||"")},l=this;l.setDataGetter(r=>{var e=r*i,t=(r+1)*i-1;if(t=Math.min(t,n-1),void 0===l.chunks[r]&&(l.chunks[r]=s(e,t)),void 0===l.chunks[r])throw new Error("doXHR failed!");return l.chunks[r]}),!a&&n||(i=n=1,n=this.getter(0).length,i=n,f("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=n,this._chunkSize=i,this.lengthKnown=!0}get length(){return this.lengthKnown||this.cacheLength(),this._length}get chunkSize(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}if("undefined"!=typeof XMLHttpRequest){if(!s)throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var i={isDevice:!1,contents:new a}}else i={isDevice:!1,url:t};var l=dr.createFile(r,e,i,n,o);i.contents?l.contents=i.contents:i.url&&(l.contents=null,l.url=i.url),Object.defineProperties(l,{usedBytes:{get:function(){return this.contents.length}}});var u={};function d(r,e,t,n,o){var a=r.node.contents;if(o>=a.length)return 0;var i=Math.min(a.length-o,n);if(a.slice)for(var s=0;s<i;s++)e[t+s]=a[o+s];else for(s=0;s<i;s++)e[t+s]=a.get(o+s);return i}return Object.keys(l.stream_ops).forEach(r=>{var e=l.stream_ops[r];u[r]=(...r)=>(dr.forceLoadFile(l),e(...r))}),u.read=(r,e,t,n,o)=>(dr.forceLoadFile(l),d(r,e,t,n,o)),u.mmap=(r,e,t,n,o)=>{dr.forceLoadFile(l);var a=ar(e);if(!a)throw new dr.ErrnoError(48);return d(r,v,a,e,t),{ptr:a,allocated:!0}},l.stream_ops=u,l}},cr=(r,e)=>r?J(y,r,e):"",hr={DEFAULT_POLLMASK:5,calculateAt(r,e,t){if(X.isAbs(e))return e;var n;if(n=-100===r?dr.cwd():hr.getStreamFromFD(r).path,0==e.length){if(!t)throw new dr.ErrnoError(44);return n}return n+"/"+e},doStat(r,e,t){var n=r(e);E[t>>2]=n.dev,E[t+4>>2]=n.mode,b[t+8>>2]=n.nlink,E[t+12>>2]=n.uid,E[t+16>>2]=n.gid,E[t+20>>2]=n.rdev,z=[n.size>>>0,(W=n.size,+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[t+24>>2]=z[0],E[t+28>>2]=z[1],E[t+32>>2]=4096,E[t+36>>2]=n.blocks;var o=n.atime.getTime(),a=n.mtime.getTime(),i=n.ctime.getTime();return z=[Math.floor(o/1e3)>>>0,(W=Math.floor(o/1e3),+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[t+40>>2]=z[0],E[t+44>>2]=z[1],b[t+48>>2]=o%1e3*1e3*1e3,z=[Math.floor(a/1e3)>>>0,(W=Math.floor(a/1e3),+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[t+56>>2]=z[0],E[t+60>>2]=z[1],b[t+64>>2]=a%1e3*1e3*1e3,z=[Math.floor(i/1e3)>>>0,(W=Math.floor(i/1e3),+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[t+72>>2]=z[0],E[t+76>>2]=z[1],b[t+80>>2]=i%1e3*1e3*1e3,z=[n.ino>>>0,(W=n.ino,+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[t+88>>2]=z[0],E[t+92>>2]=z[1],0},doMsync(r,e,t,n,o){if(!dr.isFile(e.node.mode))throw new dr.ErrnoError(43);if(2&n)return 0;var a=y.slice(r,r+t);dr.msync(e,a,o,t,n)},getStreamFromFD:r=>dr.getStreamChecked(r),varargs:void 0,getStr:r=>cr(r)},fr={},pr=r=>{for(;r.length;){var e=r.pop();r.pop()(e)}};function mr(r){return this.fromWireType(b[r>>2])}var vr,yr,wr,gr={},Er={},br={},_r=r=>{throw new vr(r)},kr=(r,e,t)=>{function n(e){var n=t(e);n.length!==r.length&&_r("Mismatched type converter count");for(var o=0;o<r.length;++o)Pr(r[o],n[o])}r.forEach(r=>br[r]=e);var o=new Array(e.length),a=[],i=0;e.forEach((r,e)=>{Er.hasOwnProperty(r)?o[e]=Er[r]:(a.push(r),gr.hasOwnProperty(r)||(gr[r]=[]),gr[r].push(()=>{o[e]=Er[r],++i===a.length&&n(o)}))}),0===a.length&&n(o)},$r=r=>{for(var e="",t=r;y[t];)e+=yr[y[t++]];return e},Cr=r=>{throw new wr(r)};function Pr(r,e,t={}){return function(r,e,t={}){var n=e.name;if(r||Cr(`type "${n}" must have a positive integer typeid pointer`),Er.hasOwnProperty(r)){if(t.ignoreDuplicateRegistrations)return;Cr(`Cannot register type '${n}' twice`)}if(Er[r]=e,delete br[r],gr.hasOwnProperty(r)){var o=gr[r];delete gr[r],o.forEach(r=>r())}}(r,e,t)}var Tr=r=>({count:r.count,deleteScheduled:r.deleteScheduled,preservePointerOnDelete:r.preservePointerOnDelete,ptr:r.ptr,ptrType:r.ptrType,smartPtr:r.smartPtr,smartPtrType:r.smartPtrType}),Ar=r=>{Cr(function(r){return r.$$.ptrType.registeredClass.name}(r)+" instance already deleted")},Sr=!1,Dr=r=>{},Fr=r=>{r.count.value-=1,0===r.count.value&&(r=>{r.smartPtr?r.smartPtrType.rawDestructor(r.smartPtr):r.ptrType.registeredClass.rawDestructor(r.ptr)})(r)},jr=(r,e,t)=>{if(e===t)return r;if(void 0===t.baseClass)return null;var n=jr(r,e,t.baseClass);return null===n?null:t.downcast(n)},Mr={},Rr={},xr=(r,e)=>(e.ptrType&&e.ptr||_r("makeClassHandle requires ptr and ptrType"),!!e.smartPtrType!=!!e.smartPtr&&_r("Both smartPtrType and smartPtr must be specified"),e.count={value:1},Or(Object.create(r,{$$:{value:e,writable:!0}})));var Or=r=>"undefined"==typeof FinalizationRegistry?(Or=r=>r,r):(Sr=new FinalizationRegistry(r=>{Fr(r.$$)}),Or=r=>{var e=r.$$;if(e.smartPtr){var t={$$:e};Sr.register(r,t,r)}return r},Dr=r=>Sr.unregister(r),Or(r));function Nr(){}var Wr=(r,e)=>Object.defineProperty(e,"name",{value:r}),zr=(r,e,t)=>{if(void 0===r[e].overloadTable){var n=r[e];r[e]=function(...n){return r[e].overloadTable.hasOwnProperty(n.length)||Cr(`Function '${t}' called with an invalid number of arguments (${n.length}) - expects one of (${r[e].overloadTable})!`),r[e].overloadTable[n.length].apply(this,n)},r[e].overloadTable=[],r[e].overloadTable[n.argCount]=n}},Ur=(r,e,t)=>{o.hasOwnProperty(r)?((void 0===t||void 0!==o[r].overloadTable&&void 0!==o[r].overloadTable[t])&&Cr(`Cannot register public name '${r}' twice`),zr(o,r,r),o[r].overloadTable.hasOwnProperty(t)&&Cr(`Cannot register multiple overloads of a function with the same number of arguments (${t})!`),o[r].overloadTable[t]=e):(o[r]=e,o[r].argCount=t)};function Br(r,e,t,n,o,a,i,s){this.name=r,this.constructor=e,this.instancePrototype=t,this.rawDestructor=n,this.baseClass=o,this.getActualType=a,this.upcast=i,this.downcast=s,this.pureVirtualFunctions=[]}var Lr=(r,e,t)=>{for(;e!==t;)e.upcast||Cr(`Expected null or instance of ${t.name}, got an instance of ${e.name}`),r=e.upcast(r),e=e.baseClass;return r};function Hr(r,e){if(null===e)return this.isReference&&Cr(`null is not a valid ${this.name}`),0;e.$$||Cr(`Cannot pass "${ce(e)}" as a ${this.name}`),e.$$.ptr||Cr(`Cannot pass deleted object as a pointer of type ${this.name}`);var t=e.$$.ptrType.registeredClass;return Lr(e.$$.ptr,t,this.registeredClass)}function Ir(r,e){var t;if(null===e)return this.isReference&&Cr(`null is not a valid ${this.name}`),this.isSmartPointer?(t=this.rawConstructor(),null!==r&&r.push(this.rawDestructor,t),t):0;e&&e.$$||Cr(`Cannot pass "${ce(e)}" as a ${this.name}`),e.$$.ptr||Cr(`Cannot pass deleted object as a pointer of type ${this.name}`),!this.isConst&&e.$$.ptrType.isConst&&Cr(`Cannot convert argument of type ${e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name} to parameter type ${this.name}`);var n=e.$$.ptrType.registeredClass;if(t=Lr(e.$$.ptr,n,this.registeredClass),this.isSmartPointer)switch(void 0===e.$$.smartPtr&&Cr("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:e.$$.smartPtrType===this?t=e.$$.smartPtr:Cr(`Cannot convert argument of type ${e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name} to parameter type ${this.name}`);break;case 1:t=e.$$.smartPtr;break;case 2:if(e.$$.smartPtrType===this)t=e.$$.smartPtr;else{var o=e.clone();t=this.rawShare(t,se.toHandle(()=>o.delete())),null!==r&&r.push(this.rawDestructor,t)}break;default:Cr("Unsupporting sharing policy")}return t}function Vr(r,e){if(null===e)return this.isReference&&Cr(`null is not a valid ${this.name}`),0;e.$$||Cr(`Cannot pass "${ce(e)}" as a ${this.name}`),e.$$.ptr||Cr(`Cannot pass deleted object as a pointer of type ${this.name}`),e.$$.ptrType.isConst&&Cr(`Cannot convert argument of type ${e.$$.ptrType.name} to parameter type ${this.name}`);var t=e.$$.ptrType.registeredClass;return Lr(e.$$.ptr,t,this.registeredClass)}function qr(r,e,t,n,o,a,i,s,l,u,d){this.name=r,this.registeredClass=e,this.isReference=t,this.isConst=n,this.isSmartPointer=o,this.pointeeType=a,this.sharingPolicy=i,this.rawGetPointee=s,this.rawConstructor=l,this.rawShare=u,this.rawDestructor=d,o||void 0!==e.baseClass?this.toWireType=Ir:n?(this.toWireType=Hr,this.destructorFunction=null):(this.toWireType=Vr,this.destructorFunction=null)}var Gr,Xr,Kr=(r,e,t)=>{o.hasOwnProperty(r)||_r("Replacing nonexistent public symbol"),void 0!==o[r].overloadTable&&void 0!==t?o[r].overloadTable[t]=e:(o[r]=e,o[r].argCount=t)},Yr=[],Zr=r=>{var e=Yr[r];return e||(r>=Yr.length&&(Yr.length=r+1),Yr[r]=e=Gr.get(r)),e},Jr=(r,e)=>{var t=(r=$r(r)).includes("j")?((r,e)=>(...t)=>((r,e,t=[])=>r.includes("j")?((r,e,t)=>(r=r.replace(/p/g,"i"),(0,o["dynCall_"+r])(e,...t)))(r,e,t):Zr(e)(...t))(r,e,t))(r,e):Zr(e);return"function"!=typeof t&&Cr(`unknown function pointer with signature ${r}: ${e}`),t},Qr=r=>{var e=Oe(r),t=$r(e);return Ne(e),t},re=(r,e)=>{var t=[],n={};throw e.forEach(function r(e){n[e]||Er[e]||(br[e]?br[e].forEach(r):(t.push(e),n[e]=!0))}),new Xr(`${r}: `+t.map(Qr).join([", "]))},ee=(r,e)=>{for(var t=[],n=0;n<r;n++)t.push(b[e+4*n>>2]);return t};function te(r,e,t,n,o,a){var i=e.length;i<2&&Cr("argTypes array size mismatch! Must at least get return value and 'this' types!");var s=null!==e[1]&&null!==t,l=function(r){for(var e=1;e<r.length;++e)if(null!==r[e]&&void 0===r[e].destructorFunction)return!0;return!1}(e),u="void"!==e[0].name,d=i-2,c=new Array(d),h=[],f=[];return Wr(r,function(...r){var t;f.length=0,h.length=s?2:1,h[0]=o,s&&(t=e[1].toWireType(f,this),h[1]=t);for(var a=0;a<d;++a)c[a]=e[a+2].toWireType(f,r[a]),h.push(c[a]);return function(r){if(l)pr(f);else for(var n=s?1:2;n<e.length;n++){var o=1===n?t:c[n-2];null!==e[n].destructorFunction&&e[n].destructorFunction(o)}if(u)return e[0].fromWireType(r)}(n(...h))})}var ne=r=>{const e=(r=r.trim()).indexOf("(");return-1!==e?r.substr(0,e):r},oe=[],ae=[],ie=r=>{r>9&&0===--ae[r+1]&&(ae[r]=void 0,oe.push(r))},se={toValue:r=>(r||Cr("Cannot use deleted val. handle = "+r),ae[r]),toHandle:r=>{switch(r){case void 0:return 2;case null:return 4;case!0:return 6;case!1:return 8;default:{const e=oe.pop()||ae.length;return ae[e]=r,ae[e+1]=1,e}}}},le={name:"emscripten::val",fromWireType:r=>{var e=se.toValue(r);return ie(r),e},toWireType:(r,e)=>se.toHandle(e),argPackAdvance:8,readValueFromPointer:mr,destructorFunction:null},ue=(r,e,t)=>{switch(e){case 1:return t?function(r){return this.fromWireType(v[r])}:function(r){return this.fromWireType(y[r])};case 2:return t?function(r){return this.fromWireType(w[r>>1])}:function(r){return this.fromWireType(g[r>>1])};case 4:return t?function(r){return this.fromWireType(E[r>>2])}:function(r){return this.fromWireType(b[r>>2])};default:throw new TypeError(`invalid integer width (${e}): ${r}`)}},de=(r,e)=>{var t=Er[r];return void 0===t&&Cr(`${e} has unknown type ${Qr(r)}`),t},ce=r=>{if(null===r)return"null";var e=typeof r;return"object"===e||"array"===e||"function"===e?r.toString():""+r},he=(r,e)=>{switch(e){case 4:return function(r){return this.fromWireType(_[r>>2])};case 8:return function(r){return this.fromWireType(k[r>>3])};default:throw new TypeError(`invalid float width (${e}): ${r}`)}},fe=(r,e,t)=>{switch(e){case 1:return t?r=>v[r]:r=>y[r];case 2:return t?r=>w[r>>1]:r=>g[r>>1];case 4:return t?r=>E[r>>2]:r=>b[r>>2];default:throw new TypeError(`invalid integer width (${e}): ${r}`)}},pe=(r,e,t)=>er(r,y,e,t),me="undefined"!=typeof TextDecoder?new TextDecoder("utf-16le"):void 0,ve=(r,e)=>{for(var t=r,n=t>>1,o=n+e/2;!(n>=o)&&g[n];)++n;if((t=n<<1)-r>32&&me)return me.decode(y.subarray(r,t));for(var a="",i=0;!(i>=e/2);++i){var s=w[r+2*i>>1];if(0==s)break;a+=String.fromCharCode(s)}return a},ye=(r,e,t)=>{if(t??=2147483647,t<2)return 0;for(var n=e,o=(t-=2)<2*r.length?t/2:r.length,a=0;a<o;++a){var i=r.charCodeAt(a);w[e>>1]=i,e+=2}return w[e>>1]=0,e-n},we=r=>2*r.length,ge=(r,e)=>{for(var t=0,n="";!(t>=e/4);){var o=E[r+4*t>>2];if(0==o)break;if(++t,o>=65536){var a=o-65536;n+=String.fromCharCode(55296|a>>10,56320|1023&a)}else n+=String.fromCharCode(o)}return n},Ee=(r,e,t)=>{if(t??=2147483647,t<4)return 0;for(var n=e,o=n+t-4,a=0;a<r.length;++a){var i=r.charCodeAt(a);if(i>=55296&&i<=57343&&(i=65536+((1023&i)<<10)|1023&r.charCodeAt(++a)),E[e>>2]=i,(e+=4)+4>o)break}return E[e>>2]=0,e-n},be=r=>{for(var e=0,t=0;t<r.length;++t){var n=r.charCodeAt(t);n>=55296&&n<=57343&&++t,e+=4}return e},_e=(r,e,t)=>{var n=[],o=r.toWireType(n,t);return n.length&&(b[e>>2]=se.toHandle(n)),o},ke={},$e=r=>{var e=ke[r];return void 0===e?$r(r):e},Ce=[],Pe=Reflect.construct,Te=(r,e)=>e+2097152>>>0<4194305-!!r?(r>>>0)+4294967296*e:NaN,Ae=()=>performance.now(),Se=()=>Date.now(),De=r=>{var e=(r-m.buffer.byteLength+65535)/65536|0;try{return m.grow(e),P(),1}catch(r){}},Fe={},je=()=>{if(!je.strings){var r={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:("object"==typeof navigator&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:c||"./this.program"};for(var e in Fe)void 0===Fe[e]?delete r[e]:r[e]=Fe[e];var t=[];for(var e in r)t.push(`${e}=${r[e]}`);je.strings=t}return je.strings};dr.createPreloadedFile=(r,e,t,n,o,a,i,s,l,u)=>{var d=e?Y.resolve(X.join2(r,e)):r;function c(t){function c(t){u?.(),s||((r,e,t,n,o,a)=>{dr.createDataFile(r,e,t,n,o,a)})(r,e,t,n,o,l),a?.(),x()}((r,e,t,n)=>{"undefined"!=typeof Browser&&Browser.init();var o=!1;return lr.forEach(a=>{o||a.canHandle(e)&&(a.handle(r,e,t,n),o=!0)}),o})(t,d,c,()=>{i?.(),x()})||c(t)}R(),"string"==typeof t?sr(t).then(c,i):c(t)},dr.staticInit(),ir.doesNotExistError=new dr.ErrnoError(44),ir.doesNotExistError.stack="<generic error, no stack>",vr=o.InternalError=class extends Error{constructor(r){super(r),this.name="InternalError"}},(()=>{for(var r=new Array(256),e=0;e<256;++e)r[e]=String.fromCharCode(e);yr=r})(),wr=o.BindingError=class extends Error{constructor(r){super(r),this.name="BindingError"}},Object.assign(Nr.prototype,{isAliasOf(r){if(!(this instanceof Nr))return!1;if(!(r instanceof Nr))return!1;var e=this.$$.ptrType.registeredClass,t=this.$$.ptr;r.$$=r.$$;for(var n=r.$$.ptrType.registeredClass,o=r.$$.ptr;e.baseClass;)t=e.upcast(t),e=e.baseClass;for(;n.baseClass;)o=n.upcast(o),n=n.baseClass;return e===n&&t===o},clone(){if(this.$$.ptr||Ar(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var r=Or(Object.create(Object.getPrototypeOf(this),{$$:{value:Tr(this.$$)}}));return r.$$.count.value+=1,r.$$.deleteScheduled=!1,r},delete(){this.$$.ptr||Ar(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&Cr("Object already scheduled for deletion"),Dr(this),Fr(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)},isDeleted(){return!this.$$.ptr},deleteLater(){return this.$$.ptr||Ar(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&Cr("Object already scheduled for deletion"),this.$$.deleteScheduled=!0,this}}),Object.assign(qr.prototype,{getPointee(r){return this.rawGetPointee&&(r=this.rawGetPointee(r)),r},destructor(r){this.rawDestructor?.(r)},argPackAdvance:8,readValueFromPointer:mr,fromWireType:function(r){var e=this.getPointee(r);if(!e)return this.destructor(r),null;var t=((r,e)=>(e=((r,e)=>{for(void 0===e&&Cr("ptr should not be undefined");r.baseClass;)e=r.upcast(e),r=r.baseClass;return e})(r,e),Rr[e]))(this.registeredClass,e);if(void 0!==t){if(0===t.$$.count.value)return t.$$.ptr=e,t.$$.smartPtr=r,t.clone();var n=t.clone();return this.destructor(r),n}function o(){return this.isSmartPointer?xr(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:e,smartPtrType:this,smartPtr:r}):xr(this.registeredClass.instancePrototype,{ptrType:this,ptr:r})}var a,i=this.registeredClass.getActualType(e),s=Mr[i];if(!s)return o.call(this);a=this.isConst?s.constPointerType:s.pointerType;var l=jr(e,this.registeredClass,a.registeredClass);return null===l?o.call(this):this.isSmartPointer?xr(a.registeredClass.instancePrototype,{ptrType:a,ptr:l,smartPtrType:this,smartPtr:r}):xr(a.registeredClass.instancePrototype,{ptrType:a,ptr:l})}}),Xr=o.UnboundTypeError=((r,e)=>{var t=Wr(e,function(r){this.name=e,this.message=r;var t=new Error(r).stack;void 0!==t&&(this.stack=this.toString()+"\n"+t.replace(/^Error(:[^\n]*)?\n/,""))});return t.prototype=Object.create(r.prototype),t.prototype.constructor=t,t.prototype.toString=function(){return void 0===this.message?this.name:`${this.name}: ${this.message}`},t})(Error,"UnboundTypeError"),ae.push(0,1,void 0,1,null,1,!0,1,!1,1),o.count_emval_handles=()=>ae.length/2-5-oe.length;var Me,Re={u:(r,e,t)=>{throw new V(r).init(e,t),r},B:function(r,e,t){hr.varargs=t;try{var n=hr.getStreamFromFD(r);switch(e){case 0:if((o=q())<0)return-28;for(;dr.streams[o];)o++;return dr.dupStream(n,o).fd;case 1:case 2:case 13:case 14:return 0;case 3:return n.flags;case 4:var o=q();return n.flags|=o,0;case 12:return o=G(),w[o+0>>1]=2,0}return-28}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},R:function(r,e){try{var t=hr.getStreamFromFD(r);return hr.doStat(dr.stat,t.path,e)}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},T:function(r,e,t){hr.varargs=t;try{var n=hr.getStreamFromFD(r);switch(e){case 21509:case 21510:case 21511:case 21512:case 21524:case 21515:return n.tty?0:-59;case 21505:if(!n.tty)return-59;if(n.tty.ops.ioctl_tcgets){var o=n.tty.ops.ioctl_tcgets(n),a=G();E[a>>2]=o.c_iflag||0,E[a+4>>2]=o.c_oflag||0,E[a+8>>2]=o.c_cflag||0,E[a+12>>2]=o.c_lflag||0;for(var i=0;i<32;i++)v[a+i+17]=o.c_cc[i]||0;return 0}return 0;case 21506:case 21507:case 21508:if(!n.tty)return-59;if(n.tty.ops.ioctl_tcsets){a=G();var s=E[a>>2],l=E[a+4>>2],u=E[a+8>>2],d=E[a+12>>2],c=[];for(i=0;i<32;i++)c.push(v[a+i+17]);return n.tty.ops.ioctl_tcsets(n.tty,e,{c_iflag:s,c_oflag:l,c_cflag:u,c_lflag:d,c_cc:c})}return 0;case 21519:return n.tty?(a=G(),E[a>>2]=0,0):-59;case 21520:return n.tty?-28:-59;case 21531:return a=G(),dr.ioctl(n,e,a);case 21523:if(!n.tty)return-59;if(n.tty.ops.ioctl_tiocgwinsz){var h=n.tty.ops.ioctl_tiocgwinsz(n.tty);a=G(),w[a>>1]=h[0],w[a+2>>1]=h[1]}return 0;default:return-28}}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},P:function(r,e,t,n){try{e=hr.getStr(e);var o=256&n,a=4096&n;return n&=-6401,e=hr.calculateAt(r,e,a),hr.doStat(o?dr.lstat:dr.stat,e,t)}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},C:function(r,e,t,n){hr.varargs=n;try{e=hr.getStr(e),e=hr.calculateAt(r,e);var o=n?q():0;return dr.open(e,t,o).fd}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},Q:function(r,e){try{return r=hr.getStr(r),hr.doStat(dr.stat,r,e)}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},W:()=>O(""),s:r=>{var e=fr[r];delete fr[r];var t=e.rawConstructor,n=e.rawDestructor,o=e.fields,a=o.map(r=>r.getterReturnType).concat(o.map(r=>r.setterArgumentType));kr([r],a,r=>{var a={};return o.forEach((e,t)=>{var n=e.fieldName,i=r[t],s=e.getter,l=e.getterContext,u=r[t+o.length],d=e.setter,c=e.setterContext;a[n]={read:r=>i.fromWireType(s(l,r)),write:(r,e)=>{var t=[];d(c,r,u.toWireType(t,e)),pr(t)}}}),[{name:e.name,fromWireType:r=>{var e={};for(var t in a)e[t]=a[t].read(r);return n(r),e},toWireType:(r,e)=>{for(var o in a)if(!(o in e))throw new TypeError(`Missing field: "${o}"`);var i=t();for(o in a)a[o].write(i,e[o]);return null!==r&&r.push(n,i),i},argPackAdvance:8,readValueFromPointer:mr,destructorFunction:n}]})},I:(r,e,t,n,o)=>{},aa:(r,e,t,n)=>{Pr(r,{name:e=$r(e),fromWireType:function(r){return!!r},toWireType:function(r,e){return e?t:n},argPackAdvance:8,readValueFromPointer:function(r){return this.fromWireType(y[r])},destructorFunction:null})},w:(r,e,t,n,o,a,i,s,l,u,d,c,h)=>{d=$r(d),a=Jr(o,a),s&&=Jr(i,s),u&&=Jr(l,u),h=Jr(c,h);var f=(r=>{var e=(r=r.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return e>=48&&e<=57?`_${r}`:r})(d);Ur(f,function(){re(`Cannot construct ${d} due to unbound types`,[n])}),kr([r,e,t],n?[n]:[],e=>{var t,o;e=e[0],o=n?(t=e.registeredClass).instancePrototype:Nr.prototype;var i=Wr(d,function(...r){if(Object.getPrototypeOf(this)!==l)throw new wr("Use 'new' to construct "+d);if(void 0===c.constructor_body)throw new wr(d+" has no accessible constructor");var e=c.constructor_body[r.length];if(void 0===e)throw new wr(`Tried to invoke ctor of ${d} with invalid number of parameters (${r.length}) - expected (${Object.keys(c.constructor_body).toString()}) parameters instead!`);return e.apply(this,r)}),l=Object.create(o,{constructor:{value:i}});i.prototype=l;var c=new Br(d,i,l,h,t,a,s,u);c.baseClass&&(c.baseClass.__derivedClasses??=[],c.baseClass.__derivedClasses.push(c));var p=new qr(d,c,!0,!1,!1),m=new qr(d+"*",c,!1,!1,!1),v=new qr(d+" const*",c,!1,!0,!1);return Mr[r]={pointerType:m,constPointerType:v},Kr(f,i),[p,m,v]})},v:(r,e,t,n,o,a)=>{var i=ee(e,t);o=Jr(n,o),kr([],[r],r=>{var t=`constructor ${(r=r[0]).name}`;if(void 0===r.registeredClass.constructor_body&&(r.registeredClass.constructor_body=[]),void 0!==r.registeredClass.constructor_body[e-1])throw new wr(`Cannot register multiple constructors with identical number of parameters (${e-1}) for class '${r.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return r.registeredClass.constructor_body[e-1]=()=>{re(`Cannot construct ${r.name} due to unbound types`,i)},kr([],i,n=>(n.splice(1,0,null),r.registeredClass.constructor_body[e-1]=te(t,n,null,o,a),[])),[]})},a:(r,e,t,n,o,a,i,s,l,u)=>{var d=ee(t,n);e=$r(e),e=ne(e),a=Jr(o,a),kr([],[r],r=>{var n=`${(r=r[0]).name}.${e}`;function o(){re(`Cannot call ${n} due to unbound types`,d)}e.startsWith("@@")&&(e=Symbol[e.substring(2)]),s&&r.registeredClass.pureVirtualFunctions.push(e);var l=r.registeredClass.instancePrototype,u=l[e];return void 0===u||void 0===u.overloadTable&&u.className!==r.name&&u.argCount===t-2?(o.argCount=t-2,o.className=r.name,l[e]=o):(zr(l,e,n),l[e].overloadTable[t-2]=o),kr([],d,o=>{var s=te(n,o,r,a,i);return void 0===l[e].overloadTable?(s.argCount=t-2,l[e]=s):l[e].overloadTable[t-2]=s,[]}),[]})},d:(r,e,t)=>{r=$r(r),kr([],[e],e=>(e=e[0],o[r]=e.fromWireType(t),[]))},_:r=>Pr(r,le),i:(r,e,t,n)=>{function o(){}e=$r(e),o.values={},Pr(r,{name:e,constructor:o,fromWireType:function(r){return this.constructor.values[r]},toWireType:(r,e)=>e.value,argPackAdvance:8,readValueFromPointer:ue(e,t,n),destructorFunction:null}),Ur(e,o)},b:(r,e,t)=>{var n=de(r,"enum");e=$r(e);var o=n.constructor,a=Object.create(n.constructor.prototype,{value:{value:t},constructor:{value:Wr(`${n.name}_${e}`,function(){})}});o.values[t]=a,o[e]=a},D:(r,e,t)=>{Pr(r,{name:e=$r(e),fromWireType:r=>r,toWireType:(r,e)=>e,argPackAdvance:8,readValueFromPointer:he(e,t),destructorFunction:null})},f:(r,e,t,n,o,a,i,s)=>{var l=ee(e,t);r=$r(r),r=ne(r),o=Jr(n,o),Ur(r,function(){re(`Cannot call ${r} due to unbound types`,l)},e-1),kr([],l,t=>{var n=[t[0],null].concat(t.slice(1));return Kr(r,te(r,n,null,o,a),e-1),[]})},j:(r,e,t,n,o)=>{e=$r(e);var a=r=>r;if(0===n){var i=32-8*t;a=r=>r<<i>>>i}var s=e.includes("unsigned");Pr(r,{name:e,fromWireType:a,toWireType:s?function(r,e){return this.name,e>>>0}:function(r,e){return this.name,e},argPackAdvance:8,readValueFromPointer:fe(e,t,0!==n),destructorFunction:null})},g:(r,e,t)=>{var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];function o(r){var e=b[r>>2],t=b[r+4>>2];return new n(v.buffer,t,e)}Pr(r,{name:t=$r(t),fromWireType:o,argPackAdvance:8,readValueFromPointer:o},{ignoreDuplicateRegistrations:!0})},$:(r,e)=>{Pr(r,{name:e=$r(e),fromWireType(r){for(var e,t=b[r>>2],n=r+4,o=n,a=0;a<=t;++a){var i=n+a;if(a==t||0==y[i]){var s=cr(o,i-o);void 0===e?e=s:(e+=String.fromCharCode(0),e+=s),o=i+1}}return Ne(r),e},toWireType(r,e){var t;e instanceof ArrayBuffer&&(e=new Uint8Array(e));var n="string"==typeof e;n||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int8Array||Cr("Cannot pass non-string to std::string"),t=n?rr(e):e.length;var o=We(4+t+1),a=o+4;if(b[o>>2]=t,n)pe(e,a,t+1);else if(n)for(var i=0;i<t;++i){var s=e.charCodeAt(i);s>255&&(Ne(a),Cr("String has UTF-16 code units that do not fit in 8 bits")),y[a+i]=s}else for(i=0;i<t;++i)y[a+i]=e[i];return null!==r&&r.push(Ne,o),o},argPackAdvance:8,readValueFromPointer:mr,destructorFunction(r){Ne(r)}})},y:(r,e,t)=>{var n,o,a,i;t=$r(t),2===e?(n=ve,o=ye,i=we,a=r=>g[r>>1]):4===e&&(n=ge,o=Ee,i=be,a=r=>b[r>>2]),Pr(r,{name:t,fromWireType:r=>{for(var t,o=b[r>>2],i=r+4,s=0;s<=o;++s){var l=r+4+s*e;if(s==o||0==a(l)){var u=n(i,l-i);void 0===t?t=u:(t+=String.fromCharCode(0),t+=u),i=l+e}}return Ne(r),t},toWireType:(r,n)=>{"string"!=typeof n&&Cr(`Cannot pass non-string to C++ string type ${t}`);var a=i(n),s=We(4+a+e);return b[s>>2]=a/e,o(n,s+4,a+e),null!==r&&r.push(Ne,s),s},argPackAdvance:8,readValueFromPointer:mr,destructorFunction(r){Ne(r)}})},t:(r,e,t,n,o,a)=>{fr[r]={name:$r(e),rawConstructor:Jr(t,n),rawDestructor:Jr(o,a),fields:[]}},c:(r,e,t,n,o,a,i,s,l,u)=>{fr[r].fields.push({fieldName:$r(e),getterReturnType:t,getter:Jr(n,o),getterContext:a,setterArgumentType:i,setter:Jr(s,l),setterContext:u})},ba:(r,e)=>{Pr(r,{isVoid:!0,name:e=$r(e),argPackAdvance:0,fromWireType:()=>{},toWireType:(r,e)=>{}})},V:(r,e,t)=>y.copyWithin(r,e,e+t),N:()=>{throw 1/0},o:(r,e,t)=>(r=se.toValue(r),e=de(e,"emval::as"),_e(e,t,r)),k:(r,e,t,n,o)=>(r=Ce[r])(e=se.toValue(e),e[t=$e(t)],n,o),e:ie,l:(r,e,t)=>{var n=((r,e)=>{for(var t=new Array(r),n=0;n<r;++n)t[n]=de(b[e+4*n>>2],"parameter "+n);return t})(r,e),o=n.shift();r--;var a=new Array(r),i=`methodCaller<(${n.map(r=>r.name).join(", ")}) => ${o.name}>`;return(r=>{var e=Ce.length;return Ce.push(r),e})(Wr(i,(e,i,s,l)=>{for(var u=0,d=0;d<r;++d)a[d]=n[d].readValueFromPointer(l+u),u+=n[d].argPackAdvance;var c=1===t?Pe(i,a):i.apply(e,a);return _e(o,s,c)}))},p:(r,e)=>(r=se.toValue(r),e=se.toValue(e),se.toHandle(r[e])),m:r=>{r>9&&(ae[r+1]+=1)},q:r=>se.toHandle($e(r)),h:r=>{var e=se.toValue(r);pr(e),ie(r)},n:(r,e)=>{var t=(r=de(r,"_emval_take_value")).readValueFromPointer(e);return se.toHandle(t)},E:function(r,e,t,n,o,a,i,s){var l=Te(o,a);try{if(isNaN(l))return 61;var u=hr.getStreamFromFD(n),d=dr.mmap(u,r,l,e,t),c=d.ptr;return E[i>>2]=d.allocated,b[s>>2]=c,0}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},F:function(r,e,t,n,o,a,i){var s=Te(a,i);try{var l=hr.getStreamFromFD(o);2&t&&hr.doMsync(r,l,e,n,s)}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return-r.errno}},K:(r,e,t,n)=>{var o=(new Date).getFullYear(),a=new Date(o,0,1),i=new Date(o,6,1),s=a.getTimezoneOffset(),l=i.getTimezoneOffset(),u=Math.max(s,l);b[r>>2]=60*u,E[e>>2]=Number(s!=l);var d=r=>{var e=r>=0?"-":"+",t=Math.abs(r);return`UTC${e}${String(Math.floor(t/60)).padStart(2,"0")}${String(t%60).padStart(2,"0")}`},c=d(s),h=d(l);l<s?(pe(c,t,17),pe(h,n,17)):(pe(c,n,17),pe(h,t,17))},H:function(r,e,t,n){if(!(r=>r>=0&&r<=3)(r))return 28;var o;o=0===r?Se():Ae();var a=Math.round(1e3*o*1e3);return z=[a>>>0,(W=a,+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[n>>2]=z[0],E[n+4>>2]=z[1],0},U:Se,J:()=>2147483648,z:Ae,O:r=>{var e=y.length,t=2147483648;if((r>>>=0)>t)return!1;for(var n=1;n<=4;n*=2){var o=e*(1+.2/n);o=Math.min(o,r+100663296);var a=Math.min(t,or(Math.max(r,o),65536));if(De(a))return!0}return!1},L:(r,e)=>{var t=0;return je().forEach((n,o)=>{var a=e+t;b[r+4*o>>2]=a,((r,e)=>{for(var t=0;t<r.length;++t)v[e++]=r.charCodeAt(t);v[e]=0})(n,a),t+=n.length+1}),0},M:(r,e)=>{var t=je();b[r>>2]=t.length;var n=0;return t.forEach(r=>n+=r.length+1),b[e>>2]=n,0},x:function(r){try{var e=hr.getStreamFromFD(r);return dr.close(e),0}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return r.errno}},S:function(r,e,t,n){try{var o=((r,e,t)=>{for(var n=0,o=0;o<t;o++){var a=b[e>>2],i=b[e+4>>2];e+=8;var s=dr.read(r,v,a,i,void 0);if(s<0)return-1;if(n+=s,s<i)break}return n})(hr.getStreamFromFD(r),e,t);return b[n>>2]=o,0}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return r.errno}},G:function(r,e,t,n,o){var a=Te(e,t);try{if(isNaN(a))return 61;var i=hr.getStreamFromFD(r);return dr.llseek(i,a,n),z=[i.position>>>0,(W=i.position,+Math.abs(W)>=1?W>0?+Math.floor(W/4294967296)>>>0:~~+Math.ceil((W-+(~~W>>>0))/4294967296)>>>0:0)],E[o>>2]=z[0],E[o+4>>2]=z[1],i.getdents&&0===a&&0===n&&(i.getdents=null),0}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return r.errno}},A:function(r,e,t,n){try{var o=((r,e,t)=>{for(var n=0,o=0;o<t;o++){var a=b[e>>2],i=b[e+4>>2];e+=8;var s=dr.write(r,v,a,i,void 0);if(s<0)return-1;if(n+=s,s<i)break}return n})(hr.getStreamFromFD(r),e,t);return b[n>>2]=o,0}catch(r){if(void 0===dr||"ErrnoError"!==r.name)throw r;return r.errno}},Y:function(r,e){var t=I();try{return Zr(r)(e)}catch(r){if(H(t),r!==r+0)throw r;Ue(1,0)}},r:function(r,e){var t=I();try{Zr(r)(e)}catch(r){if(H(t),r!==r+0)throw r;Ue(1,0)}},X:function(r,e,t){var n=I();try{Zr(r)(e,t)}catch(r){if(H(n),r!==r+0)throw r;Ue(1,0)}},Z:function(r,e,t,n){var o=I();try{Zr(r)(e,t,n)}catch(r){if(H(o),r!==r+0)throw r;Ue(1,0)}}};!async function(){function r(r,e){return Me=r.exports,m=Me.ca,P(),Gr=Me.ga,function(r){A.unshift(r)}(Me.da),x(),Me}R();var e={a:Re};if(o.instantiateWasm)try{return o.instantiateWasm(e,r)}catch(r){p(`Module.instantiateWasm callback failed with error: ${r}`),t(r)}N??=function(){var r="basis_encoder.wasm";return U(r)?r:function(r){return o.locateFile?o.locateFile(r,h):h+r}(r)}();try{var n=await B($,N,e);return function(e){r(e.instance)}(n),n}catch(r){return void t(r)}}();var xe,Oe=r=>(Oe=Me.ea)(r),Ne=r=>(Ne=Me.fa)(r),We=r=>(We=Me.ha)(r),ze=(r,e)=>(ze=Me.ia)(r,e),Ue=(r,e)=>(Ue=Me.ja)(r,e),Be=r=>(Be=Me.ka)(r),Le=()=>(Le=Me.la)();function He(){function r(){xe||(xe=!0,o.calledRun=!0,C||(o.noFSInit||dr.initialized||dr.init(),dr.ignorePermissions=!1,L(A),e(o),o.onRuntimeInitialized?.(),function(){if(o.postRun)for("function"==typeof o.postRun&&(o.postRun=[o.postRun]);o.postRun.length;)F(o.postRun.shift());L(S)}()))}j>0||(function(){if(o.preRun)for("function"==typeof o.preRun&&(o.preRun=[o.preRun]);o.preRun.length;)D(o.preRun.shift());L(T)}(),j>0||(o.setStatus?(o.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>o.setStatus(""),1),r()},1)):r()))}if(o.dynCall_ji=(r,e)=>(o.dynCall_ji=Me.ma)(r,e),o.dynCall_iij=(r,e,t,n)=>(o.dynCall_iij=Me.na)(r,e,t,n),o.dynCall_jiiii=(r,e,t,n,a)=>(o.dynCall_jiiii=Me.oa)(r,e,t,n,a),o.dynCall_jiji=(r,e,t,n,a)=>(o.dynCall_jiji=Me.pa)(r,e,t,n,a),o.dynCall_viijii=(r,e,t,n,a,i,s)=>(o.dynCall_viijii=Me.qa)(r,e,t,n,a,i,s),o.dynCall_iiiiij=(r,e,t,n,a,i,s)=>(o.dynCall_iiiiij=Me.ra)(r,e,t,n,a,i,s),o.dynCall_iiiiijj=(r,e,t,n,a,i,s,l,u)=>(o.dynCall_iiiiijj=Me.sa)(r,e,t,n,a,i,s,l,u),o.dynCall_iiiiiijj=(r,e,t,n,a,i,s,l,u,d)=>(o.dynCall_iiiiiijj=Me.ta)(r,e,t,n,a,i,s,l,u,d),M=function r(){xe||He(),xe||(M=r)},o.preInit)for("function"==typeof o.preInit&&(o.preInit=[o.preInit]);o.preInit.length>0;)o.preInit.pop()();return He(),a})}}]);
|