@map-colonies/react-components 3.15.1 → 4.0.1
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/dist/@map-colonies/react-components.es.js +3662 -0
- package/dist/@map-colonies/react-components.umd.js +24 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_0.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_1.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_10.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_11.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_12.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_13.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_14.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_15.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_16.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_17.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_18.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_19.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_2.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_20.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_21.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_22.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_23.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_24.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_25.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_26.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_27.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_3.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_4.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_5.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_6.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_7.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_8.json +1 -0
- package/dist/Cesium/Assets/IAU2006_XYS/IAU2006_XYS_9.json +1 -0
- package/dist/Cesium/Assets/Images/bing_maps_credit.png +0 -0
- package/dist/Cesium/Assets/Images/cesium_credit.png +0 -0
- package/dist/Cesium/Assets/Images/google_earth_credit.png +0 -0
- package/dist/Cesium/Assets/Images/ion-credit.png +0 -0
- package/dist/Cesium/Assets/Textures/LensFlare/DirtMask.jpg +0 -0
- package/dist/Cesium/Assets/Textures/LensFlare/StarBurst.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/0/0/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/0/1/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/0/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/0/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/1/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/1/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/2/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/2/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/3/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/1/3/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/0/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/0/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/0/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/0/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/1/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/1/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/1/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/1/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/2/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/2/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/2/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/2/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/3/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/3/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/3/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/3/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/4/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/4/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/4/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/4/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/5/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/5/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/5/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/5/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/6/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/6/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/6/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/6/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/7/0.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/7/1.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/7/2.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/2/7/3.jpg +0 -0
- package/dist/Cesium/Assets/Textures/NaturalEarthII/tilemapresource.xml +14 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_mx.jpg +0 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_my.jpg +0 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_mz.jpg +0 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_px.jpg +0 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_py.jpg +0 -0
- package/dist/Cesium/Assets/Textures/SkyBox/tycho2t3_80_pz.jpg +0 -0
- package/dist/Cesium/Assets/Textures/maki/airfield.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/airport.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/alcohol-shop.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/america-football.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/art-gallery.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/bakery.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/bank.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/bar.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/baseball.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/basketball.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/beer.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/bicycle.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/building.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/bus.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cafe.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/camera.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/campsite.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/car.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cemetery.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cesium.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/chemist.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cinema.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/circle-stroked.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/circle.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/city.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/clothing-store.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/college.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/commercial.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cricket.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/cross.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/dam.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/danger.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/disability.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/dog-park.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/embassy.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/emergency-telephone.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/entrance.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/farm.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/fast-food.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/ferry.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/fire-station.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/fuel.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/garden.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/gift.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/golf.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/grocery.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/hairdresser.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/harbor.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/heart.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/heliport.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/hospital.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/ice-cream.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/industrial.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/land-use.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/laundry.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/library.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/lighthouse.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/lodging.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/logging.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/london-underground.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/marker-stroked.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/marker.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/minefield.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/mobilephone.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/monument.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/museum.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/music.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/oil-well.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/park.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/park2.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/parking-garage.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/parking.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/pharmacy.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/pitch.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/place-of-worship.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/playground.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/police.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/polling-place.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/post.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/prison.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rail-above.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rail-light.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rail-metro.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rail-underground.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rail.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/religious-christian.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/religious-jewish.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/religious-muslim.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/restaurant.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/roadblock.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/rocket.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/school.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/scooter.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/shop.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/skiing.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/slaughterhouse.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/soccer.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/square-stroked.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/square.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/star-stroked.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/star.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/suitcase.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/swimming.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/telephone.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/tennis.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/theatre.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/toilets.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/town-hall.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/town.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/triangle-stroked.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/triangle.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/village.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/warehouse.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/waste-basket.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/water.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/wetland.png +0 -0
- package/dist/Cesium/Assets/Textures/maki/zoo.png +0 -0
- package/dist/Cesium/Assets/Textures/moonSmall.jpg +0 -0
- package/dist/Cesium/Assets/Textures/pin.svg +1 -0
- package/dist/Cesium/Assets/Textures/waterNormals.jpg +0 -0
- package/dist/Cesium/Assets/Textures/waterNormalsSmall.jpg +0 -0
- package/dist/Cesium/Assets/approximateTerrainHeights.json +1 -0
- package/dist/Cesium/Cesium.js +14464 -0
- package/dist/Cesium/ThirdParty/Workers/basis_transcoder.js +31 -0
- package/dist/Cesium/ThirdParty/Workers/draco_decoder_nodejs.js +1 -0
- package/dist/Cesium/ThirdParty/Workers/package.js +1 -0
- package/dist/Cesium/ThirdParty/Workers/package.json +1 -0
- package/dist/Cesium/ThirdParty/Workers/pako_deflate.min.js +1 -0
- package/dist/Cesium/ThirdParty/Workers/pako_inflate.min.js +1 -0
- package/dist/Cesium/ThirdParty/Workers/z-worker-pako.js +1 -0
- package/dist/Cesium/ThirdParty/basis_transcoder.wasm +0 -0
- package/dist/Cesium/ThirdParty/draco_decoder.wasm +0 -0
- package/dist/Cesium/ThirdParty/google-earth-dbroot-parser.js +1 -0
- package/dist/Cesium/Widgets/Animation/Animation.css +127 -0
- package/dist/Cesium/Widgets/Animation/lighter.css +70 -0
- package/dist/Cesium/Widgets/BaseLayerPicker/BaseLayerPicker.css +108 -0
- package/dist/Cesium/Widgets/BaseLayerPicker/lighter.css +22 -0
- package/dist/Cesium/Widgets/Cesium3DTilesInspector/Cesium3DTilesInspector.css +102 -0
- package/dist/Cesium/Widgets/CesiumInspector/CesiumInspector.css +113 -0
- package/dist/Cesium/Widgets/CesiumWidget/CesiumWidget.css +124 -0
- package/dist/Cesium/Widgets/CesiumWidget/lighter.css +14 -0
- package/dist/Cesium/Widgets/FullscreenButton/FullscreenButton.css +8 -0
- package/dist/Cesium/Widgets/Geocoder/Geocoder.css +70 -0
- package/dist/Cesium/Widgets/Geocoder/lighter.css +17 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/bingAerial.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/bingAerialLabels.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/bingRoads.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/blueMarble.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/earthAtNight.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/esriNationalGeographic.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/esriWorldImagery.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/esriWorldStreetMap.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/mapQuestOpenStreetMap.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/mapboxSatellite.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/mapboxStreets.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/mapboxTerrain.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/naturalEarthII.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/openStreetMap.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/sentinel-2.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/stamenToner.png +0 -0
- package/dist/Cesium/Widgets/Images/ImageryProviders/stamenWatercolor.png +0 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/Mouse.svg +84 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/MouseLeft.svg +76 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/MouseMiddle.svg +76 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/MouseRight.svg +76 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/Touch.svg +120 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/TouchDrag.svg +129 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/TouchRotate.svg +76 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/TouchTilt.svg +135 -0
- package/dist/Cesium/Widgets/Images/NavigationHelp/TouchZoom.svg +74 -0
- package/dist/Cesium/Widgets/Images/TerrainProviders/CesiumWorldTerrain.png +0 -0
- package/dist/Cesium/Widgets/Images/TerrainProviders/Ellipsoid.png +0 -0
- package/dist/Cesium/Widgets/Images/TimelineIcons.png +0 -0
- package/dist/Cesium/Widgets/Images/info-loading.gif +0 -0
- package/dist/Cesium/Widgets/InfoBox/InfoBox.css +92 -0
- package/dist/Cesium/Widgets/InfoBox/InfoBoxDescription.css +178 -0
- package/dist/Cesium/Widgets/NavigationHelpButton/NavigationHelpButton.css +93 -0
- package/dist/Cesium/Widgets/NavigationHelpButton/lighter.css +38 -0
- package/dist/Cesium/Widgets/PerformanceWatchdog/PerformanceWatchdog.css +15 -0
- package/dist/Cesium/Widgets/ProjectionPicker/ProjectionPicker.css +38 -0
- package/dist/Cesium/Widgets/SceneModePicker/SceneModePicker.css +56 -0
- package/dist/Cesium/Widgets/SelectionIndicator/SelectionIndicator.css +20 -0
- package/dist/Cesium/Widgets/Timeline/Timeline.css +96 -0
- package/dist/Cesium/Widgets/Timeline/lighter.css +18 -0
- package/dist/Cesium/Widgets/VRButton/VRButton.css +8 -0
- package/dist/Cesium/Widgets/Viewer/Viewer.css +107 -0
- package/dist/Cesium/Widgets/VoxelInspector/VoxelInspector.css +16 -0
- package/dist/Cesium/Widgets/lighter.css +232 -0
- package/dist/Cesium/Widgets/lighterShared.css +46 -0
- package/dist/Cesium/Widgets/shared.css +103 -0
- package/dist/Cesium/Widgets/widgets.css +1311 -0
- package/dist/Cesium/Workers/ArcType-26a3f38d.js +1 -0
- package/dist/Cesium/Workers/AttributeCompression-48e336db.js +1 -0
- package/dist/Cesium/Workers/AxisAlignedBoundingBox-39ab50d0.js +1 -0
- package/dist/Cesium/Workers/BoundingRectangle-2379df5a.js +1 -0
- package/dist/Cesium/Workers/BoxGeometry-61fa3148.js +1 -0
- package/dist/Cesium/Workers/Color-7d827393.js +1 -0
- package/dist/Cesium/Workers/ComponentDatatype-ab629b88.js +1 -0
- package/dist/Cesium/Workers/CoplanarPolygonGeometryLibrary-9cff5a6c.js +1 -0
- package/dist/Cesium/Workers/CorridorGeometryLibrary-28996bf3.js +1 -0
- package/dist/Cesium/Workers/CylinderGeometry-966ff1e5.js +1 -0
- package/dist/Cesium/Workers/CylinderGeometryLibrary-f49f33a8.js +1 -0
- package/dist/Cesium/Workers/EllipseGeometry-fddb3596.js +1 -0
- package/dist/Cesium/Workers/EllipseGeometryLibrary-08d055cc.js +1 -0
- package/dist/Cesium/Workers/EllipseOutlineGeometry-a72d7da8.js +1 -0
- package/dist/Cesium/Workers/EllipsoidGeodesic-2723ab86.js +1 -0
- package/dist/Cesium/Workers/EllipsoidGeometry-fd18adbd.js +1 -0
- package/dist/Cesium/Workers/EllipsoidOutlineGeometry-d9d02643.js +1 -0
- package/dist/Cesium/Workers/EllipsoidRhumbLine-77eff028.js +1 -0
- package/dist/Cesium/Workers/EllipsoidTangentPlane-82f2a887.js +1 -0
- package/dist/Cesium/Workers/EncodedCartesian3-5e2017ab.js +1 -0
- package/dist/Cesium/Workers/FrustumGeometry-9378eccf.js +1 -0
- package/dist/Cesium/Workers/GeometryAttribute-81ff775c.js +1 -0
- package/dist/Cesium/Workers/GeometryAttributes-1e4ddcd2.js +1 -0
- package/dist/Cesium/Workers/GeometryInstance-0318e0cd.js +1 -0
- package/dist/Cesium/Workers/GeometryOffsetAttribute-2579b8d2.js +1 -0
- package/dist/Cesium/Workers/GeometryPipeline-e049e700.js +1 -0
- package/dist/Cesium/Workers/IndexDatatype-d3db4e7d.js +1 -0
- package/dist/Cesium/Workers/IntersectionTests-357c3d7f.js +1 -0
- package/dist/Cesium/Workers/Math-2ce22ee9.js +1 -0
- package/dist/Cesium/Workers/Matrix2-413c4048.js +1 -0
- package/dist/Cesium/Workers/Matrix3-81054f0f.js +1 -0
- package/dist/Cesium/Workers/OrientedBoundingBox-cfd17917.js +1 -0
- package/dist/Cesium/Workers/Plane-6add0ae1.js +1 -0
- package/dist/Cesium/Workers/PolygonGeometryLibrary-003d1689.js +1 -0
- package/dist/Cesium/Workers/PolygonPipeline-61ca1579.js +1 -0
- package/dist/Cesium/Workers/PolylinePipeline-8495667b.js +1 -0
- package/dist/Cesium/Workers/PolylineVolumeGeometryLibrary-2df3f067.js +1 -0
- package/dist/Cesium/Workers/PrimitivePipeline-8033b34b.js +1 -0
- package/dist/Cesium/Workers/RectangleGeometryLibrary-a0a06d23.js +1 -0
- package/dist/Cesium/Workers/RuntimeError-9b4ce3fb.js +1 -0
- package/dist/Cesium/Workers/TerrainEncoding-bd5c9ed5.js +1 -0
- package/dist/Cesium/Workers/Transforms-fce95115.js +14 -0
- package/dist/Cesium/Workers/VertexFormat-fbdec922.js +1 -0
- package/dist/Cesium/Workers/WallGeometryLibrary-1c767084.js +1 -0
- package/dist/Cesium/Workers/WebGLConstants-7f557f93.js +1 -0
- package/dist/Cesium/Workers/WebMercatorProjection-943e2226.js +1 -0
- package/dist/Cesium/Workers/arrayRemoveDuplicates-9b636830.js +1 -0
- package/dist/Cesium/Workers/cesiumWorkerBootstrapper.js +31 -0
- package/dist/Cesium/Workers/combine-0c102d93.js +1 -0
- package/dist/Cesium/Workers/combineGeometry.js +1 -0
- package/dist/Cesium/Workers/createBoxGeometry.js +1 -0
- package/dist/Cesium/Workers/createBoxOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createCircleGeometry.js +1 -0
- package/dist/Cesium/Workers/createCircleOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createCoplanarPolygonGeometry.js +1 -0
- package/dist/Cesium/Workers/createCoplanarPolygonOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createCorridorGeometry.js +1 -0
- package/dist/Cesium/Workers/createCorridorOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createCylinderGeometry.js +1 -0
- package/dist/Cesium/Workers/createCylinderOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createEllipseGeometry.js +1 -0
- package/dist/Cesium/Workers/createEllipseOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createEllipsoidGeometry.js +1 -0
- package/dist/Cesium/Workers/createEllipsoidOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createFrustumGeometry.js +1 -0
- package/dist/Cesium/Workers/createFrustumOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createGeometry.js +1 -0
- package/dist/Cesium/Workers/createGroundPolylineGeometry.js +1 -0
- package/dist/Cesium/Workers/createPlaneGeometry.js +1 -0
- package/dist/Cesium/Workers/createPlaneOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createPolygonGeometry.js +1 -0
- package/dist/Cesium/Workers/createPolygonOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createPolylineGeometry.js +1 -0
- package/dist/Cesium/Workers/createPolylineVolumeGeometry.js +1 -0
- package/dist/Cesium/Workers/createPolylineVolumeOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createRectangleGeometry.js +1 -0
- package/dist/Cesium/Workers/createRectangleOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createSimplePolylineGeometry.js +1 -0
- package/dist/Cesium/Workers/createSphereGeometry.js +1 -0
- package/dist/Cesium/Workers/createSphereOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/createTaskProcessorWorker.js +1 -0
- package/dist/Cesium/Workers/createVectorTileClampedPolylines.js +1 -0
- package/dist/Cesium/Workers/createVectorTileGeometries.js +1 -0
- package/dist/Cesium/Workers/createVectorTilePoints.js +1 -0
- package/dist/Cesium/Workers/createVectorTilePolygons.js +1 -0
- package/dist/Cesium/Workers/createVectorTilePolylines.js +1 -0
- package/dist/Cesium/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +1 -0
- package/dist/Cesium/Workers/createVerticesFromHeightmap.js +3 -0
- package/dist/Cesium/Workers/createVerticesFromQuantizedTerrainMesh.js +1 -0
- package/dist/Cesium/Workers/createWallGeometry.js +1 -0
- package/dist/Cesium/Workers/createWallOutlineGeometry.js +1 -0
- package/dist/Cesium/Workers/decodeDraco.js +1 -0
- package/dist/Cesium/Workers/decodeGoogleEarthEnterprisePacket.js +1 -0
- package/dist/Cesium/Workers/decodeI3S.js +1 -0
- package/dist/Cesium/Workers/defaultValue-f6d5e6da.js +1 -0
- package/dist/Cesium/Workers/package.js +26 -0
- package/dist/Cesium/Workers/transcodeKTX2.js +1 -0
- package/dist/Cesium/Workers/transferTypedArrayTest.js +26 -0
- package/dist/Cesium/Workers/upsampleQuantizedTerrainMesh.js +1 -0
- package/dist/Cesium/index.cjs +14464 -0
- package/dist/Cesium/index.js +14464 -0
- package/dist/autocomplete/autocomplete.d.ts +32 -33
- package/dist/autocomplete/index.d.ts +1 -1
- package/dist/box/box.d.ts +3 -3
- package/dist/box/index.d.ts +1 -1
- package/dist/cesium-map/data-sources/custom.data-source.d.ts +5 -5
- package/dist/cesium-map/data-sources/drawings.data-source.d.ts +34 -34
- package/dist/cesium-map/data-sources/index.d.ts +2 -2
- package/dist/cesium-map/entities/entity.d.ts +5 -5
- package/dist/cesium-map/entities/entity.description.d.ts +8 -6
- package/dist/cesium-map/entities/graphics/polygon.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/graphics/polyline.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/graphics/rectangle.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/index.d.ts +4 -4
- package/dist/cesium-map/helpers/customImageryProviders.d.ts +34 -34
- package/dist/cesium-map/helpers/utils.d.ts +17 -17
- package/dist/cesium-map/index.d.ts +8 -8
- package/dist/cesium-map/layers/3d.tileset.d.ts +7 -7
- package/dist/cesium-map/layers/geojson.layer.d.ts +5 -5
- package/dist/cesium-map/layers/imagery.layer.d.ts +6 -6
- package/dist/cesium-map/layers/index.d.ts +7 -7
- package/dist/cesium-map/layers/osm.layer.d.ts +9 -9
- package/dist/cesium-map/layers/wms.layer.d.ts +9 -9
- package/dist/cesium-map/layers/wmts.layer.d.ts +9 -9
- package/dist/cesium-map/layers/xyz.layer.d.ts +9 -9
- package/dist/cesium-map/layers-manager.d.ts +59 -59
- package/dist/cesium-map/map-legend/MapLegend.d.ts +14 -15
- package/dist/cesium-map/map-legend/MapLegendList.d.ts +12 -13
- package/dist/cesium-map/map-legend/MapLegendSidebar.d.ts +15 -16
- package/dist/cesium-map/map-legend/MapLegendToggle.d.ts +6 -7
- package/dist/cesium-map/map-legend/index.d.ts +3 -3
- package/dist/cesium-map/map.d.ts +69 -68
- package/dist/cesium-map/map.types.d.ts +8 -8
- package/dist/cesium-map/proxied.types.d.ts +30 -30
- package/dist/cesium-map/settings/base-maps.d.ts +6 -7
- package/dist/cesium-map/settings/scene-modes.d.ts +6 -7
- package/dist/cesium-map/settings/settings.d.ts +22 -23
- package/dist/cesium-map/tools/cesium/primitives-conversions.cesium.d.ts +2 -2
- package/dist/cesium-map/tools/coordinates-tracker.tool.d.ts +6 -7
- package/dist/cesium-map/tools/draw/drawHelper.d.ts +27 -28
- package/dist/cesium-map/tools/geojson/geojson-to-primitive.d.ts +4 -4
- package/dist/cesium-map/tools/geojson/index.d.ts +2 -2
- package/dist/cesium-map/tools/geojson/point.geojson.d.ts +7 -7
- package/dist/cesium-map/tools/geojson/polygon.geojson.d.ts +3 -3
- package/dist/cesium-map/tools/geojson/rectangle.geojson.d.ts +3 -3
- package/dist/cesium-map/tools/scale-tracker.tool.d.ts +7 -8
- package/dist/cesium-map/tools/zoom_level-tracker.tool.d.ts +7 -8
- package/dist/cssbaseline/cssbaseline.d.ts +5 -5
- package/dist/cssbaseline/index.d.ts +1 -1
- package/dist/date-picker/date-picker.d.ts +12 -14
- package/dist/date-picker/index.d.ts +1 -1
- package/dist/date-range-picker/date-range-picker.d.ts +24 -26
- package/dist/date-range-picker/date-range-picker.form-control.d.ts +26 -28
- package/dist/date-range-picker/index.d.ts +2 -2
- package/dist/file-picker/file-picker.d.ts +275 -276
- package/dist/file-picker/index.d.ts +2 -2
- package/dist/file-picker/localization.d.ts +11 -11
- package/dist/fonts/material-icons/MaterialIcons-Regular.eot +0 -0
- package/dist/fonts/material-icons/MaterialIcons-Regular.ijmap +1 -0
- package/dist/fonts/material-icons/MaterialIcons-Regular.svg +2373 -0
- package/dist/fonts/material-icons/MaterialIcons-Regular.ttf +0 -0
- package/dist/fonts/material-icons/MaterialIcons-Regular.woff +0 -0
- package/dist/fonts/material-icons/MaterialIcons-Regular.woff2 +0 -0
- package/dist/fonts/material-icons/README.md +9 -0
- package/dist/fonts/material-icons/codepoints +932 -0
- package/dist/fonts/material-icons/material-icons.css +36 -0
- package/dist/index.d.ts +12 -13
- package/dist/map-filter-container/container-map.d.ts +10 -11
- package/dist/map-filter-container/index.d.ts +1 -1
- package/dist/map-filter-container/map-filter-container.d.ts +9 -9
- package/dist/map-filter-container/polygon-selection-ui.d.ts +9 -12
- package/dist/models/defaults.d.ts +28 -28
- package/dist/models/enums.d.ts +14 -14
- package/dist/models/index.d.ts +1 -1
- package/dist/ol-map/feature.d.ts +6 -6
- package/dist/ol-map/interactions/draw.d.ts +8 -8
- package/dist/ol-map/layers/tile-layer.d.ts +9 -9
- package/dist/ol-map/layers/vector-layer.d.ts +4 -4
- package/dist/ol-map/map.d.ts +12 -14
- package/dist/ol-map/source/osm.d.ts +2 -2
- package/dist/ol-map/source/vector-source.d.ts +4 -4
- package/dist/popover/index.d.ts +1 -1
- package/dist/popover/popover.d.ts +3 -3
- package/dist/smart-table/index.d.ts +2 -2
- package/dist/smart-table/smart-table-head.d.ts +11 -11
- package/dist/smart-table/smart-table-row.d.ts +13 -12
- package/dist/smart-table/smart-table-types.d.ts +9 -9
- package/dist/smart-table/smart-table.d.ts +17 -17
- package/dist/theme/index.d.ts +1 -1
- package/dist/theme/theme.d.ts +9 -8
- package/dist/utils/map.d.ts +3 -3
- package/dist/utils/projections.d.ts +6 -6
- package/package.json +41 -71
- package/.env +0 -1
- package/.eslintignore +0 -2
- package/.storybook/main.js +0 -13
- package/.storybook/manager.js +0 -6
- package/.storybook/preview-head.html +0 -21
- package/.storybook/preview.js +0 -18
- package/.storybook/theme.js +0 -9
- package/CHANGELOG.md +0 -909
- package/README.md +0 -53
- package/dist/assets/img/dragIcon.png +0 -0
- package/dist/assets/img/dragIconLight.png +0 -0
- package/dist/assets/img/glyphicons_067_cleaning.png +0 -0
- package/dist/assets/img/glyphicons_094_vector_path_square.png +0 -0
- package/dist/assets/img/glyphicons_095_vector_path_circle.png +0 -0
- package/dist/assets/img/glyphicons_096_vector_path_polygon.png +0 -0
- package/dist/assets/img/glyphicons_097_vector_path_line.png +0 -0
- package/dist/assets/img/glyphicons_242_google_maps.png +0 -0
- package/dist/assets/img/map-marker.gif +0 -0
- package/dist/assets/img/transparent-tile.png +0 -0
- package/dist/autocomplete/autocomplete.js +0 -478
- package/dist/autocomplete/index.js +0 -5
- package/dist/box/box.js +0 -35
- package/dist/box/index.js +0 -5
- package/dist/cesium-map/data-sources/custom.data-source.js +0 -23
- package/dist/cesium-map/data-sources/drawings.data-source.js +0 -193
- package/dist/cesium-map/data-sources/index.js +0 -14
- package/dist/cesium-map/entities/entity.description.js +0 -27
- package/dist/cesium-map/entities/entity.js +0 -23
- package/dist/cesium-map/entities/graphics/polygon.graphics.js +0 -23
- package/dist/cesium-map/entities/graphics/polyline.graphics.js +0 -23
- package/dist/cesium-map/entities/graphics/rectangle.graphics.js +0 -23
- package/dist/cesium-map/entities/index.js +0 -16
- package/dist/cesium-map/helpers/customImageryProviders.js +0 -106
- package/dist/cesium-map/helpers/utils.js +0 -142
- package/dist/cesium-map/index.js +0 -20
- package/dist/cesium-map/layers/3d.tileset.js +0 -43
- package/dist/cesium-map/layers/3d.tileset.with.update.d.ts +0 -6
- package/dist/cesium-map/layers/3d.tileset.with.update.js +0 -115
- package/dist/cesium-map/layers/geojson.layer.js +0 -23
- package/dist/cesium-map/layers/imagery.layer.js +0 -68
- package/dist/cesium-map/layers/index.js +0 -19
- package/dist/cesium-map/layers/osm.layer.js +0 -36
- package/dist/cesium-map/layers/wms.layer.js +0 -42
- package/dist/cesium-map/layers/wmts.layer.js +0 -42
- package/dist/cesium-map/layers/xyz.layer.js +0 -42
- package/dist/cesium-map/layers-manager.js +0 -403
- package/dist/cesium-map/map-legend/MapLegend.js +0 -57
- package/dist/cesium-map/map-legend/MapLegendList.js +0 -43
- package/dist/cesium-map/map-legend/MapLegendSidebar.js +0 -20
- package/dist/cesium-map/map-legend/MapLegendToggle.js +0 -20
- package/dist/cesium-map/map-legend/index.js +0 -14
- package/dist/cesium-map/map.js +0 -339
- package/dist/cesium-map/map.types.js +0 -12
- package/dist/cesium-map/proxied.types.js +0 -133
- package/dist/cesium-map/settings/base-maps.js +0 -78
- package/dist/cesium-map/settings/scene-modes.js +0 -65
- package/dist/cesium-map/settings/settings.js +0 -79
- package/dist/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.d.ts +0 -3
- package/dist/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.js +0 -245
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-decoder.d.ts +0 -9
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-decoder.js +0 -202
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.d.ts +0 -50
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.js +0 -136
- package/dist/cesium-map/tools/cesium/primitives-conversions.cesium.js +0 -38
- package/dist/cesium-map/tools/coordinates-tracker.tool.js +0 -82
- package/dist/cesium-map/tools/draw/drawHelper.js +0 -1694
- package/dist/cesium-map/tools/geojson/geojson-to-primitive.js +0 -41
- package/dist/cesium-map/tools/geojson/index.js +0 -14
- package/dist/cesium-map/tools/geojson/point.geojson.js +0 -43
- package/dist/cesium-map/tools/geojson/polygon.geojson.js +0 -24
- package/dist/cesium-map/tools/geojson/rectangle.geojson.js +0 -44
- package/dist/cesium-map/tools/inspector.tool.d.ts +0 -4
- package/dist/cesium-map/tools/inspector.tool.js +0 -33
- package/dist/cesium-map/tools/scale-tracker.tool.js +0 -161
- package/dist/cesium-map/tools/terranian-height.tool.d.ts +0 -4
- package/dist/cesium-map/tools/terranian-height.tool.js +0 -114
- package/dist/cesium-map/tools/zoom_level-tracker.tool.js +0 -134
- package/dist/cssbaseline/cssbaseline.js +0 -41
- package/dist/cssbaseline/index.js +0 -6
- package/dist/date-picker/date-picker.js +0 -78
- package/dist/date-picker/index.js +0 -13
- package/dist/date-range-picker/date-range-picker.form-control.js +0 -95
- package/dist/date-range-picker/date-range-picker.js +0 -104
- package/dist/date-range-picker/index.js +0 -14
- package/dist/file-picker/file-picker.js +0 -151
- package/dist/file-picker/index.js +0 -14
- package/dist/file-picker/localization.js +0 -124
- package/dist/index.js +0 -25
- package/dist/map-filter-container/container-map.js +0 -31
- package/dist/map-filter-container/index.js +0 -13
- package/dist/map-filter-container/map-filter-container.js +0 -78
- package/dist/map-filter-container/polygon-selection-ui.js +0 -62
- package/dist/models/defaults.js +0 -32
- package/dist/models/enums.js +0 -20
- package/dist/models/index.js +0 -13
- package/dist/ol-map/feature.js +0 -20
- package/dist/ol-map/index.d.ts +0 -6
- package/dist/ol-map/index.js +0 -18
- package/dist/ol-map/interactions/draw.js +0 -44
- package/dist/ol-map/interactions/index.d.ts +0 -1
- package/dist/ol-map/interactions/index.js +0 -13
- package/dist/ol-map/layers/index.d.ts +0 -3
- package/dist/ol-map/layers/index.js +0 -15
- package/dist/ol-map/layers/tile-layer.js +0 -48
- package/dist/ol-map/layers/vector-layer.js +0 -48
- package/dist/ol-map/layers/vector-tile-layer.d.ts +0 -10
- package/dist/ol-map/layers/vector-tile-layer.js +0 -66
- package/dist/ol-map/map.js +0 -117
- package/dist/ol-map/source/index.d.ts +0 -6
- package/dist/ol-map/source/index.js +0 -18
- package/dist/ol-map/source/mvt.d.ts +0 -11
- package/dist/ol-map/source/mvt.js +0 -37
- package/dist/ol-map/source/osm.js +0 -14
- package/dist/ol-map/source/vector-source.js +0 -45
- package/dist/ol-map/source/wms.d.ts +0 -17
- package/dist/ol-map/source/wms.js +0 -30
- package/dist/ol-map/source/wmts.d.ts +0 -21
- package/dist/ol-map/source/wmts.js +0 -59
- package/dist/ol-map/source/xyz.d.ts +0 -12
- package/dist/ol-map/source/xyz.js +0 -27
- package/dist/ol-map/style.d.ts +0 -4
- package/dist/ol-map/style.js +0 -22
- package/dist/popover/index.js +0 -5
- package/dist/popover/popover.js +0 -35
- package/dist/smart-table/__mock-data__/smartTableMocks.d.ts +0 -7
- package/dist/smart-table/__mock-data__/smartTableMocks.js +0 -17
- package/dist/smart-table/index.js +0 -14
- package/dist/smart-table/smart-table-head.js +0 -22
- package/dist/smart-table/smart-table-row.js +0 -46
- package/dist/smart-table/smart-table-types.js +0 -2
- package/dist/smart-table/smart-table.js +0 -51
- package/dist/theme/index.js +0 -13
- package/dist/theme/theme.js +0 -124
- package/dist/utils/map.js +0 -21
- package/dist/utils/projections.js +0 -10
- package/dist/utils/story.d.ts +0 -12
- package/dist/utils/story.js +0 -2
- package/public/assets/img/dragIcon.png +0 -0
- package/public/assets/img/dragIconLight.png +0 -0
- package/public/assets/img/glyphicons_067_cleaning.png +0 -0
- package/public/assets/img/glyphicons_094_vector_path_square.png +0 -0
- package/public/assets/img/glyphicons_095_vector_path_circle.png +0 -0
- package/public/assets/img/glyphicons_096_vector_path_polygon.png +0 -0
- package/public/assets/img/glyphicons_097_vector_path_line.png +0 -0
- package/public/assets/img/glyphicons_242_google_maps.png +0 -0
- package/public/assets/img/map-marker.gif +0 -0
- package/public/assets/img/transparent-tile.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/index.html +0 -43
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +0 -25
- package/public/robots.txt +0 -3
- package/src/index.tsx +0 -9
- package/src/lib/autocomplete/autocomplete.css +0 -25
- package/src/lib/autocomplete/autocomplete.stories.tsx +0 -101
- package/src/lib/autocomplete/autocomplete.tsx +0 -681
- package/src/lib/autocomplete/get-input-selection.d.ts +0 -1
- package/src/lib/autocomplete/index.ts +0 -1
- package/src/lib/box/box.tsx +0 -7
- package/src/lib/box/index.ts +0 -1
- package/src/lib/cesium-map/context-menu.stories.tsx +0 -444
- package/src/lib/cesium-map/data-sources/custom.data-source.tsx +0 -12
- package/src/lib/cesium-map/data-sources/drawings.data-source.stories.tsx +0 -161
- package/src/lib/cesium-map/data-sources/drawings.data-source.tsx +0 -213
- package/src/lib/cesium-map/data-sources/index.ts +0 -2
- package/src/lib/cesium-map/entities/entity.description.tsx +0 -19
- package/src/lib/cesium-map/entities/entity.graphics.stories.tsx +0 -48
- package/src/lib/cesium-map/entities/entity.stories.tsx +0 -146
- package/src/lib/cesium-map/entities/entity.tsx +0 -10
- package/src/lib/cesium-map/entities/graphics/polygon.graphics.tsx +0 -12
- package/src/lib/cesium-map/entities/graphics/polyline.graphics.tsx +0 -12
- package/src/lib/cesium-map/entities/graphics/rectangle.graphics.tsx +0 -12
- package/src/lib/cesium-map/entities/index.ts +0 -4
- package/src/lib/cesium-map/helpers/customImageryProviders.ts +0 -173
- package/src/lib/cesium-map/helpers/utils.ts +0 -135
- package/src/lib/cesium-map/index.ts +0 -8
- package/src/lib/cesium-map/layers/3d.tileset.stories.tsx +0 -164
- package/src/lib/cesium-map/layers/3d.tileset.tsx +0 -51
- package/src/lib/cesium-map/layers/3d.tileset.with.update.tsx +0 -120
- package/src/lib/cesium-map/layers/geojson.layer.stories.tsx +0 -180
- package/src/lib/cesium-map/layers/geojson.layer.tsx +0 -12
- package/src/lib/cesium-map/layers/imagery.layer.stories.tsx +0 -39
- package/src/lib/cesium-map/layers/imagery.layer.tsx +0 -37
- package/src/lib/cesium-map/layers/index.ts +0 -7
- package/src/lib/cesium-map/layers/layers.rect.stories.tsx +0 -171
- package/src/lib/cesium-map/layers/optimized-tile-requests.stories.tsx +0 -279
- package/src/lib/cesium-map/layers/osm.layer.stories.tsx +0 -40
- package/src/lib/cesium-map/layers/osm.layer.tsx +0 -22
- package/src/lib/cesium-map/layers/wms.layer.stories.tsx +0 -38
- package/src/lib/cesium-map/layers/wms.layer.tsx +0 -28
- package/src/lib/cesium-map/layers/wmts.layer.stories.tsx +0 -53
- package/src/lib/cesium-map/layers/wmts.layer.tsx +0 -27
- package/src/lib/cesium-map/layers/xyz.layer.stories.tsx +0 -37
- package/src/lib/cesium-map/layers/xyz.layer.tsx +0 -27
- package/src/lib/cesium-map/layers-manager.stories.tsx +0 -286
- package/src/lib/cesium-map/layers-manager.ts +0 -558
- package/src/lib/cesium-map/map-legend/MapLegend.css +0 -136
- package/src/lib/cesium-map/map-legend/MapLegend.tsx +0 -92
- package/src/lib/cesium-map/map-legend/MapLegendList.tsx +0 -47
- package/src/lib/cesium-map/map-legend/MapLegendSidebar.tsx +0 -55
- package/src/lib/cesium-map/map-legend/MapLegendToggle.tsx +0 -31
- package/src/lib/cesium-map/map-legend/index.tsx +0 -3
- package/src/lib/cesium-map/map-legend/legends-sidebar.stories.tsx +0 -201
- package/src/lib/cesium-map/map.css +0 -59
- package/src/lib/cesium-map/map.stories.tsx +0 -144
- package/src/lib/cesium-map/map.tsx +0 -492
- package/src/lib/cesium-map/map.types.ts +0 -11
- package/src/lib/cesium-map/proxied.types.ts +0 -58
- package/src/lib/cesium-map/settings/base-maps.css +0 -37
- package/src/lib/cesium-map/settings/base-maps.tsx +0 -94
- package/src/lib/cesium-map/settings/scene-modes.css +0 -19
- package/src/lib/cesium-map/settings/scene-modes.tsx +0 -100
- package/src/lib/cesium-map/settings/settings.css +0 -52
- package/src/lib/cesium-map/settings/settings.stories.tsx +0 -186
- package/src/lib/cesium-map/settings/settings.tsx +0 -141
- package/src/lib/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.ts +0 -243
- package/src/lib/cesium-map/terrain-providers/custom/quantized-mesh-decoder.ts +0 -321
- package/src/lib/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.ts +0 -237
- package/src/lib/cesium-map/terrain-providers/terrain-provider-heights-tool.stories.tsx +0 -170
- package/src/lib/cesium-map/terrain-providers/terrain-provider.stories.tsx +0 -187
- package/src/lib/cesium-map/tools/cesium/primitives-conversions.cesium.ts +0 -15
- package/src/lib/cesium-map/tools/coordinates-tracker.tool.css +0 -11
- package/src/lib/cesium-map/tools/coordinates-tracker.tool.tsx +0 -85
- package/src/lib/cesium-map/tools/draw/drawHelper.css +0 -101
- package/src/lib/cesium-map/tools/draw/drawHelper.ts +0 -2116
- package/src/lib/cesium-map/tools/geojson/geojson-to-primitive.ts +0 -54
- package/src/lib/cesium-map/tools/geojson/index.ts +0 -2
- package/src/lib/cesium-map/tools/geojson/point.geojson.ts +0 -63
- package/src/lib/cesium-map/tools/geojson/polygon.geojson.ts +0 -24
- package/src/lib/cesium-map/tools/geojson/rectangle.geojson.ts +0 -21
- package/src/lib/cesium-map/tools/inspector.tool.tsx +0 -15
- package/src/lib/cesium-map/tools/scale-tracker.tool.css +0 -16
- package/src/lib/cesium-map/tools/scale-tracker.tool.tsx +0 -195
- package/src/lib/cesium-map/tools/terranian-height.tool.tsx +0 -171
- package/src/lib/cesium-map/tools/zoom_level-tracker.tool.css +0 -19
- package/src/lib/cesium-map/tools/zoom_level-tracker.tool.tsx +0 -144
- package/src/lib/cssbaseline/cssbaseline.tsx +0 -19
- package/src/lib/cssbaseline/index.ts +0 -4
- package/src/lib/date-picker/date-picker.css +0 -9
- package/src/lib/date-picker/date-picker.stories.tsx +0 -130
- package/src/lib/date-picker/date-picker.tsx +0 -90
- package/src/lib/date-picker/index.ts +0 -1
- package/src/lib/date-range-picker/date-range-picker.css +0 -9
- package/src/lib/date-range-picker/date-range-picker.form-control.css +0 -3
- package/src/lib/date-range-picker/date-range-picker.form-control.spec.tsx +0 -58
- package/src/lib/date-range-picker/date-range-picker.form-control.tsx +0 -150
- package/src/lib/date-range-picker/date-range-picker.spec.tsx +0 -81
- package/src/lib/date-range-picker/date-range-picker.stories.tsx +0 -207
- package/src/lib/date-range-picker/date-range-picker.tsx +0 -156
- package/src/lib/date-range-picker/index.ts +0 -2
- package/src/lib/file-picker/file-picker.css +0 -63
- package/src/lib/file-picker/file-picker.stories.tsx +0 -447
- package/src/lib/file-picker/file-picker.tsx +0 -180
- package/src/lib/file-picker/fs-map.json +0 -1557
- package/src/lib/file-picker/index.ts +0 -2
- package/src/lib/file-picker/localization.ts +0 -164
- package/src/lib/index.ts +0 -13
- package/src/lib/map-filter-container/container-map.css +0 -5
- package/src/lib/map-filter-container/container-map.tsx +0 -48
- package/src/lib/map-filter-container/index.ts +0 -1
- package/src/lib/map-filter-container/map-filter-container.tsx +0 -91
- package/src/lib/map-filter-container/polygon-selection-ui.spec.tsx +0 -119
- package/src/lib/map-filter-container/polygon-selection-ui.tsx +0 -111
- package/src/lib/map-filter-container/stories/Map.stories.tsx +0 -76
- package/src/lib/models/defaults.ts +0 -32
- package/src/lib/models/enums.ts +0 -16
- package/src/lib/models/index.ts +0 -1
- package/src/lib/ol-map/feature.tsx +0 -23
- package/src/lib/ol-map/index.ts +0 -6
- package/src/lib/ol-map/interactions/draw.tsx +0 -56
- package/src/lib/ol-map/interactions/index.ts +0 -1
- package/src/lib/ol-map/layers/index.ts +0 -3
- package/src/lib/ol-map/layers/tile-layer.tsx +0 -36
- package/src/lib/ol-map/layers/vector-layer.tsx +0 -32
- package/src/lib/ol-map/layers/vector-tile-layer.tsx +0 -56
- package/src/lib/ol-map/map.css +0 -17
- package/src/lib/ol-map/map.tsx +0 -137
- package/src/lib/ol-map/source/index.ts +0 -6
- package/src/lib/ol-map/source/mvt.tsx +0 -46
- package/src/lib/ol-map/source/osm.tsx +0 -13
- package/src/lib/ol-map/source/stories/mvt.stories.tsx +0 -68
- package/src/lib/ol-map/source/stories/vector-source.stories.tsx +0 -78
- package/src/lib/ol-map/source/stories/wms.stories.tsx +0 -51
- package/src/lib/ol-map/source/stories/wmts.stories.tsx +0 -72
- package/src/lib/ol-map/source/stories/xyz.stories.tsx +0 -53
- package/src/lib/ol-map/source/vector-source.tsx +0 -30
- package/src/lib/ol-map/source/wms.tsx +0 -40
- package/src/lib/ol-map/source/wmts.tsx +0 -82
- package/src/lib/ol-map/source/xyz.tsx +0 -33
- package/src/lib/ol-map/stories/map.stories.tsx +0 -60
- package/src/lib/ol-map/style.ts +0 -24
- package/src/lib/popover/index.ts +0 -1
- package/src/lib/popover/popover.tsx +0 -7
- package/src/lib/smart-table/__mock-data__/smartTableMocks.ts +0 -22
- package/src/lib/smart-table/index.ts +0 -2
- package/src/lib/smart-table/smart-table-head.spec.tsx +0 -116
- package/src/lib/smart-table/smart-table-head.tsx +0 -47
- package/src/lib/smart-table/smart-table-row.spec.tsx +0 -109
- package/src/lib/smart-table/smart-table-row.tsx +0 -78
- package/src/lib/smart-table/smart-table-types.ts +0 -10
- package/src/lib/smart-table/smart-table.spec.tsx +0 -116
- package/src/lib/smart-table/smart-table.tsx +0 -115
- package/src/lib/smart-table/stories/SmartTable.stories.tsx +0 -114
- package/src/lib/theme/index.ts +0 -1
- package/src/lib/theme/theme.ts +0 -123
- package/src/lib/utils/map.ts +0 -19
- package/src/lib/utils/projections.ts +0 -7
- package/src/lib/utils/story.ts +0 -11
- package/src/react-app-env.d.ts +0 -1
- package/src/setupTests.ts +0 -14
- package/src/types/quantized-mesh-decoder.d.ts +0 -1
- package/tsbuildconfig.json +0 -37
- package/tsconfig.json +0 -26
|
@@ -0,0 +1,3662 @@
|
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('body[dir=rtl] .drpOpener .mdc-text-field{direction:ltr}body[dir=rtl] .drpContainer .MuiInputLabel-formControl{right:0px;left:unset}body[dir=rtl] .drpContainer .MuiInputBase-input{direction:ltr;text-align:end}.map{height:100%;width:100%}.ol-mouse-position{top:auto!important;right:auto!important;bottom:8px;left:8px;background-color:#fff;opacity:.7;font-size:12px;padding:2px;border-radius:2px}.ol-zoom{top:2.5em;right:.5em;left:unset}.trackerPosition{background-color:var(--mdc-theme-surface);z-index:2000;padding:2px;border-radius:2px;font-size:12px;height:24px;text-align:center;line-height:20px;white-space:nowrap}.scalePosition{background-color:var(--mdc-theme-surface);padding:1px;border-radius:2px;font-size:12px;width:110px}.distance-legend-label{text-align:center}.distance-legend-scale-bar{background:var(--mdc-theme-on-surface);margin:0 auto;display:block;transition:all .5s ease-in-out}.zoomLevel{z-index:2000;background-color:var(--mdc-theme-surface);border-radius:2px;padding:2px;height:24px}.zoomLevelValue{margin:2px;font-size:14px;line-height:10px;text-align:center}.zoomLevelLabel{font-size:8px;line-height:8px}.mapViewIcon{fill:#fff;width:40px;height:40px;background:#303336;border:1px solid #444;border-radius:4px}.mapViewIcon:hover{background:#48b;border-color:#aef}.mapViewCurrent{fill:#aef;border:1px solid #aef;border-radius:4px}.mapSelector{width:260px;list-style:none;padding-left:0;display:flex;flex-wrap:wrap;grid-gap:4px;min-height:140px;margin-block-start:0px;padding-inline-start:0px}.mapContainerSelected{border:blueviolet 2px solid!important;border-radius:2px}.mapContainer:hover{border:tomato 2px solid;border-radius:2px}.mapContainerImg{width:100%;height:100%}.mapLabel{font-size:12px}.mapLabel:before{content:"\\a0"}.mapScenesContainer{display:flex;gap:8px}.settingsIconContainer,.mapLegendToggleContainer{fill:#fff;width:40px;height:40px;background:#303336;border:1px solid #444;border-radius:4px}.settingsIconContainer:hover,.mapLegendToggleContainer:hover{background:#48b;border-color:#aef}.baseMapsContainer{margin-top:12px;min-height:58%}.settingsDialogPortal{transform:translateZ(0);height:calc(100vh - 220px);max-height:460px;width:280px;position:absolute;top:40px;right:80px}.settingsDialogPortal .mdc-dialog__container{align-items:unset}.settingsDialogPortal .mdc-dialog .mdc-dialog__surface{max-height:unset}body[dir=rtl] .settingsDialogPortal{left:80px;right:unset}.sectionLabel{margin-block-end:.5em}.mapLegendSidebarContainer{width:340px;height:100%;position:relative;overflow-y:auto;overflow-x:hidden;font-size:16px}.mapLegendSidebarContainer.mdc-drawer--animate{transform:translate(0)!important;transition:none!important}.mapLegendSidebarContainer.mdc-drawer--dismissible{position:relative}div.MuiPaper-root{transition:none!important}.mapLegendCloseBtn{position:absolute;top:0;right:0;cursor:pointer;width:50px;height:50px;padding:20px;font-size:24px}body[dir=rtl] .mapLegendCloseBtn{right:unset;left:0}.mapLegendToggleContainer{display:flex;align-items:center;justify-content:center}.mapLegendIcon{width:2rem;height:2rem;transform:translate(8%,8%)}.sidebarHeaderContainer{text-align:center;margin-top:40px}.sidebarTitle{font-size:1.5rem;font-weight:700}.mapLegend{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:10px 14px}.layerNameContainer{width:90%;display:flex;justify-content:center;align-items:center}.layerName{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.legendImg{width:90%;height:150px;border:1px solid black;border-radius:5px;object-fit:cover;cursor:pointer}.legendActionsContainer{display:flex;flex-direction:row;align-self:center}.legendAction:not(:last-child):after{content:"|";margin:0 4px}.mapLegendsList{display:flex;flex-direction:column;padding:20px 0;width:100%;height:90%}.legendAction{text-decoration:underline;cursor:pointer;font-size:1.1rem;transition:all .1s ease-in-out;width:max-content}.legendAction:hover{filter:brightness(1.2)}.noLegendsContainer{width:100%;height:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}.noLegendsMsg{text-align:center}.cesium-widget-credits{display:none!important}.cesium-viewer-fullscreenContainer{bottom:8px;right:8px;left:unset}body[dir=rtl] .cesium-viewer-fullscreenContainer{left:8px;right:unset}body[dir=rtl] .cesium-viewer-toolbar{left:5px;right:unset}.cesium-button.cesium-fullscreenButton{border-radius:14%}.toolsContainer{color:var(--mdc-theme-on-surface);display:flex;gap:8px;z-index:2000;position:absolute;bottom:12px;right:40px;opacity:.7}body[dir=rtl] .toolsContainer{left:40px;right:unset}.sideToolsContainer{display:flex;flex-direction:row;gap:8px;z-index:2000;position:absolute;top:12px;right:40px}body[dir=rtl] .sideToolsContainer{left:40px;right:unset}.viewer{display:flex;flex-direction:row}.twipsy{display:block;position:absolute;visibility:visible;max-width:200px;min-width:100px;padding:5px;font-size:11px;z-index:1000;opacity:.8;-khtml-opacity:.8;-moz-opacity:.8;filter:alpha(opacity=80)}.twipsy.left .twipsy-arrow{top:50%;right:0;margin-top:-5px;border-top:5px solid transparent;border-bottom:5px solid transparent;border-left:5px solid #000000}.twipsy.right .twipsy-arrow{top:50%;left:0;margin-top:-5px;border-top:5px solid transparent;border-bottom:5px solid transparent;border-right:5px solid #000000}.twipsy-inner{padding:3px 8px;background-color:#000;color:#fff;text-align:center;max-width:200px;text-decoration:none;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.twipsy-arrow{position:absolute;width:0;height:0}.toolbar{margin:0;padding:0;background:white}.toolbar>.button{margin:5px;padding:5px;border:1px solid #eee;cursor:pointer}.toolbar>.button:hover{background:#eee}.infoWindow{position:absolute;min-width:100px;max-width:300px}.infoWindow #frame{padding:10px;border:1px solid black;background:white}.infoWindow #close{float:right;margin:5px 2px;font-size:small;color:gray;cursor:pointer}.infoWindow #arrow{position:absolute;bottom:-8px;left:50%;margin-left:-10px;border-right:10px solid transparent;border-left:10px solid transparent;border-top:10px solid white}.react-autocomplete-input{background-clip:padding-box;background-color:#fff;bottom:auto;box-shadow:0 6px 12px #0000002d;display:block;font-size:14px;list-style:none;padding:1px;position:absolute;z-index:20000;margin-block-start:unset;margin-block-end:unset}.react-autocomplete-input>li{cursor:pointer;padding:10px;min-width:100px}.react-autocomplete-input>li.active{background-color:#337ab7;color:#fff}body[dir=rtl] .chonky-fileListWrapper [class^=listContainer-]{direction:rtl!important}body[dir=rtl] .chonky-fileEntryClickableWrapper [class^=listFileEntryProperty-],body[dir=rtl] .chonky-navbarContainer{direction:ltr!important}body[dir=rtl] .chonky-chonkyRoot{text-align:right}body[dir=rtl] .chonky-infoText{margin-left:unset;margin-right:12px}body[dir=rtl] .chonky-contextMenuList .MuiListItemText-root,body[dir=rtl] .chonky-dropdownList .MuiListItemText-root{text-align:right}body[dir=rtl] .chonky-icon{margin-right:unset;margin-left:8px}.chonky-chonkyRoot div[class^=folderBackSide]{box-shadow:unset}.chonky-chonkyRoot div[class^=folderBackSide]:after{border-color:var(--fp-theme-background, #fff) var(--fp-theme-background, #fff) transparent transparent}.chonky-chonkyRoot div[class^=listFileEntryIcon-]{color:#d5d5d5}.chonky-chonkyRoot div[class*=previewFile-d]{background-color:#d5d5d5}.chonky-chonkyRoot div[class^=selectionIndicator-]{background:var(--fp-theme-selection-background, #455570)}.chonky-chonkyRoot{background-color:var(--fp-theme-background, #fff)!important}.chonky-contextMenuList{background-color:var(--fp-theme-surface, #fff)!important}button[class*=chonky-activeButton],.chonky-selectionSizeText{color:var(--fp-theme-primary, #24aee9)!important}')),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
|
|
2
|
+
var Ut = Object.defineProperty;
|
|
3
|
+
var Wt = (e, i, t) => i in e ? Ut(e, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[i] = t;
|
|
4
|
+
var J = (e, i, t) => (Wt(e, typeof i != "symbol" ? i + "" : i, t), t);
|
|
5
|
+
import { jsx as l, jsxs as D, Fragment as oe } from "react/jsx-runtime";
|
|
6
|
+
import ve, { useState as k, useEffect as I, useMemo as ft, createContext as Se, useRef as Le, useContext as Pe, useCallback as ge, useLayoutEffect as jt } from "react";
|
|
7
|
+
import { isValid as Ee, isBefore as Kt, format as rt } from "date-fns";
|
|
8
|
+
import { he as yt, enUS as vt } from "date-fns/locale";
|
|
9
|
+
import { MuiPickersUtilsProvider as Et, KeyboardDateTimePicker as Ue, KeyboardDatePicker as qt } from "@material-ui/pickers";
|
|
10
|
+
import Ct from "@date-io/date-fns";
|
|
11
|
+
import { createTheme as Yt, makeStyles as Me, createStyles as Re } from "@material-ui/core/styles";
|
|
12
|
+
import { Box as Xt, ThemeProvider as wt, Popover as Zt, Paper as We, TableRow as ke, TableCell as we, TableSortLabel as Jt, IconButton as Qt, Collapse as ei, TableContainer as ti, Table as ii, TableBody as ni, Typography as ri, TablePagination as oi } from "@material-ui/core";
|
|
13
|
+
import { useTheme as bt, ThemeProvider as si, Button as Ie, TextField as ai, Tooltip as je, Menu as li, MenuItem as He, Icon as be, Dialog as ci, DialogTitle as di, DialogContent as ui, Drawer as hi, DrawerHeader as pi, DrawerTitle as mi, DrawerContent as gi } from "@map-colonies/react-core";
|
|
14
|
+
import { default as ys } from "@material-ui/core/useMediaQuery";
|
|
15
|
+
import fi from "@turf/rewind";
|
|
16
|
+
import { Map as yi, View as vi } from "ol";
|
|
17
|
+
import "ol/ol.css";
|
|
18
|
+
import { format as ot } from "ol/coordinate";
|
|
19
|
+
import { defaults as Ei, FullScreen as st } from "ol/control";
|
|
20
|
+
import Ge from "ol/control/MousePosition";
|
|
21
|
+
import { transform as Ci } from "ol/proj";
|
|
22
|
+
import { Tile as wi, Vector as bi } from "ol/layer";
|
|
23
|
+
import { Vector as Ti, OSM as _i } from "ol/source";
|
|
24
|
+
import { GeoJSON as Tt } from "ol/format";
|
|
25
|
+
import { Draw as Si } from "ol/interaction";
|
|
26
|
+
import { createBox as Li } from "ol/interaction/Draw";
|
|
27
|
+
import Pi from "@material-ui/core/TableHead";
|
|
28
|
+
import { KeyboardArrowUp as Mi, KeyboardArrowDown as Ai } from "@material-ui/icons";
|
|
29
|
+
import xi from "@material-ui/core/CssBaseline";
|
|
30
|
+
import ki from "@material-ui/core/ScopedCssBaseline";
|
|
31
|
+
import { createPortal as Ii } from "react-dom";
|
|
32
|
+
import { Viewer as Oi, Cesium3DTileset as Di, GeoJsonDataSource as Ri, ImageryLayer as Bi, Entity as Ni, EntityDescription as _t, PolygonGraphics as Fi, RectangleGraphics as Hi, CustomDataSource as Gi, PolylineGraphics as Vi } from "resium";
|
|
33
|
+
import * as p from "cesium";
|
|
34
|
+
import { ScreenSpaceEventType as St, Cartesian3 as me, Math as le, WebMercatorProjection as zi, EventHelper as $i, EllipsoidGeodesic as Ui, Cartesian2 as Te, SceneMode as ye, Cartographic as Be, UrlTemplateImageryProvider as Ze, WebMapServiceImageryProvider as Je, WebMapTileServiceImageryProvider as Qe, Event as Wi, SingleTileImageryProvider as ji, Rectangle as Ce, Viewer as Ki, Matrix4 as qi, OpenStreetMapImageryProvider as Yi, Color as Xi, PolygonHierarchy as Zi, PolylineDashMaterialProperty as Ji, ConstantProperty as Qi, ConstantPositionProperty as en, BoundingSphere as tn, Ellipsoid as nn, GeographicTilingScheme as rn, Resource as on, EllipsoidTerrainProvider as sn, CesiumTerrainProvider as an, VerticalOrigin as ln, LabelStyle as cn } from "cesium";
|
|
35
|
+
import { Math as Es, sampleTerrainMostDetailed as Cs } from "cesium";
|
|
36
|
+
import { get as Q, isNumber as Oe, isEmpty as Ke, isArray as dn, find as at } from "lodash";
|
|
37
|
+
import un from "@turf/boolean-point-in-polygon";
|
|
38
|
+
import * as Lt from "@turf/helpers";
|
|
39
|
+
import Pt from "@turf/bbox";
|
|
40
|
+
import Mt from "@turf/bbox-polygon";
|
|
41
|
+
import hn from "textarea-caret";
|
|
42
|
+
import pn, { setCaretPosition as mn } from "get-input-selection";
|
|
43
|
+
import { ChonkyActions as N, FileHelper as At, setChonkyDefaults as gn, FullFileBrowser as fn } from "chonky";
|
|
44
|
+
import { ChonkyIconFA as yn } from "chonky-icon-fontawesome";
|
|
45
|
+
import vn from "filesize";
|
|
46
|
+
var re = /* @__PURE__ */ ((e) => (e.BOX = "BOX", e.POLYGON = "POLYGON", e.UNKNOWN = "UNKNOWN", e))(re || {}), ce = /* @__PURE__ */ ((e) => (e.HE = "he", e.EN = "en", e.RU = "ru", e))(ce || {}), qe = /* @__PURE__ */ ((e) => (e.TOP_RIGHT = "TOP_RIGHT", e.BOTTOM_LEFT = "BOTTOM_LEFT", e))(qe || {});
|
|
47
|
+
const Z = {
|
|
48
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
49
|
+
DATE_PICKER: {
|
|
50
|
+
dateFormat: "dd/MM/yyyy",
|
|
51
|
+
local: {
|
|
52
|
+
setText: "set",
|
|
53
|
+
placeHolderText: "Enter the Date",
|
|
54
|
+
calendarLocale: ce.EN
|
|
55
|
+
},
|
|
56
|
+
disableFuture: !0,
|
|
57
|
+
showTime: !1,
|
|
58
|
+
variant: "inline"
|
|
59
|
+
},
|
|
60
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
61
|
+
DATE_RANGE_PICKER: {
|
|
62
|
+
dateFormat: "dd/MM/yyyy HH:mm",
|
|
63
|
+
controlsLayout: "row",
|
|
64
|
+
local: {
|
|
65
|
+
setText: "set",
|
|
66
|
+
startPlaceHolderText: "Start of time",
|
|
67
|
+
endPlaceHolderText: "End of time",
|
|
68
|
+
calendarLocale: ce.EN
|
|
69
|
+
},
|
|
70
|
+
renderAsButton: !0,
|
|
71
|
+
offset: 0,
|
|
72
|
+
disableFuture: !0
|
|
73
|
+
}
|
|
74
|
+
}, ae = (e) => {
|
|
75
|
+
const { children: i, ...t } = e;
|
|
76
|
+
return /* @__PURE__ */ l(Xt, { ...t, children: i });
|
|
77
|
+
}, xt = (e) => {
|
|
78
|
+
const i = e.type === "dark";
|
|
79
|
+
return ve.useMemo(() => En(e, i), [
|
|
80
|
+
i,
|
|
81
|
+
e
|
|
82
|
+
]);
|
|
83
|
+
}, En = (e, i = !1) => Yt({
|
|
84
|
+
palette: {
|
|
85
|
+
type: i ? "dark" : "light",
|
|
86
|
+
primary: {
|
|
87
|
+
main: e.primary
|
|
88
|
+
},
|
|
89
|
+
secondary: {
|
|
90
|
+
main: e.secondary
|
|
91
|
+
},
|
|
92
|
+
error: {
|
|
93
|
+
main: e.error
|
|
94
|
+
},
|
|
95
|
+
background: {
|
|
96
|
+
default: e.surface,
|
|
97
|
+
paper: e.background
|
|
98
|
+
},
|
|
99
|
+
text: {
|
|
100
|
+
primary: i ? e.textPrimaryOnDark : e.textPrimaryOnLight,
|
|
101
|
+
secondary: i ? e.textSecondaryOnDark : e.textSecondaryOnLight
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
const Cn = 2, wn = 0.5, bn = Me(
|
|
106
|
+
(e) => Re({
|
|
107
|
+
container: {
|
|
108
|
+
padding: e.spacing(Cn),
|
|
109
|
+
alignItems: "center"
|
|
110
|
+
},
|
|
111
|
+
setButton: {
|
|
112
|
+
marginTop: e.spacing(1)
|
|
113
|
+
},
|
|
114
|
+
margin: {
|
|
115
|
+
marginLeft: e.spacing(wn)
|
|
116
|
+
}
|
|
117
|
+
})
|
|
118
|
+
), Tn = (e) => {
|
|
119
|
+
var U, V, j, O;
|
|
120
|
+
const i = bn(), t = bt(), n = xt(t), [a, o] = k(null), [d, u] = k(null), [v, C] = k(
|
|
121
|
+
Z.DATE_RANGE_PICKER.dateFormat
|
|
122
|
+
), S = e.controlsLayout ?? Z.DATE_RANGE_PICKER.controlsLayout, A = e.disableFuture ?? Z.DATE_RANGE_PICKER.disableFuture, L = ((U = e.local) == null ? void 0 : U.startPlaceHolderText) ?? Z.DATE_RANGE_PICKER.local.startPlaceHolderText, R = ((V = e.local) == null ? void 0 : V.endPlaceHolderText) ?? Z.DATE_RANGE_PICKER.local.endPlaceHolderText, z = ((j = e.local) == null ? void 0 : j.setText) ?? Z.DATE_RANGE_PICKER.local.setText, Y = (((O = e.local) == null ? void 0 : O.calendarLocale) ?? Z.DATE_RANGE_PICKER.local.calendarLocale) === ce.HE ? yt : vt;
|
|
123
|
+
I(() => {
|
|
124
|
+
o(e.from ?? null);
|
|
125
|
+
}, [e.from]), I(() => {
|
|
126
|
+
u(e.to ?? null);
|
|
127
|
+
}, [e.to]), I(() => {
|
|
128
|
+
C(e.dateFormat ?? Z.DATE_RANGE_PICKER.dateFormat);
|
|
129
|
+
}, [e.dateFormat]);
|
|
130
|
+
const F = Boolean(
|
|
131
|
+
Ee(a) && !d || Ee(d) && !a || a && d && Ee(a) && Ee(d) && Kt(a, d)
|
|
132
|
+
), X = () => {
|
|
133
|
+
e.onChange({
|
|
134
|
+
from: a && Ee(a) ? a : void 0,
|
|
135
|
+
to: d && Ee(d) ? d : void 0
|
|
136
|
+
});
|
|
137
|
+
};
|
|
138
|
+
return /* @__PURE__ */ l(wt, { theme: n, children: /* @__PURE__ */ l(
|
|
139
|
+
ae,
|
|
140
|
+
{
|
|
141
|
+
className: `${i.container} drpContainer`,
|
|
142
|
+
display: "flex",
|
|
143
|
+
flexDirection: S,
|
|
144
|
+
width: S === "column" ? e.contentWidth : "unset",
|
|
145
|
+
children: /* @__PURE__ */ D(Et, { utils: Ct, locale: Y, children: [
|
|
146
|
+
/* @__PURE__ */ l(
|
|
147
|
+
Ue,
|
|
148
|
+
{
|
|
149
|
+
variant: "inline",
|
|
150
|
+
placeholder: L,
|
|
151
|
+
onChange: ($) => o($),
|
|
152
|
+
value: a,
|
|
153
|
+
disableFuture: A,
|
|
154
|
+
format: v,
|
|
155
|
+
maxDate: e.maxDate,
|
|
156
|
+
minDate: e.minDate
|
|
157
|
+
}
|
|
158
|
+
),
|
|
159
|
+
/* @__PURE__ */ l(
|
|
160
|
+
Ue,
|
|
161
|
+
{
|
|
162
|
+
variant: "inline",
|
|
163
|
+
placeholder: R,
|
|
164
|
+
className: i.margin,
|
|
165
|
+
onChange: ($) => u($),
|
|
166
|
+
value: d,
|
|
167
|
+
disableFuture: A,
|
|
168
|
+
format: v,
|
|
169
|
+
maxDate: e.maxDate,
|
|
170
|
+
minDate: e.minDate
|
|
171
|
+
}
|
|
172
|
+
),
|
|
173
|
+
/* @__PURE__ */ l(si, { options: t, children: /* @__PURE__ */ l(
|
|
174
|
+
Ie,
|
|
175
|
+
{
|
|
176
|
+
className: `${i.setButton} ${i.margin}`,
|
|
177
|
+
raised: !0,
|
|
178
|
+
onClick: X,
|
|
179
|
+
disabled: !F,
|
|
180
|
+
children: z
|
|
181
|
+
}
|
|
182
|
+
) })
|
|
183
|
+
] })
|
|
184
|
+
}
|
|
185
|
+
) });
|
|
186
|
+
}, _n = (e) => {
|
|
187
|
+
const { children: i, ...t } = e;
|
|
188
|
+
return /* @__PURE__ */ l(Zt, { ...t, children: i });
|
|
189
|
+
};
|
|
190
|
+
const Oo = (e) => {
|
|
191
|
+
var V, j;
|
|
192
|
+
const [i, t] = k(null), [n, a] = k(null), [o, d] = k(
|
|
193
|
+
Z.DATE_RANGE_PICKER.dateFormat
|
|
194
|
+
), [u, v] = ve.useState(
|
|
195
|
+
null
|
|
196
|
+
), C = (O) => {
|
|
197
|
+
v(O.currentTarget);
|
|
198
|
+
}, S = (O) => {
|
|
199
|
+
O.currentTarget.tagName === "I" ? v(
|
|
200
|
+
O.currentTarget.previousElementSibling
|
|
201
|
+
) : v(O.currentTarget);
|
|
202
|
+
}, A = () => {
|
|
203
|
+
v(null);
|
|
204
|
+
}, L = Boolean(u), R = e.controlsLayout ?? "column";
|
|
205
|
+
I(() => {
|
|
206
|
+
t(e.from ?? null);
|
|
207
|
+
}, [e.from]), I(() => {
|
|
208
|
+
a(e.to ?? null);
|
|
209
|
+
}, [e.to]), I(() => {
|
|
210
|
+
d(e.dateFormat ?? Z.DATE_RANGE_PICKER.dateFormat);
|
|
211
|
+
}, [e.dateFormat]);
|
|
212
|
+
const z = ((V = e.local) == null ? void 0 : V.startPlaceHolderText) ?? Z.DATE_RANGE_PICKER.local.startPlaceHolderText, K = ((j = e.local) == null ? void 0 : j.endPlaceHolderText) ?? Z.DATE_RANGE_PICKER.local.endPlaceHolderText, Y = e.renderAsButton === void 0 ? Z.DATE_RANGE_PICKER.renderAsButton : e.renderAsButton, F = e.offset === void 0 ? Z.DATE_RANGE_PICKER.offset : e.offset, X = e.disableFuture === void 0 ? Z.DATE_RANGE_PICKER.disableFuture : e.disableFuture, U = ft(() => `${i ? rt(i, o) : z} - ${n ? rt(n, o) : K}`, [i, n, o, z, K]);
|
|
213
|
+
return /* @__PURE__ */ D(oe, { children: [
|
|
214
|
+
Y ? /* @__PURE__ */ l(
|
|
215
|
+
Ie,
|
|
216
|
+
{
|
|
217
|
+
style: { width: e.width },
|
|
218
|
+
raised: !0,
|
|
219
|
+
onClick: C,
|
|
220
|
+
className: "drpOpener",
|
|
221
|
+
children: U
|
|
222
|
+
}
|
|
223
|
+
) : /* @__PURE__ */ l(
|
|
224
|
+
ai,
|
|
225
|
+
{
|
|
226
|
+
className: "drpOpener",
|
|
227
|
+
readOnly: !0,
|
|
228
|
+
style: { width: e.width },
|
|
229
|
+
value: U,
|
|
230
|
+
onClick: S,
|
|
231
|
+
trailingIcon: {
|
|
232
|
+
icon: "date_range",
|
|
233
|
+
tabIndex: 0,
|
|
234
|
+
onClick: S
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
),
|
|
238
|
+
/* @__PURE__ */ l(
|
|
239
|
+
_n,
|
|
240
|
+
{
|
|
241
|
+
open: L,
|
|
242
|
+
anchorEl: u,
|
|
243
|
+
onClose: A,
|
|
244
|
+
anchorOrigin: { vertical: "bottom", horizontal: "left" },
|
|
245
|
+
keepMounted: !0,
|
|
246
|
+
children: /* @__PURE__ */ l(
|
|
247
|
+
Tn,
|
|
248
|
+
{
|
|
249
|
+
controlsLayout: R,
|
|
250
|
+
contentWidth: ((u == null ? void 0 : u.clientWidth) ?? 0) - F,
|
|
251
|
+
dateFormat: o,
|
|
252
|
+
disableFuture: X,
|
|
253
|
+
minDate: e.minDate,
|
|
254
|
+
maxDate: e.maxDate,
|
|
255
|
+
local: e.local,
|
|
256
|
+
from: i ?? void 0,
|
|
257
|
+
to: n ?? void 0,
|
|
258
|
+
onChange: ({ from: O, to: $ }) => {
|
|
259
|
+
t(O ?? null), a($ ?? null), e.onChange({ from: O, to: $ }), A();
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
)
|
|
263
|
+
}
|
|
264
|
+
)
|
|
265
|
+
] });
|
|
266
|
+
};
|
|
267
|
+
const Do = (e) => {
|
|
268
|
+
const i = bt(), t = xt(i), [n, a] = k(e.value), {
|
|
269
|
+
format: o = Z.DATE_PICKER.dateFormat,
|
|
270
|
+
variant: d = Z.DATE_PICKER.variant,
|
|
271
|
+
disableFuture: u = Z.DATE_PICKER.disableFuture,
|
|
272
|
+
local: v,
|
|
273
|
+
onChange: C,
|
|
274
|
+
showTime: S = Z.DATE_PICKER.showTime,
|
|
275
|
+
value: A,
|
|
276
|
+
...L
|
|
277
|
+
} = e, {
|
|
278
|
+
placeHolderText: R = Z.DATE_PICKER.local.placeHolderText,
|
|
279
|
+
calendarLocale: z
|
|
280
|
+
} = v ?? {
|
|
281
|
+
placeHolderText: Z.DATE_PICKER.local.placeHolderText,
|
|
282
|
+
calendarLocale: ce.EN
|
|
283
|
+
}, K = z === ce.HE ? yt : vt, Y = (F) => {
|
|
284
|
+
a(F), C(F);
|
|
285
|
+
};
|
|
286
|
+
return /* @__PURE__ */ l(wt, { theme: t, children: /* @__PURE__ */ D(Et, { utils: Ct, locale: K, children: [
|
|
287
|
+
S && /* @__PURE__ */ l(
|
|
288
|
+
Ue,
|
|
289
|
+
{
|
|
290
|
+
variant: d,
|
|
291
|
+
placeholder: R,
|
|
292
|
+
onChange: Y,
|
|
293
|
+
value: n,
|
|
294
|
+
disableFuture: u,
|
|
295
|
+
format: o,
|
|
296
|
+
...L
|
|
297
|
+
}
|
|
298
|
+
),
|
|
299
|
+
!S && /* @__PURE__ */ l(
|
|
300
|
+
qt,
|
|
301
|
+
{
|
|
302
|
+
variant: d,
|
|
303
|
+
placeholder: R,
|
|
304
|
+
onChange: Y,
|
|
305
|
+
value: n,
|
|
306
|
+
disableFuture: u,
|
|
307
|
+
format: o,
|
|
308
|
+
...L
|
|
309
|
+
}
|
|
310
|
+
)
|
|
311
|
+
] }) });
|
|
312
|
+
}, Sn = 18, Ln = Me(
|
|
313
|
+
(e) => Re({
|
|
314
|
+
drawingButton: {
|
|
315
|
+
width: e.spacing(Sn)
|
|
316
|
+
},
|
|
317
|
+
fullWidth: {
|
|
318
|
+
width: "100%",
|
|
319
|
+
marginTop: "36px"
|
|
320
|
+
}
|
|
321
|
+
})
|
|
322
|
+
), Pn = (e) => {
|
|
323
|
+
const i = Ln(), [t, n] = ve.useState(null), { isSelectionEnabled: a, onCancelDraw: o, onStartDraw: d, onReset: u } = e, v = (S) => {
|
|
324
|
+
n(S.currentTarget);
|
|
325
|
+
}, C = () => {
|
|
326
|
+
n(null);
|
|
327
|
+
};
|
|
328
|
+
return a ? /* @__PURE__ */ l(je, { content: "Cancel the ongoing draw", align: "bottomLeft", children: /* @__PURE__ */ l(Ie, { className: i.drawingButton, raised: !0, onClick: o, children: "Cancel Draw" }) }) : /* @__PURE__ */ D(ae, { position: "relative", children: [
|
|
329
|
+
/* @__PURE__ */ l(
|
|
330
|
+
je,
|
|
331
|
+
{
|
|
332
|
+
content: "draw an Area of interest to limit the search",
|
|
333
|
+
align: "bottomLeft",
|
|
334
|
+
children: /* @__PURE__ */ l(
|
|
335
|
+
Ie,
|
|
336
|
+
{
|
|
337
|
+
className: i.drawingButton,
|
|
338
|
+
raised: !0,
|
|
339
|
+
onClick: v,
|
|
340
|
+
children: "Draw AOI"
|
|
341
|
+
}
|
|
342
|
+
)
|
|
343
|
+
}
|
|
344
|
+
),
|
|
345
|
+
/* @__PURE__ */ D(
|
|
346
|
+
li,
|
|
347
|
+
{
|
|
348
|
+
className: i.fullWidth,
|
|
349
|
+
open: Boolean(t),
|
|
350
|
+
onClose: C,
|
|
351
|
+
children: [
|
|
352
|
+
/* @__PURE__ */ l(
|
|
353
|
+
He,
|
|
354
|
+
{
|
|
355
|
+
onClick: () => {
|
|
356
|
+
d(re.POLYGON), C();
|
|
357
|
+
},
|
|
358
|
+
children: "Polygon"
|
|
359
|
+
}
|
|
360
|
+
),
|
|
361
|
+
/* @__PURE__ */ l(
|
|
362
|
+
He,
|
|
363
|
+
{
|
|
364
|
+
onClick: () => {
|
|
365
|
+
d(re.BOX), C();
|
|
366
|
+
},
|
|
367
|
+
children: "Box"
|
|
368
|
+
}
|
|
369
|
+
),
|
|
370
|
+
/* @__PURE__ */ l(
|
|
371
|
+
He,
|
|
372
|
+
{
|
|
373
|
+
onClick: () => {
|
|
374
|
+
u(), C();
|
|
375
|
+
},
|
|
376
|
+
children: "Clear"
|
|
377
|
+
}
|
|
378
|
+
)
|
|
379
|
+
]
|
|
380
|
+
}
|
|
381
|
+
)
|
|
382
|
+
] });
|
|
383
|
+
};
|
|
384
|
+
var ue = /* @__PURE__ */ ((e) => (e.WGS84 = "EPSG:4326", e.WEB_MERCATOR = "EPSG:3857", e))(ue || {});
|
|
385
|
+
const Ye = 5, Xe = 2, kt = Se(null), Mn = kt.Provider, lt = 35, ct = 32, An = 10, xn = (e) => e !== void 0 && e !== ue.WGS84 ? Ci([lt, ct], ue.WGS84, e) : [lt, ct], kn = (e) => {
|
|
386
|
+
switch (e) {
|
|
387
|
+
case ue.WEB_MERCATOR:
|
|
388
|
+
return (i) => ot(
|
|
389
|
+
i,
|
|
390
|
+
"Mercator: {y}m, {x}m",
|
|
391
|
+
Xe
|
|
392
|
+
);
|
|
393
|
+
case ue.WGS84:
|
|
394
|
+
return (i) => ot(
|
|
395
|
+
i,
|
|
396
|
+
"WGS84: {y}°N {x}°E",
|
|
397
|
+
Ye
|
|
398
|
+
);
|
|
399
|
+
default:
|
|
400
|
+
return (i) => "";
|
|
401
|
+
}
|
|
402
|
+
}, et = () => {
|
|
403
|
+
const e = Pe(kt);
|
|
404
|
+
if (e === null)
|
|
405
|
+
throw new Error("map context is null, please check the provider");
|
|
406
|
+
return e;
|
|
407
|
+
}, In = (e) => {
|
|
408
|
+
const i = Le(null), { allowFullScreen: t, showMousePosition: n, projection: a } = e, [o] = k(
|
|
409
|
+
new yi({
|
|
410
|
+
view: new vi({
|
|
411
|
+
projection: a ?? ue.WGS84
|
|
412
|
+
}),
|
|
413
|
+
controls: Ei()
|
|
414
|
+
})
|
|
415
|
+
);
|
|
416
|
+
I(() => {
|
|
417
|
+
o.getView().setCenter(e.center ?? xn(e.projection));
|
|
418
|
+
}, [o, e.center, e.projection]), I(() => {
|
|
419
|
+
o.getView().setZoom(e.zoom ?? An);
|
|
420
|
+
}, [o, e.zoom, e.projection]);
|
|
421
|
+
const d = (u, v) => {
|
|
422
|
+
v.getControls().forEach((S) => {
|
|
423
|
+
S instanceof u && v.removeControl(S);
|
|
424
|
+
});
|
|
425
|
+
};
|
|
426
|
+
return I(() => {
|
|
427
|
+
o.setTarget(i.current), t !== void 0 && t ? o.addControl(new st()) : d(st, o);
|
|
428
|
+
}, [o, t]), I(() => {
|
|
429
|
+
n !== void 0 && n ? (d(Ge, o), o.addControl(
|
|
430
|
+
new Ge({
|
|
431
|
+
coordinateFormat: kn(a ?? ue.WGS84),
|
|
432
|
+
projection: a ?? ue.WGS84,
|
|
433
|
+
undefinedHTML: " "
|
|
434
|
+
})
|
|
435
|
+
)) : d(Ge, o);
|
|
436
|
+
}, [o, n, a]), /* @__PURE__ */ D(Mn, { value: o, children: [
|
|
437
|
+
/* @__PURE__ */ l("div", { className: "map", ref: i }),
|
|
438
|
+
e.children
|
|
439
|
+
] });
|
|
440
|
+
}, It = Se(null), On = It.Provider, Dn = () => {
|
|
441
|
+
const e = Pe(It);
|
|
442
|
+
if (e === null)
|
|
443
|
+
throw new Error("tile layer context is null, please check the provider");
|
|
444
|
+
return e;
|
|
445
|
+
}, Rn = ({ options: e, children: i }) => {
|
|
446
|
+
const t = et(), [n] = k(new wi(e));
|
|
447
|
+
return I(() => (t.addLayer(n), () => {
|
|
448
|
+
t.removeLayer(n);
|
|
449
|
+
}), [t, n]), /* @__PURE__ */ l(On, { value: n, children: i });
|
|
450
|
+
}, Ot = Se(null), Bn = Ot.Provider, Nn = () => {
|
|
451
|
+
const e = Pe(Ot);
|
|
452
|
+
if (e === null)
|
|
453
|
+
throw new Error("vector layer context is null, please check the provider");
|
|
454
|
+
return e;
|
|
455
|
+
}, Fn = ({ children: e }) => {
|
|
456
|
+
const i = et(), [t] = k(new bi());
|
|
457
|
+
return I(() => (i.addLayer(t), () => {
|
|
458
|
+
i.removeLayer(t);
|
|
459
|
+
}), [i, t]), /* @__PURE__ */ l(Bn, { value: t, children: e });
|
|
460
|
+
}, Dt = Se(null), Hn = Dt.Provider, Gn = () => {
|
|
461
|
+
const e = Pe(Dt);
|
|
462
|
+
if (e === null)
|
|
463
|
+
throw new Error("vector source context is null, please check the provider");
|
|
464
|
+
return e;
|
|
465
|
+
}, Vn = ({ children: e }) => {
|
|
466
|
+
const i = Nn(), [t] = k(new Ti());
|
|
467
|
+
return I(() => {
|
|
468
|
+
i.setSource(t);
|
|
469
|
+
}, [t, i]), /* @__PURE__ */ l(Hn, { value: t, children: e });
|
|
470
|
+
}, zn = ({ geometry: e }) => {
|
|
471
|
+
const i = Gn();
|
|
472
|
+
return I(() => {
|
|
473
|
+
const n = new Tt().readFeature(e);
|
|
474
|
+
return i.addFeature(n), () => {
|
|
475
|
+
i.removeFeature(n);
|
|
476
|
+
};
|
|
477
|
+
}, [e, i]), null;
|
|
478
|
+
}, $n = (e) => {
|
|
479
|
+
const i = Dn();
|
|
480
|
+
return I(() => {
|
|
481
|
+
i.setSource(new _i());
|
|
482
|
+
}, [i]), null;
|
|
483
|
+
}, Un = ({
|
|
484
|
+
drawType: e,
|
|
485
|
+
onPolygonSelected: i
|
|
486
|
+
}) => {
|
|
487
|
+
const t = et();
|
|
488
|
+
return I(() => {
|
|
489
|
+
const n = {
|
|
490
|
+
type: "Circle"
|
|
491
|
+
/* CIRCLE */
|
|
492
|
+
};
|
|
493
|
+
switch (e) {
|
|
494
|
+
case re.BOX:
|
|
495
|
+
n.geometryFunction = Li();
|
|
496
|
+
break;
|
|
497
|
+
case re.POLYGON:
|
|
498
|
+
n.type = "Polygon";
|
|
499
|
+
break;
|
|
500
|
+
default:
|
|
501
|
+
return;
|
|
502
|
+
}
|
|
503
|
+
const a = new Si(n);
|
|
504
|
+
t.addInteraction(a);
|
|
505
|
+
const o = (d) => {
|
|
506
|
+
const v = new Tt().writeGeometryObject(d.feature.getGeometry());
|
|
507
|
+
i == null || i(v);
|
|
508
|
+
};
|
|
509
|
+
return a.on("drawend", o), () => {
|
|
510
|
+
a.un("drawend", o), t.removeInteraction(a);
|
|
511
|
+
};
|
|
512
|
+
}, [i, e, t]), null;
|
|
513
|
+
};
|
|
514
|
+
const Wn = (e) => {
|
|
515
|
+
const i = (t) => {
|
|
516
|
+
const n = fi(t);
|
|
517
|
+
e.onPolygonSelection(n);
|
|
518
|
+
};
|
|
519
|
+
return /* @__PURE__ */ D(In, { allowFullScreen: !0, showMousePosition: !0, children: [
|
|
520
|
+
/* @__PURE__ */ l(Rn, { children: /* @__PURE__ */ l($n, {}) }),
|
|
521
|
+
e.selectionPolygon && /* @__PURE__ */ l(Fn, { children: /* @__PURE__ */ l(Vn, { children: /* @__PURE__ */ l(zn, { geometry: e.selectionPolygon }) }) }),
|
|
522
|
+
e.children,
|
|
523
|
+
e.drawType !== void 0 && /* @__PURE__ */ l(
|
|
524
|
+
Un,
|
|
525
|
+
{
|
|
526
|
+
drawType: e.drawType,
|
|
527
|
+
onPolygonSelected: i
|
|
528
|
+
}
|
|
529
|
+
)
|
|
530
|
+
] });
|
|
531
|
+
}, Ve = 1.5, jn = 80, Kn = Me(
|
|
532
|
+
(e) => Re({
|
|
533
|
+
map: {
|
|
534
|
+
height: "100%",
|
|
535
|
+
width: "100%",
|
|
536
|
+
position: "absolute"
|
|
537
|
+
},
|
|
538
|
+
absolute: {
|
|
539
|
+
position: "absolute",
|
|
540
|
+
zIndex: 1e3,
|
|
541
|
+
left: e.spacing(Ve),
|
|
542
|
+
top: e.spacing(Ve)
|
|
543
|
+
},
|
|
544
|
+
contentContainer: {
|
|
545
|
+
marginTop: e.spacing(Ve),
|
|
546
|
+
width: e.spacing(jn)
|
|
547
|
+
},
|
|
548
|
+
filtersContainer: {
|
|
549
|
+
display: "flex",
|
|
550
|
+
padding: e.spacing(1)
|
|
551
|
+
},
|
|
552
|
+
filtersMargin: {
|
|
553
|
+
marginLeft: e.spacing(1)
|
|
554
|
+
}
|
|
555
|
+
})
|
|
556
|
+
), Ro = (e) => {
|
|
557
|
+
var v;
|
|
558
|
+
const [i, t] = k(), [n, a] = k(), o = Kn(), d = (C) => {
|
|
559
|
+
a(C), t(void 0), e.handlePolygonSelected(C);
|
|
560
|
+
}, u = () => {
|
|
561
|
+
a(void 0), e.handlePolygonReset();
|
|
562
|
+
};
|
|
563
|
+
return /* @__PURE__ */ D("div", { className: o.map, children: [
|
|
564
|
+
/* @__PURE__ */ D("div", { className: `${o.absolute}`, children: [
|
|
565
|
+
/* @__PURE__ */ D(We, { className: o.filtersContainer, children: [
|
|
566
|
+
/* @__PURE__ */ l(
|
|
567
|
+
Pn,
|
|
568
|
+
{
|
|
569
|
+
onCancelDraw: () => t(void 0),
|
|
570
|
+
onReset: u,
|
|
571
|
+
onStartDraw: t,
|
|
572
|
+
isSelectionEnabled: i !== void 0
|
|
573
|
+
}
|
|
574
|
+
),
|
|
575
|
+
(v = e.filters) == null ? void 0 : v.map((C, S) => /* @__PURE__ */ l("div", { className: o.filtersMargin, children: C }, S))
|
|
576
|
+
] }),
|
|
577
|
+
/* @__PURE__ */ l(We, { color: "red", className: `${o.contentContainer}`, children: e.children })
|
|
578
|
+
] }),
|
|
579
|
+
/* @__PURE__ */ l(
|
|
580
|
+
Wn,
|
|
581
|
+
{
|
|
582
|
+
children: e.mapContent,
|
|
583
|
+
onPolygonSelection: d,
|
|
584
|
+
drawType: i,
|
|
585
|
+
selectionPolygon: n
|
|
586
|
+
}
|
|
587
|
+
)
|
|
588
|
+
] });
|
|
589
|
+
};
|
|
590
|
+
function qn(e) {
|
|
591
|
+
const { headCells: i, order: t, orderBy: n, onRequestSort: a, isCollapseable: o } = e, d = (u) => (v) => {
|
|
592
|
+
a(v, u);
|
|
593
|
+
};
|
|
594
|
+
return /* @__PURE__ */ l(Pi, { children: /* @__PURE__ */ D(ke, { children: [
|
|
595
|
+
o && /* @__PURE__ */ l(we, {}),
|
|
596
|
+
i.map((u) => /* @__PURE__ */ l(
|
|
597
|
+
we,
|
|
598
|
+
{
|
|
599
|
+
align: u.numeric ? "right" : "left",
|
|
600
|
+
padding: u.disablePadding ? "none" : "default",
|
|
601
|
+
sortDirection: n === u.id ? t : !1,
|
|
602
|
+
children: /* @__PURE__ */ l(
|
|
603
|
+
Jt,
|
|
604
|
+
{
|
|
605
|
+
active: n === u.id,
|
|
606
|
+
direction: n === u.id ? t : "asc",
|
|
607
|
+
onClick: d(u.id),
|
|
608
|
+
children: u.label
|
|
609
|
+
}
|
|
610
|
+
)
|
|
611
|
+
},
|
|
612
|
+
u.id
|
|
613
|
+
))
|
|
614
|
+
] }) });
|
|
615
|
+
}
|
|
616
|
+
function Yn(e) {
|
|
617
|
+
const {
|
|
618
|
+
cellsMetadata: i,
|
|
619
|
+
isRowSelected: t,
|
|
620
|
+
item: n,
|
|
621
|
+
onRowSelected: a,
|
|
622
|
+
rowIndex: o,
|
|
623
|
+
isCollapseable: d,
|
|
624
|
+
collapsedElement: u
|
|
625
|
+
} = e, [v, C] = k(!1), S = i.length;
|
|
626
|
+
return /* @__PURE__ */ D(oe, { children: [
|
|
627
|
+
/* @__PURE__ */ D(ke, { hover: !0, selected: t, onClick: () => {
|
|
628
|
+
a == null || a(o);
|
|
629
|
+
}, children: [
|
|
630
|
+
d && /* @__PURE__ */ l(we, { padding: "checkbox", children: /* @__PURE__ */ l(
|
|
631
|
+
Qt,
|
|
632
|
+
{
|
|
633
|
+
"aria-label": "expand row",
|
|
634
|
+
size: "small",
|
|
635
|
+
onClick: (L) => {
|
|
636
|
+
L.stopPropagation(), C(!v);
|
|
637
|
+
},
|
|
638
|
+
children: v ? /* @__PURE__ */ l(Mi, {}) : /* @__PURE__ */ l(Ai, {})
|
|
639
|
+
}
|
|
640
|
+
) }),
|
|
641
|
+
i.map((L) => /* @__PURE__ */ l(
|
|
642
|
+
we,
|
|
643
|
+
{
|
|
644
|
+
align: L.numeric ? "right" : "left",
|
|
645
|
+
padding: L.disablePadding ? "none" : "default",
|
|
646
|
+
children: L.transform ? L.transform(n[L.id]) : n[L.id]
|
|
647
|
+
},
|
|
648
|
+
L.id + o.toString()
|
|
649
|
+
))
|
|
650
|
+
] }),
|
|
651
|
+
d && /* @__PURE__ */ l(ke, { children: /* @__PURE__ */ l(
|
|
652
|
+
we,
|
|
653
|
+
{
|
|
654
|
+
style: { paddingBottom: 0, paddingTop: 0 },
|
|
655
|
+
colSpan: S + 1,
|
|
656
|
+
children: /* @__PURE__ */ l(ei, { in: v, unmountOnExit: !0, timeout: "auto", children: u == null ? void 0 : u(n) })
|
|
657
|
+
}
|
|
658
|
+
) })
|
|
659
|
+
] });
|
|
660
|
+
}
|
|
661
|
+
function Bo(e) {
|
|
662
|
+
const [i, t] = k(""), [n, a] = k("asc"), {
|
|
663
|
+
cellsMetadata: o,
|
|
664
|
+
items: d,
|
|
665
|
+
onRequestSort: u,
|
|
666
|
+
onRowSelected: v,
|
|
667
|
+
isCollapseable: C,
|
|
668
|
+
collapsedElement: S,
|
|
669
|
+
isDense: A,
|
|
670
|
+
page: L,
|
|
671
|
+
rowsPerPage: R,
|
|
672
|
+
count: z,
|
|
673
|
+
handleChangePage: K,
|
|
674
|
+
handleChangeRowsPerPage: Y
|
|
675
|
+
} = e;
|
|
676
|
+
return /* @__PURE__ */ D(ti, { component: We, children: [
|
|
677
|
+
/* @__PURE__ */ D(ii, { size: A ? "small" : "medium", children: [
|
|
678
|
+
/* @__PURE__ */ l(
|
|
679
|
+
qn,
|
|
680
|
+
{
|
|
681
|
+
headCells: o,
|
|
682
|
+
onRequestSort: (X, U) => {
|
|
683
|
+
const V = i === U && n === "asc";
|
|
684
|
+
a(V ? "desc" : "asc"), t(U), u(U, V ? "desc" : "asc");
|
|
685
|
+
},
|
|
686
|
+
order: n,
|
|
687
|
+
orderBy: i,
|
|
688
|
+
isCollapseable: C
|
|
689
|
+
}
|
|
690
|
+
),
|
|
691
|
+
/* @__PURE__ */ D(ni, { children: [
|
|
692
|
+
d.map((X, U) => /* @__PURE__ */ l(
|
|
693
|
+
Yn,
|
|
694
|
+
{
|
|
695
|
+
item: X,
|
|
696
|
+
rowIndex: U,
|
|
697
|
+
isCollapseable: C,
|
|
698
|
+
cellsMetadata: o,
|
|
699
|
+
collapsedElement: S,
|
|
700
|
+
isRowSelected: !1,
|
|
701
|
+
onRowSelected: v
|
|
702
|
+
},
|
|
703
|
+
U
|
|
704
|
+
)),
|
|
705
|
+
(d.length === 0 || R > d.length) && /* @__PURE__ */ l(
|
|
706
|
+
ke,
|
|
707
|
+
{
|
|
708
|
+
style: {
|
|
709
|
+
height: (A ? 33 : 53) * (R - d.length)
|
|
710
|
+
},
|
|
711
|
+
children: /* @__PURE__ */ l(
|
|
712
|
+
we,
|
|
713
|
+
{
|
|
714
|
+
colSpan: C ? o.length + 1 : o.length,
|
|
715
|
+
children: d.length === 0 && /* @__PURE__ */ l(ri, { align: "center", children: "No results :(" })
|
|
716
|
+
}
|
|
717
|
+
)
|
|
718
|
+
}
|
|
719
|
+
)
|
|
720
|
+
] })
|
|
721
|
+
] }),
|
|
722
|
+
/* @__PURE__ */ l(
|
|
723
|
+
oi,
|
|
724
|
+
{
|
|
725
|
+
rowsPerPage: R,
|
|
726
|
+
rowsPerPageOptions: [5, 10],
|
|
727
|
+
component: "div",
|
|
728
|
+
count: z,
|
|
729
|
+
page: L,
|
|
730
|
+
onPageChange: K,
|
|
731
|
+
onRowsPerPageChange: Y
|
|
732
|
+
}
|
|
733
|
+
)
|
|
734
|
+
] });
|
|
735
|
+
}
|
|
736
|
+
const No = (e) => {
|
|
737
|
+
const { children: i, ...t } = e;
|
|
738
|
+
return /* @__PURE__ */ l(xi, { ...t, children: i });
|
|
739
|
+
}, Fo = (e) => {
|
|
740
|
+
const { children: i, ...t } = e;
|
|
741
|
+
return /* @__PURE__ */ l(ki, { ...t, children: i });
|
|
742
|
+
}, dt = (e) => e * Math.PI / 180, Ae = (e) => e * (180 / Math.PI), Xn = (e) => 0.05 * (5916575505e-1 / Math.pow(2, e - 1) / 2) * (Math.cos(dt(85.362 / 2)) / Math.sin(dt(85.362 / 2)));
|
|
743
|
+
const Zn = (e) => {
|
|
744
|
+
const i = he(), t = Le(null), [n, a] = k({ x: 0, y: 0 });
|
|
745
|
+
return I(() => {
|
|
746
|
+
i.screenSpaceEventHandler.setInputAction(
|
|
747
|
+
(o) => {
|
|
748
|
+
o != null && o.endPosition && a({ ...o.endPosition });
|
|
749
|
+
},
|
|
750
|
+
St.MOUSE_MOVE
|
|
751
|
+
);
|
|
752
|
+
}, [t, i]), I(() => {
|
|
753
|
+
const o = i.scene.globe.ellipsoid, d = i.camera.pickEllipsoid(
|
|
754
|
+
new me(n.x, n.y),
|
|
755
|
+
o
|
|
756
|
+
);
|
|
757
|
+
if (d) {
|
|
758
|
+
const u = o.cartesianToCartographic(d);
|
|
759
|
+
if (t.current) {
|
|
760
|
+
let v = "";
|
|
761
|
+
switch (e.projection) {
|
|
762
|
+
case ue.WEB_MERCATOR: {
|
|
763
|
+
const S = new zi(o).project(u);
|
|
764
|
+
v = `Mercator: ${S.y.toFixed(
|
|
765
|
+
Xe
|
|
766
|
+
)}m, ${S.x.toFixed(Xe)}m`, t.current.style.width = "220px";
|
|
767
|
+
break;
|
|
768
|
+
}
|
|
769
|
+
case ue.WGS84: {
|
|
770
|
+
const C = le.toDegrees(
|
|
771
|
+
u.longitude
|
|
772
|
+
).toFixed(Ye);
|
|
773
|
+
v = `WGS84: ${le.toDegrees(
|
|
774
|
+
u.latitude
|
|
775
|
+
).toFixed(Ye)}°N ${C}°E`, t.current.style.width = "200px";
|
|
776
|
+
break;
|
|
777
|
+
}
|
|
778
|
+
}
|
|
779
|
+
t.current.innerHTML = v;
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
}, [n, t, i, e.projection]), /* @__PURE__ */ l("div", { className: "trackerPosition", ref: t });
|
|
783
|
+
};
|
|
784
|
+
const ze = [
|
|
785
|
+
1,
|
|
786
|
+
2,
|
|
787
|
+
3,
|
|
788
|
+
5,
|
|
789
|
+
10,
|
|
790
|
+
20,
|
|
791
|
+
30,
|
|
792
|
+
50,
|
|
793
|
+
100,
|
|
794
|
+
200,
|
|
795
|
+
300,
|
|
796
|
+
500,
|
|
797
|
+
1e3,
|
|
798
|
+
2e3,
|
|
799
|
+
3e3,
|
|
800
|
+
5e3,
|
|
801
|
+
1e4,
|
|
802
|
+
2e4,
|
|
803
|
+
3e4,
|
|
804
|
+
5e4,
|
|
805
|
+
1e5,
|
|
806
|
+
2e5,
|
|
807
|
+
3e5,
|
|
808
|
+
5e5,
|
|
809
|
+
1e6,
|
|
810
|
+
2e6,
|
|
811
|
+
3e6,
|
|
812
|
+
5e6,
|
|
813
|
+
1e7,
|
|
814
|
+
2e7,
|
|
815
|
+
3e7,
|
|
816
|
+
5e7
|
|
817
|
+
], Jn = (e, i, t, n) => {
|
|
818
|
+
const a = Q(n, "METERS_UNIT") ?? "m", o = Q(n, "KILOMETERS_UNIT") ?? "km", d = {
|
|
819
|
+
barWidth: void 0,
|
|
820
|
+
distanceLabel: void 0,
|
|
821
|
+
lastLegendUpdate: i.lastLegendUpdate
|
|
822
|
+
}, u = new Ui(), v = new Date().getTime();
|
|
823
|
+
if (v < d.lastLegendUpdate + 250)
|
|
824
|
+
return;
|
|
825
|
+
d.lastLegendUpdate = v;
|
|
826
|
+
const C = e.scene.canvas.clientWidth, S = e.scene.canvas.clientHeight, A = e.scene.camera.getPickRay(
|
|
827
|
+
new Te(C / 2 | 0, S - 1)
|
|
828
|
+
), L = e.scene.camera.getPickRay(
|
|
829
|
+
new Te(1 + C / 2 | 0, S - 1)
|
|
830
|
+
), R = e.scene.globe, z = R.pick(A, e.scene), K = R.pick(L, e.scene);
|
|
831
|
+
if (!z || !K)
|
|
832
|
+
return;
|
|
833
|
+
const Y = R.ellipsoid.cartesianToCartographic(
|
|
834
|
+
z
|
|
835
|
+
), F = R.ellipsoid.cartesianToCartographic(
|
|
836
|
+
K
|
|
837
|
+
);
|
|
838
|
+
u.setEndPoints(Y, F);
|
|
839
|
+
const X = u.surfaceDistance, U = 100;
|
|
840
|
+
let V;
|
|
841
|
+
for (let j = ze.length - 1; !Oe(V) && j >= 0; --j)
|
|
842
|
+
ze[j] / X < U && (V = ze[j]);
|
|
843
|
+
if (Oe(V)) {
|
|
844
|
+
let j = "";
|
|
845
|
+
V >= 1e3 ? j = `${(V / 1e3).toString()} ${o}` : j = `${V.toString()} ${a}`, d.barWidth = V / X | 0, d.distanceLabel = j;
|
|
846
|
+
}
|
|
847
|
+
t(d);
|
|
848
|
+
}, Qn = (e) => {
|
|
849
|
+
const i = he(), [t, n] = k({
|
|
850
|
+
barWidth: void 0,
|
|
851
|
+
distanceLabel: void 0,
|
|
852
|
+
lastLegendUpdate: -1
|
|
853
|
+
});
|
|
854
|
+
I(() => {
|
|
855
|
+
const o = (v) => {
|
|
856
|
+
Jn(
|
|
857
|
+
i,
|
|
858
|
+
t,
|
|
859
|
+
n,
|
|
860
|
+
e.locale
|
|
861
|
+
);
|
|
862
|
+
}, d = new $i(), u = (v) => {
|
|
863
|
+
i.scene.globe.tilesLoaded && (o(new MouseEvent("mouse")), d.removeAll());
|
|
864
|
+
};
|
|
865
|
+
return d.add(i.scene.globe.tileLoadProgressEvent, u), i.camera.moveEnd.addEventListener(o), () => {
|
|
866
|
+
try {
|
|
867
|
+
Q(i, "_cesiumWidget") != null && i.camera.moveEnd.removeEventListener(o);
|
|
868
|
+
} catch (v) {
|
|
869
|
+
console.log('CESIUM camera "moveEnd" remove listener failed', v);
|
|
870
|
+
}
|
|
871
|
+
};
|
|
872
|
+
}, [i, e.locale, t]);
|
|
873
|
+
const a = (o) => 5 + (125 - o) / 2;
|
|
874
|
+
return /* @__PURE__ */ l("div", { className: "scalePosition", children: Oe(t.barWidth) && /* @__PURE__ */ D(oe, { children: [
|
|
875
|
+
/* @__PURE__ */ l("div", { className: "distance-legend-label", children: t.distanceLabel }),
|
|
876
|
+
/* @__PURE__ */ l(
|
|
877
|
+
"div",
|
|
878
|
+
{
|
|
879
|
+
className: "distance-legend-scale-bar",
|
|
880
|
+
style: {
|
|
881
|
+
height: "2px",
|
|
882
|
+
width: `${t.barWidth.toString()}px`,
|
|
883
|
+
left: `${a(t.barWidth).toString()}px`
|
|
884
|
+
}
|
|
885
|
+
}
|
|
886
|
+
)
|
|
887
|
+
] }) });
|
|
888
|
+
}, ie = {
|
|
889
|
+
MORPHING: ye.MORPHING,
|
|
890
|
+
COLUMBUS_VIEW: ye.COLUMBUS_VIEW,
|
|
891
|
+
SCENE2D: ye.SCENE2D,
|
|
892
|
+
SCENE3D: ye.SCENE3D
|
|
893
|
+
};
|
|
894
|
+
const ut = (e, i) => {
|
|
895
|
+
const n = Q(i.scene.globe, "_surface.tileProvider"), a = n._quadtree, o = i.canvas.height, d = Q(i.camera.frustum, "sseDenominator") ?? 1;
|
|
896
|
+
for (let u = 0; u <= 19; u++)
|
|
897
|
+
if (n.getLevelMaximumGeometricError(u) * o / (e * d) < a.maximumScreenSpaceError)
|
|
898
|
+
return u;
|
|
899
|
+
return null;
|
|
900
|
+
}, er = (e, i) => {
|
|
901
|
+
e = e || 10;
|
|
902
|
+
const t = [];
|
|
903
|
+
let n = 1e5, a = 0;
|
|
904
|
+
for (let o = 1e8; o > n; o = o - n) {
|
|
905
|
+
const d = ut(o, i);
|
|
906
|
+
if (d === null)
|
|
907
|
+
break;
|
|
908
|
+
if (d !== a) {
|
|
909
|
+
let u = o, v = o + n;
|
|
910
|
+
for (; v - u > e; )
|
|
911
|
+
o = u + (v - u) / 2, ut(o, i) === d ? u = o : v = o;
|
|
912
|
+
t.push({
|
|
913
|
+
level: d,
|
|
914
|
+
height: Math.round(o)
|
|
915
|
+
}), a = d, t.length >= 2 && (n = (t[t.length - 2].height - o) / 1e3);
|
|
916
|
+
}
|
|
917
|
+
}
|
|
918
|
+
return t;
|
|
919
|
+
}, tr = (e) => {
|
|
920
|
+
const i = he(), [t, n] = k(1), a = er(1, i);
|
|
921
|
+
return I(() => {
|
|
922
|
+
const o = () => {
|
|
923
|
+
const d = i.camera, u = 0.5;
|
|
924
|
+
let v = 0;
|
|
925
|
+
switch (i.scene.mode) {
|
|
926
|
+
case ie.SCENE3D:
|
|
927
|
+
v = i.scene.mapProjection.ellipsoid.cartesianToCartographic(
|
|
928
|
+
d.positionWC
|
|
929
|
+
).height;
|
|
930
|
+
break;
|
|
931
|
+
case ie.SCENE2D:
|
|
932
|
+
v = (d.frustum.right - d.frustum.left) * u;
|
|
933
|
+
break;
|
|
934
|
+
case ie.COLUMBUS_VIEW:
|
|
935
|
+
v = d.position.z;
|
|
936
|
+
break;
|
|
937
|
+
default:
|
|
938
|
+
v = 0;
|
|
939
|
+
break;
|
|
940
|
+
}
|
|
941
|
+
if (a.length > 0) {
|
|
942
|
+
const C = a.reduce((S, A) => Math.abs(A.height - v) < Math.abs(S.height - v) ? A : S);
|
|
943
|
+
n(C.level);
|
|
944
|
+
}
|
|
945
|
+
};
|
|
946
|
+
return i.camera.moveEnd.addEventListener(o), () => {
|
|
947
|
+
try {
|
|
948
|
+
Q(i, "_cesiumWidget") != null && i.camera.moveEnd.removeEventListener(o);
|
|
949
|
+
} catch (d) {
|
|
950
|
+
console.log(
|
|
951
|
+
'CESIUM camera "moveEnd"(from zoom tracker) remove listener failed',
|
|
952
|
+
d
|
|
953
|
+
);
|
|
954
|
+
}
|
|
955
|
+
};
|
|
956
|
+
}, [i, a.length]), /* @__PURE__ */ D("div", { className: "zoomLevel", children: [
|
|
957
|
+
/* @__PURE__ */ l("div", { className: "zoomLevelValue", children: t }),
|
|
958
|
+
/* @__PURE__ */ l("div", { className: "zoomLevelLabel", children: Q(e.locale, "ZOOM_LABEL") ?? "zoom" })
|
|
959
|
+
] });
|
|
960
|
+
};
|
|
961
|
+
const ir = -1, nr = (e) => {
|
|
962
|
+
const i = he(), [t, n] = k(), { sceneModes: a } = e, o = (d) => a.findIndex((u) => u === d) > ir;
|
|
963
|
+
return I(() => {
|
|
964
|
+
n(i.scene.mode);
|
|
965
|
+
}, []), /* @__PURE__ */ D(oe, { children: [
|
|
966
|
+
o(ie.SCENE3D) && /* @__PURE__ */ l(
|
|
967
|
+
be,
|
|
968
|
+
{
|
|
969
|
+
icon: /* @__PURE__ */ l(
|
|
970
|
+
"div",
|
|
971
|
+
{
|
|
972
|
+
className: `mapViewIcon ${t === ie.SCENE3D ? "mapViewCurrent" : ""}`,
|
|
973
|
+
children: /* @__PURE__ */ l("svg", { width: "100%", height: "100%", viewBox: "0 0 64 64", children: /* @__PURE__ */ l("path", { d: "m 32.401392,4.9330437 c -7.087603,0 -14.096095,2.884602 -19.10793,7.8946843 -5.0118352,5.010083 -7.9296167,11.987468 -7.9296167,19.072999 0,7.085531 2.9177815,14.097848 7.9296167,19.107931 4.837653,4.835961 11.541408,7.631372 18.374354,7.82482 0.05712,0.01231 0.454119,0.139729 0.454119,0.139729 l 0.03493,-0.104797 c 0.08246,7.84e-4 0.162033,0.03493 0.244525,0.03493 0.08304,0 0.161515,-0.03414 0.244526,-0.03493 l 0.03493,0.104797 c 0,0 0.309474,-0.129487 0.349323,-0.139729 6.867765,-0.168094 13.582903,-2.965206 18.444218,-7.82482 2.558195,-2.5573 4.551081,-5.638134 5.903547,-8.977584 1.297191,-3.202966 2.02607,-6.661489 2.02607,-10.130347 0,-6.237309 -2.366261,-12.31219 -6.322734,-17.116794 -0.0034,-0.02316 0.0049,-0.04488 0,-0.06986 -0.01733,-0.08745 -0.104529,-0.278855 -0.104797,-0.279458 -5.31e-4,-0.0012 -0.522988,-0.628147 -0.523984,-0.62878 -3.47e-4,-2.2e-4 -0.133444,-0.03532 -0.244525,-0.06987 C 51.944299,13.447603 51.751076,13.104317 51.474391,12.827728 46.462556,7.8176457 39.488996,4.9330437 32.401392,4.9330437 z m -2.130866,3.5281554 0.104797,9.6762289 c -4.111695,-0.08361 -7.109829,-0.423664 -9.257041,-0.943171 1.198093,-2.269271 2.524531,-4.124404 3.91241,-5.414496 2.167498,-2.0147811 3.950145,-2.8540169 5.239834,-3.3185619 z m 2.794579,0 c 1.280302,0.4754953 3.022186,1.3285948 5.065173,3.2486979 1.424667,1.338973 2.788862,3.303645 3.982275,5.728886 -2.29082,0.403367 -5.381258,0.621049 -8.942651,0.698645 L 33.065105,8.4611991 z m 5.728886,0.2445256 c 4.004072,1.1230822 7.793098,3.1481363 10.724195,6.0782083 0.03468,0.03466 0.07033,0.06991 0.104797,0.104797 -0.45375,0.313891 -0.923054,0.663002 -1.956205,1.082899 -0.647388,0.263114 -1.906242,0.477396 -2.829511,0.733577 -1.382296,-2.988132 -3.027146,-5.368585 -4.785716,-7.0213781 -0.422866,-0.397432 -0.835818,-0.6453247 -1.25756,-0.9781032 z m -15.33525,0.7685092 c -0.106753,0.09503 -0.207753,0.145402 -0.31439,0.244526 -1.684973,1.5662541 -3.298068,3.8232211 -4.680919,6.5672591 -0.343797,-0.14942 -1.035052,-0.273198 -1.292493,-0.419186 -0.956528,-0.542427 -1.362964,-1.022024 -1.537018,-1.292493 -0.0241,-0.03745 -0.01868,-0.0401 -0.03493,-0.06986 2.250095,-2.163342 4.948824,-3.869984 7.859752,-5.0302421 z m -9.641296,7.0912431 c 0.464973,0.571618 0.937729,1.169056 1.956205,1.746612 0.349907,0.198425 1.107143,0.335404 1.537018,0.523983 -1.20166,3.172984 -1.998037,7.051901 -2.165798,11.772162 C 14.256557,30.361384 12.934823,30.161483 12.280427,29.90959 10.644437,29.279855 9.6888882,28.674891 9.1714586,28.267775 8.6540289,27.860658 8.6474751,27.778724 8.6474751,27.778724 l -0.069864,0.03493 C 9.3100294,23.691285 11.163248,19.798527 13.817445,16.565477 z m 37.552149,0.523984 c 2.548924,3.289983 4.265057,7.202594 4.890513,11.318043 -0.650428,0.410896 -1.756876,1.001936 -3.563088,1.606882 -1.171552,0.392383 -3.163859,0.759153 -4.960377,1.117832 -0.04367,-4.752703 -0.784809,-8.591423 -1.88634,-11.807094 0.917574,-0.263678 2.170552,-0.486495 2.864443,-0.76851 1.274693,-0.518066 2.003942,-1.001558 2.654849,-1.467153 z m -31.439008,2.619917 c 2.487341,0.672766 5.775813,1.137775 10.479669,1.222628 l 0.104797,10.689263 0,0.03493 0,0.733577 c -5.435005,-0.09059 -9.512219,-0.519044 -12.610536,-1.117831 0.106127,-4.776683 0.879334,-8.55791 2.02607,-11.562569 z m 23.264866,0.31439 c 1.073459,3.067541 1.833795,6.821314 1.816476,11.702298 -3.054474,0.423245 -7.062018,0.648559 -11.702298,0.698644 l 0,-0.838373 -0.104796,-10.654331 c 4.082416,-0.0864 7.404468,-0.403886 9.990618,-0.908238 z M 8.2632205,30.922625 c 0.7558676,0.510548 1.5529563,1.013339 3.0041715,1.57195 0.937518,0.360875 2.612202,0.647642 3.91241,0.978102 0.112814,3.85566 0.703989,7.107756 1.606883,9.920754 -1.147172,-0.324262 -2.644553,-0.640648 -3.423359,-0.978102 -1.516688,-0.657177 -2.386627,-1.287332 -2.864443,-1.71168 -0.477816,-0.424347 -0.489051,-0.489051 -0.489051,-0.489051 L 9.8002387,40.319395 C 8.791691,37.621767 8.1584238,34.769583 8.1584238,31.900727 c 0,-0.330153 0.090589,-0.648169 0.1047967,-0.978102 z m 48.2763445,0.419186 c 0.0047,0.188973 0.06986,0.36991 0.06986,0.558916 0,2.938869 -0.620228,5.873558 -1.676747,8.628261 -0.07435,0.07583 -0.06552,0.07411 -0.454119,0.349323 -0.606965,0.429857 -1.631665,1.042044 -3.318562,1.676747 -1.208528,0.454713 -3.204964,0.850894 -5.135038,1.25756 0.84593,-2.765726 1.41808,-6.005357 1.606883,-9.815957 2.232369,-0.413371 4.483758,-0.840201 5.938479,-1.327425 1.410632,-0.472457 2.153108,-0.89469 2.96924,-1.327425 z m -38.530252,2.864443 c 3.208141,0.56697 7.372279,0.898588 12.575603,0.978103 l 0.174662,9.885821 c -4.392517,-0.06139 -8.106722,-0.320566 -10.863925,-0.803441 -1.051954,-2.664695 -1.692909,-6.043794 -1.88634,-10.060483 z m 26.793022,0.31439 c -0.246298,3.923551 -0.877762,7.263679 -1.816476,9.885822 -2.561957,0.361954 -5.766249,0.560708 -9.431703,0.62878 l -0.174661,-9.815957 c 4.491734,-0.04969 8.334769,-0.293032 11.42284,-0.698645 z M 12.035901,44.860585 c 0.09977,0.04523 0.105535,0.09465 0.209594,0.139729 1.337656,0.579602 3.441099,1.058072 5.589157,1.537018 1.545042,3.399208 3.548524,5.969402 5.589157,7.789888 -3.034411,-1.215537 -5.871615,-3.007978 -8.174142,-5.309699 -1.245911,-1.245475 -2.271794,-2.662961 -3.213766,-4.156936 z m 40.69605,0 c -0.941972,1.493975 -1.967855,2.911461 -3.213765,4.156936 -2.74253,2.741571 -6.244106,4.696717 -9.955686,5.868615 0.261347,-0.241079 0.507495,-0.394491 0.768509,-0.663713 1.674841,-1.727516 3.320792,-4.181056 4.645987,-7.265904 2.962447,-0.503021 5.408965,-1.122293 7.161107,-1.781544 0.284034,-0.106865 0.337297,-0.207323 0.593848,-0.31439 z m -31.404076,2.305527 c 2.645807,0.376448 5.701178,0.649995 9.466635,0.698645 l 0.139729,7.789888 c -1.38739,-0.480844 -3.316218,-1.29837 -5.659022,-3.388427 -1.388822,-1.238993 -2.743668,-3.0113 -3.947342,-5.100106 z m 20.365491,0.104797 c -1.04872,2.041937 -2.174337,3.779068 -3.353494,4.995309 -1.853177,1.911459 -3.425515,2.82679 -4.611055,3.353494 l -0.139729,-7.789887 c 3.13091,-0.05714 5.728238,-0.278725 8.104278,-0.558916 z" }) })
|
|
974
|
+
}
|
|
975
|
+
),
|
|
976
|
+
onClick: () => {
|
|
977
|
+
i.scene.morphTo3D(), n(ie.SCENE3D);
|
|
978
|
+
}
|
|
979
|
+
}
|
|
980
|
+
),
|
|
981
|
+
o(ie.SCENE2D) && /* @__PURE__ */ l(
|
|
982
|
+
be,
|
|
983
|
+
{
|
|
984
|
+
icon: /* @__PURE__ */ l(
|
|
985
|
+
"div",
|
|
986
|
+
{
|
|
987
|
+
className: `mapViewIcon ${t === ie.SCENE2D ? "mapViewCurrent" : ""}`,
|
|
988
|
+
children: /* @__PURE__ */ l("svg", { width: "100%", height: "100%", viewBox: "0 0 64 64", children: /* @__PURE__ */ l("path", { d: "m 2.9825053,17.550598 0,1.368113 0,26.267766 0,1.368113 1.36811,0 54.9981397,0 1.36811,0 0,-1.368113 0,-26.267766 0,-1.368113 -1.36811,0 -54.9981397,0 -1.36811,0 z m 2.73623,2.736226 10.3292497,0 0,10.466063 -10.3292497,0 0,-10.466063 z m 13.0654697,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 10.32926,0 0,10.466063 -10.32926,0 0,-10.466063 z m -41.9326497,13.202288 10.3292497,0 0,10.329252 -10.3292497,0 0,-10.329252 z m 13.0654697,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 10.32926,0 0,10.329252 -10.32926,0 0,-10.329252 z" }) })
|
|
989
|
+
}
|
|
990
|
+
),
|
|
991
|
+
onClick: () => {
|
|
992
|
+
i.scene.morphTo2D(), n(ie.SCENE2D);
|
|
993
|
+
}
|
|
994
|
+
}
|
|
995
|
+
),
|
|
996
|
+
o(ie.COLUMBUS_VIEW) && /* @__PURE__ */ l(
|
|
997
|
+
be,
|
|
998
|
+
{
|
|
999
|
+
icon: /* @__PURE__ */ l(
|
|
1000
|
+
"div",
|
|
1001
|
+
{
|
|
1002
|
+
className: `mapViewIcon ${t === ie.COLUMBUS_VIEW ? "mapViewCurrent" : ""}`,
|
|
1003
|
+
children: /* @__PURE__ */ l("svg", { width: "100%", height: "100%", viewBox: "0 0 64 64", children: /* @__PURE__ */ l("path", { d: "m 14.723969,17.675598 -0.340489,0.817175 -11.1680536,26.183638 -0.817175,1.872692 2.076986,0 54.7506996,0 2.07698,0 -0.81717,-1.872692 -11.16805,-26.183638 -0.34049,-0.817175 -0.91933,0 -32.414586,0 -0.919322,0 z m 1.838643,2.723916 6.196908,0 -2.928209,10.418977 -7.729111,0 4.460412,-10.418977 z m 9.02297,0 4.903049,0 0,10.418977 -7.831258,0 2.928209,-10.418977 z m 7.626964,0 5.584031,0 2.62176,10.418977 -8.205791,0 0,-10.418977 z m 8.410081,0 5.51593,0 4.46042,10.418977 -7.38863,0 -2.58772,-10.418977 z m -30.678091,13.142892 8.103649,0 -2.89416,10.282782 -9.6018026,0 4.3923136,-10.282782 z m 10.929711,0 8.614384,0 0,10.282782 -11.508544,0 2.89416,-10.282782 z m 11.338299,0 8.852721,0 2.58772,10.282782 -11.440441,0 0,-10.282782 z m 11.678781,0 7.86531,0 4.39231,10.282782 -9.6699,0 -2.58772,-10.282782 z" }) })
|
|
1004
|
+
}
|
|
1005
|
+
),
|
|
1006
|
+
onClick: () => {
|
|
1007
|
+
i.scene.morphToColumbusView(), n(ie.COLUMBUS_VIEW);
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
)
|
|
1011
|
+
] });
|
|
1012
|
+
};
|
|
1013
|
+
const rr = Me(
|
|
1014
|
+
(e) => Re({
|
|
1015
|
+
mapContainer: {
|
|
1016
|
+
width: "60px",
|
|
1017
|
+
height: "60px",
|
|
1018
|
+
border: `${e.palette.background.paper} 2px solid`
|
|
1019
|
+
}
|
|
1020
|
+
})
|
|
1021
|
+
), or = (e) => {
|
|
1022
|
+
const i = he(), { baseMaps: t } = e, [n, a] = k(" "), [o, d] = k(), u = rr();
|
|
1023
|
+
I(() => {
|
|
1024
|
+
const C = t == null ? void 0 : t.maps.find((S) => S.isCurrent);
|
|
1025
|
+
C && (d(C), a(C.title !== void 0 ? C.title : " "));
|
|
1026
|
+
}, [t]);
|
|
1027
|
+
const v = (C) => {
|
|
1028
|
+
var S, A;
|
|
1029
|
+
if (t) {
|
|
1030
|
+
(S = i.layersManager) == null || S.removeBaseMapLayers();
|
|
1031
|
+
const L = t.maps.find(
|
|
1032
|
+
(R) => R.id === C
|
|
1033
|
+
);
|
|
1034
|
+
L && ((A = i.layersManager) == null || A.setBaseMapLayers(L), d(L), t.maps.forEach((R) => {
|
|
1035
|
+
R.isCurrent = L === R;
|
|
1036
|
+
}));
|
|
1037
|
+
}
|
|
1038
|
+
};
|
|
1039
|
+
return /* @__PURE__ */ D(oe, { children: [
|
|
1040
|
+
/* @__PURE__ */ l("label", { className: "mapLabel", children: n }),
|
|
1041
|
+
/* @__PURE__ */ l("ul", { className: "mapSelector", children: t == null ? void 0 : t.maps.map((C) => /* @__PURE__ */ l(
|
|
1042
|
+
"li",
|
|
1043
|
+
{
|
|
1044
|
+
className: `mapContainer ${u.mapContainer} ${C === o ? "mapContainerSelected" : ""}`,
|
|
1045
|
+
children: /* @__PURE__ */ l(
|
|
1046
|
+
"img",
|
|
1047
|
+
{
|
|
1048
|
+
alt: "",
|
|
1049
|
+
className: "mapContainerImg",
|
|
1050
|
+
src: C.thumbnail,
|
|
1051
|
+
onMouseOver: () => {
|
|
1052
|
+
a(C.title);
|
|
1053
|
+
},
|
|
1054
|
+
onMouseOut: () => {
|
|
1055
|
+
a(
|
|
1056
|
+
(o == null ? void 0 : o.title) !== void 0 ? o.title : " "
|
|
1057
|
+
);
|
|
1058
|
+
},
|
|
1059
|
+
onClick: () => {
|
|
1060
|
+
v(C.id);
|
|
1061
|
+
}
|
|
1062
|
+
}
|
|
1063
|
+
)
|
|
1064
|
+
},
|
|
1065
|
+
C.id
|
|
1066
|
+
)) })
|
|
1067
|
+
] });
|
|
1068
|
+
};
|
|
1069
|
+
const $e = "ic_settings_24px", sr = (e) => {
|
|
1070
|
+
const [i, t] = k(!1), { sceneModes: n, baseMaps: a, locale: o } = e, d = Le(null), u = Q(o, "MAP_SETTINGS_DIALOG_TITLE") ?? "Map Settings", v = Q(o, "MAP_SETTINGS_SCENE_MODE_TITLE") ?? "Scene Mode", C = Q(o, "MAP_SETTINGS_BASE_MAP_TITLE") ?? "Base Map";
|
|
1071
|
+
return I(() => {
|
|
1072
|
+
const S = (A) => {
|
|
1073
|
+
var z;
|
|
1074
|
+
const L = A.target, R = Q(d, "current");
|
|
1075
|
+
R && !R.contains(L) && L.id !== $e && ((z = L.parentElement) == null ? void 0 : z.id) !== $e && (document.removeEventListener("click", S, !1), t(!1));
|
|
1076
|
+
};
|
|
1077
|
+
return document.addEventListener("click", S, !1), () => {
|
|
1078
|
+
document.removeEventListener("click", S, !1);
|
|
1079
|
+
};
|
|
1080
|
+
}), /* @__PURE__ */ D(oe, { children: [
|
|
1081
|
+
/* @__PURE__ */ l(
|
|
1082
|
+
be,
|
|
1083
|
+
{
|
|
1084
|
+
icon: /* @__PURE__ */ l("div", { className: "settingsIconContainer", children: /* @__PURE__ */ l(
|
|
1085
|
+
"svg",
|
|
1086
|
+
{
|
|
1087
|
+
width: "100%",
|
|
1088
|
+
height: "100%",
|
|
1089
|
+
viewBox: "0 0 24 24",
|
|
1090
|
+
id: $e,
|
|
1091
|
+
x: "288",
|
|
1092
|
+
y: "24",
|
|
1093
|
+
children: /* @__PURE__ */ l("path", { d: "M19.43 12.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46c-.12-.22-.39-.3-.61-.22l-2.49 1c-.52-.4-1.08-.73-1.69-.98l-.38-2.65A.488.488 0 0 0 14 2h-4c-.25 0-.46.18-.49.42l-.38 2.65c-.61.25-1.17.59-1.69.98l-2.49-1c-.23-.09-.49 0-.61.22l-2 3.46c-.13.22-.07.49.12.64l2.11 1.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11 1.65c-.19.15-.24.42-.12.64l2 3.46c.12.22.39.3.61.22l2.49-1c.52.4 1.08.73 1.69.98l.38 2.65c.03.24.24.42.49.42h4c.25 0 .46-.18.49-.42l.38-2.65c.61-.25 1.17-.59 1.69-.98l2.49 1c.23.09.49 0 .61-.22l2-3.46c.12-.22.07-.49-.12-.64l-2.11-1.65zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z" })
|
|
1094
|
+
}
|
|
1095
|
+
) }),
|
|
1096
|
+
onClick: () => {
|
|
1097
|
+
t(!i);
|
|
1098
|
+
}
|
|
1099
|
+
}
|
|
1100
|
+
),
|
|
1101
|
+
i && /* @__PURE__ */ l(
|
|
1102
|
+
"div",
|
|
1103
|
+
{
|
|
1104
|
+
id: "dialog-portal-example",
|
|
1105
|
+
className: "settingsDialogPortal",
|
|
1106
|
+
ref: d,
|
|
1107
|
+
children: /* @__PURE__ */ D(
|
|
1108
|
+
ci,
|
|
1109
|
+
{
|
|
1110
|
+
open: i,
|
|
1111
|
+
onClosed: () => {
|
|
1112
|
+
t(!1);
|
|
1113
|
+
},
|
|
1114
|
+
children: [
|
|
1115
|
+
/* @__PURE__ */ l(di, { children: u }),
|
|
1116
|
+
/* @__PURE__ */ D(ui, { children: [
|
|
1117
|
+
/* @__PURE__ */ l("h4", { className: "sectionLabel", children: v }),
|
|
1118
|
+
/* @__PURE__ */ l(ae, { className: "mapScenesContainer", children: /* @__PURE__ */ l(nr, { sceneModes: n }) }),
|
|
1119
|
+
/* @__PURE__ */ l(ae, { className: "baseMapsContainer", children: a && /* @__PURE__ */ D(oe, { children: [
|
|
1120
|
+
/* @__PURE__ */ l("h4", { className: "sectionLabel", children: C }),
|
|
1121
|
+
/* @__PURE__ */ l(or, { baseMaps: a })
|
|
1122
|
+
] }) })
|
|
1123
|
+
] })
|
|
1124
|
+
]
|
|
1125
|
+
}
|
|
1126
|
+
)
|
|
1127
|
+
}
|
|
1128
|
+
)
|
|
1129
|
+
] });
|
|
1130
|
+
};
|
|
1131
|
+
const ar = /* @__PURE__ */ l(
|
|
1132
|
+
"svg",
|
|
1133
|
+
{
|
|
1134
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1135
|
+
enableBackground: "new 0 0 24 24",
|
|
1136
|
+
height: "24",
|
|
1137
|
+
width: "24",
|
|
1138
|
+
viewBox: "0 0 612 612",
|
|
1139
|
+
children: /* @__PURE__ */ D("g", { xmlns: "http://www.w3.org/2000/svg", children: [
|
|
1140
|
+
/* @__PURE__ */ l("path", { d: "M322.4,173.9l-129,16.2l-4.6,21.4l25.3,4.7c16.5,3.9,19.8,9.9,16.2,26.4l-41.5,195.3c-10.9,50.5,5.9,74.3,45.5,74.3 c30.7,0,66.3-14.2,82.5-33.6l4.9-23.4c-11.3,9.9-27.7,13.9-38.6,13.9c-15.5,0-21.1-10.9-17.1-30L322.4,173.9z" }),
|
|
1141
|
+
/* @__PURE__ */ l("circle", { cx: "270.1", cy: "56.3", r: "56.3" })
|
|
1142
|
+
] })
|
|
1143
|
+
}
|
|
1144
|
+
), lr = ({ onClick: e }) => /* @__PURE__ */ l(ae, { onClick: e, className: "mapLegendToggleContainer", children: /* @__PURE__ */ l(be, { icon: ar, className: "mapLegendIcon" }) }), cr = ({
|
|
1145
|
+
legend: { legendImg: e, legendDoc: i, layer: t },
|
|
1146
|
+
docText: n,
|
|
1147
|
+
imgText: a
|
|
1148
|
+
}) => {
|
|
1149
|
+
const o = ge(() => {
|
|
1150
|
+
window.open(e, "_blank");
|
|
1151
|
+
}, [e]);
|
|
1152
|
+
ge(() => {
|
|
1153
|
+
window.open(i, "_blank");
|
|
1154
|
+
}, [i]);
|
|
1155
|
+
const d = ge(() => {
|
|
1156
|
+
const C = /* @__PURE__ */ l(ae, { className: "layerNameContainer", children: /* @__PURE__ */ l(
|
|
1157
|
+
"h3",
|
|
1158
|
+
{
|
|
1159
|
+
style: { maxWidth: `${15}ch` },
|
|
1160
|
+
className: "layerName",
|
|
1161
|
+
children: t
|
|
1162
|
+
}
|
|
1163
|
+
) });
|
|
1164
|
+
return (t ?? "").length > 15 ? /* @__PURE__ */ l(je, { content: t, children: C }) : C;
|
|
1165
|
+
}, [t]), u = ge(() => [
|
|
1166
|
+
typeof e == "string" && /* @__PURE__ */ l(
|
|
1167
|
+
"a",
|
|
1168
|
+
{
|
|
1169
|
+
className: "legendAction",
|
|
1170
|
+
href: e,
|
|
1171
|
+
target: "_blank",
|
|
1172
|
+
rel: "noreferrer",
|
|
1173
|
+
children: a
|
|
1174
|
+
}
|
|
1175
|
+
),
|
|
1176
|
+
typeof i == "string" && /* @__PURE__ */ l(
|
|
1177
|
+
"a",
|
|
1178
|
+
{
|
|
1179
|
+
className: "legendAction",
|
|
1180
|
+
href: i,
|
|
1181
|
+
target: "_blank",
|
|
1182
|
+
rel: "noreferrer",
|
|
1183
|
+
children: n
|
|
1184
|
+
}
|
|
1185
|
+
)
|
|
1186
|
+
], [e, a, i, n]);
|
|
1187
|
+
return /* @__PURE__ */ D(ae, { className: "mapLegend", children: [
|
|
1188
|
+
d(),
|
|
1189
|
+
/* @__PURE__ */ l(
|
|
1190
|
+
"img",
|
|
1191
|
+
{
|
|
1192
|
+
alt: "Map Legend",
|
|
1193
|
+
className: "legendImg",
|
|
1194
|
+
src: e,
|
|
1195
|
+
onClick: o
|
|
1196
|
+
}
|
|
1197
|
+
),
|
|
1198
|
+
/* @__PURE__ */ l(ae, { className: "legendActionsContainer", children: u() })
|
|
1199
|
+
] });
|
|
1200
|
+
}, dr = ({
|
|
1201
|
+
legends: e,
|
|
1202
|
+
actionsTexts: { docText: i, imgText: t },
|
|
1203
|
+
noLegendsText: n
|
|
1204
|
+
}) => {
|
|
1205
|
+
const a = ge(() => /* @__PURE__ */ l(ae, { className: "noLegendsContainer", children: /* @__PURE__ */ l("h2", { className: "noLegendsMsg", children: n }) }), [n]), o = ge(() => e.length ? e.map((d, u) => /* @__PURE__ */ l(
|
|
1206
|
+
cr,
|
|
1207
|
+
{
|
|
1208
|
+
legend: d,
|
|
1209
|
+
docText: i,
|
|
1210
|
+
imgText: t
|
|
1211
|
+
},
|
|
1212
|
+
`${d.layer}_${u}`
|
|
1213
|
+
)) : a(), [e]);
|
|
1214
|
+
return /* @__PURE__ */ l(ae, { className: "mapLegendsList", children: o() });
|
|
1215
|
+
}, ur = ({
|
|
1216
|
+
isOpen: e,
|
|
1217
|
+
toggleSidebar: i,
|
|
1218
|
+
title: t = "Map Legends",
|
|
1219
|
+
noLegendsText: n = "No legends to display...",
|
|
1220
|
+
actionsTexts: a = { docText: "Docs", imgText: "View Image" },
|
|
1221
|
+
legends: o = []
|
|
1222
|
+
}) => e ? /* @__PURE__ */ D(
|
|
1223
|
+
hi,
|
|
1224
|
+
{
|
|
1225
|
+
className: "mapLegendSidebarContainer",
|
|
1226
|
+
modal: !1,
|
|
1227
|
+
dismissible: !0,
|
|
1228
|
+
open: e,
|
|
1229
|
+
children: [
|
|
1230
|
+
/* @__PURE__ */ l(pi, { className: "sidebarHeaderContainer", children: /* @__PURE__ */ l(mi, { className: "sidebarTitle", children: t }) }),
|
|
1231
|
+
/* @__PURE__ */ D(gi, { className: "sidebarContent", children: [
|
|
1232
|
+
/* @__PURE__ */ l(
|
|
1233
|
+
be,
|
|
1234
|
+
{
|
|
1235
|
+
onClick: i,
|
|
1236
|
+
className: "mapLegendCloseBtn",
|
|
1237
|
+
icon: { icon: "close", size: "small" }
|
|
1238
|
+
}
|
|
1239
|
+
),
|
|
1240
|
+
/* @__PURE__ */ l(
|
|
1241
|
+
dr,
|
|
1242
|
+
{
|
|
1243
|
+
noLegendsText: n,
|
|
1244
|
+
legends: o,
|
|
1245
|
+
actionsTexts: a
|
|
1246
|
+
}
|
|
1247
|
+
)
|
|
1248
|
+
] })
|
|
1249
|
+
]
|
|
1250
|
+
}
|
|
1251
|
+
) : null, Rt = (e, i, t) => {
|
|
1252
|
+
let n;
|
|
1253
|
+
if (e.scene.mode !== ye.SCENE2D)
|
|
1254
|
+
n = e.scene.pickPosition(new Te(i, t));
|
|
1255
|
+
else {
|
|
1256
|
+
const a = e.scene.globe.ellipsoid;
|
|
1257
|
+
n = e.camera.pickEllipsoid(new Te(i, t), a);
|
|
1258
|
+
}
|
|
1259
|
+
return Be.fromCartesian(n);
|
|
1260
|
+
}, hr = (e, i, t) => {
|
|
1261
|
+
const n = Rt(e, i, t);
|
|
1262
|
+
return {
|
|
1263
|
+
type: "Feature",
|
|
1264
|
+
properties: {},
|
|
1265
|
+
geometry: {
|
|
1266
|
+
type: "Point",
|
|
1267
|
+
coordinates: [
|
|
1268
|
+
le.toDegrees(n.longitude),
|
|
1269
|
+
le.toDegrees(n.latitude)
|
|
1270
|
+
]
|
|
1271
|
+
}
|
|
1272
|
+
};
|
|
1273
|
+
}, pr = (e, i, t) => {
|
|
1274
|
+
try {
|
|
1275
|
+
const n = Rt(e, i, t);
|
|
1276
|
+
return {
|
|
1277
|
+
longitude: le.toDegrees(n.longitude),
|
|
1278
|
+
latitude: le.toDegrees(n.latitude)
|
|
1279
|
+
};
|
|
1280
|
+
} catch {
|
|
1281
|
+
return;
|
|
1282
|
+
}
|
|
1283
|
+
}, de = document.createElement("canvas"), te = de.getContext("2d"), ht = (e) => {
|
|
1284
|
+
const n = (e == null ? void 0 : e.data) ?? [];
|
|
1285
|
+
for (let a = 3; a < n.length; a += 4)
|
|
1286
|
+
if (n[a] < 255)
|
|
1287
|
+
return !0;
|
|
1288
|
+
return !1;
|
|
1289
|
+
}, mr = async (e, i) => (i && i.tileTransparencyCheckedCounter++, new Promise((t, n) => {
|
|
1290
|
+
try {
|
|
1291
|
+
te == null || te.clearRect(0, 0, de.width, de.height);
|
|
1292
|
+
let a;
|
|
1293
|
+
if (e instanceof HTMLImageElement)
|
|
1294
|
+
a = e;
|
|
1295
|
+
else if (e instanceof ImageBitmap) {
|
|
1296
|
+
de.width = e.width, de.height = e.height, te == null || te.drawImage(e, 0, 0);
|
|
1297
|
+
const o = te == null ? void 0 : te.getImageData(
|
|
1298
|
+
0,
|
|
1299
|
+
0,
|
|
1300
|
+
de.width,
|
|
1301
|
+
de.height
|
|
1302
|
+
), d = ht(o);
|
|
1303
|
+
d && i && (i.tileTransparencyCheckedCounter = i.maxTilesForTransparencyCheck), t(d);
|
|
1304
|
+
return;
|
|
1305
|
+
} else
|
|
1306
|
+
a = new Image(), a.crossOrigin = "anonymous", a.src = e;
|
|
1307
|
+
a.onload = () => {
|
|
1308
|
+
de.width = a.width, de.height = a.height, te == null || te.drawImage(a, 0, 0);
|
|
1309
|
+
const o = te == null ? void 0 : te.getImageData(
|
|
1310
|
+
0,
|
|
1311
|
+
0,
|
|
1312
|
+
de.width,
|
|
1313
|
+
de.height
|
|
1314
|
+
);
|
|
1315
|
+
ht(o) ? (i && (i.tileTransparencyCheckedCounter = i.maxTilesForTransparencyCheck), t(!0)) : t(!1);
|
|
1316
|
+
};
|
|
1317
|
+
} catch (a) {
|
|
1318
|
+
console.error("Could not determine image transparency. Error => ", a), n(a);
|
|
1319
|
+
}
|
|
1320
|
+
})), xe = (e, i) => {
|
|
1321
|
+
const { west: t, east: n, north: a, south: o } = e, {
|
|
1322
|
+
west: d,
|
|
1323
|
+
east: u,
|
|
1324
|
+
north: v,
|
|
1325
|
+
south: C
|
|
1326
|
+
} = i;
|
|
1327
|
+
return t >= d && n <= u && a <= v && o >= C;
|
|
1328
|
+
}, Ne = 3, De = "hasTransparency";
|
|
1329
|
+
function tt(e, i, t, n, a) {
|
|
1330
|
+
return setTimeout(() => {
|
|
1331
|
+
var u;
|
|
1332
|
+
const o = (u = this.layerListInstance.find(
|
|
1333
|
+
/* eslint-disable */
|
|
1334
|
+
(v) => {
|
|
1335
|
+
var C, S;
|
|
1336
|
+
return ((C = v._imageryProvider._resource) == null ? void 0 : C._url) === ((S = this._resource) == null ? void 0 : S._url);
|
|
1337
|
+
}
|
|
1338
|
+
/* eslint-enable */
|
|
1339
|
+
)) == null ? void 0 : u.meta, d = Q(o, De) === !0;
|
|
1340
|
+
this.tileTransparencyCheckedCounter < Ne && !d && mr(a == null ? void 0 : a.url, this).then(
|
|
1341
|
+
(v) => {
|
|
1342
|
+
var C;
|
|
1343
|
+
(C = this.mapViewer.layersManager) == null || C.addMetaToLayer(
|
|
1344
|
+
{ [De]: v },
|
|
1345
|
+
/* eslint-disable */
|
|
1346
|
+
(S) => S._imageryProvider._resource._url === this._resource._url
|
|
1347
|
+
);
|
|
1348
|
+
}
|
|
1349
|
+
);
|
|
1350
|
+
}, 0), e(i, t, n, a);
|
|
1351
|
+
}
|
|
1352
|
+
class Bt extends Ze {
|
|
1353
|
+
constructor(t, n) {
|
|
1354
|
+
var a;
|
|
1355
|
+
super(t);
|
|
1356
|
+
J(this, "layerListInstance");
|
|
1357
|
+
J(this, "mapViewer");
|
|
1358
|
+
J(this, "maxTilesForTransparencyCheck", Ne);
|
|
1359
|
+
J(this, "tileTransparencyCheckedCounter", 0);
|
|
1360
|
+
this.layerListInstance = (a = n.layersManager) == null ? void 0 : a.layerList, this.mapViewer = n;
|
|
1361
|
+
}
|
|
1362
|
+
requestImage(t, n, a, o) {
|
|
1363
|
+
return tt.call(
|
|
1364
|
+
this,
|
|
1365
|
+
super.requestImage.bind(this),
|
|
1366
|
+
t,
|
|
1367
|
+
n,
|
|
1368
|
+
a,
|
|
1369
|
+
o
|
|
1370
|
+
);
|
|
1371
|
+
}
|
|
1372
|
+
}
|
|
1373
|
+
class Nt extends Je {
|
|
1374
|
+
constructor(t, n) {
|
|
1375
|
+
var a;
|
|
1376
|
+
super(t);
|
|
1377
|
+
J(this, "layerListInstance");
|
|
1378
|
+
J(this, "mapViewer");
|
|
1379
|
+
J(this, "maxTilesForTransparencyCheck", Ne);
|
|
1380
|
+
J(this, "tileTransparencyCheckedCounter", 0);
|
|
1381
|
+
this.layerListInstance = (a = n.layersManager) == null ? void 0 : a.layerList, this.mapViewer = n;
|
|
1382
|
+
}
|
|
1383
|
+
requestImage(t, n, a, o) {
|
|
1384
|
+
return tt.call(
|
|
1385
|
+
this,
|
|
1386
|
+
super.requestImage.bind(this),
|
|
1387
|
+
t,
|
|
1388
|
+
n,
|
|
1389
|
+
a,
|
|
1390
|
+
o
|
|
1391
|
+
);
|
|
1392
|
+
}
|
|
1393
|
+
}
|
|
1394
|
+
class Ft extends Qe {
|
|
1395
|
+
constructor(t, n) {
|
|
1396
|
+
var a;
|
|
1397
|
+
super(t);
|
|
1398
|
+
J(this, "layerListInstance");
|
|
1399
|
+
J(this, "mapViewer");
|
|
1400
|
+
J(this, "maxTilesForTransparencyCheck", Ne);
|
|
1401
|
+
J(this, "tileTransparencyCheckedCounter", 0);
|
|
1402
|
+
this.layerListInstance = (a = n.layersManager) == null ? void 0 : a.layerList, this.mapViewer = n;
|
|
1403
|
+
}
|
|
1404
|
+
requestImage(t, n, a, o) {
|
|
1405
|
+
return tt.call(
|
|
1406
|
+
this,
|
|
1407
|
+
super.requestImage.bind(this),
|
|
1408
|
+
t,
|
|
1409
|
+
n,
|
|
1410
|
+
a,
|
|
1411
|
+
o
|
|
1412
|
+
);
|
|
1413
|
+
}
|
|
1414
|
+
}
|
|
1415
|
+
const gr = 1, fr = -1, pt = "TRANSPARENT_BASE_LAYER";
|
|
1416
|
+
class yr {
|
|
1417
|
+
constructor(i, t, n) {
|
|
1418
|
+
J(this, "mapViewer");
|
|
1419
|
+
J(this, "legendsList");
|
|
1420
|
+
J(this, "layerUpdated");
|
|
1421
|
+
J(this, "layers");
|
|
1422
|
+
J(this, "legendsExtractor");
|
|
1423
|
+
this.mapViewer = i, this.layers = this.mapViewer.imageryLayers._layers, this.legendsList = [], this.legendsExtractor = t, this.layerUpdated = new Wi(), n && this.layerUpdated.addEventListener(n, this), this.mapViewer.shouldOptimizedTileRequests && (this.layerUpdated.addEventListener((a) => {
|
|
1424
|
+
const o = Object.keys(a);
|
|
1425
|
+
o.length === 1 && o[0] === De && (this.markRelevantLayersForExtent(), this.hideNonRelevantLayers());
|
|
1426
|
+
}), this.mapViewer.imageryLayers.layerRemoved.addEventListener(() => {
|
|
1427
|
+
this.setLegends(), this.markRelevantLayersForExtent(), this.hideNonRelevantLayers();
|
|
1428
|
+
}), this.mapViewer.imageryLayers.layerMoved.addEventListener(() => {
|
|
1429
|
+
this.markRelevantLayersForExtent(), this.hideNonRelevantLayers();
|
|
1430
|
+
}), this.mapViewer.imageryLayers.layerAdded.addEventListener(() => {
|
|
1431
|
+
this.markRelevantLayersForExtent(), this.hideNonRelevantLayers();
|
|
1432
|
+
}), this.mapViewer.camera.moveEnd.addEventListener(() => {
|
|
1433
|
+
this.markRelevantLayersForExtent(), this.hideNonRelevantLayers();
|
|
1434
|
+
}));
|
|
1435
|
+
}
|
|
1436
|
+
get layerList() {
|
|
1437
|
+
return this.layers;
|
|
1438
|
+
}
|
|
1439
|
+
/* eslint-disable */
|
|
1440
|
+
addMetaToLayer(i, t) {
|
|
1441
|
+
const n = this.layers.find(t);
|
|
1442
|
+
n && (n.meta = { ...n.meta ?? {}, ...i }, this.setLegends(), this.layerUpdated.raiseEvent(i));
|
|
1443
|
+
}
|
|
1444
|
+
/* eslint-enable */
|
|
1445
|
+
setBaseMapLayers(i) {
|
|
1446
|
+
i.baseRasteLayers.sort(
|
|
1447
|
+
(n, a) => n.zIndex - a.zIndex
|
|
1448
|
+
).forEach((n, a) => {
|
|
1449
|
+
this.addRasterLayer(n, a, i.id);
|
|
1450
|
+
}), this.mapViewer.shouldOptimizedTileRequests && (this.removeLayer(pt), this.addTransparentImageryProvider());
|
|
1451
|
+
}
|
|
1452
|
+
addRasterLayer(i, t, n) {
|
|
1453
|
+
let a;
|
|
1454
|
+
switch (i.type) {
|
|
1455
|
+
case "XYZ_LAYER": {
|
|
1456
|
+
const o = i.options, d = this.mapViewer.shouldOptimizedTileRequests ? new Bt(o, this.mapViewer) : new Ze(o);
|
|
1457
|
+
a = this.mapViewer.imageryLayers.addImageryProvider(
|
|
1458
|
+
d,
|
|
1459
|
+
t
|
|
1460
|
+
);
|
|
1461
|
+
break;
|
|
1462
|
+
}
|
|
1463
|
+
case "WMS_LAYER": {
|
|
1464
|
+
const o = i.options, d = this.mapViewer.shouldOptimizedTileRequests ? new Nt(o, this.mapViewer) : new Je(o);
|
|
1465
|
+
a = this.mapViewer.imageryLayers.addImageryProvider(
|
|
1466
|
+
d,
|
|
1467
|
+
t
|
|
1468
|
+
);
|
|
1469
|
+
break;
|
|
1470
|
+
}
|
|
1471
|
+
case "WMTS_LAYER": {
|
|
1472
|
+
const o = i.options, d = this.mapViewer.shouldOptimizedTileRequests ? new Ft(o, this.mapViewer) : new Qe(o);
|
|
1473
|
+
a = this.mapViewer.imageryLayers.addImageryProvider(
|
|
1474
|
+
d,
|
|
1475
|
+
t
|
|
1476
|
+
);
|
|
1477
|
+
break;
|
|
1478
|
+
}
|
|
1479
|
+
}
|
|
1480
|
+
a && (a.alpha = i.opacity, a.meta = {
|
|
1481
|
+
parentBasetMapId: n,
|
|
1482
|
+
...i
|
|
1483
|
+
}, i.show !== void 0 && (a.show = i.show));
|
|
1484
|
+
}
|
|
1485
|
+
removeLayer(i) {
|
|
1486
|
+
const t = this.findLayerById(i);
|
|
1487
|
+
t && this.mapViewer.imageryLayers.remove(t, !0);
|
|
1488
|
+
}
|
|
1489
|
+
removeBaseMapLayers() {
|
|
1490
|
+
this.layers.filter((t) => !!Q(t.meta, "parentBasetMapId")).forEach((t) => {
|
|
1491
|
+
this.mapViewer.imageryLayers.remove(t, !0);
|
|
1492
|
+
});
|
|
1493
|
+
}
|
|
1494
|
+
// Remove all non base layers
|
|
1495
|
+
removeNotBaseMapLayers() {
|
|
1496
|
+
this.layers.filter((t) => !Q(t.meta, "parentBasetMapId")).forEach((t) => {
|
|
1497
|
+
this.mapViewer.imageryLayers.remove(t, !0);
|
|
1498
|
+
});
|
|
1499
|
+
}
|
|
1500
|
+
raise(i, t = 1) {
|
|
1501
|
+
const n = this.findLayerById(i), a = (n == null ? void 0 : n.meta).zIndex;
|
|
1502
|
+
if (n)
|
|
1503
|
+
for (let o = 0; o < t; o++)
|
|
1504
|
+
this.mapViewer.imageryLayers.raise(n);
|
|
1505
|
+
this.updateLayersOrder(i, a, a + t);
|
|
1506
|
+
}
|
|
1507
|
+
lower(i, t = 1) {
|
|
1508
|
+
const n = this.findLayerById(i), a = (n == null ? void 0 : n.meta).zIndex, o = this.getBaseLayersCount(), d = this.mapViewer.imageryLayers.indexOf(
|
|
1509
|
+
n
|
|
1510
|
+
);
|
|
1511
|
+
if (d - t <= o && (t = d - o), n)
|
|
1512
|
+
for (let u = 0; u < t; u++)
|
|
1513
|
+
this.mapViewer.imageryLayers.lower(n);
|
|
1514
|
+
this.updateLayersOrder(i, a, a - t);
|
|
1515
|
+
}
|
|
1516
|
+
raiseToTop(i) {
|
|
1517
|
+
const t = this.findLayerById(i), n = (t == null ? void 0 : t.meta).zIndex;
|
|
1518
|
+
t && this.mapViewer.imageryLayers.raiseToTop(t), this.updateLayersOrder(
|
|
1519
|
+
i,
|
|
1520
|
+
n,
|
|
1521
|
+
this.mapViewer.imageryLayers.length - this.getBaseLayersCount() - 1
|
|
1522
|
+
);
|
|
1523
|
+
}
|
|
1524
|
+
lowerToBottom(i) {
|
|
1525
|
+
const t = this.findLayerById(i), n = this.getBaseLayersCount(), a = this.mapViewer.imageryLayers.indexOf(
|
|
1526
|
+
t
|
|
1527
|
+
);
|
|
1528
|
+
this.lower(i, a - n);
|
|
1529
|
+
}
|
|
1530
|
+
length() {
|
|
1531
|
+
return this.mapViewer.imageryLayers.length;
|
|
1532
|
+
}
|
|
1533
|
+
show(i, t) {
|
|
1534
|
+
const n = this.get(i);
|
|
1535
|
+
n !== void 0 && (n.show = t);
|
|
1536
|
+
}
|
|
1537
|
+
showAllNotBase(i) {
|
|
1538
|
+
this.layers.filter((n) => !Q(n.meta, "parentBasetMapId")).forEach((n) => {
|
|
1539
|
+
var a;
|
|
1540
|
+
this.show((a = n.meta) == null ? void 0 : a.id, i);
|
|
1541
|
+
});
|
|
1542
|
+
}
|
|
1543
|
+
get(i) {
|
|
1544
|
+
const t = this.findLayerById(i), n = this.mapViewer.imageryLayers.indexOf(
|
|
1545
|
+
t
|
|
1546
|
+
);
|
|
1547
|
+
return n ? this.mapViewer.imageryLayers.get(n) : void 0;
|
|
1548
|
+
}
|
|
1549
|
+
findLayerByPOI(i, t) {
|
|
1550
|
+
const n = hr(this.mapViewer, i, t);
|
|
1551
|
+
return this.layers.filter((d) => !Q(d.meta, "parentBasetMapId")).filter((d) => {
|
|
1552
|
+
const u = Q(d.meta, "details.footprint");
|
|
1553
|
+
return u !== void 0 ? un(n.geometry, {
|
|
1554
|
+
type: "Feature",
|
|
1555
|
+
properties: {},
|
|
1556
|
+
geometry: u
|
|
1557
|
+
}) && d.show : (console.warn("CesiumImageryLayer has no defined footprint", d.meta), !1);
|
|
1558
|
+
}).sort((d, u) => {
|
|
1559
|
+
var v, C;
|
|
1560
|
+
return ((v = u.meta) == null ? void 0 : v.zIndex) - ((C = d.meta) == null ? void 0 : C.zIndex);
|
|
1561
|
+
});
|
|
1562
|
+
}
|
|
1563
|
+
addTransparentImageryProvider() {
|
|
1564
|
+
const i = this.mapViewer.imageryLayers.addImageryProvider(
|
|
1565
|
+
new ji({
|
|
1566
|
+
url: "./assets/img/transparent-tile.png",
|
|
1567
|
+
/* eslint-disable @typescript-eslint/no-magic-numbers */
|
|
1568
|
+
rectangle: new Ce(
|
|
1569
|
+
-3.141592653589793,
|
|
1570
|
+
-1.5707963267948966,
|
|
1571
|
+
3.141592653589793,
|
|
1572
|
+
1.5707963267948966
|
|
1573
|
+
)
|
|
1574
|
+
/* eslint-enable @typescript-eslint/no-magic-numbers */
|
|
1575
|
+
}),
|
|
1576
|
+
0
|
|
1577
|
+
);
|
|
1578
|
+
i.meta = {
|
|
1579
|
+
id: pt,
|
|
1580
|
+
skipRelevancyCheck: !0
|
|
1581
|
+
};
|
|
1582
|
+
}
|
|
1583
|
+
setLegends() {
|
|
1584
|
+
typeof this.legendsExtractor < "u" && (this.legendsList = this.legendsExtractor(this.layers));
|
|
1585
|
+
}
|
|
1586
|
+
getBaseLayersCount() {
|
|
1587
|
+
return this.layers.filter((t) => !!Q(t.meta, "parentBasetMapId")).length;
|
|
1588
|
+
}
|
|
1589
|
+
findLayerById(i) {
|
|
1590
|
+
return this.layers.find((t) => t.meta !== void 0 ? t.meta.id === i : !1);
|
|
1591
|
+
}
|
|
1592
|
+
updateLayersOrder(i, t, n) {
|
|
1593
|
+
const a = t > n ? gr : fr, o = t < n ? t : n, d = t < n ? n : t;
|
|
1594
|
+
this.layers.forEach((u) => {
|
|
1595
|
+
var C;
|
|
1596
|
+
if (!Q(u.meta, "parentBasetMapId")) {
|
|
1597
|
+
const S = (C = u.meta) == null ? void 0 : C.zIndex;
|
|
1598
|
+
u.meta.zIndex = S >= o && S <= d && S !== t ? S + a : S === t ? n : S;
|
|
1599
|
+
}
|
|
1600
|
+
});
|
|
1601
|
+
}
|
|
1602
|
+
hideNonRelevantLayers() {
|
|
1603
|
+
var i, t;
|
|
1604
|
+
for (const n of this.layers)
|
|
1605
|
+
((i = n.meta) == null ? void 0 : i.relevantToExtent) !== n.show && n.imageryProvider.ready && (n.show = ((t = n.meta) == null ? void 0 : t.relevantToExtent) ?? !0);
|
|
1606
|
+
}
|
|
1607
|
+
markRelevantLayersForExtent() {
|
|
1608
|
+
var i, t;
|
|
1609
|
+
try {
|
|
1610
|
+
const n = this.mapViewer.camera.computeViewRectangle();
|
|
1611
|
+
for (let a = this.layers.length - 1; a >= 0; a--) {
|
|
1612
|
+
const o = this.layers[a], d = !Ke(n) && !Ke(o.rectangle) && Ce.intersection(n, o.rectangle);
|
|
1613
|
+
for (let u = this.layers.length - 1; u >= a; u--) {
|
|
1614
|
+
if (((i = o.meta) == null ? void 0 : i.skipRelevancyCheck) === !0) {
|
|
1615
|
+
o.meta = { ...o.meta, relevantToExtent: !0 };
|
|
1616
|
+
continue;
|
|
1617
|
+
}
|
|
1618
|
+
const v = this.layers[u], C = ((t = v.meta) == null ? void 0 : t[De]) === !0;
|
|
1619
|
+
if (o !== v)
|
|
1620
|
+
if (d instanceof Ce) {
|
|
1621
|
+
if (xe(n, o.rectangle))
|
|
1622
|
+
if (xe(n, v.rectangle) && !C) {
|
|
1623
|
+
o.meta = {
|
|
1624
|
+
...o.meta ?? {},
|
|
1625
|
+
relevantToExtent: !1
|
|
1626
|
+
};
|
|
1627
|
+
break;
|
|
1628
|
+
} else
|
|
1629
|
+
o.meta = {
|
|
1630
|
+
...o.meta ?? {},
|
|
1631
|
+
relevantToExtent: !0
|
|
1632
|
+
};
|
|
1633
|
+
if (xe(n, v.rectangle) && !C) {
|
|
1634
|
+
o.meta = { ...o.meta ?? {}, relevantToExtent: !1 };
|
|
1635
|
+
break;
|
|
1636
|
+
}
|
|
1637
|
+
if (xe(o.rectangle, v.rectangle)) {
|
|
1638
|
+
if (o.meta = {
|
|
1639
|
+
...o.meta ?? {},
|
|
1640
|
+
relevantToExtent: C
|
|
1641
|
+
}, !C)
|
|
1642
|
+
break;
|
|
1643
|
+
} else
|
|
1644
|
+
o.meta = { ...o.meta ?? {}, relevantToExtent: !0 };
|
|
1645
|
+
} else
|
|
1646
|
+
o.meta = { ...o.meta ?? {}, relevantToExtent: !1 };
|
|
1647
|
+
else
|
|
1648
|
+
a === this.layers.length - 1 && (o.meta = {
|
|
1649
|
+
...o.meta ?? {},
|
|
1650
|
+
relevantToExtent: d instanceof Ce
|
|
1651
|
+
});
|
|
1652
|
+
}
|
|
1653
|
+
}
|
|
1654
|
+
} catch (n) {
|
|
1655
|
+
console.error(n);
|
|
1656
|
+
}
|
|
1657
|
+
}
|
|
1658
|
+
}
|
|
1659
|
+
const mt = 212, gt = 260, vr = 0;
|
|
1660
|
+
class Ho extends Ki {
|
|
1661
|
+
constructor(t, n) {
|
|
1662
|
+
super(t, n);
|
|
1663
|
+
J(this, "layersManager");
|
|
1664
|
+
J(this, "useOptimizedTileRequests");
|
|
1665
|
+
}
|
|
1666
|
+
get shouldOptimizedTileRequests() {
|
|
1667
|
+
return this.useOptimizedTileRequests ?? !1;
|
|
1668
|
+
}
|
|
1669
|
+
set shouldOptimizedTileRequests(t) {
|
|
1670
|
+
this.useOptimizedTileRequests = t;
|
|
1671
|
+
}
|
|
1672
|
+
}
|
|
1673
|
+
const Ht = Se(null), Er = Ht.Provider, Cr = 1e4, he = () => {
|
|
1674
|
+
const e = Pe(Ht);
|
|
1675
|
+
if (e === null)
|
|
1676
|
+
throw new Error("map context is null, please check the provider");
|
|
1677
|
+
return e;
|
|
1678
|
+
}, Go = (e) => {
|
|
1679
|
+
var E, T, b, w, _, P, H, W;
|
|
1680
|
+
const i = Le(null), [t, n] = k(), [a, o] = k(), [d, u] = k(), [v, C] = k(), [S, A] = k(), [L, R] = k(), [z, K] = k(), [Y, F] = k(), [X, U] = k([]), [V, j] = k(), [O, $] = k(!1), [q, r] = k(void 0), [s, f] = k(
|
|
1681
|
+
!1
|
|
1682
|
+
), [c, g] = k(), h = {
|
|
1683
|
+
fullscreenButton: !0,
|
|
1684
|
+
timeline: !1,
|
|
1685
|
+
animation: !1,
|
|
1686
|
+
baseLayerPicker: !1,
|
|
1687
|
+
geocoder: !1,
|
|
1688
|
+
navigationHelpButton: !1,
|
|
1689
|
+
homeButton: !1,
|
|
1690
|
+
sceneModePicker: !1,
|
|
1691
|
+
...e
|
|
1692
|
+
}, y = (M, x, B, G, pe) => {
|
|
1693
|
+
const ne = t.container, ee = ne.clientWidth, se = ne.clientHeight, _e = G + pe;
|
|
1694
|
+
return {
|
|
1695
|
+
left: `${ee - M < B ? M - (B - (ee - M)) : M}px`,
|
|
1696
|
+
top: `${se - x < _e ? x - (_e - (se - x)) : x}px`
|
|
1697
|
+
};
|
|
1698
|
+
};
|
|
1699
|
+
I(() => {
|
|
1700
|
+
var M;
|
|
1701
|
+
if (i.current !== null) {
|
|
1702
|
+
const x = i.current.cesiumElement;
|
|
1703
|
+
e.imageryContextMenu && x.screenSpaceEventHandler.setInputAction(
|
|
1704
|
+
(B) => {
|
|
1705
|
+
const G = B.position;
|
|
1706
|
+
$(!1), r(G), g(
|
|
1707
|
+
pr(x, G.x, G.y)
|
|
1708
|
+
), $(!0);
|
|
1709
|
+
},
|
|
1710
|
+
St.RIGHT_CLICK
|
|
1711
|
+
);
|
|
1712
|
+
}
|
|
1713
|
+
n((M = i.current) == null ? void 0 : M.cesiumElement);
|
|
1714
|
+
}, [i, e.imageryContextMenu]), I(() => {
|
|
1715
|
+
var M;
|
|
1716
|
+
t && (t.shouldOptimizedTileRequests = e.useOptimizedTileRequests ?? !1, t.layersManager = new yr(
|
|
1717
|
+
t,
|
|
1718
|
+
(M = e.legends) == null ? void 0 : M.mapLegendsExtractor,
|
|
1719
|
+
() => {
|
|
1720
|
+
var x;
|
|
1721
|
+
U(
|
|
1722
|
+
(x = t.layersManager) == null ? void 0 : x.legendsList
|
|
1723
|
+
);
|
|
1724
|
+
}
|
|
1725
|
+
));
|
|
1726
|
+
}, [t]), I(() => {
|
|
1727
|
+
t && (t.shouldOptimizedTileRequests = e.useOptimizedTileRequests ?? !1);
|
|
1728
|
+
}, [e.useOptimizedTileRequests, t]), I(() => {
|
|
1729
|
+
F(
|
|
1730
|
+
e.sceneModes ?? [
|
|
1731
|
+
ie.SCENE2D,
|
|
1732
|
+
ie.SCENE3D,
|
|
1733
|
+
ie.COLUMBUS_VIEW
|
|
1734
|
+
]
|
|
1735
|
+
);
|
|
1736
|
+
}, [e.sceneModes]), I(() => {
|
|
1737
|
+
var x, B;
|
|
1738
|
+
j(e.baseMaps);
|
|
1739
|
+
const M = (x = e.baseMaps) == null ? void 0 : x.maps.find(
|
|
1740
|
+
(G) => G.isCurrent
|
|
1741
|
+
);
|
|
1742
|
+
M && t && ((B = t.layersManager) == null || B.setBaseMapLayers(M));
|
|
1743
|
+
}, [e.baseMaps, t]), I(() => {
|
|
1744
|
+
o(e.projection ?? ue.WGS84);
|
|
1745
|
+
}, [e.projection]), I(() => {
|
|
1746
|
+
R(e.locale);
|
|
1747
|
+
}, [e.locale]), I(() => {
|
|
1748
|
+
u(e.showMousePosition ?? !0);
|
|
1749
|
+
}, [e.showMousePosition]), I(() => {
|
|
1750
|
+
C(e.showZoomLevel ?? !0);
|
|
1751
|
+
}, [e.showZoomLevel]), I(() => {
|
|
1752
|
+
A(e.showScale ?? !0);
|
|
1753
|
+
}, [e.showScale]), I(() => {
|
|
1754
|
+
const M = () => {
|
|
1755
|
+
if (t === void 0)
|
|
1756
|
+
return {
|
|
1757
|
+
longitude: 0,
|
|
1758
|
+
latitude: 0,
|
|
1759
|
+
height: 0
|
|
1760
|
+
};
|
|
1761
|
+
const B = () => {
|
|
1762
|
+
const G = t.camera.positionCartographic;
|
|
1763
|
+
return {
|
|
1764
|
+
longitude: Ae(G.longitude),
|
|
1765
|
+
latitude: Ae(G.latitude),
|
|
1766
|
+
height: G.height
|
|
1767
|
+
};
|
|
1768
|
+
};
|
|
1769
|
+
if (t.scene.mode === ye.SCENE3D) {
|
|
1770
|
+
const G = new Te(
|
|
1771
|
+
// eslint-disable-next-line @typescript-eslint/no-magic-numbers
|
|
1772
|
+
t.container.clientWidth / 2,
|
|
1773
|
+
// eslint-disable-next-line @typescript-eslint/no-magic-numbers
|
|
1774
|
+
t.container.clientHeight / 2
|
|
1775
|
+
), pe = t.scene.camera.getPickRay(G), ne = t.scene.globe.pick(
|
|
1776
|
+
pe,
|
|
1777
|
+
t.scene
|
|
1778
|
+
), ee = t.scene.globe.ellipsoid.cartesianToCartographic(
|
|
1779
|
+
ne
|
|
1780
|
+
);
|
|
1781
|
+
return ee !== void 0 ? {
|
|
1782
|
+
longitude: Ae(ee.longitude),
|
|
1783
|
+
latitude: Ae(ee.latitude),
|
|
1784
|
+
height: t.scene.camera.positionCartographic.height
|
|
1785
|
+
} : B();
|
|
1786
|
+
} else
|
|
1787
|
+
return B();
|
|
1788
|
+
}, x = setInterval(() => {
|
|
1789
|
+
if (t && t.scene.mode !== ye.MORPHING) {
|
|
1790
|
+
const B = t.camera, G = {
|
|
1791
|
+
position: M(),
|
|
1792
|
+
direction: B.direction.clone(),
|
|
1793
|
+
up: B.up.clone(),
|
|
1794
|
+
right: B.right.clone(),
|
|
1795
|
+
transform: B.transform.clone(),
|
|
1796
|
+
frustum: B.frustum.clone()
|
|
1797
|
+
};
|
|
1798
|
+
K(G);
|
|
1799
|
+
}
|
|
1800
|
+
}, Cr);
|
|
1801
|
+
return () => {
|
|
1802
|
+
clearInterval(x);
|
|
1803
|
+
};
|
|
1804
|
+
}, [t]), I(() => {
|
|
1805
|
+
const M = () => {
|
|
1806
|
+
t && z && t.camera.flyTo({
|
|
1807
|
+
destination: me.fromDegrees(
|
|
1808
|
+
z.position.longitude,
|
|
1809
|
+
z.position.latitude,
|
|
1810
|
+
z.position.height
|
|
1811
|
+
),
|
|
1812
|
+
duration: 0
|
|
1813
|
+
});
|
|
1814
|
+
};
|
|
1815
|
+
return t && t.scene.morphComplete.addEventListener(M), () => {
|
|
1816
|
+
if (t)
|
|
1817
|
+
try {
|
|
1818
|
+
t.scene.morphComplete.removeEventListener(
|
|
1819
|
+
M
|
|
1820
|
+
);
|
|
1821
|
+
} catch {
|
|
1822
|
+
console.error("morphCompleteHandler event not cleaned");
|
|
1823
|
+
}
|
|
1824
|
+
};
|
|
1825
|
+
}, [t, z]), I(() => {
|
|
1826
|
+
const M = e.zoom, x = e.center;
|
|
1827
|
+
t && Oe(M) && dn(x) && t.camera.flyTo({
|
|
1828
|
+
destination: me.fromDegrees(
|
|
1829
|
+
x[0],
|
|
1830
|
+
x[1],
|
|
1831
|
+
Xn(M)
|
|
1832
|
+
),
|
|
1833
|
+
duration: 0
|
|
1834
|
+
});
|
|
1835
|
+
}, [e.zoom, e.center, t]);
|
|
1836
|
+
const m = ge(() => t && Ii(
|
|
1837
|
+
/* @__PURE__ */ D(oe, { children: [
|
|
1838
|
+
/* @__PURE__ */ D(ae, { className: "sideToolsContainer", children: [
|
|
1839
|
+
/* @__PURE__ */ l(
|
|
1840
|
+
sr,
|
|
1841
|
+
{
|
|
1842
|
+
sceneModes: Y,
|
|
1843
|
+
baseMaps: V,
|
|
1844
|
+
locale: L
|
|
1845
|
+
}
|
|
1846
|
+
),
|
|
1847
|
+
/* @__PURE__ */ l(
|
|
1848
|
+
lr,
|
|
1849
|
+
{
|
|
1850
|
+
onClick: () => f(!s)
|
|
1851
|
+
}
|
|
1852
|
+
)
|
|
1853
|
+
] }),
|
|
1854
|
+
/* @__PURE__ */ D(ae, { className: "toolsContainer", children: [
|
|
1855
|
+
d === !0 ? /* @__PURE__ */ l(Zn, { projection: a }) : /* @__PURE__ */ l(oe, {}),
|
|
1856
|
+
v === !0 ? /* @__PURE__ */ l(tr, { locale: L }) : /* @__PURE__ */ l(oe, {}),
|
|
1857
|
+
S === !0 ? /* @__PURE__ */ l(Qn, { locale: L }) : /* @__PURE__ */ l(oe, {})
|
|
1858
|
+
] })
|
|
1859
|
+
] }),
|
|
1860
|
+
document.querySelector(".cesium-viewer")
|
|
1861
|
+
), [
|
|
1862
|
+
V,
|
|
1863
|
+
L,
|
|
1864
|
+
t,
|
|
1865
|
+
a,
|
|
1866
|
+
Y,
|
|
1867
|
+
d,
|
|
1868
|
+
S,
|
|
1869
|
+
s
|
|
1870
|
+
]);
|
|
1871
|
+
return /* @__PURE__ */ l(Oi, { className: "viewer", full: !0, ref: i, ...h, children: /* @__PURE__ */ D(Er, { value: t, children: [
|
|
1872
|
+
/* @__PURE__ */ l(
|
|
1873
|
+
ur,
|
|
1874
|
+
{
|
|
1875
|
+
title: (E = e.legends) == null ? void 0 : E.title,
|
|
1876
|
+
isOpen: s,
|
|
1877
|
+
toggleSidebar: () => f(!s),
|
|
1878
|
+
noLegendsText: (T = e.legends) == null ? void 0 : T.emptyText,
|
|
1879
|
+
legends: ((b = e.legends) == null ? void 0 : b.legendsList) ?? X,
|
|
1880
|
+
actionsTexts: (w = e.legends) == null ? void 0 : w.actionsTexts
|
|
1881
|
+
}
|
|
1882
|
+
),
|
|
1883
|
+
e.children,
|
|
1884
|
+
m(),
|
|
1885
|
+
e.imageryContextMenu && O && q && c && ve.cloneElement(e.imageryContextMenu, {
|
|
1886
|
+
data: (_ = t == null ? void 0 : t.layersManager) == null ? void 0 : _.findLayerByPOI(
|
|
1887
|
+
q.x,
|
|
1888
|
+
q.y
|
|
1889
|
+
),
|
|
1890
|
+
position: {
|
|
1891
|
+
x: q.x,
|
|
1892
|
+
y: q.y
|
|
1893
|
+
},
|
|
1894
|
+
coordinates: c,
|
|
1895
|
+
style: y(
|
|
1896
|
+
q.x,
|
|
1897
|
+
q.y,
|
|
1898
|
+
((P = e.imageryContextMenuSize) == null ? void 0 : P.width) ?? gt,
|
|
1899
|
+
((H = e.imageryContextMenuSize) == null ? void 0 : H.height) ?? mt,
|
|
1900
|
+
((W = e.imageryContextMenuSize) == null ? void 0 : W.dynamicHeightIncrement) ?? vr
|
|
1901
|
+
),
|
|
1902
|
+
size: e.imageryContextMenuSize ?? {
|
|
1903
|
+
height: mt,
|
|
1904
|
+
width: gt
|
|
1905
|
+
},
|
|
1906
|
+
handleClose: () => {
|
|
1907
|
+
$(!O);
|
|
1908
|
+
}
|
|
1909
|
+
})
|
|
1910
|
+
] }) });
|
|
1911
|
+
}, wr = 0, Vo = (e) => {
|
|
1912
|
+
const i = he();
|
|
1913
|
+
return /* @__PURE__ */ l(
|
|
1914
|
+
Di,
|
|
1915
|
+
{
|
|
1916
|
+
...e,
|
|
1917
|
+
onReady: (t) => {
|
|
1918
|
+
e.isZoomTo === !0 && i.zoomTo(t);
|
|
1919
|
+
const n = i.scene;
|
|
1920
|
+
n.globe.depthTestAgainstTerrain = !0;
|
|
1921
|
+
const a = Be.fromCartesian(
|
|
1922
|
+
t.boundingSphere.center
|
|
1923
|
+
), o = e.heightFromGround ?? wr;
|
|
1924
|
+
if (o) {
|
|
1925
|
+
const d = me.fromRadians(
|
|
1926
|
+
a.longitude,
|
|
1927
|
+
a.latitude,
|
|
1928
|
+
a.height
|
|
1929
|
+
), u = me.fromRadians(
|
|
1930
|
+
a.longitude,
|
|
1931
|
+
a.latitude,
|
|
1932
|
+
a.height + o
|
|
1933
|
+
), v = me.subtract(
|
|
1934
|
+
u,
|
|
1935
|
+
d,
|
|
1936
|
+
new me()
|
|
1937
|
+
);
|
|
1938
|
+
t.modelMatrix = qi.fromTranslation(v);
|
|
1939
|
+
}
|
|
1940
|
+
}
|
|
1941
|
+
}
|
|
1942
|
+
);
|
|
1943
|
+
}, zo = (e) => /* @__PURE__ */ l(Ri, { ...e }), Fe = (e) => {
|
|
1944
|
+
const { meta: i, ...t } = e, n = he();
|
|
1945
|
+
return jt(() => {
|
|
1946
|
+
var a;
|
|
1947
|
+
(a = n.layersManager) == null || a.addMetaToLayer(
|
|
1948
|
+
i,
|
|
1949
|
+
/* eslint-disable */
|
|
1950
|
+
i.searchLayerPredicate ?? ((o, d) => {
|
|
1951
|
+
var u, v;
|
|
1952
|
+
return i !== void 0 ? ((u = o._imageryProvider._resource) == null ? void 0 : u._url) === ((v = i.options) == null ? void 0 : v.url) : !1;
|
|
1953
|
+
})
|
|
1954
|
+
);
|
|
1955
|
+
}, [i, n]), /* @__PURE__ */ l(Bi, { ...t });
|
|
1956
|
+
}, $o = (e) => {
|
|
1957
|
+
const { options: i, ...t } = e, n = he(), a = n.shouldOptimizedTileRequests ? new Nt(i, n) : new Je(i);
|
|
1958
|
+
return /* @__PURE__ */ l(Fe, { ...t, imageryProvider: a });
|
|
1959
|
+
}, Uo = (e) => {
|
|
1960
|
+
const { options: i, ...t } = e, n = he(), a = n.shouldOptimizedTileRequests ? new Ft(i, n) : new Qe(i);
|
|
1961
|
+
return /* @__PURE__ */ l(Fe, { ...t, imageryProvider: a });
|
|
1962
|
+
}, Wo = (e) => {
|
|
1963
|
+
const { options: i, ...t } = e, n = he(), a = n.shouldOptimizedTileRequests ? new Bt(i, n) : new Ze(i);
|
|
1964
|
+
return /* @__PURE__ */ l(Fe, { ...t, imageryProvider: a });
|
|
1965
|
+
}, jo = (e) => {
|
|
1966
|
+
const { options: i, ...t } = e;
|
|
1967
|
+
return /* @__PURE__ */ l(
|
|
1968
|
+
Fe,
|
|
1969
|
+
{
|
|
1970
|
+
...t,
|
|
1971
|
+
imageryProvider: new Yi(i)
|
|
1972
|
+
}
|
|
1973
|
+
);
|
|
1974
|
+
}, br = (e) => /* @__PURE__ */ l(Ni, { ...e }), Ko = (e) => /* @__PURE__ */ l(_t, { ...e }), Tr = (e) => /* @__PURE__ */ l(_t, { ...e }), _r = (e) => /* @__PURE__ */ l(Fi, { ...e }), Sr = (e) => /* @__PURE__ */ l(Hi, { ...e }), Lr = (e) => /* @__PURE__ */ l(Gi, { ...e }), Pr = (e) => /* @__PURE__ */ l(Vi, { ...e });
|
|
1975
|
+
var fe = function() {
|
|
1976
|
+
var e = p.Ellipsoid.WGS84, i, t = p.Material.fromType(p.Material.ColorType);
|
|
1977
|
+
function n(r, s = new p.Color(1, 1, 0, 0.5), f = new p.Color(1, 1, 1, 1)) {
|
|
1978
|
+
this._scene = r.scene, t.uniforms.color = s, i = f, this._tooltip = {
|
|
1979
|
+
setVisible: () => {
|
|
1980
|
+
},
|
|
1981
|
+
showAt: () => {
|
|
1982
|
+
}
|
|
1983
|
+
}, this._surfaces = [], this.initialiseHandlers(), this.enhancePrimitives();
|
|
1984
|
+
}
|
|
1985
|
+
n.prototype.initialiseHandlers = function() {
|
|
1986
|
+
var r = this._scene, s = this, f = new p.ScreenSpaceEventHandler(r.canvas);
|
|
1987
|
+
function c(h, y) {
|
|
1988
|
+
if (s._handlersMuted != !0) {
|
|
1989
|
+
var m = r.pick(y);
|
|
1990
|
+
m && m.primitive && m.primitive[h] && m.primitive[h](y);
|
|
1991
|
+
}
|
|
1992
|
+
}
|
|
1993
|
+
f.setInputAction(function(h) {
|
|
1994
|
+
c("leftClick", h.position);
|
|
1995
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), f.setInputAction(function(h) {
|
|
1996
|
+
c("leftDoubleClick", h.position);
|
|
1997
|
+
}, p.ScreenSpaceEventType.LEFT_DOUBLE_CLICK);
|
|
1998
|
+
var g;
|
|
1999
|
+
f.setInputAction(function(h) {
|
|
2000
|
+
if (s._handlersMuted != !0) {
|
|
2001
|
+
var y = r.pick(h.endPosition);
|
|
2002
|
+
g && (!y || g != y.primitive) && (!(g.isDestroyed && g.isDestroyed()) && g.mouseOut(h.endPosition), g = null), y && y.primitive && (y = y.primitive, y.mouseOut && (g = y), y.mouseMove && y.mouseMove(h.endPosition));
|
|
2003
|
+
}
|
|
2004
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE), f.setInputAction(function(h) {
|
|
2005
|
+
c("leftUp", h.position);
|
|
2006
|
+
}, p.ScreenSpaceEventType.LEFT_UP), f.setInputAction(function(h) {
|
|
2007
|
+
c("leftDown", h.position);
|
|
2008
|
+
}, p.ScreenSpaceEventType.LEFT_DOWN);
|
|
2009
|
+
}, n.prototype.setListener = function(r, s, f) {
|
|
2010
|
+
r[s] = f;
|
|
2011
|
+
}, n.prototype.muteHandlers = function(r) {
|
|
2012
|
+
this._handlersMuted = r;
|
|
2013
|
+
}, n.prototype.registerEditableShape = function(r) {
|
|
2014
|
+
var s = this;
|
|
2015
|
+
$(r, "mouseMove", function(f) {
|
|
2016
|
+
r.setHighlighted(!0), r._editMode || s._tooltip.showAt(f, "Click to edit this shape");
|
|
2017
|
+
}), $(r, "mouseOut", function(f) {
|
|
2018
|
+
r.setHighlighted(!1), s._tooltip.setVisible(!1);
|
|
2019
|
+
}), $(r, "leftClick", function(f) {
|
|
2020
|
+
r.setEditMode(!0);
|
|
2021
|
+
});
|
|
2022
|
+
}, n.prototype.startDrawing = function(r) {
|
|
2023
|
+
this.disableAllEditMode(), this.editCleanUp && this.editCleanUp(), this.editCleanUp = r, this.muteHandlers(!0);
|
|
2024
|
+
}, n.prototype.stopDrawing = function() {
|
|
2025
|
+
this.editCleanUp && (this.editCleanUp(), this.editCleanUp = null), this.muteHandlers(!1);
|
|
2026
|
+
}, n.prototype.disableAllHighlights = function() {
|
|
2027
|
+
this.setHighlighted(void 0);
|
|
2028
|
+
}, n.prototype.setHighlighted = function(r) {
|
|
2029
|
+
this._highlightedSurface && !this._highlightedSurface.isDestroyed() && this._highlightedSurface != r && this._highlightedSurface.setHighlighted(!1), this._highlightedSurface = r;
|
|
2030
|
+
}, n.prototype.disableAllEditMode = function() {
|
|
2031
|
+
this.setEdited(void 0);
|
|
2032
|
+
}, n.prototype.setEdited = function(r) {
|
|
2033
|
+
this._editedSurface && !this._editedSurface.isDestroyed() && this._editedSurface.setEditMode(!1), this._editedSurface = r;
|
|
2034
|
+
};
|
|
2035
|
+
var a = {
|
|
2036
|
+
ellipsoid: p.Ellipsoid.WGS84,
|
|
2037
|
+
textureRotationAngle: 0,
|
|
2038
|
+
height: 0,
|
|
2039
|
+
asynchronous: !0,
|
|
2040
|
+
show: !0,
|
|
2041
|
+
debugShowBoundingVolume: !1
|
|
2042
|
+
}, o = O(a, {
|
|
2043
|
+
appearance: new p.EllipsoidSurfaceAppearance({
|
|
2044
|
+
aboveGround: !1
|
|
2045
|
+
}),
|
|
2046
|
+
material: t,
|
|
2047
|
+
granularity: Math.PI / 180
|
|
2048
|
+
}), d = O(a, {}), u = O(a, {}), v = O(a, {}), C = O(o, {
|
|
2049
|
+
rotation: 0
|
|
2050
|
+
}), S = O(a, {
|
|
2051
|
+
width: 5,
|
|
2052
|
+
geodesic: !0,
|
|
2053
|
+
granularity: 1e4,
|
|
2054
|
+
appearance: new p.PolylineMaterialAppearance({
|
|
2055
|
+
aboveGround: !1
|
|
2056
|
+
}),
|
|
2057
|
+
material: t
|
|
2058
|
+
}), A = function() {
|
|
2059
|
+
function r() {
|
|
2060
|
+
}
|
|
2061
|
+
return r.prototype.initialiseOptions = function(s) {
|
|
2062
|
+
j(this, s), this._ellipsoid = void 0, this._granularity = void 0, this._height = void 0, this._textureRotationAngle = void 0, this._id = void 0, this._createPrimitive = !0, this._primitive = void 0, this._outlinePolygon = void 0;
|
|
2063
|
+
}, r.prototype.setAttribute = function(s, f) {
|
|
2064
|
+
this[s] = f, this._createPrimitive = !0;
|
|
2065
|
+
}, r.prototype.getAttribute = function(s) {
|
|
2066
|
+
return this[s];
|
|
2067
|
+
}, r.prototype.update = function(s, f, c) {
|
|
2068
|
+
if (!p.defined(this.ellipsoid))
|
|
2069
|
+
throw new p.DeveloperError("this.ellipsoid must be defined.");
|
|
2070
|
+
if (!p.defined(this.appearance))
|
|
2071
|
+
throw new p.DeveloperError("this.material must be defined.");
|
|
2072
|
+
if (this.granularity < 0)
|
|
2073
|
+
throw new p.DeveloperError("this.granularity and scene2D/scene3D overrides must be greater than zero.");
|
|
2074
|
+
if (this.show && !(!this._createPrimitive && !p.defined(this._primitive))) {
|
|
2075
|
+
if (this._createPrimitive || this._ellipsoid !== this.ellipsoid || this._granularity !== this.granularity || this._height !== this.height || this._textureRotationAngle !== this.textureRotationAngle || this._id !== this.id) {
|
|
2076
|
+
var g = this.getGeometry();
|
|
2077
|
+
if (!g)
|
|
2078
|
+
return;
|
|
2079
|
+
this._createPrimitive = !1, this._ellipsoid = this.ellipsoid, this._granularity = this.granularity, this._height = this.height, this._textureRotationAngle = this.textureRotationAngle, this._id = this.id, this._primitive = this._primitive && this._primitive.destroy(), this._primitive = new p.Primitive({
|
|
2080
|
+
geometryInstances: new p.GeometryInstance({
|
|
2081
|
+
geometry: g,
|
|
2082
|
+
id: this.id,
|
|
2083
|
+
pickPrimitive: this
|
|
2084
|
+
}),
|
|
2085
|
+
appearance: this.appearance,
|
|
2086
|
+
asynchronous: this.asynchronous
|
|
2087
|
+
}), this._outlinePolygon = this._outlinePolygon && this._outlinePolygon.destroy(), this.strokeColor && this.getOutlineGeometry && (this._outlinePolygon = new p.Primitive({
|
|
2088
|
+
geometryInstances: new p.GeometryInstance({
|
|
2089
|
+
geometry: this.getOutlineGeometry(),
|
|
2090
|
+
attributes: {
|
|
2091
|
+
color: p.ColorGeometryInstanceAttribute.fromColor(this.strokeColor)
|
|
2092
|
+
}
|
|
2093
|
+
}),
|
|
2094
|
+
appearance: new p.PerInstanceColorAppearance({
|
|
2095
|
+
flat: !0,
|
|
2096
|
+
renderState: {
|
|
2097
|
+
depthTest: {
|
|
2098
|
+
enabled: !0
|
|
2099
|
+
},
|
|
2100
|
+
//MC_CHANGE
|
|
2101
|
+
lineWidth: this.strokeWidth || 4
|
|
2102
|
+
// lineWidth : Math.min(this.strokeWidth || 4.0, context._aliasedLineWidthRange[1])
|
|
2103
|
+
}
|
|
2104
|
+
})
|
|
2105
|
+
}));
|
|
2106
|
+
}
|
|
2107
|
+
var h = this._primitive;
|
|
2108
|
+
h.appearance.material = this.material, h.debugShowBoundingVolume = this.debugShowBoundingVolume, h.update(s, f, c), this._outlinePolygon && this._outlinePolygon.update(s, f, c);
|
|
2109
|
+
}
|
|
2110
|
+
}, r.prototype.isDestroyed = function() {
|
|
2111
|
+
return !1;
|
|
2112
|
+
}, r.prototype.destroy = function() {
|
|
2113
|
+
return this._primitive = this._primitive && this._primitive.destroy(), p.destroyObject(this);
|
|
2114
|
+
}, r.prototype.setStrokeStyle = function(s, f) {
|
|
2115
|
+
(!this.strokeColor || !this.strokeColor.equals(s) || this.strokeWidth != f) && (this._createPrimitive = !0, this.strokeColor = s, this.strokeWidth = f);
|
|
2116
|
+
}, r;
|
|
2117
|
+
}();
|
|
2118
|
+
n.ExtentPrimitive = function() {
|
|
2119
|
+
function r(s) {
|
|
2120
|
+
if (!p.defined(s.extent))
|
|
2121
|
+
throw new p.DeveloperError("Extent is required");
|
|
2122
|
+
s = O(s, o), this.initialiseOptions(s), this.setExtent(s.extent);
|
|
2123
|
+
}
|
|
2124
|
+
return r.prototype = new A(), r.prototype.setExtent = function(s) {
|
|
2125
|
+
this.setAttribute("extent", s);
|
|
2126
|
+
}, r.prototype.getExtent = function() {
|
|
2127
|
+
return this.getAttribute("extent");
|
|
2128
|
+
}, r.prototype.getGeometry = function() {
|
|
2129
|
+
if (p.defined(this.extent))
|
|
2130
|
+
return new p.RectangleGeometry({
|
|
2131
|
+
rectangle: this.extent,
|
|
2132
|
+
height: this.height,
|
|
2133
|
+
vertexFormat: p.EllipsoidSurfaceAppearance.VERTEX_FORMAT,
|
|
2134
|
+
stRotation: this.textureRotationAngle,
|
|
2135
|
+
ellipsoid: this.ellipsoid,
|
|
2136
|
+
granularity: this.granularity
|
|
2137
|
+
});
|
|
2138
|
+
}, r.prototype.getOutlineGeometry = function() {
|
|
2139
|
+
return new p.RectangleOutlineGeometry({
|
|
2140
|
+
rectangle: this.extent
|
|
2141
|
+
});
|
|
2142
|
+
}, r;
|
|
2143
|
+
}(), n.PolygonPrimitive = function() {
|
|
2144
|
+
function r(s) {
|
|
2145
|
+
s = O(s, o), this.initialiseOptions(s), this.isPolygon = !0;
|
|
2146
|
+
}
|
|
2147
|
+
return r.prototype = new A(), r.prototype.setPositions = function(s) {
|
|
2148
|
+
this.setAttribute("positions", s);
|
|
2149
|
+
}, r.prototype.getPositions = function() {
|
|
2150
|
+
return this.getAttribute("positions");
|
|
2151
|
+
}, r.prototype.getGeometry = function() {
|
|
2152
|
+
if (!(!p.defined(this.positions) || this.positions.length < 3))
|
|
2153
|
+
return p.PolygonGeometry.fromPositions({
|
|
2154
|
+
positions: this.positions,
|
|
2155
|
+
height: this.height,
|
|
2156
|
+
vertexFormat: p.EllipsoidSurfaceAppearance.VERTEX_FORMAT,
|
|
2157
|
+
stRotation: this.textureRotationAngle,
|
|
2158
|
+
ellipsoid: this.ellipsoid,
|
|
2159
|
+
granularity: this.granularity
|
|
2160
|
+
});
|
|
2161
|
+
}, r.prototype.getOutlineGeometry = function() {
|
|
2162
|
+
return p.PolygonOutlineGeometry.fromPositions({
|
|
2163
|
+
positions: this.getPositions()
|
|
2164
|
+
});
|
|
2165
|
+
}, r;
|
|
2166
|
+
}(), n.CirclePrimitive = function() {
|
|
2167
|
+
function r(s) {
|
|
2168
|
+
if (!(p.defined(s.center) && p.defined(s.radius)))
|
|
2169
|
+
throw new p.DeveloperError("Center and radius are required");
|
|
2170
|
+
s = O(s, o), this.initialiseOptions(s), this.setRadius(s.radius);
|
|
2171
|
+
}
|
|
2172
|
+
return r.prototype = new A(), r.prototype.setCenter = function(s) {
|
|
2173
|
+
this.setAttribute("center", s);
|
|
2174
|
+
}, r.prototype.setRadius = function(s) {
|
|
2175
|
+
this.setAttribute("radius", Math.max(0.1, s));
|
|
2176
|
+
}, r.prototype.getCenter = function() {
|
|
2177
|
+
return this.getAttribute("center");
|
|
2178
|
+
}, r.prototype.getRadius = function() {
|
|
2179
|
+
return this.getAttribute("radius");
|
|
2180
|
+
}, r.prototype.getGeometry = function() {
|
|
2181
|
+
if (p.defined(this.center) && p.defined(this.radius))
|
|
2182
|
+
return new p.CircleGeometry({
|
|
2183
|
+
center: this.center,
|
|
2184
|
+
radius: this.radius,
|
|
2185
|
+
height: this.height,
|
|
2186
|
+
vertexFormat: p.EllipsoidSurfaceAppearance.VERTEX_FORMAT,
|
|
2187
|
+
stRotation: this.textureRotationAngle,
|
|
2188
|
+
ellipsoid: this.ellipsoid,
|
|
2189
|
+
granularity: this.granularity
|
|
2190
|
+
});
|
|
2191
|
+
}, r.prototype.getOutlineGeometry = function() {
|
|
2192
|
+
return new p.CircleOutlineGeometry({
|
|
2193
|
+
center: this.getCenter(),
|
|
2194
|
+
radius: this.getRadius()
|
|
2195
|
+
});
|
|
2196
|
+
}, r;
|
|
2197
|
+
}(), n.EllipsePrimitive = function() {
|
|
2198
|
+
function r(s) {
|
|
2199
|
+
if (!(p.defined(s.center) && p.defined(s.semiMajorAxis) && p.defined(s.semiMinorAxis)))
|
|
2200
|
+
throw new p.DeveloperError("Center and semi major and semi minor axis are required");
|
|
2201
|
+
s = O(s, C), this.initialiseOptions(s);
|
|
2202
|
+
}
|
|
2203
|
+
return r.prototype = new A(), r.prototype.setCenter = function(s) {
|
|
2204
|
+
this.setAttribute("center", s);
|
|
2205
|
+
}, r.prototype.setSemiMajorAxis = function(s) {
|
|
2206
|
+
s < this.getSemiMinorAxis() || this.setAttribute("semiMajorAxis", s);
|
|
2207
|
+
}, r.prototype.setSemiMinorAxis = function(s) {
|
|
2208
|
+
s > this.getSemiMajorAxis() || this.setAttribute("semiMinorAxis", s);
|
|
2209
|
+
}, r.prototype.setRotation = function(s) {
|
|
2210
|
+
return this.setAttribute("rotation", s);
|
|
2211
|
+
}, r.prototype.getCenter = function() {
|
|
2212
|
+
return this.getAttribute("center");
|
|
2213
|
+
}, r.prototype.getSemiMajorAxis = function() {
|
|
2214
|
+
return this.getAttribute("semiMajorAxis");
|
|
2215
|
+
}, r.prototype.getSemiMinorAxis = function() {
|
|
2216
|
+
return this.getAttribute("semiMinorAxis");
|
|
2217
|
+
}, r.prototype.getRotation = function() {
|
|
2218
|
+
return this.getAttribute("rotation");
|
|
2219
|
+
}, r.prototype.getGeometry = function() {
|
|
2220
|
+
if (p.defined(this.center) && p.defined(this.semiMajorAxis) && p.defined(this.semiMinorAxis))
|
|
2221
|
+
return new p.EllipseGeometry({
|
|
2222
|
+
ellipsoid: this.ellipsoid,
|
|
2223
|
+
center: this.center,
|
|
2224
|
+
semiMajorAxis: this.semiMajorAxis,
|
|
2225
|
+
semiMinorAxis: this.semiMinorAxis,
|
|
2226
|
+
rotation: this.rotation,
|
|
2227
|
+
height: this.height,
|
|
2228
|
+
vertexFormat: p.EllipsoidSurfaceAppearance.VERTEX_FORMAT,
|
|
2229
|
+
stRotation: this.textureRotationAngle,
|
|
2230
|
+
granularity: this.granularity
|
|
2231
|
+
});
|
|
2232
|
+
}, r.prototype.getOutlineGeometry = function() {
|
|
2233
|
+
return new p.EllipseOutlineGeometry({
|
|
2234
|
+
center: this.getCenter(),
|
|
2235
|
+
semiMajorAxis: this.getSemiMajorAxis(),
|
|
2236
|
+
semiMinorAxis: this.getSemiMinorAxis(),
|
|
2237
|
+
rotation: this.getRotation()
|
|
2238
|
+
});
|
|
2239
|
+
}, r;
|
|
2240
|
+
}(), n.PolylinePrimitive = function() {
|
|
2241
|
+
function r(s) {
|
|
2242
|
+
s = O(s, S), this.initialiseOptions(s);
|
|
2243
|
+
}
|
|
2244
|
+
return r.prototype = new A(), r.prototype.setPositions = function(s) {
|
|
2245
|
+
this.setAttribute("positions", s);
|
|
2246
|
+
}, r.prototype.setWidth = function(s) {
|
|
2247
|
+
this.setAttribute("width", s);
|
|
2248
|
+
}, r.prototype.setGeodesic = function(s) {
|
|
2249
|
+
this.setAttribute("geodesic", s);
|
|
2250
|
+
}, r.prototype.getPositions = function() {
|
|
2251
|
+
return this.getAttribute("positions");
|
|
2252
|
+
}, r.prototype.getWidth = function() {
|
|
2253
|
+
return this.getAttribute("width");
|
|
2254
|
+
}, r.prototype.getGeodesic = function(s) {
|
|
2255
|
+
return this.getAttribute("geodesic");
|
|
2256
|
+
}, r.prototype.getGeometry = function() {
|
|
2257
|
+
if (!(!p.defined(this.positions) || this.positions.length < 2))
|
|
2258
|
+
return new p.PolylineGeometry({
|
|
2259
|
+
positions: this.positions,
|
|
2260
|
+
height: this.height,
|
|
2261
|
+
width: this.width < 1 ? 1 : this.width,
|
|
2262
|
+
vertexFormat: p.EllipsoidSurfaceAppearance.VERTEX_FORMAT,
|
|
2263
|
+
ellipsoid: this.ellipsoid
|
|
2264
|
+
});
|
|
2265
|
+
}, r;
|
|
2266
|
+
}();
|
|
2267
|
+
var L = {
|
|
2268
|
+
iconUrl: "./assets/img/dragIcon.png",
|
|
2269
|
+
shiftX: 0,
|
|
2270
|
+
shiftY: 0
|
|
2271
|
+
}, R = {
|
|
2272
|
+
iconUrl: "./assets/img/dragIcon.png",
|
|
2273
|
+
shiftX: 0,
|
|
2274
|
+
shiftY: 0
|
|
2275
|
+
}, z = {
|
|
2276
|
+
iconUrl: "./assets/img/dragIconLight.png",
|
|
2277
|
+
shiftX: 0,
|
|
2278
|
+
shiftY: 0
|
|
2279
|
+
};
|
|
2280
|
+
n.prototype.createBillboardGroup = function(r, s, f) {
|
|
2281
|
+
var c = new n.BillboardGroup(this, s);
|
|
2282
|
+
return c.addBillboards(r, f), c;
|
|
2283
|
+
}, n.BillboardGroup = function(r, s) {
|
|
2284
|
+
this._drawHelper = r, this._scene = r._scene, this._options = O(s, L);
|
|
2285
|
+
var f = new p.BillboardCollection();
|
|
2286
|
+
this._scene.primitives.add(f), this._billboards = f, this._orderedBillboards = [];
|
|
2287
|
+
}, n.BillboardGroup.prototype.createBillboard = function(r, s) {
|
|
2288
|
+
var f = this._billboards.add({
|
|
2289
|
+
show: !0,
|
|
2290
|
+
position: r,
|
|
2291
|
+
pixelOffset: new p.Cartesian2(this._options.shiftX, this._options.shiftY),
|
|
2292
|
+
eyeOffset: new p.Cartesian3(0, 0, 0),
|
|
2293
|
+
horizontalOrigin: p.HorizontalOrigin.CENTER,
|
|
2294
|
+
verticalOrigin: p.VerticalOrigin.CENTER,
|
|
2295
|
+
scale: 1,
|
|
2296
|
+
image: this._options.iconUrl,
|
|
2297
|
+
color: i
|
|
2298
|
+
});
|
|
2299
|
+
if (s) {
|
|
2300
|
+
let h = function(m) {
|
|
2301
|
+
g.enableRotate = m;
|
|
2302
|
+
}, y = function() {
|
|
2303
|
+
for (var m = 0, E = c._orderedBillboards.length; m < E && c._orderedBillboards[m] != f; ++m)
|
|
2304
|
+
;
|
|
2305
|
+
return m;
|
|
2306
|
+
};
|
|
2307
|
+
var c = this, g = this._scene.screenSpaceCameraController;
|
|
2308
|
+
if (s.dragHandlers) {
|
|
2309
|
+
var c = this;
|
|
2310
|
+
$(f, "leftDown", function(E) {
|
|
2311
|
+
function T(_) {
|
|
2312
|
+
f.position = _;
|
|
2313
|
+
for (var P = 0, H = c._orderedBillboards.length; P < H && c._orderedBillboards[P] != f; ++P)
|
|
2314
|
+
;
|
|
2315
|
+
s.dragHandlers.onDrag && s.dragHandlers.onDrag(y(), _);
|
|
2316
|
+
}
|
|
2317
|
+
function b(_) {
|
|
2318
|
+
w.destroy(), h(!0), s.dragHandlers.onDragEnd && s.dragHandlers.onDragEnd(y(), _);
|
|
2319
|
+
}
|
|
2320
|
+
var w = new p.ScreenSpaceEventHandler(c._scene.canvas);
|
|
2321
|
+
w.setInputAction(function(_) {
|
|
2322
|
+
var P = c._scene.camera.pickEllipsoid(_.endPosition, e);
|
|
2323
|
+
P ? T(P) : b(P);
|
|
2324
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE), w.setInputAction(function(_) {
|
|
2325
|
+
b(c._scene.camera.pickEllipsoid(_.position, e));
|
|
2326
|
+
}, p.ScreenSpaceEventType.LEFT_UP), h(!1), s.dragHandlers.onDragStart && s.dragHandlers.onDragStart(y(), c._scene.camera.pickEllipsoid(E, e));
|
|
2327
|
+
});
|
|
2328
|
+
}
|
|
2329
|
+
s.onDoubleClick && $(f, "leftDoubleClick", function(m) {
|
|
2330
|
+
s.onDoubleClick(y());
|
|
2331
|
+
}), s.onClick && $(f, "leftClick", function(m) {
|
|
2332
|
+
s.onClick(y());
|
|
2333
|
+
}), s.tooltip && ($(f, "mouseMove", function(m) {
|
|
2334
|
+
c._drawHelper._tooltip.showAt(m, s.tooltip());
|
|
2335
|
+
}), $(f, "mouseOut", function(m) {
|
|
2336
|
+
c._drawHelper._tooltip.setVisible(!1);
|
|
2337
|
+
}));
|
|
2338
|
+
}
|
|
2339
|
+
return f;
|
|
2340
|
+
}, n.BillboardGroup.prototype.insertBillboard = function(r, s, f) {
|
|
2341
|
+
this._orderedBillboards.splice(r, 0, this.createBillboard(s, f));
|
|
2342
|
+
}, n.BillboardGroup.prototype.addBillboard = function(r, s) {
|
|
2343
|
+
this._orderedBillboards.push(this.createBillboard(r, s));
|
|
2344
|
+
}, n.BillboardGroup.prototype.addBillboards = function(r, s) {
|
|
2345
|
+
for (var f = 0; f < r.length; f++)
|
|
2346
|
+
this.addBillboard(r[f], s);
|
|
2347
|
+
}, n.BillboardGroup.prototype.updateBillboardsPositions = function(r) {
|
|
2348
|
+
for (var s = 0; s < r.length; s++)
|
|
2349
|
+
this.getBillboard(s).position = r[s];
|
|
2350
|
+
}, n.BillboardGroup.prototype.countBillboards = function() {
|
|
2351
|
+
return this._orderedBillboards.length;
|
|
2352
|
+
}, n.BillboardGroup.prototype.getBillboard = function(r) {
|
|
2353
|
+
return this._orderedBillboards[r];
|
|
2354
|
+
}, n.BillboardGroup.prototype.removeBillboard = function(r) {
|
|
2355
|
+
this._billboards.remove(this.getBillboard(r)), this._orderedBillboards.splice(r, 1);
|
|
2356
|
+
}, n.BillboardGroup.prototype.remove = function() {
|
|
2357
|
+
this._billboards = this._billboards && this._billboards.removeAll() && this._billboards.destroy();
|
|
2358
|
+
}, n.BillboardGroup.prototype.setOnTop = function() {
|
|
2359
|
+
this._scene.primitives.raiseToTop(this._billboards);
|
|
2360
|
+
}, n.prototype.startDrawingMarker = function(s) {
|
|
2361
|
+
var s = O(s, L);
|
|
2362
|
+
this.startDrawing(function() {
|
|
2363
|
+
h.remove(), y.destroy(), g.setVisible(!1);
|
|
2364
|
+
});
|
|
2365
|
+
var f = this, c = this._scene;
|
|
2366
|
+
c.primitives;
|
|
2367
|
+
var g = this._tooltip, h = new n.BillboardGroup(this, s), y = new p.ScreenSpaceEventHandler(c.canvas);
|
|
2368
|
+
y.setInputAction(function(m) {
|
|
2369
|
+
if (m.position != null) {
|
|
2370
|
+
var E = c.camera.pickEllipsoid(m.position, e);
|
|
2371
|
+
E && (h.addBillboard(E), f.stopDrawing(), s.callback(E));
|
|
2372
|
+
}
|
|
2373
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), y.setInputAction(function(m) {
|
|
2374
|
+
var E = m.endPosition;
|
|
2375
|
+
if (E != null) {
|
|
2376
|
+
var T = c.camera.pickEllipsoid(E, e);
|
|
2377
|
+
T ? g.showAt(
|
|
2378
|
+
E,
|
|
2379
|
+
"<p>Click to add your marker. Position is: </p>" + U(e.cartesianToCartographic(T))
|
|
2380
|
+
) : g.showAt(E, "<p>Click on the globe to add your marker.</p>");
|
|
2381
|
+
}
|
|
2382
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE);
|
|
2383
|
+
}, n.prototype.startDrawingPolygon = function(s) {
|
|
2384
|
+
var s = O(s, o);
|
|
2385
|
+
this.startDrawingPolyshape(!0, s);
|
|
2386
|
+
}, n.prototype.startDrawingPolyline = function(s) {
|
|
2387
|
+
var s = O(s, S);
|
|
2388
|
+
this.startDrawingPolyshape(!1, s);
|
|
2389
|
+
}, n.prototype.startDrawingPolyshape = function(r, s) {
|
|
2390
|
+
this.startDrawing(function() {
|
|
2391
|
+
g.remove(m), T.remove(), b.destroy(), h.setVisible(!1), F(c);
|
|
2392
|
+
});
|
|
2393
|
+
var f = this, c = this._scene, g = c.primitives, h = this._tooltip, y = r ? 3 : 2, m;
|
|
2394
|
+
r ? m = new fe.PolygonPrimitive(s) : m = new fe.PolylinePrimitive(s), m.asynchronous = !1, g.add(m);
|
|
2395
|
+
var E = [], T = new n.BillboardGroup(this, L), b = new p.ScreenSpaceEventHandler(c.canvas);
|
|
2396
|
+
Y(c), b.setInputAction(function(w) {
|
|
2397
|
+
if (w.position != null) {
|
|
2398
|
+
var _ = c.camera.pickEllipsoid(w.position, e);
|
|
2399
|
+
_ && (E.length == 0 && (E.push(_.clone()), T.addBillboard(E[0])), E.length >= y && (m.positions = E, m._createPrimitive = !0), E.push(_), T.addBillboard(_));
|
|
2400
|
+
}
|
|
2401
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), b.setInputAction(function(w) {
|
|
2402
|
+
var _ = w.endPosition;
|
|
2403
|
+
if (_ != null)
|
|
2404
|
+
if (E.length == 0)
|
|
2405
|
+
h.showAt(_, "<p>Click to add first point</p>");
|
|
2406
|
+
else {
|
|
2407
|
+
var P = c.camera.pickEllipsoid(_, e);
|
|
2408
|
+
P && (E.pop(), P.y += 1 + Math.random(), E.push(P), E.length >= y && (m.positions = E, m._createPrimitive = !0), T.getBillboard(E.length - 1).position = P, h.showAt(
|
|
2409
|
+
_,
|
|
2410
|
+
"<p>Click to add new point (" + E.length + ")</p>" + (E.length > y ? "<p>Double click to finish drawing</p>" : "")
|
|
2411
|
+
));
|
|
2412
|
+
}
|
|
2413
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE), b.setInputAction(function(w) {
|
|
2414
|
+
var _ = w.position;
|
|
2415
|
+
if (_ != null) {
|
|
2416
|
+
if (E.length < y + 2)
|
|
2417
|
+
return;
|
|
2418
|
+
var P = c.camera.pickEllipsoid(_, e);
|
|
2419
|
+
P && (F(c), f.stopDrawing(), typeof s.callback == "function" && (E.length - 1, s.callback(E)));
|
|
2420
|
+
}
|
|
2421
|
+
}, p.ScreenSpaceEventType.LEFT_DOUBLE_CLICK);
|
|
2422
|
+
};
|
|
2423
|
+
function K(r) {
|
|
2424
|
+
return e.cartographicArrayToCartesianArray([
|
|
2425
|
+
p.Rectangle.northwest(r),
|
|
2426
|
+
p.Rectangle.northeast(r),
|
|
2427
|
+
p.Rectangle.southeast(r),
|
|
2428
|
+
p.Rectangle.southwest(r)
|
|
2429
|
+
]);
|
|
2430
|
+
}
|
|
2431
|
+
function Y(r) {
|
|
2432
|
+
r && (r.canvas.style.cursor = "crosshair");
|
|
2433
|
+
}
|
|
2434
|
+
function F(r) {
|
|
2435
|
+
r && (r.canvas.style.cursor = "");
|
|
2436
|
+
}
|
|
2437
|
+
n.prototype.startDrawingExtent = function(s) {
|
|
2438
|
+
var s = O(s, o);
|
|
2439
|
+
this.startDrawing(function() {
|
|
2440
|
+
m != null && g.remove(m), E != null && E.remove(), T.destroy(), h.setVisible(!1), F(c);
|
|
2441
|
+
});
|
|
2442
|
+
var f = this, c = this._scene, g = this._scene.primitives, h = this._tooltip, y = null, m = null, E = null, T = new p.ScreenSpaceEventHandler(c.canvas);
|
|
2443
|
+
Y(c);
|
|
2444
|
+
function b(w) {
|
|
2445
|
+
m == null && (m = new fe.ExtentPrimitive({
|
|
2446
|
+
extent: w,
|
|
2447
|
+
material: s.material
|
|
2448
|
+
}), m.asynchronous = !1, g.add(m)), m.setExtent(w);
|
|
2449
|
+
var _ = K(w);
|
|
2450
|
+
E == null ? (E = new n.BillboardGroup(f, L), E.addBillboards(_)) : E.updateBillboardsPositions(_);
|
|
2451
|
+
}
|
|
2452
|
+
T.setInputAction(function(w) {
|
|
2453
|
+
if (w.position != null) {
|
|
2454
|
+
var _ = c.camera.pickEllipsoid(w.position, e);
|
|
2455
|
+
if (_)
|
|
2456
|
+
if (m == null) {
|
|
2457
|
+
y = e.cartesianToCartographic(_);
|
|
2458
|
+
var P = X(y, y);
|
|
2459
|
+
b(P);
|
|
2460
|
+
} else
|
|
2461
|
+
f.stopDrawing(), typeof s.callback == "function" && s.callback(X(y, e.cartesianToCartographic(_)));
|
|
2462
|
+
}
|
|
2463
|
+
}, p.ScreenSpaceEventType.LEFT_DOWN), T.setInputAction(function(w) {
|
|
2464
|
+
var _ = w.endPosition;
|
|
2465
|
+
if (_ != null)
|
|
2466
|
+
if (m == null)
|
|
2467
|
+
h.showAt(_, "<p>Click to start drawing rectangle</p>");
|
|
2468
|
+
else {
|
|
2469
|
+
var P = c.camera.pickEllipsoid(_, e);
|
|
2470
|
+
if (P) {
|
|
2471
|
+
var H = X(y, e.cartesianToCartographic(P));
|
|
2472
|
+
b(H), h.showAt(_, "<p>Drag to change rectangle extent</p><p>Click again to finish drawing</p>");
|
|
2473
|
+
}
|
|
2474
|
+
}
|
|
2475
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE);
|
|
2476
|
+
}, n.prototype.startDrawingCircle = function(s) {
|
|
2477
|
+
var s = O(s, o);
|
|
2478
|
+
this.startDrawing(function() {
|
|
2479
|
+
y != null && g.remove(y), m.remove(), E.destroy(), h.setVisible(!1);
|
|
2480
|
+
});
|
|
2481
|
+
var f = this, c = this._scene, g = this._scene.primitives, h = this._tooltip, y = null, m = null, E = new p.ScreenSpaceEventHandler(c.canvas);
|
|
2482
|
+
E.setInputAction(function(T) {
|
|
2483
|
+
if (T.position != null) {
|
|
2484
|
+
var b = c.camera.pickEllipsoid(T.position, e);
|
|
2485
|
+
b && (y == null ? (y = new n.CirclePrimitive({
|
|
2486
|
+
center: b,
|
|
2487
|
+
radius: 0,
|
|
2488
|
+
asynchronous: !1,
|
|
2489
|
+
material: s.material
|
|
2490
|
+
}), g.add(y), m = new n.BillboardGroup(f, L), m.addBillboards([b])) : (typeof s.callback == "function" && s.callback(y.getCenter(), y.getRadius()), f.stopDrawing()));
|
|
2491
|
+
}
|
|
2492
|
+
}, p.ScreenSpaceEventType.LEFT_DOWN), E.setInputAction(function(T) {
|
|
2493
|
+
var b = T.endPosition;
|
|
2494
|
+
if (b != null)
|
|
2495
|
+
if (y == null)
|
|
2496
|
+
h.showAt(b, "<p>Click to start drawing the circle</p>");
|
|
2497
|
+
else {
|
|
2498
|
+
var w = c.camera.pickEllipsoid(b, e);
|
|
2499
|
+
w && (y.setRadius(p.Cartesian3.distance(y.getCenter(), w)), m.updateBillboardsPositions(w), h.showAt(b, "<p>Move mouse to change circle radius</p><p>Click again to finish drawing</p>"));
|
|
2500
|
+
}
|
|
2501
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE);
|
|
2502
|
+
}, n.prototype.enhancePrimitives = function() {
|
|
2503
|
+
var r = this;
|
|
2504
|
+
p.Billboard.prototype.setEditable = function() {
|
|
2505
|
+
if (this._editable)
|
|
2506
|
+
return;
|
|
2507
|
+
this._editable = !0;
|
|
2508
|
+
var c = this, g = this;
|
|
2509
|
+
function h(y) {
|
|
2510
|
+
r._scene.screenSpaceCameraController.enableRotate = y;
|
|
2511
|
+
}
|
|
2512
|
+
$(c, "leftDown", function(y) {
|
|
2513
|
+
function m(b) {
|
|
2514
|
+
c.position = b, g.executeListeners({ name: "drag", positions: b });
|
|
2515
|
+
}
|
|
2516
|
+
function E(b) {
|
|
2517
|
+
T.destroy(), h(!0), g.executeListeners({ name: "dragEnd", positions: b });
|
|
2518
|
+
}
|
|
2519
|
+
var T = new p.ScreenSpaceEventHandler(r._scene.canvas);
|
|
2520
|
+
T.setInputAction(function(b) {
|
|
2521
|
+
var w = r._scene.camera.pickEllipsoid(b.endPosition, e);
|
|
2522
|
+
w ? m(w) : E(w);
|
|
2523
|
+
}, p.ScreenSpaceEventType.MOUSE_MOVE), T.setInputAction(function(b) {
|
|
2524
|
+
E(r._scene.camera.pickEllipsoid(b.position, e));
|
|
2525
|
+
}, p.ScreenSpaceEventType.LEFT_UP), h(!1);
|
|
2526
|
+
}), q(c);
|
|
2527
|
+
};
|
|
2528
|
+
function s(c) {
|
|
2529
|
+
r._scene, !(this._highlighted && this._highlighted == c) && this._editMode !== !0 && (this._highlighted = c, c ? (r.setHighlighted(this), this._strokeColor = this.strokeColor, this.setStrokeStyle(p.Color.fromCssColorString("white"), this.strokeWidth)) : this._strokeColor ? this.setStrokeStyle(this._strokeColor, this.strokeWidth) : this.setStrokeStyle(void 0, void 0));
|
|
2530
|
+
}
|
|
2531
|
+
function f(c) {
|
|
2532
|
+
if (this._editMode != c)
|
|
2533
|
+
if (r.disableAllHighlights(), c) {
|
|
2534
|
+
r.setEdited(this);
|
|
2535
|
+
var g = r._scene, h = this;
|
|
2536
|
+
if (this._markers == null) {
|
|
2537
|
+
let P = function(M, x) {
|
|
2538
|
+
var B = M - 1 < 0 ? x.length - 1 : M - 1;
|
|
2539
|
+
B < m.countBillboards() && (m.getBillboard(B).position = W(B)), B = M, B < m.countBillboards() && (m.getBillboard(B).position = W(B));
|
|
2540
|
+
}, H = function() {
|
|
2541
|
+
h.executeListeners({
|
|
2542
|
+
name: "onEdited",
|
|
2543
|
+
positions: h.positions
|
|
2544
|
+
});
|
|
2545
|
+
}, W = function(M) {
|
|
2546
|
+
var x = h.positions;
|
|
2547
|
+
return e.cartographicToCartesian(
|
|
2548
|
+
new p.EllipsoidGeodesic(
|
|
2549
|
+
e.cartesianToCartographic(x[M]),
|
|
2550
|
+
e.cartesianToCartographic(x[M < x.length - 1 ? M + 1 : 0])
|
|
2551
|
+
).interpolateUsingFraction(0.5)
|
|
2552
|
+
);
|
|
2553
|
+
};
|
|
2554
|
+
var y = new n.BillboardGroup(r, R), m = new n.BillboardGroup(r, z), E = {
|
|
2555
|
+
dragHandlers: {
|
|
2556
|
+
onDrag: function(M, x) {
|
|
2557
|
+
h.positions[M] = x, P(M, h.positions), h._createPrimitive = !0;
|
|
2558
|
+
},
|
|
2559
|
+
onDragEnd: function(M, x) {
|
|
2560
|
+
h._createPrimitive = !0, H();
|
|
2561
|
+
}
|
|
2562
|
+
},
|
|
2563
|
+
onDoubleClick: function(M) {
|
|
2564
|
+
h.positions.length < 4 || (h.positions.splice(M, 1), h._createPrimitive = !0, y.removeBillboard(M), m.removeBillboard(M), P(M, h.positions), H());
|
|
2565
|
+
},
|
|
2566
|
+
tooltip: function() {
|
|
2567
|
+
if (h.positions.length > 3)
|
|
2568
|
+
return "Double click to remove this point";
|
|
2569
|
+
}
|
|
2570
|
+
};
|
|
2571
|
+
y.addBillboards(h.positions, E), this._markers = y;
|
|
2572
|
+
for (var T = [], b = 0, w = h.positions.length + (this.isPolygon ? 0 : -1); b < w; b++)
|
|
2573
|
+
T.push(W(b));
|
|
2574
|
+
var _ = {
|
|
2575
|
+
dragHandlers: {
|
|
2576
|
+
onDragStart: function(M, x) {
|
|
2577
|
+
this.index = M + 1, h.positions.splice(this.index, 0, x), h._createPrimitive = !0;
|
|
2578
|
+
},
|
|
2579
|
+
onDrag: function(M, x) {
|
|
2580
|
+
h.positions[this.index] = x, h._createPrimitive = !0;
|
|
2581
|
+
},
|
|
2582
|
+
onDragEnd: function(M, x) {
|
|
2583
|
+
y.insertBillboard(this.index, x, E), m.getBillboard(this.index - 1).position = W(this.index - 1), m.insertBillboard(this.index, W(this.index), _), h._createPrimitive = !0, H();
|
|
2584
|
+
}
|
|
2585
|
+
},
|
|
2586
|
+
tooltip: function() {
|
|
2587
|
+
return "Drag to create a new point";
|
|
2588
|
+
}
|
|
2589
|
+
};
|
|
2590
|
+
m.addBillboards(T, _), this._editMarkers = m, this._globeClickhandler = new p.ScreenSpaceEventHandler(g.canvas), this._globeClickhandler.setInputAction(function(M) {
|
|
2591
|
+
var x = g.pick(M.position);
|
|
2592
|
+
x && x.primitive || h.setEditMode(!1);
|
|
2593
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), y.setOnTop(), m.setOnTop();
|
|
2594
|
+
}
|
|
2595
|
+
this._editMode = !0;
|
|
2596
|
+
} else
|
|
2597
|
+
this._markers != null && (this._markers.remove(), this._editMarkers.remove(), this._markers = null, this._editMarkers = null, this._globeClickhandler.destroy()), this._editMode = !1;
|
|
2598
|
+
}
|
|
2599
|
+
fe.PolylinePrimitive.prototype.setEditable = function() {
|
|
2600
|
+
if (!this.setEditMode) {
|
|
2601
|
+
var c = this;
|
|
2602
|
+
c.isPolygon = !1, c.asynchronous = !1, r.registerEditableShape(c), c.setEditMode = f;
|
|
2603
|
+
var g = this.width;
|
|
2604
|
+
c.setHighlighted = function(h) {
|
|
2605
|
+
this._editMode !== !0 && (h ? (r.setHighlighted(this), this.setWidth(g * 2)) : this.setWidth(g));
|
|
2606
|
+
}, c.getExtent = function() {
|
|
2607
|
+
return p.Rectangle.fromCartographicArray(e.cartesianArrayToCartographicArray(this.positions));
|
|
2608
|
+
}, q(c), c.setEditMode(!1);
|
|
2609
|
+
}
|
|
2610
|
+
}, fe.PolygonPrimitive.prototype.setEditable = function() {
|
|
2611
|
+
var c = this;
|
|
2612
|
+
c.asynchronous = !1, r._scene, r.registerEditableShape(c), c.setEditMode = f, c.setHighlighted = s, q(c), c.setEditMode(!1);
|
|
2613
|
+
}, fe.ExtentPrimitive.prototype.setEditable = function() {
|
|
2614
|
+
if (!this.setEditMode) {
|
|
2615
|
+
var c = this, g = r._scene;
|
|
2616
|
+
r.registerEditableShape(c), c.asynchronous = !1, c.setEditMode = function(h) {
|
|
2617
|
+
if (this._editMode != h)
|
|
2618
|
+
if (r.disableAllHighlights(), h) {
|
|
2619
|
+
if (r.setEdited(this), this._markers == null) {
|
|
2620
|
+
let E = function() {
|
|
2621
|
+
c.executeListeners({
|
|
2622
|
+
name: "onEdited",
|
|
2623
|
+
extent: c.extent
|
|
2624
|
+
});
|
|
2625
|
+
};
|
|
2626
|
+
var y = new n.BillboardGroup(r, R), m = {
|
|
2627
|
+
dragHandlers: {
|
|
2628
|
+
onDrag: function(T, b) {
|
|
2629
|
+
var w = y.getBillboard((T + 2) % 4).position;
|
|
2630
|
+
c.setExtent(X(e.cartesianToCartographic(w), e.cartesianToCartographic(b))), y.updateBillboardsPositions(K(c.extent));
|
|
2631
|
+
},
|
|
2632
|
+
onDragEnd: function(T, b) {
|
|
2633
|
+
E();
|
|
2634
|
+
}
|
|
2635
|
+
},
|
|
2636
|
+
tooltip: function() {
|
|
2637
|
+
return "Drag to change the corners of this extent";
|
|
2638
|
+
}
|
|
2639
|
+
};
|
|
2640
|
+
y.addBillboards(K(c.extent), m), this._markers = y, this._globeClickhandler = new p.ScreenSpaceEventHandler(g.canvas), this._globeClickhandler.setInputAction(function(T) {
|
|
2641
|
+
var b = g.pick(T.position);
|
|
2642
|
+
b && !b.isDestroyed() && b.primitive || c.setEditMode(!1);
|
|
2643
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), y.setOnTop();
|
|
2644
|
+
}
|
|
2645
|
+
this._editMode = !0;
|
|
2646
|
+
} else
|
|
2647
|
+
this._markers != null && (this._markers.remove(), this._markers = null, this._globeClickhandler.destroy()), this._editMode = !1;
|
|
2648
|
+
}, c.setHighlighted = s, q(c), c.setEditMode(!1);
|
|
2649
|
+
}
|
|
2650
|
+
}, n.EllipsePrimitive.prototype.setEditable = function() {
|
|
2651
|
+
if (!this.setEditMode) {
|
|
2652
|
+
var c = this, g = r._scene;
|
|
2653
|
+
c.asynchronous = !1, r.registerEditableShape(c), c.setEditMode = function(h) {
|
|
2654
|
+
if (this._editMode != h)
|
|
2655
|
+
if (r.disableAllHighlights(), h) {
|
|
2656
|
+
r.setEdited(this);
|
|
2657
|
+
var y = this;
|
|
2658
|
+
if (this._markers == null) {
|
|
2659
|
+
let T = function() {
|
|
2660
|
+
return p.EllipseOutlineGeometry(
|
|
2661
|
+
e,
|
|
2662
|
+
c.getCenter(),
|
|
2663
|
+
c.getSemiMajorAxis(),
|
|
2664
|
+
c.getSemiMinorAxis(),
|
|
2665
|
+
c.getRotation() + Math.PI / 2,
|
|
2666
|
+
Math.PI / 2
|
|
2667
|
+
).splice(0, 4);
|
|
2668
|
+
}, b = function() {
|
|
2669
|
+
c.executeListeners({
|
|
2670
|
+
name: "onEdited",
|
|
2671
|
+
center: c.getCenter(),
|
|
2672
|
+
semiMajorAxis: c.getSemiMajorAxis(),
|
|
2673
|
+
semiMinorAxis: c.getSemiMinorAxis(),
|
|
2674
|
+
rotation: 0
|
|
2675
|
+
});
|
|
2676
|
+
};
|
|
2677
|
+
var m = new n.BillboardGroup(r, R), E = {
|
|
2678
|
+
dragHandlers: {
|
|
2679
|
+
onDrag: function(w, _) {
|
|
2680
|
+
var P = p.Cartesian3.distance(c.getCenter(), _);
|
|
2681
|
+
w % 2 == 0 ? c.setSemiMajorAxis(P) : c.setSemiMinorAxis(P), m.updateBillboardsPositions(T());
|
|
2682
|
+
},
|
|
2683
|
+
onDragEnd: function(w, _) {
|
|
2684
|
+
b();
|
|
2685
|
+
}
|
|
2686
|
+
},
|
|
2687
|
+
tooltip: function() {
|
|
2688
|
+
return "Drag to change the excentricity and radius";
|
|
2689
|
+
}
|
|
2690
|
+
};
|
|
2691
|
+
m.addBillboards(T(), E), this._markers = m, this._globeClickhandler = new p.ScreenSpaceEventHandler(g.canvas), this._globeClickhandler.setInputAction(function(w) {
|
|
2692
|
+
var _ = g.pick(w.position);
|
|
2693
|
+
_ && _.primitive || y.setEditMode(!1);
|
|
2694
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), m.setOnTop();
|
|
2695
|
+
}
|
|
2696
|
+
this._editMode = !0;
|
|
2697
|
+
} else
|
|
2698
|
+
this._markers != null && (this._markers.remove(), this._markers = null, this._globeClickhandler.destroy()), this._editMode = !1;
|
|
2699
|
+
}, c.setHighlighted = s, q(c), c.setEditMode(!1);
|
|
2700
|
+
}
|
|
2701
|
+
}, n.CirclePrimitive.prototype.getCircleCartesianCoordinates = function(c) {
|
|
2702
|
+
for (var g = p.CircleOutlineGeometry.createGeometry(
|
|
2703
|
+
new p.CircleOutlineGeometry({
|
|
2704
|
+
ellipsoid: e,
|
|
2705
|
+
center: this.getCenter(),
|
|
2706
|
+
radius: this.getRadius(),
|
|
2707
|
+
granularity: c
|
|
2708
|
+
})
|
|
2709
|
+
), h = 0, y, m = []; h < g.attributes.position.values.length; h += 3)
|
|
2710
|
+
y = g.attributes.position.values, m.push(new p.Cartesian3(y[h], y[h + 1], y[h + 2]));
|
|
2711
|
+
return m;
|
|
2712
|
+
}, n.CirclePrimitive.prototype.setEditable = function() {
|
|
2713
|
+
if (!this.setEditMode) {
|
|
2714
|
+
var c = this, g = r._scene;
|
|
2715
|
+
c.asynchronous = !1, r.registerEditableShape(c), c.setEditMode = function(h) {
|
|
2716
|
+
if (this._editMode != h)
|
|
2717
|
+
if (r.disableAllHighlights(), h) {
|
|
2718
|
+
r.setEdited(this);
|
|
2719
|
+
var y = this;
|
|
2720
|
+
if (this._markers == null) {
|
|
2721
|
+
let T = function() {
|
|
2722
|
+
return y.getCircleCartesianCoordinates(p.Math.PI_OVER_TWO);
|
|
2723
|
+
}, b = function() {
|
|
2724
|
+
c.executeListeners({
|
|
2725
|
+
name: "onEdited",
|
|
2726
|
+
center: c.getCenter(),
|
|
2727
|
+
radius: c.getRadius()
|
|
2728
|
+
});
|
|
2729
|
+
};
|
|
2730
|
+
var m = new n.BillboardGroup(r, R), E = {
|
|
2731
|
+
dragHandlers: {
|
|
2732
|
+
onDrag: function(w, _) {
|
|
2733
|
+
c.setRadius(p.Cartesian3.distance(c.getCenter(), _)), m.updateBillboardsPositions(T());
|
|
2734
|
+
},
|
|
2735
|
+
onDragEnd: function(w, _) {
|
|
2736
|
+
b();
|
|
2737
|
+
}
|
|
2738
|
+
},
|
|
2739
|
+
tooltip: function() {
|
|
2740
|
+
return "Drag to change the radius";
|
|
2741
|
+
}
|
|
2742
|
+
};
|
|
2743
|
+
m.addBillboards(T(), E), this._markers = m, this._globeClickhandler = new p.ScreenSpaceEventHandler(g.canvas), this._globeClickhandler.setInputAction(function(w) {
|
|
2744
|
+
var _ = g.pick(w.position);
|
|
2745
|
+
_ && _.primitive || y.setEditMode(!1);
|
|
2746
|
+
}, p.ScreenSpaceEventType.LEFT_CLICK), m.setOnTop();
|
|
2747
|
+
}
|
|
2748
|
+
this._editMode = !0;
|
|
2749
|
+
} else
|
|
2750
|
+
this._markers != null && (this._markers.remove(), this._markers = null, this._globeClickhandler.destroy()), this._editMode = !1;
|
|
2751
|
+
}, c.setHighlighted = s, q(c), c.setEditMode(!1);
|
|
2752
|
+
}
|
|
2753
|
+
};
|
|
2754
|
+
}, n.DrawHelperWidget = function() {
|
|
2755
|
+
function r(s, f) {
|
|
2756
|
+
if (!p.defined(f.container))
|
|
2757
|
+
throw new p.DeveloperError("Container is required");
|
|
2758
|
+
var c = {
|
|
2759
|
+
markerIcon: "./assets/img/glyphicons_242_google_maps.png",
|
|
2760
|
+
polylineIcon: "./assets/img/glyphicons_097_vector_path_line.png",
|
|
2761
|
+
polygonIcon: "./assets/img/glyphicons_096_vector_path_polygon.png",
|
|
2762
|
+
circleIcon: "./assets/img/glyphicons_095_vector_path_circle.png",
|
|
2763
|
+
extentIcon: "./assets/img/glyphicons_094_vector_path_square.png",
|
|
2764
|
+
clearIcon: "./assets/img/glyphicons_067_cleaning.png",
|
|
2765
|
+
polylineDrawingOptions: S,
|
|
2766
|
+
polygonDrawingOptions: d,
|
|
2767
|
+
extentDrawingOptions: u,
|
|
2768
|
+
circleDrawingOptions: v
|
|
2769
|
+
};
|
|
2770
|
+
j(f, c);
|
|
2771
|
+
var g = this, h = document.createElement("DIV");
|
|
2772
|
+
h.className = "toolbar", f.container.appendChild(h);
|
|
2773
|
+
function y(T, b, w, _) {
|
|
2774
|
+
var P = document.createElement("DIV");
|
|
2775
|
+
P.className = "button", P.title = w, h.appendChild(P), P.onclick = _;
|
|
2776
|
+
var H = document.createElement("SPAN");
|
|
2777
|
+
P.appendChild(H);
|
|
2778
|
+
var W = document.createElement("IMG");
|
|
2779
|
+
return W.src = b, H.appendChild(W), P;
|
|
2780
|
+
}
|
|
2781
|
+
var m = s._scene;
|
|
2782
|
+
y("marker", f.markerIcon, "Click to start drawing a 2D marker", function() {
|
|
2783
|
+
s.startDrawingMarker({
|
|
2784
|
+
callback: function(T) {
|
|
2785
|
+
g.executeListeners({
|
|
2786
|
+
name: "markerCreated",
|
|
2787
|
+
position: T
|
|
2788
|
+
});
|
|
2789
|
+
}
|
|
2790
|
+
});
|
|
2791
|
+
}), y("polyline", f.polylineIcon, "Click to start drawing a 2D polyline", function() {
|
|
2792
|
+
s.startDrawingPolyline({
|
|
2793
|
+
callback: function(T) {
|
|
2794
|
+
g.executeListeners({
|
|
2795
|
+
name: "polylineCreated",
|
|
2796
|
+
positions: T
|
|
2797
|
+
});
|
|
2798
|
+
}
|
|
2799
|
+
});
|
|
2800
|
+
}), y("polygon", f.polygonIcon, "Click to start drawing a 2D polygon", function() {
|
|
2801
|
+
s.startDrawingPolygon({
|
|
2802
|
+
callback: function(T) {
|
|
2803
|
+
g.executeListeners({
|
|
2804
|
+
name: "polygonCreated",
|
|
2805
|
+
positions: T
|
|
2806
|
+
});
|
|
2807
|
+
}
|
|
2808
|
+
});
|
|
2809
|
+
}), y("extent", f.extentIcon, "Click to start drawing an Extent", function() {
|
|
2810
|
+
s.startDrawingExtent({
|
|
2811
|
+
callback: function(T) {
|
|
2812
|
+
g.executeListeners({ name: "extentCreated", extent: T });
|
|
2813
|
+
}
|
|
2814
|
+
});
|
|
2815
|
+
}), y("circle", f.circleIcon, "Click to start drawing a Circle", function() {
|
|
2816
|
+
s.startDrawingCircle({
|
|
2817
|
+
callback: function(T, b) {
|
|
2818
|
+
g.executeListeners({
|
|
2819
|
+
name: "circleCreated",
|
|
2820
|
+
center: T,
|
|
2821
|
+
radius: b
|
|
2822
|
+
});
|
|
2823
|
+
}
|
|
2824
|
+
});
|
|
2825
|
+
});
|
|
2826
|
+
var E = document.createElement("DIV");
|
|
2827
|
+
E.className = "divider", h.appendChild(E), y("clear", f.clearIcon, "Remove all primitives", function() {
|
|
2828
|
+
m.primitives.removeAll();
|
|
2829
|
+
}), q(this);
|
|
2830
|
+
}
|
|
2831
|
+
return r;
|
|
2832
|
+
}(), n.prototype.addToolbar = function(r, s) {
|
|
2833
|
+
return s = O(s, { container: r }), new n.DrawHelperWidget(this, s);
|
|
2834
|
+
};
|
|
2835
|
+
function X(r, s) {
|
|
2836
|
+
var f = new p.Rectangle();
|
|
2837
|
+
f.west = Math.min(r.longitude, s.longitude), f.east = Math.max(r.longitude, s.longitude), f.south = Math.min(r.latitude, s.latitude), f.north = Math.max(r.latitude, s.latitude);
|
|
2838
|
+
var c = p.Math.EPSILON7;
|
|
2839
|
+
return f.east - f.west < c && (f.east += c * 2), f.north - f.south < c && (f.north += c * 2), f;
|
|
2840
|
+
}
|
|
2841
|
+
function U(r, s) {
|
|
2842
|
+
return r.longitude.toFixed(s || 3) + ", " + r.latitude.toFixed(s || 3);
|
|
2843
|
+
}
|
|
2844
|
+
function V(r, s) {
|
|
2845
|
+
if (r == null || typeof r != "object" || r.constructor != Object && r.constructor != Array)
|
|
2846
|
+
return r;
|
|
2847
|
+
if (r.constructor == Date || r.constructor == RegExp || r.constructor == Function || r.constructor == String || r.constructor == Number || r.constructor == Boolean)
|
|
2848
|
+
return new r.constructor(r);
|
|
2849
|
+
s = s || new r.constructor();
|
|
2850
|
+
for (var f in r)
|
|
2851
|
+
s[f] = typeof s[f] > "u" ? V(r[f], null) : s[f];
|
|
2852
|
+
return s;
|
|
2853
|
+
}
|
|
2854
|
+
function j(r, s) {
|
|
2855
|
+
r = r || {};
|
|
2856
|
+
var f;
|
|
2857
|
+
for (f in s)
|
|
2858
|
+
r[f] === void 0 && (r[f] = V(s[f]));
|
|
2859
|
+
}
|
|
2860
|
+
function O(r, s) {
|
|
2861
|
+
var f = V(r), c;
|
|
2862
|
+
for (c in s)
|
|
2863
|
+
f[c] === void 0 && (f[c] = V(s[c]));
|
|
2864
|
+
return f;
|
|
2865
|
+
}
|
|
2866
|
+
function $(r, s, f) {
|
|
2867
|
+
r[s] = f;
|
|
2868
|
+
}
|
|
2869
|
+
function q(r) {
|
|
2870
|
+
r._listeners = {}, r.addListener = function(s, f) {
|
|
2871
|
+
return this._listeners[s] = this._listeners[s] || [], this._listeners[s].push(f), this._listeners[s].length;
|
|
2872
|
+
}, r.executeListeners = function(s, f) {
|
|
2873
|
+
if (this._listeners[s.name] && this._listeners[s.name].length > 0)
|
|
2874
|
+
for (var c = 0; c < this._listeners[s.name].length; c++)
|
|
2875
|
+
this._listeners[s.name][c](s);
|
|
2876
|
+
else
|
|
2877
|
+
f && f(s);
|
|
2878
|
+
};
|
|
2879
|
+
}
|
|
2880
|
+
return n;
|
|
2881
|
+
}();
|
|
2882
|
+
const Mr = 2, Ar = (e, i) => {
|
|
2883
|
+
switch (e) {
|
|
2884
|
+
case re.BOX: {
|
|
2885
|
+
if (i.features.length !== Mr)
|
|
2886
|
+
throw new Error(`${e} must have 2 points`);
|
|
2887
|
+
const t = at(i.features, (a) => {
|
|
2888
|
+
var o;
|
|
2889
|
+
return ((o = a.properties) == null ? void 0 : o.type) === qe.BOTTOM_LEFT;
|
|
2890
|
+
}), n = at(i.features, (a) => {
|
|
2891
|
+
var o;
|
|
2892
|
+
return ((o = a.properties) == null ? void 0 : o.type) === qe.TOP_RIGHT;
|
|
2893
|
+
});
|
|
2894
|
+
if (n && t) {
|
|
2895
|
+
if (t.geometry.coordinates[0] === n.geometry.coordinates[0] && t.geometry.coordinates[1] === n.geometry.coordinates[1])
|
|
2896
|
+
throw new Error(
|
|
2897
|
+
`${e} must define BOTTOM_LEFT and TOP_RIGHT different points`
|
|
2898
|
+
);
|
|
2899
|
+
return Ce.fromDegrees(
|
|
2900
|
+
t.geometry.coordinates[0],
|
|
2901
|
+
t.geometry.coordinates[1],
|
|
2902
|
+
n.geometry.coordinates[0],
|
|
2903
|
+
n.geometry.coordinates[1]
|
|
2904
|
+
);
|
|
2905
|
+
} else
|
|
2906
|
+
throw new Error(
|
|
2907
|
+
`${e} geojson must define BOTTOM_LEFT and TOP_RIGHT points`
|
|
2908
|
+
);
|
|
2909
|
+
}
|
|
2910
|
+
default:
|
|
2911
|
+
throw new Error(`${e} type geoJSON still not supported`);
|
|
2912
|
+
}
|
|
2913
|
+
}, xr = (e) => {
|
|
2914
|
+
const i = e.map((t) => {
|
|
2915
|
+
const n = Be.fromCartesian(t);
|
|
2916
|
+
return [
|
|
2917
|
+
le.toDegrees(n.longitude),
|
|
2918
|
+
le.toDegrees(n.latitude)
|
|
2919
|
+
];
|
|
2920
|
+
});
|
|
2921
|
+
return i.push(i[0]), {
|
|
2922
|
+
type: "Feature",
|
|
2923
|
+
properties: {},
|
|
2924
|
+
geometry: {
|
|
2925
|
+
type: "Polygon",
|
|
2926
|
+
coordinates: [i]
|
|
2927
|
+
}
|
|
2928
|
+
};
|
|
2929
|
+
}, kr = (e) => {
|
|
2930
|
+
const i = Lt.lineString([
|
|
2931
|
+
[
|
|
2932
|
+
le.toDegrees(e.west),
|
|
2933
|
+
le.toDegrees(e.south)
|
|
2934
|
+
],
|
|
2935
|
+
[
|
|
2936
|
+
le.toDegrees(e.east),
|
|
2937
|
+
le.toDegrees(e.north)
|
|
2938
|
+
]
|
|
2939
|
+
]);
|
|
2940
|
+
return Mt(Pt(i));
|
|
2941
|
+
}, Ir = (e) => {
|
|
2942
|
+
const i = Lt.lineString([
|
|
2943
|
+
[e.west, e.south],
|
|
2944
|
+
[e.east, e.north]
|
|
2945
|
+
]);
|
|
2946
|
+
return Mt(Pt(i)).geometry.coordinates[0].map(
|
|
2947
|
+
(n) => me.fromRadiansArray(n)[0]
|
|
2948
|
+
);
|
|
2949
|
+
};
|
|
2950
|
+
class qo extends Xi {
|
|
2951
|
+
}
|
|
2952
|
+
const Yo = (e) => {
|
|
2953
|
+
const {
|
|
2954
|
+
drawState: i,
|
|
2955
|
+
drawingMaterial: t,
|
|
2956
|
+
drawingVertexColor: n,
|
|
2957
|
+
material: a,
|
|
2958
|
+
hollow: o,
|
|
2959
|
+
outlineWidth: d
|
|
2960
|
+
} = e, u = he(), [v, C] = k();
|
|
2961
|
+
I(() => {
|
|
2962
|
+
C(
|
|
2963
|
+
// eslint-disable-next-line
|
|
2964
|
+
new fe(u, t, n)
|
|
2965
|
+
);
|
|
2966
|
+
}, []), I(() => {
|
|
2967
|
+
if (v) {
|
|
2968
|
+
const A = v;
|
|
2969
|
+
if (i.drawing)
|
|
2970
|
+
switch (i.type) {
|
|
2971
|
+
case re.POLYGON:
|
|
2972
|
+
u.scene.globe.depthTestAgainstTerrain = !1, A.startDrawingPolygon({
|
|
2973
|
+
callback: (L) => {
|
|
2974
|
+
i.handler({
|
|
2975
|
+
primitive: L,
|
|
2976
|
+
type: re.POLYGON,
|
|
2977
|
+
geojson: xr(L)
|
|
2978
|
+
});
|
|
2979
|
+
}
|
|
2980
|
+
});
|
|
2981
|
+
break;
|
|
2982
|
+
case re.BOX:
|
|
2983
|
+
u.scene.globe.depthTestAgainstTerrain = !1, A.startDrawingExtent({
|
|
2984
|
+
callback: (L) => {
|
|
2985
|
+
i.handler({
|
|
2986
|
+
primitive: L,
|
|
2987
|
+
type: re.BOX,
|
|
2988
|
+
geojson: kr(L)
|
|
2989
|
+
});
|
|
2990
|
+
}
|
|
2991
|
+
});
|
|
2992
|
+
break;
|
|
2993
|
+
default:
|
|
2994
|
+
throw new Error(
|
|
2995
|
+
`[CESIUM DRAW]: ${i.type} unrecognized primitive to draw.`
|
|
2996
|
+
);
|
|
2997
|
+
}
|
|
2998
|
+
else
|
|
2999
|
+
A.stopDrawing(), u.scene.globe.depthTestAgainstTerrain = !0;
|
|
3000
|
+
}
|
|
3001
|
+
}, [i, v]);
|
|
3002
|
+
const S = (A) => {
|
|
3003
|
+
let L = A.coordinates !== void 0 ? A.coordinates : Ar(
|
|
3004
|
+
A.type,
|
|
3005
|
+
A.geojson
|
|
3006
|
+
);
|
|
3007
|
+
if (o !== !0)
|
|
3008
|
+
switch (A.type) {
|
|
3009
|
+
case re.BOX:
|
|
3010
|
+
return /* @__PURE__ */ l(
|
|
3011
|
+
Sr,
|
|
3012
|
+
{
|
|
3013
|
+
coordinates: L,
|
|
3014
|
+
material: a ?? t
|
|
3015
|
+
}
|
|
3016
|
+
);
|
|
3017
|
+
case re.POLYGON:
|
|
3018
|
+
return /* @__PURE__ */ l(
|
|
3019
|
+
_r,
|
|
3020
|
+
{
|
|
3021
|
+
hierarchy: new Zi(L),
|
|
3022
|
+
material: a ?? t
|
|
3023
|
+
}
|
|
3024
|
+
);
|
|
3025
|
+
default:
|
|
3026
|
+
return /* @__PURE__ */ l(oe, {});
|
|
3027
|
+
}
|
|
3028
|
+
else {
|
|
3029
|
+
switch (A.type) {
|
|
3030
|
+
case re.BOX:
|
|
3031
|
+
L = Ir(L);
|
|
3032
|
+
break;
|
|
3033
|
+
case re.POLYGON:
|
|
3034
|
+
L = [
|
|
3035
|
+
...L,
|
|
3036
|
+
L[0]
|
|
3037
|
+
];
|
|
3038
|
+
break;
|
|
3039
|
+
default:
|
|
3040
|
+
return /* @__PURE__ */ l(oe, {});
|
|
3041
|
+
}
|
|
3042
|
+
return /* @__PURE__ */ l(
|
|
3043
|
+
Pr,
|
|
3044
|
+
{
|
|
3045
|
+
positions: L,
|
|
3046
|
+
width: d ?? 1,
|
|
3047
|
+
material: a ?? t
|
|
3048
|
+
}
|
|
3049
|
+
);
|
|
3050
|
+
}
|
|
3051
|
+
};
|
|
3052
|
+
return /* @__PURE__ */ l(Lr, { ...e, children: e.drawings.map((A, L) => /* @__PURE__ */ D(br, { name: A.name, children: [
|
|
3053
|
+
/* @__PURE__ */ D(Tr, { children: [
|
|
3054
|
+
/* @__PURE__ */ D("h1", { children: [
|
|
3055
|
+
"Drawed Entity ",
|
|
3056
|
+
A.name
|
|
3057
|
+
] }),
|
|
3058
|
+
/* @__PURE__ */ l("p", { children: "This is description of drawed entity" })
|
|
3059
|
+
] }),
|
|
3060
|
+
S(A)
|
|
3061
|
+
] }, A.id)) });
|
|
3062
|
+
};
|
|
3063
|
+
class Xo extends Ji {
|
|
3064
|
+
}
|
|
3065
|
+
class Zo extends Qi {
|
|
3066
|
+
}
|
|
3067
|
+
class Jo extends en {
|
|
3068
|
+
}
|
|
3069
|
+
class Qo extends Te {
|
|
3070
|
+
}
|
|
3071
|
+
class es extends me {
|
|
3072
|
+
}
|
|
3073
|
+
class ts extends Be {
|
|
3074
|
+
}
|
|
3075
|
+
class is extends tn {
|
|
3076
|
+
}
|
|
3077
|
+
class ns extends nn {
|
|
3078
|
+
}
|
|
3079
|
+
class rs extends rn {
|
|
3080
|
+
}
|
|
3081
|
+
class os extends Ce {
|
|
3082
|
+
}
|
|
3083
|
+
class ss extends on {
|
|
3084
|
+
}
|
|
3085
|
+
class as extends sn {
|
|
3086
|
+
}
|
|
3087
|
+
class ls extends an {
|
|
3088
|
+
}
|
|
3089
|
+
const cs = ln, ds = cn;
|
|
3090
|
+
const Or = 38, Dr = 40, Rr = 13, Br = 14, Nr = 27, Fr = 9, Hr = 10, Gr = 100, Vr = (e) => {
|
|
3091
|
+
const [i, t] = k(e.defaultValue ?? ""), [n, a] = k(!1), [o, d] = k({
|
|
3092
|
+
helperVisible: !1,
|
|
3093
|
+
left: 0,
|
|
3094
|
+
right: 0,
|
|
3095
|
+
trigger: "",
|
|
3096
|
+
matchLength: 0,
|
|
3097
|
+
matchStart: 0,
|
|
3098
|
+
options: [],
|
|
3099
|
+
selection: 0,
|
|
3100
|
+
top: 0,
|
|
3101
|
+
value: "",
|
|
3102
|
+
caret: 0,
|
|
3103
|
+
width: "unset"
|
|
3104
|
+
}), u = Le(null);
|
|
3105
|
+
I(() => (window.addEventListener("resize", z), () => {
|
|
3106
|
+
try {
|
|
3107
|
+
window.removeEventListener("resize", z);
|
|
3108
|
+
} catch (g) {
|
|
3109
|
+
console.log('WINDOW "resize" remove listener failed', g);
|
|
3110
|
+
}
|
|
3111
|
+
}), []), I(() => {
|
|
3112
|
+
typeof e.value < "u" && t(e.value), typeof e.defaultValue < "u" && t(e.defaultValue);
|
|
3113
|
+
}, [e.value, e.defaultValue]), I(() => {
|
|
3114
|
+
const { options: g } = e, { caret: h } = o;
|
|
3115
|
+
X(i, h, g);
|
|
3116
|
+
}, [e]);
|
|
3117
|
+
const v = (g, h, y) => {
|
|
3118
|
+
const { trigger: m, matchAny: E, regex: T } = e, b = new RegExp(T);
|
|
3119
|
+
let w = m;
|
|
3120
|
+
Array.isArray(w) || (w = new Array(m)), w.sort();
|
|
3121
|
+
const _ = {};
|
|
3122
|
+
Array.isArray(y) && w.forEach((W) => {
|
|
3123
|
+
_[W] = y;
|
|
3124
|
+
});
|
|
3125
|
+
const P = C(w, b);
|
|
3126
|
+
let H = {};
|
|
3127
|
+
for (let W = 0; W < P.length; W++) {
|
|
3128
|
+
const { triggerStr: M, triggerMatch: x, triggerLength: B } = P[W];
|
|
3129
|
+
for (let G = h - 1; G >= 0; --G) {
|
|
3130
|
+
const ne = g.substring(G, h).match(b);
|
|
3131
|
+
let ee = -1;
|
|
3132
|
+
if (B > 0) {
|
|
3133
|
+
const se = x ? G : G - B + 1;
|
|
3134
|
+
if (se < 0 || (S(M, g, se) && (ee = se + B), !ne && ee < 0))
|
|
3135
|
+
break;
|
|
3136
|
+
} else {
|
|
3137
|
+
if (ne && G > 0)
|
|
3138
|
+
continue;
|
|
3139
|
+
if (ee = G === 0 && ne ? 0 : G + 1, h - ee === 0)
|
|
3140
|
+
break;
|
|
3141
|
+
}
|
|
3142
|
+
if (ee >= 0) {
|
|
3143
|
+
const se = _[M];
|
|
3144
|
+
if (!Array.isArray(se))
|
|
3145
|
+
continue;
|
|
3146
|
+
const _e = g.substring(ee, h), Gt = se.filter(($t) => {
|
|
3147
|
+
const nt = $t.toLowerCase().indexOf(_e.toLowerCase());
|
|
3148
|
+
return nt !== -1 && (E || nt === 0);
|
|
3149
|
+
}), Vt = M, zt = _e.length;
|
|
3150
|
+
H = {
|
|
3151
|
+
...H,
|
|
3152
|
+
trigger: Vt,
|
|
3153
|
+
matchStart: ee,
|
|
3154
|
+
matchLength: zt,
|
|
3155
|
+
options: Gt
|
|
3156
|
+
};
|
|
3157
|
+
}
|
|
3158
|
+
}
|
|
3159
|
+
}
|
|
3160
|
+
return H;
|
|
3161
|
+
}, C = (g, h) => g.map((m) => ({
|
|
3162
|
+
triggerStr: m,
|
|
3163
|
+
triggerMatch: m.match(h),
|
|
3164
|
+
triggerLength: m.length
|
|
3165
|
+
})), S = (g, h, y) => !g || !g.length || h.substr(y, g.length) === g, A = (g) => {
|
|
3166
|
+
const { onChange: h, options: y, spaceRemovers: m, spacer: E, value: T } = e, b = i, w = g.target.value, _ = pn(L(g.target)).end;
|
|
3167
|
+
if (w.length || F({
|
|
3168
|
+
...o,
|
|
3169
|
+
helperVisible: !1
|
|
3170
|
+
}), t(w), F({
|
|
3171
|
+
...o,
|
|
3172
|
+
caret: _,
|
|
3173
|
+
value: g.target.value
|
|
3174
|
+
}), !w.length || !_)
|
|
3175
|
+
return h(g.target.value);
|
|
3176
|
+
if (n && m.length && w.length > 2 && E.length) {
|
|
3177
|
+
for (let P = 0; P < Math.max(b.length, w.length); ++P)
|
|
3178
|
+
if (b[P] !== w[P]) {
|
|
3179
|
+
if (P >= 2 && w[P - 1] === E && m.indexOf(w[P - 2]) === -1 && m.indexOf(w[P]) !== -1 && !Ke(v(w.substring(0, P - 2), _ - 3, y))) {
|
|
3180
|
+
const H = `${w.slice(0, P - 1)}${w.slice(
|
|
3181
|
+
P,
|
|
3182
|
+
P + 1
|
|
3183
|
+
)}${w.slice(P - 1, P)}${w.slice(P + 1)}`;
|
|
3184
|
+
return Y(P + 1), u.current !== null && (u.current.value = H), T || F({
|
|
3185
|
+
...o,
|
|
3186
|
+
value: H
|
|
3187
|
+
}), h(H);
|
|
3188
|
+
}
|
|
3189
|
+
break;
|
|
3190
|
+
}
|
|
3191
|
+
a(!1);
|
|
3192
|
+
}
|
|
3193
|
+
return X(w, _, y), h(g.target.value);
|
|
3194
|
+
}, L = (g) => {
|
|
3195
|
+
if (g !== void 0)
|
|
3196
|
+
if (g.children.length > 0) {
|
|
3197
|
+
const h = g.getElementsByTagName("textarea");
|
|
3198
|
+
if (h.length > 0)
|
|
3199
|
+
return h[0];
|
|
3200
|
+
const y = g.getElementsByTagName("input");
|
|
3201
|
+
if (y.length > 0)
|
|
3202
|
+
return y[0];
|
|
3203
|
+
} else
|
|
3204
|
+
return g;
|
|
3205
|
+
}, R = (g) => {
|
|
3206
|
+
const { helperVisible: h, options: y, selection: m } = o, { onKeyDown: E, passThroughEnter: T } = e;
|
|
3207
|
+
if (h)
|
|
3208
|
+
switch (g.keyCode) {
|
|
3209
|
+
case Nr:
|
|
3210
|
+
g.preventDefault(), U();
|
|
3211
|
+
break;
|
|
3212
|
+
case Or:
|
|
3213
|
+
g.preventDefault(), F({
|
|
3214
|
+
...o,
|
|
3215
|
+
selection: (y.length + m - 1) % y.length
|
|
3216
|
+
});
|
|
3217
|
+
break;
|
|
3218
|
+
case Dr:
|
|
3219
|
+
g.preventDefault(), F({
|
|
3220
|
+
...o,
|
|
3221
|
+
selection: (m + 1) % y.length
|
|
3222
|
+
});
|
|
3223
|
+
break;
|
|
3224
|
+
case Br:
|
|
3225
|
+
case Rr:
|
|
3226
|
+
T || g.preventDefault(), K(m);
|
|
3227
|
+
break;
|
|
3228
|
+
case Fr:
|
|
3229
|
+
K(m);
|
|
3230
|
+
break;
|
|
3231
|
+
default:
|
|
3232
|
+
E(g);
|
|
3233
|
+
break;
|
|
3234
|
+
}
|
|
3235
|
+
else
|
|
3236
|
+
E(g);
|
|
3237
|
+
}, z = () => {
|
|
3238
|
+
F({
|
|
3239
|
+
...o,
|
|
3240
|
+
helperVisible: !1
|
|
3241
|
+
});
|
|
3242
|
+
}, K = (g) => {
|
|
3243
|
+
const { spacer: h, onSelect: y, changeOnSelect: m } = e, { matchStart: E, matchLength: T, options: b, trigger: w } = o, _ = b[g], P = i, H = P.substring(0, E - w.length), W = P.substring(E + T), M = { target: u.current }, x = m(w, _);
|
|
3244
|
+
M.target !== null && (M.target.value = `${H}${x}${h}${W}`), A(M), M.target !== null && y(M.target.value), U(), Y(H.length + x.length + 1), a(!0);
|
|
3245
|
+
}, Y = (g) => {
|
|
3246
|
+
F({
|
|
3247
|
+
...o,
|
|
3248
|
+
caret: g
|
|
3249
|
+
});
|
|
3250
|
+
const h = L(u.current);
|
|
3251
|
+
mn(h, g);
|
|
3252
|
+
}, F = (g) => {
|
|
3253
|
+
setTimeout(() => {
|
|
3254
|
+
d({
|
|
3255
|
+
...g
|
|
3256
|
+
});
|
|
3257
|
+
}, 0);
|
|
3258
|
+
}, X = (g, h, y) => {
|
|
3259
|
+
const m = u.current;
|
|
3260
|
+
if (u.current === null)
|
|
3261
|
+
return;
|
|
3262
|
+
const E = L(m);
|
|
3263
|
+
if (E === void 0)
|
|
3264
|
+
return;
|
|
3265
|
+
const T = m.getBoundingClientRect(), b = v(g, h, y);
|
|
3266
|
+
if (Object.keys(b).length > 0 && E !== null) {
|
|
3267
|
+
const w = hn(E, h), _ = E.getBoundingClientRect(), {
|
|
3268
|
+
minChars: P,
|
|
3269
|
+
onRequestOptions: H,
|
|
3270
|
+
requestOnlyIfNoOptions: W,
|
|
3271
|
+
mode: M
|
|
3272
|
+
} = e;
|
|
3273
|
+
let x, B, G, pe = "unset";
|
|
3274
|
+
M === "assist" ? (x = m === E ? w.top + E.offsetTop : w.top + T.top, B = Math.min(
|
|
3275
|
+
w.left + E.offsetLeft - Hr,
|
|
3276
|
+
E.offsetLeft + _.width - Gr
|
|
3277
|
+
)) : (x = T.top + m.offsetHeight, B = m.offsetLeft, G = m.offsetLeft - m.offsetWidth, pe = `${T.width}px`), b.matchLength >= P && (b.options.length > 1 || b.options.length === 1 && b.options[0].length !== b.matchLength) ? F({
|
|
3278
|
+
...o,
|
|
3279
|
+
value: g,
|
|
3280
|
+
helperVisible: !0,
|
|
3281
|
+
top: x,
|
|
3282
|
+
left: B,
|
|
3283
|
+
right: G,
|
|
3284
|
+
width: pe,
|
|
3285
|
+
...b
|
|
3286
|
+
}) : ((!W || !b.options.length) && H(g.substr(b.matchStart, b.matchLength)), U());
|
|
3287
|
+
} else
|
|
3288
|
+
U();
|
|
3289
|
+
}, U = () => {
|
|
3290
|
+
setTimeout(() => {
|
|
3291
|
+
F({
|
|
3292
|
+
...o,
|
|
3293
|
+
helperVisible: !1,
|
|
3294
|
+
selection: 0
|
|
3295
|
+
});
|
|
3296
|
+
}, 100);
|
|
3297
|
+
}, V = () => {
|
|
3298
|
+
const {
|
|
3299
|
+
helperVisible: g,
|
|
3300
|
+
left: h,
|
|
3301
|
+
right: y,
|
|
3302
|
+
matchStart: m,
|
|
3303
|
+
matchLength: E,
|
|
3304
|
+
options: T,
|
|
3305
|
+
selection: b,
|
|
3306
|
+
top: w,
|
|
3307
|
+
value: _,
|
|
3308
|
+
width: P
|
|
3309
|
+
} = o;
|
|
3310
|
+
if (!g)
|
|
3311
|
+
return null;
|
|
3312
|
+
const { maxOptions: H, offsetX: W, offsetY: M, direction: x } = e;
|
|
3313
|
+
if (T.length === 0)
|
|
3314
|
+
return null;
|
|
3315
|
+
if (b >= T.length)
|
|
3316
|
+
return F({
|
|
3317
|
+
...o,
|
|
3318
|
+
selection: 0
|
|
3319
|
+
}), null;
|
|
3320
|
+
const B = H === 0 ? T.length : H, G = T.slice(0, B).map((ne, ee) => {
|
|
3321
|
+
const se = ne.toLowerCase().indexOf(_.substr(m, E).toLowerCase());
|
|
3322
|
+
return /* @__PURE__ */ D(
|
|
3323
|
+
"li",
|
|
3324
|
+
{
|
|
3325
|
+
className: ee === b ? "active" : void 0,
|
|
3326
|
+
onClick: () => {
|
|
3327
|
+
K(ee);
|
|
3328
|
+
},
|
|
3329
|
+
onMouseEnter: () => {
|
|
3330
|
+
F({
|
|
3331
|
+
...o,
|
|
3332
|
+
selection: ee
|
|
3333
|
+
});
|
|
3334
|
+
},
|
|
3335
|
+
children: [
|
|
3336
|
+
ne.slice(0, se),
|
|
3337
|
+
/* @__PURE__ */ l("strong", { children: ne.substr(se, E) }),
|
|
3338
|
+
ne.slice(se + E)
|
|
3339
|
+
]
|
|
3340
|
+
},
|
|
3341
|
+
ne
|
|
3342
|
+
);
|
|
3343
|
+
}), pe = x === "ltr" ? { left: h + W } : { right: y + W };
|
|
3344
|
+
return /* @__PURE__ */ l(
|
|
3345
|
+
"ul",
|
|
3346
|
+
{
|
|
3347
|
+
className: "react-autocomplete-input",
|
|
3348
|
+
style: { ...pe, top: w + M, width: P },
|
|
3349
|
+
children: G
|
|
3350
|
+
}
|
|
3351
|
+
);
|
|
3352
|
+
}, {
|
|
3353
|
+
Component: j,
|
|
3354
|
+
ComponentProps: O,
|
|
3355
|
+
defaultValue: $,
|
|
3356
|
+
disabled: q,
|
|
3357
|
+
onBlur: r,
|
|
3358
|
+
value: s,
|
|
3359
|
+
...f
|
|
3360
|
+
} = e, c = Object.assign({}, f);
|
|
3361
|
+
return Object.keys(e).forEach((g) => {
|
|
3362
|
+
delete c[g];
|
|
3363
|
+
}), /* @__PURE__ */ D(oe, { children: [
|
|
3364
|
+
ve.cloneElement(j, {
|
|
3365
|
+
disabled: q,
|
|
3366
|
+
onBlur: r,
|
|
3367
|
+
onChange: A,
|
|
3368
|
+
onKeyDown: R,
|
|
3369
|
+
ref: u,
|
|
3370
|
+
value: i,
|
|
3371
|
+
...c,
|
|
3372
|
+
...O
|
|
3373
|
+
}),
|
|
3374
|
+
V()
|
|
3375
|
+
] });
|
|
3376
|
+
}, zr = {
|
|
3377
|
+
Component: /* @__PURE__ */ l("textarea", {}),
|
|
3378
|
+
ComponentProps: {},
|
|
3379
|
+
defaultValue: void 0,
|
|
3380
|
+
disabled: !1,
|
|
3381
|
+
maxOptions: 6,
|
|
3382
|
+
onBlur: (e) => {
|
|
3383
|
+
},
|
|
3384
|
+
onChange: (e) => {
|
|
3385
|
+
},
|
|
3386
|
+
onKeyDown: (e) => {
|
|
3387
|
+
},
|
|
3388
|
+
onRequestOptions: (e) => {
|
|
3389
|
+
},
|
|
3390
|
+
onSelect: (e) => {
|
|
3391
|
+
},
|
|
3392
|
+
changeOnSelect: (e, i) => `${e}${i}`,
|
|
3393
|
+
options: [],
|
|
3394
|
+
regex: "^[A-Za-z0-9\\-_]+$",
|
|
3395
|
+
matchAny: !1,
|
|
3396
|
+
minChars: 0,
|
|
3397
|
+
requestOnlyIfNoOptions: !0,
|
|
3398
|
+
spaceRemovers: [",", ".", "!", "?"],
|
|
3399
|
+
spacer: " ",
|
|
3400
|
+
trigger: "@",
|
|
3401
|
+
offsetX: 0,
|
|
3402
|
+
offsetY: 0,
|
|
3403
|
+
value: void 0,
|
|
3404
|
+
passThroughEnter: !1,
|
|
3405
|
+
mode: "assist",
|
|
3406
|
+
direction: "ltr"
|
|
3407
|
+
}, us = (e) => {
|
|
3408
|
+
let i = {
|
|
3409
|
+
...zr,
|
|
3410
|
+
...e
|
|
3411
|
+
};
|
|
3412
|
+
return e.mode === "autocomplete" && (i = {
|
|
3413
|
+
...i,
|
|
3414
|
+
trigger: "",
|
|
3415
|
+
regex: ".",
|
|
3416
|
+
spacer: ""
|
|
3417
|
+
}), /* @__PURE__ */ l(Vr, { ...i });
|
|
3418
|
+
}, it = {
|
|
3419
|
+
formatFileModDate: (e, i) => {
|
|
3420
|
+
const t = At.getModDate(i);
|
|
3421
|
+
return t ? e.formatDate(t, {
|
|
3422
|
+
dateStyle: "short",
|
|
3423
|
+
timeStyle: "short"
|
|
3424
|
+
}) : null;
|
|
3425
|
+
},
|
|
3426
|
+
formatFileSize: (e, i) => {
|
|
3427
|
+
if (!i || typeof i.size != "number")
|
|
3428
|
+
return null;
|
|
3429
|
+
const t = i.size, n = vn(t, {
|
|
3430
|
+
bits: !1,
|
|
3431
|
+
output: "object"
|
|
3432
|
+
});
|
|
3433
|
+
return n.symbol === "B" ? `${Math.round(n.value / 10) / 100} KB` : n.symbol === "KB" ? `${Math.round(n.value)} ${n.symbol}` : `${n.value} ${n.symbol.toUpperCase()}`;
|
|
3434
|
+
}
|
|
3435
|
+
}, $r = {
|
|
3436
|
+
locale: ce.EN,
|
|
3437
|
+
formatters: { ...it }
|
|
3438
|
+
}, Ur = {
|
|
3439
|
+
locale: ce.RU,
|
|
3440
|
+
formatters: { ...it },
|
|
3441
|
+
messages: {
|
|
3442
|
+
"chonky.toolbar.searchPlaceholder": "Поиск",
|
|
3443
|
+
"chonky.toolbar.visibleFileCount": `{fileCount, plural,
|
|
3444
|
+
one {# файл}
|
|
3445
|
+
few {# файла}
|
|
3446
|
+
other {# файлов}
|
|
3447
|
+
}`,
|
|
3448
|
+
"chonky.toolbar.selectedFileCount": `{fileCount, plural,
|
|
3449
|
+
=0 {}
|
|
3450
|
+
one {# выделен}
|
|
3451
|
+
other {# выделено}
|
|
3452
|
+
}`,
|
|
3453
|
+
"chonky.toolbar.hiddenFileCount": `{fileCount, plural,
|
|
3454
|
+
=0 {}
|
|
3455
|
+
one {# скрыт}
|
|
3456
|
+
other {# скрыто}
|
|
3457
|
+
}`,
|
|
3458
|
+
"chonky.fileList.nothingToShow": "Здесь пусто!",
|
|
3459
|
+
"chonky.contextMenu.browserMenuShortcut": "Меню браузера: {shortcut}",
|
|
3460
|
+
// Actions
|
|
3461
|
+
["chonky.actionGroups.Actions"]: "Действия",
|
|
3462
|
+
["chonky.actionGroups.Options"]: "Опции",
|
|
3463
|
+
[`chonky.actions.${N.OpenParentFolder.id}.button.name`]: "Открыть родительскую папку",
|
|
3464
|
+
[`chonky.actions.${N.CreateFolder.id}.button.name`]: "Новая папка",
|
|
3465
|
+
[`chonky.actions.${N.CreateFolder.id}.button.tooltip`]: "Создать новую папку",
|
|
3466
|
+
[`chonky.actions.${N.DeleteFiles.id}.button.name`]: "Удалить файлы",
|
|
3467
|
+
[`chonky.actions.${N.OpenSelection.id}.button.name`]: "Открыть выделение",
|
|
3468
|
+
[`chonky.actions.${N.SelectAllFiles.id}.button.name`]: "Выделить все",
|
|
3469
|
+
[`chonky.actions.${N.ClearSelection.id}.button.name`]: "Сбросить выделение",
|
|
3470
|
+
[`chonky.actions.${N.EnableListView.id}.button.name`]: "Показать список",
|
|
3471
|
+
[`chonky.actions.${N.EnableGridView.id}.button.name`]: "Показать иконки",
|
|
3472
|
+
[`chonky.actions.${N.SortFilesByName.id}.button.name`]: "Сорт. по имени",
|
|
3473
|
+
[`chonky.actions.${N.SortFilesBySize.id}.button.name`]: "Сорт. по размеру",
|
|
3474
|
+
[`chonky.actions.${N.SortFilesByDate.id}.button.name`]: "Сорт. по дате",
|
|
3475
|
+
[`chonky.actions.${N.ToggleHiddenFiles.id}.button.name`]: "Скрытые файлы",
|
|
3476
|
+
[`chonky.actions.${N.ToggleShowFoldersFirst.id}.button.name`]: "Папки в начале"
|
|
3477
|
+
}
|
|
3478
|
+
}, Wr = {
|
|
3479
|
+
locale: ce.HE,
|
|
3480
|
+
formatters: { ...it },
|
|
3481
|
+
messages: {
|
|
3482
|
+
"chonky.toolbar.searchPlaceholder": "חיפוש",
|
|
3483
|
+
"chonky.toolbar.visibleFileCount": `{fileCount, plural,
|
|
3484
|
+
one {פריט #}
|
|
3485
|
+
other {# פריטים}
|
|
3486
|
+
}`,
|
|
3487
|
+
"chonky.toolbar.selectedFileCount": `{fileCount, plural,
|
|
3488
|
+
=0 {}
|
|
3489
|
+
one {# נבחר}
|
|
3490
|
+
other {# נבחרו}
|
|
3491
|
+
}`,
|
|
3492
|
+
"chonky.toolbar.hiddenFileCount": `{fileCount, plural,
|
|
3493
|
+
=0 {}
|
|
3494
|
+
one {# נסתר}
|
|
3495
|
+
other {# נסתרים}
|
|
3496
|
+
}`,
|
|
3497
|
+
"chonky.fileList.nothingToShow": "ריק",
|
|
3498
|
+
"chonky.contextMenu.browserMenuShortcut": "תפריט דפדפן: {shortcut}",
|
|
3499
|
+
// Actions
|
|
3500
|
+
["chonky.actionGroups.Actions"]: "פעולות",
|
|
3501
|
+
["chonky.actionGroups.Options"]: "אפשרויות",
|
|
3502
|
+
[`chonky.actions.${N.OpenParentFolder.id}.button.name`]: "פתח סיפריית אב",
|
|
3503
|
+
[`chonky.actions.${N.CreateFolder.id}.button.name`]: "סיפרייה חדשה",
|
|
3504
|
+
[`chonky.actions.${N.CreateFolder.id}.button.tooltip`]: "צור סיפרייה חדשה",
|
|
3505
|
+
[`chonky.actions.${N.DeleteFiles.id}.button.name`]: "מחק",
|
|
3506
|
+
[`chonky.actions.${N.OpenSelection.id}.button.name`]: "פתח את הבחירה",
|
|
3507
|
+
[`chonky.actions.${N.SelectAllFiles.id}.button.name`]: "בחר הכל",
|
|
3508
|
+
[`chonky.actions.${N.ClearSelection.id}.button.name`]: "אפס את הבחירה",
|
|
3509
|
+
[`chonky.actions.${N.EnableListView.id}.button.name`]: "תצוגת רשימה",
|
|
3510
|
+
[`chonky.actions.${N.EnableGridView.id}.button.name`]: "תצוגת גריד",
|
|
3511
|
+
[`chonky.actions.${N.SortFilesByName.id}.button.name`]: "מיון לפי שם",
|
|
3512
|
+
[`chonky.actions.${N.SortFilesBySize.id}.button.name`]: "מיון לפי גודל",
|
|
3513
|
+
[`chonky.actions.${N.SortFilesByDate.id}.button.name`]: "מיון לפי תאריך",
|
|
3514
|
+
[`chonky.actions.${N.ToggleHiddenFiles.id}.button.name`]: "קבצים נסתרים",
|
|
3515
|
+
[`chonky.actions.${N.ToggleShowFoldersFirst.id}.button.name`]: "הצגת תיקיות בראש הרשימה"
|
|
3516
|
+
}
|
|
3517
|
+
}, jr = {
|
|
3518
|
+
[ce.EN]: $r,
|
|
3519
|
+
[ce.RU]: Ur,
|
|
3520
|
+
[ce.HE]: Wr
|
|
3521
|
+
};
|
|
3522
|
+
class hs extends At {
|
|
3523
|
+
}
|
|
3524
|
+
const ps = N, Kr = {
|
|
3525
|
+
listView: N.EnableListView.id,
|
|
3526
|
+
gridView: N.EnableGridView.id
|
|
3527
|
+
};
|
|
3528
|
+
gn({ iconComponent: yn });
|
|
3529
|
+
const ms = ve.memo(
|
|
3530
|
+
ve.forwardRef(
|
|
3531
|
+
({
|
|
3532
|
+
theme: e,
|
|
3533
|
+
styles: i = { height: "100%", minWidth: "600px" },
|
|
3534
|
+
defaultView: t = Kr.listView,
|
|
3535
|
+
readOnlyMode: n = !1,
|
|
3536
|
+
locale: a,
|
|
3537
|
+
files: o,
|
|
3538
|
+
folderChain: d,
|
|
3539
|
+
onFileAction: u,
|
|
3540
|
+
...v
|
|
3541
|
+
}, C) => {
|
|
3542
|
+
const S = ge(
|
|
3543
|
+
($) => null,
|
|
3544
|
+
// file.thumbnailUrl ? `https://chonky.io${file.thumbnailUrl}` : null,
|
|
3545
|
+
[]
|
|
3546
|
+
);
|
|
3547
|
+
Me({
|
|
3548
|
+
"@global": {
|
|
3549
|
+
".chonky-dropdownList": {
|
|
3550
|
+
backgroundColor: `${e == null ? void 0 : e.surface} !important`
|
|
3551
|
+
},
|
|
3552
|
+
'li[class*="chonky-activeButton"]': {
|
|
3553
|
+
color: `${e == null ? void 0 : e.primary} !important`
|
|
3554
|
+
}
|
|
3555
|
+
}
|
|
3556
|
+
})();
|
|
3557
|
+
const A = ($) => $.replace(/([A-Z])/g, (q) => "-" + q.toLowerCase()), L = ft(() => e !== void 0 ? Object.keys(e).reduce(
|
|
3558
|
+
(q, r) => {
|
|
3559
|
+
const s = e[r];
|
|
3560
|
+
return r = r.startsWith("--") ? r : `--fp-theme-${A(r)}`, q[r] = s, q;
|
|
3561
|
+
},
|
|
3562
|
+
{}
|
|
3563
|
+
) : {}, [e]), [R, z] = k(!1), [K, Y] = k(), [F, X] = k(
|
|
3564
|
+
!1
|
|
3565
|
+
), [U, V] = k(), [j, O] = k();
|
|
3566
|
+
return I(() => {
|
|
3567
|
+
e && z(!0), Y(t), n ? X(!0) : V([
|
|
3568
|
+
N.CreateFolder,
|
|
3569
|
+
N.DeleteFiles
|
|
3570
|
+
]), a !== void 0 && O(jr[a]);
|
|
3571
|
+
}, [e, t, n, a]), /* @__PURE__ */ l(
|
|
3572
|
+
ae,
|
|
3573
|
+
{
|
|
3574
|
+
style: {
|
|
3575
|
+
...i,
|
|
3576
|
+
...L
|
|
3577
|
+
},
|
|
3578
|
+
children: /* @__PURE__ */ l(
|
|
3579
|
+
fn,
|
|
3580
|
+
{
|
|
3581
|
+
ref: C,
|
|
3582
|
+
files: o ?? [],
|
|
3583
|
+
folderChain: d,
|
|
3584
|
+
onFileAction: ($) => {
|
|
3585
|
+
typeof u == "function" && u($);
|
|
3586
|
+
},
|
|
3587
|
+
thumbnailGenerator: S,
|
|
3588
|
+
defaultFileViewActionId: K,
|
|
3589
|
+
disableDragAndDrop: F,
|
|
3590
|
+
fileActions: U,
|
|
3591
|
+
darkMode: R,
|
|
3592
|
+
i18n: j,
|
|
3593
|
+
...v
|
|
3594
|
+
}
|
|
3595
|
+
)
|
|
3596
|
+
}
|
|
3597
|
+
);
|
|
3598
|
+
}
|
|
3599
|
+
)
|
|
3600
|
+
);
|
|
3601
|
+
export {
|
|
3602
|
+
us as Autocomplete,
|
|
3603
|
+
qe as BboxCorner,
|
|
3604
|
+
ae as Box,
|
|
3605
|
+
Xe as COORDINATES_MERCATOR_FRACTION_DIGITS,
|
|
3606
|
+
Ye as COORDINATES_WGS_FRACTION_DIGITS,
|
|
3607
|
+
Vo as Cesium3DTileset,
|
|
3608
|
+
is as CesiumBoundingSphere,
|
|
3609
|
+
Qo as CesiumCartesian2,
|
|
3610
|
+
es as CesiumCartesian3,
|
|
3611
|
+
ts as CesiumCartographic,
|
|
3612
|
+
ls as CesiumCesiumTerrainProvider,
|
|
3613
|
+
qo as CesiumColor,
|
|
3614
|
+
Jo as CesiumConstantPositionProperty,
|
|
3615
|
+
Zo as CesiumConstantProperty,
|
|
3616
|
+
Lr as CesiumCustomDataSource,
|
|
3617
|
+
Yo as CesiumDrawingsDataSource,
|
|
3618
|
+
ns as CesiumEllipsoid,
|
|
3619
|
+
as as CesiumEllipsoidTerrainProvider,
|
|
3620
|
+
br as CesiumEntity,
|
|
3621
|
+
Ko as CesiumEntityDescription,
|
|
3622
|
+
Tr as CesiumEntityStaticDescription,
|
|
3623
|
+
rs as CesiumGeographicTilingScheme,
|
|
3624
|
+
zo as CesiumGeojsonLayer,
|
|
3625
|
+
Fe as CesiumImageryLayer,
|
|
3626
|
+
ds as CesiumLabelStyle,
|
|
3627
|
+
Go as CesiumMap,
|
|
3628
|
+
Es as CesiumMath,
|
|
3629
|
+
jo as CesiumOSMLayer,
|
|
3630
|
+
_r as CesiumPolygonGraphics,
|
|
3631
|
+
Xo as CesiumPolylineDashMaterialProperty,
|
|
3632
|
+
os as CesiumRectangle,
|
|
3633
|
+
Sr as CesiumRectangleGraphics,
|
|
3634
|
+
ss as CesiumResource,
|
|
3635
|
+
ie as CesiumSceneMode,
|
|
3636
|
+
cs as CesiumVerticalOrigin,
|
|
3637
|
+
Ho as CesiumViewer,
|
|
3638
|
+
$o as CesiumWMSLayer,
|
|
3639
|
+
Uo as CesiumWMTSLayer,
|
|
3640
|
+
Wo as CesiumXYZLayer,
|
|
3641
|
+
No as CssBaseline,
|
|
3642
|
+
Do as DateTimePicker,
|
|
3643
|
+
Tn as DateTimeRangePicker,
|
|
3644
|
+
Oo as DateTimeRangePickerFormControl,
|
|
3645
|
+
re as DrawType,
|
|
3646
|
+
hs as FileHelper,
|
|
3647
|
+
ms as FilePicker,
|
|
3648
|
+
ps as FilePickerActions,
|
|
3649
|
+
Kr as FilePickerView,
|
|
3650
|
+
Ro as MapFilterContainer,
|
|
3651
|
+
_n as Popover,
|
|
3652
|
+
ue as Proj,
|
|
3653
|
+
Fo as ScopedCssBaseline,
|
|
3654
|
+
Bo as SmartTable,
|
|
3655
|
+
ce as SupportedLocales,
|
|
3656
|
+
Cs as cesiumSampleTerrainMostDetailed,
|
|
3657
|
+
it as defaultFormatters,
|
|
3658
|
+
En as mapMcToMuiTheme,
|
|
3659
|
+
he as useCesiumMap,
|
|
3660
|
+
xt as useMappedMuiTheme,
|
|
3661
|
+
ys as useMediaQuery
|
|
3662
|
+
};
|