@vcmap/ui 5.0.0-rc.6
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/LICENSE.md +21 -0
- package/README.md +132 -0
- package/build/.eslintrc +6 -0
- package/build/build.js +165 -0
- package/build/buildCesium.js +19 -0
- package/build/buildHelpers.js +213 -0
- package/build/buildPreview.js +23 -0
- package/build/commonViteConfig.js +39 -0
- package/build/determineHost.js +46 -0
- package/build/generateOLLib.js +196 -0
- package/build/getPluginProxies.js +29 -0
- package/build/info/api-plugin.js +11 -0
- package/build/info/conf.json +21 -0
- package/build/info/define-plugin.js +31 -0
- package/build/info/package.json +3 -0
- package/build/info/publish.js +190 -0
- package/build/info/virtual-plugin.js +15 -0
- package/build/staging/Dockerfile +2 -0
- package/config/aerowest.config.json +378 -0
- package/config/base.config.json +1073 -0
- package/config/berlin.config.json +529 -0
- package/config/dev.config.json +44 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_0.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_1.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_10.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_11.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_12.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_13.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_14.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_15.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_16.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_17.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_18.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_19.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_2.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_20.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_21.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_22.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_23.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_24.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_25.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_26.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_27.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_3.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_4.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_5.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_6.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_7.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_8.json +1 -0
- package/dist/assets/cesium/Assets/IAU2006_XYS/IAU2006_XYS_9.json +1 -0
- package/dist/assets/cesium/Assets/Images/bing_maps_credit.png +0 -0
- package/dist/assets/cesium/Assets/Images/cesium_credit.png +0 -0
- package/dist/assets/cesium/Assets/Images/google_earth_credit.png +0 -0
- package/dist/assets/cesium/Assets/Images/ion-credit.png +0 -0
- package/dist/assets/cesium/Assets/Textures/LensFlare/DirtMask.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/LensFlare/StarBurst.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/0/0/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/0/1/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/0/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/0/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/1/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/1/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/2/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/2/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/3/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/1/3/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/0/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/0/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/0/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/0/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/1/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/1/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/1/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/1/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/2/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/2/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/2/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/2/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/3/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/3/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/3/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/3/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/4/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/4/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/4/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/4/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/5/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/5/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/5/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/5/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/6/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/6/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/6/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/6/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/7/0.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/7/1.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/7/2.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/2/7/3.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/NaturalEarthII/tilemapresource.xml +14 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_mx.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_my.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_mz.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_px.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_py.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/SkyBox/tycho2t3_80_pz.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/airfield.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/airport.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/alcohol-shop.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/america-football.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/art-gallery.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/bakery.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/bank.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/bar.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/baseball.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/basketball.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/beer.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/bicycle.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/building.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/bus.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cafe.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/camera.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/campsite.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/car.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cemetery.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cesium.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/chemist.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cinema.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/circle-stroked.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/circle.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/city.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/clothing-store.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/college.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/commercial.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cricket.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/cross.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/dam.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/danger.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/disability.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/dog-park.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/embassy.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/emergency-telephone.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/entrance.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/farm.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/fast-food.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/ferry.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/fire-station.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/fuel.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/garden.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/gift.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/golf.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/grocery.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/hairdresser.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/harbor.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/heart.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/heliport.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/hospital.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/ice-cream.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/industrial.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/land-use.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/laundry.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/library.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/lighthouse.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/lodging.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/logging.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/london-underground.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/marker-stroked.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/marker.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/minefield.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/mobilephone.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/monument.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/museum.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/music.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/oil-well.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/park.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/park2.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/parking-garage.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/parking.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/pharmacy.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/pitch.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/place-of-worship.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/playground.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/police.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/polling-place.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/post.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/prison.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rail-above.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rail-light.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rail-metro.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rail-underground.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rail.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/religious-christian.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/religious-jewish.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/religious-muslim.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/restaurant.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/roadblock.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/rocket.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/school.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/scooter.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/shop.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/skiing.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/slaughterhouse.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/soccer.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/square-stroked.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/square.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/star-stroked.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/star.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/suitcase.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/swimming.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/telephone.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/tennis.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/theatre.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/toilets.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/town-hall.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/town.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/triangle-stroked.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/triangle.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/village.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/warehouse.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/waste-basket.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/water.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/wetland.png +0 -0
- package/dist/assets/cesium/Assets/Textures/maki/zoo.png +0 -0
- package/dist/assets/cesium/Assets/Textures/moonSmall.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/pin.svg +1 -0
- package/dist/assets/cesium/Assets/Textures/waterNormals.jpg +0 -0
- package/dist/assets/cesium/Assets/Textures/waterNormalsSmall.jpg +0 -0
- package/dist/assets/cesium/Assets/approximateTerrainHeights.json +1 -0
- package/dist/assets/cesium/Workers/ArcType-fc72c06c.js +1 -0
- package/dist/assets/cesium/Workers/AttributeCompression-27507afe.js +1 -0
- package/dist/assets/cesium/Workers/AxisAlignedBoundingBox-7565c1e8.js +1 -0
- package/dist/assets/cesium/Workers/BoundingRectangle-9d707275.js +1 -0
- package/dist/assets/cesium/Workers/BoxGeometry-fb31d3b5.js +1 -0
- package/dist/assets/cesium/Workers/Color-56bb5728.js +1 -0
- package/dist/assets/cesium/Workers/ComponentDatatype-a15c9a19.js +1 -0
- package/dist/assets/cesium/Workers/CoplanarPolygonGeometryLibrary-72143c19.js +1 -0
- package/dist/assets/cesium/Workers/CorridorGeometryLibrary-7bae1712.js +1 -0
- package/dist/assets/cesium/Workers/CylinderGeometry-331891fe.js +1 -0
- package/dist/assets/cesium/Workers/CylinderGeometryLibrary-76cda53e.js +1 -0
- package/dist/assets/cesium/Workers/EllipseGeometry-5e3f67b6.js +1 -0
- package/dist/assets/cesium/Workers/EllipseGeometryLibrary-dbc15162.js +1 -0
- package/dist/assets/cesium/Workers/EllipseOutlineGeometry-21191fce.js +1 -0
- package/dist/assets/cesium/Workers/EllipsoidGeodesic-cc3bace8.js +1 -0
- package/dist/assets/cesium/Workers/EllipsoidGeometry-8bfa24a9.js +1 -0
- package/dist/assets/cesium/Workers/EllipsoidOutlineGeometry-48d9c023.js +1 -0
- package/dist/assets/cesium/Workers/EllipsoidRhumbLine-125a8b72.js +1 -0
- package/dist/assets/cesium/Workers/EllipsoidTangentPlane-678e34e4.js +1 -0
- package/dist/assets/cesium/Workers/EncodedCartesian3-96fdc0ef.js +1 -0
- package/dist/assets/cesium/Workers/FrustumGeometry-9ab86004.js +1 -0
- package/dist/assets/cesium/Workers/GeometryAttribute-3915ea0b.js +1 -0
- package/dist/assets/cesium/Workers/GeometryAttributes-32b29525.js +1 -0
- package/dist/assets/cesium/Workers/GeometryInstance-13e4ff38.js +1 -0
- package/dist/assets/cesium/Workers/GeometryOffsetAttribute-8c5e10db.js +1 -0
- package/dist/assets/cesium/Workers/GeometryPipeline-e0eb4567.js +1 -0
- package/dist/assets/cesium/Workers/IndexDatatype-f1dcdf35.js +1 -0
- package/dist/assets/cesium/Workers/IntersectionTests-ac2459de.js +1 -0
- package/dist/assets/cesium/Workers/Matrix2-37e55508.js +1 -0
- package/dist/assets/cesium/Workers/OrientedBoundingBox-e9c07538.js +1 -0
- package/dist/assets/cesium/Workers/Plane-6ee42cab.js +1 -0
- package/dist/assets/cesium/Workers/PolygonGeometryLibrary-b408c688.js +1 -0
- package/dist/assets/cesium/Workers/PolygonPipeline-7b8e4643.js +1 -0
- package/dist/assets/cesium/Workers/PolylinePipeline-6757400c.js +1 -0
- package/dist/assets/cesium/Workers/PolylineVolumeGeometryLibrary-eb972210.js +1 -0
- package/dist/assets/cesium/Workers/PrimitivePipeline-f244975e.js +1 -0
- package/dist/assets/cesium/Workers/RectangleGeometryLibrary-1bd6152a.js +1 -0
- package/dist/assets/cesium/Workers/RuntimeError-8952249c.js +1 -0
- package/dist/assets/cesium/Workers/TerrainEncoding-5a21a97f.js +1 -0
- package/dist/assets/cesium/Workers/Transforms-eb5c1a84.js +39 -0
- package/dist/assets/cesium/Workers/VertexFormat-a0b706b0.js +1 -0
- package/dist/assets/cesium/Workers/WallGeometryLibrary-a6b6a368.js +1 -0
- package/dist/assets/cesium/Workers/WebGLConstants-508b9636.js +1 -0
- package/dist/assets/cesium/Workers/WebMercatorProjection-2839e524.js +1 -0
- package/dist/assets/cesium/Workers/_commonjsHelpers-3aae1032-26891ab7.js +1 -0
- package/dist/assets/cesium/Workers/_rollup_plugin_ignore_empty_module_placeholder-57d574d0.js +1 -0
- package/dist/assets/cesium/Workers/arrayRemoveDuplicates-dc2f4046.js +1 -0
- package/dist/assets/cesium/Workers/cesiumWorkerBootstrapper.js +6 -0
- package/dist/assets/cesium/Workers/combine-3c023bda.js +1 -0
- package/dist/assets/cesium/Workers/combineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createBoxGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createBoxOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCircleGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCircleOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCoplanarPolygonGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCoplanarPolygonOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCorridorGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCorridorOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCylinderGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createCylinderOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createEllipseGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createEllipseOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createEllipsoidGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createEllipsoidOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createFrustumGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createFrustumOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createGroundPolylineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPlaneGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPlaneOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPolygonGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPolygonOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPolylineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPolylineVolumeGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createPolylineVolumeOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createRectangleGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createRectangleOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createSimplePolylineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createSphereGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createSphereOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createTaskProcessorWorker.js +1 -0
- package/dist/assets/cesium/Workers/createVectorTileClampedPolylines.js +1 -0
- package/dist/assets/cesium/Workers/createVectorTileGeometries.js +1 -0
- package/dist/assets/cesium/Workers/createVectorTilePoints.js +1 -0
- package/dist/assets/cesium/Workers/createVectorTilePolygons.js +1 -0
- package/dist/assets/cesium/Workers/createVectorTilePolylines.js +1 -0
- package/dist/assets/cesium/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +1 -0
- package/dist/assets/cesium/Workers/createVerticesFromHeightmap.js +3 -0
- package/dist/assets/cesium/Workers/createVerticesFromQuantizedTerrainMesh.js +1 -0
- package/dist/assets/cesium/Workers/createWallGeometry.js +1 -0
- package/dist/assets/cesium/Workers/createWallOutlineGeometry.js +1 -0
- package/dist/assets/cesium/Workers/decodeDraco.js +1 -0
- package/dist/assets/cesium/Workers/decodeGoogleEarthEnterprisePacket.js +1 -0
- package/dist/assets/cesium/Workers/defaultValue-81eec7ed.js +1 -0
- package/dist/assets/cesium/Workers/transcodeKTX2.js +1 -0
- package/dist/assets/cesium/Workers/transferTypedArrayTest.js +1 -0
- package/dist/assets/cesium/Workers/upsampleQuantizedTerrainMesh.js +1 -0
- package/dist/assets/cesium.fba8ca.js +9118 -0
- package/dist/assets/cesium.js +1 -0
- package/dist/assets/core.d5ed0f.js +4 -0
- package/dist/assets/core.js +1 -0
- package/dist/assets/index.60dea538.css +1 -0
- package/dist/assets/index.6a83278e.js +1 -0
- package/dist/assets/ol.abea3a.js +318 -0
- package/dist/assets/ol.js +1 -0
- package/dist/assets/ui.ad1ec9.css +1 -0
- package/dist/assets/ui.ad1ec9.js +39 -0
- package/dist/assets/ui.js +1 -0
- package/dist/assets/uicomponents.161461.css +1 -0
- package/dist/assets/uicomponents.161461.js +31 -0
- package/dist/assets/uicomponents.js +1 -0
- package/dist/assets/vue-composition-api.7051d7.js +14 -0
- package/dist/assets/vue-composition-api.js +2 -0
- package/dist/assets/vue.9fd7f6.js +9 -0
- package/dist/assets/vue.js +1 -0
- package/dist/assets/vuetify.33dafc.css +5 -0
- package/dist/assets/vuetify.33dafc.js +48 -0
- package/dist/assets/vuetify.js +2 -0
- package/dist/index.html +26 -0
- package/index.js +18 -0
- package/lib/cesium.js +1 -0
- package/lib/core.js +1 -0
- package/lib/ol.js +1 -0
- package/lib/olLib.js +844 -0
- package/lib/ui.js +1 -0
- package/lib/uicomponents.js +1 -0
- package/lib/vue-composition-api.js +2 -0
- package/lib/vue.js +1 -0
- package/lib/vuetify.js +2 -0
- package/map.config.json +35 -0
- package/package.json +130 -0
- package/plugins/@vcmap/pluginExample/config.json +6 -0
- package/plugins/@vcmap/pluginExample/index.js +193 -0
- package/plugins/@vcmap/pluginExample/package.json +7 -0
- package/plugins/@vcmap/pluginExample/pluginExampleComponent.vue +374 -0
- package/plugins/@vcmap/pluginExample/validation.js +30 -0
- package/plugins/@vcmap/project-selector/ContextsListComponent.vue +62 -0
- package/plugins/@vcmap/project-selector/ProjectSelectorComponent.vue +81 -0
- package/plugins/@vcmap/project-selector/README.md +29 -0
- package/plugins/@vcmap/project-selector/config.json +15 -0
- package/plugins/@vcmap/project-selector/index.js +254 -0
- package/plugins/@vcmap/project-selector/package.json +15 -0
- package/plugins/@vcmap/theme-changer/README.md +21 -0
- package/plugins/@vcmap/theme-changer/ThemeChangerComponent.vue +92 -0
- package/plugins/@vcmap/theme-changer/config.json +69 -0
- package/plugins/@vcmap/theme-changer/index.js +102 -0
- package/plugins/@vcmap/theme-changer/package.json +12 -0
- package/plugins/buttonExamples/ButtonExamples.vue +190 -0
- package/plugins/buttonExamples/index.js +40 -0
- package/plugins/categoryTest/Categories.vue +145 -0
- package/plugins/categoryTest/Category.vue +114 -0
- package/plugins/categoryTest/ItemEditor.vue +13 -0
- package/plugins/categoryTest/index.js +41 -0
- package/plugins/example/index.js +56 -0
- package/plugins/example/mySuperComponent.vue +127 -0
- package/plugins/package.json +5 -0
- package/plugins/test/editor.vue +63 -0
- package/plugins/test/index.js +93 -0
- package/plugins/test/myCustomHeader.vue +19 -0
- package/plugins/test/toolbox-data.js +49 -0
- package/plugins/test/vcsContent.vue +23 -0
- package/plugins/test/windowManagerExample.vue +144 -0
- package/src/actions/actionHelper.js +221 -0
- package/src/actions/stateRefAction.js +50 -0
- package/src/actions/styleSelector.vue +90 -0
- package/src/application/Navbar.vue +89 -0
- package/src/application/VcsApp.vue +147 -0
- package/src/application/VcsMap.vue +57 -0
- package/src/application/empty-cmp.vue +6 -0
- package/src/assets/logo.svg +26 -0
- package/src/contentTree/LayerTree.vue +40 -0
- package/src/contentTree/contentTreeCollection.js +311 -0
- package/src/contentTree/contentTreeItem.js +457 -0
- package/src/contentTree/groupContentTreeItem.js +67 -0
- package/src/contentTree/layerContentTreeItem.js +233 -0
- package/src/contentTree/layerGroupContentTreeItem.js +154 -0
- package/src/contentTree/nodeContentTreeItem.js +37 -0
- package/src/contentTree/obliqueCollectionContentTreeItem.js +155 -0
- package/src/contentTree/subContentTreeItem.js +42 -0
- package/src/contentTree/vcsObjectContentTreeItem.js +98 -0
- package/src/contentTree/viewPointContentTreeItem.js +107 -0
- package/src/init.js +36 -0
- package/src/lang/de.js +60 -0
- package/src/lang/en.js +53 -0
- package/src/manager/buttonManager.js +203 -0
- package/src/manager/toolbox/ToolboxManager.vue +114 -0
- package/src/manager/toolbox/ToolboxMultiSelectButton.vue +96 -0
- package/src/manager/toolbox/ToolboxSingleSelectButton.vue +98 -0
- package/src/manager/toolbox/toolbox-manager.js +203 -0
- package/src/manager/window/WindowComponent.vue +133 -0
- package/src/manager/window/WindowComponentHeader.vue +46 -0
- package/src/manager/window/WindowManager.vue +109 -0
- package/src/manager/window/windowManager.js +437 -0
- package/src/navigation/mapNavCompass.vue +161 -0
- package/src/navigation/mapNavigation.vue +176 -0
- package/src/navigation/obliqueRotation.vue +48 -0
- package/src/navigation/orientationToolsButton.vue +52 -0
- package/src/navigation/tiltSlider.vue +96 -0
- package/src/navigation/vcsCompass.vue +144 -0
- package/src/navigation/vcsZoomButton.vue +27 -0
- package/src/pluginHelper.js +106 -0
- package/src/setup.js +10 -0
- package/src/styles/_theming.scss +15 -0
- package/src/styles/_typography.scss +42 -0
- package/src/styles/main.scss +9 -0
- package/src/styles/utils/_all.scss +12 -0
- package/src/styles/utils/_border.scss +7 -0
- package/src/styles/utils/_cursor.scss +15 -0
- package/src/styles/utils/_display.scss +3 -0
- package/src/styles/utils/_fade-in.scss +8 -0
- package/src/styles/utils/_position.scss +38 -0
- package/src/styles/utils/_size.scss +79 -0
- package/src/styles/utils/_slide-in.scss +26 -0
- package/src/styles/utils/_spacing.scss +11 -0
- package/src/styles/utils/_text.scss +30 -0
- package/src/styles/utils/_transform.scss +11 -0
- package/src/styles/utils/_transition.scss +11 -0
- package/src/styles/utils/_z-index.scss +15 -0
- package/src/vcsUiApp.js +223 -0
- package/src/vuePlugins/i18n.js +20 -0
- package/src/vuePlugins/vuetify.js +54 -0
- package/start.js +3 -0
@@ -0,0 +1,457 @@
|
|
1
|
+
import { ref, reactive, computed } from '@vue/composition-api';
|
2
|
+
import { check, checkMaybe } from '@vcsuite/check';
|
3
|
+
import { parseBoolean, parseNumber } from '@vcsuite/parsers';
|
4
|
+
import { ClassRegistry, VcsEvent } from '@vcmap/core';
|
5
|
+
import { createLinkAction } from '../actions/actionHelper.js';
|
6
|
+
import { createStateRefAction, StateActionState } from '../actions/stateRefAction.js';
|
7
|
+
|
8
|
+
/**
|
9
|
+
* @typedef {Object} ContentTreeItemOptions
|
10
|
+
* @property {string} name
|
11
|
+
* @property {Object<string, string>|string} [title] - may be unset, if set from object properties later on. required otherwise
|
12
|
+
* @property {string|HTMLCanvasElement|HTMLImageElement|undefined} icon - an icon URL or element to display
|
13
|
+
* @property {number} [weight]
|
14
|
+
* @property {string} [infoUrl]
|
15
|
+
* @property {boolean} [initOpen=false]
|
16
|
+
*/
|
17
|
+
|
18
|
+
/**
|
19
|
+
* A readonly rendering interface of a ContentTreeItem.
|
20
|
+
* @typedef {Object} TreeViewItem
|
21
|
+
* @property {string} name
|
22
|
+
* @property {boolean} visible
|
23
|
+
* @property {boolean} clickable
|
24
|
+
* @property {boolean} disabled
|
25
|
+
* @property {StateActionState} state
|
26
|
+
* @property {Object<string, string>|string} title
|
27
|
+
* @property {string|HTMLCanvasElement|HTMLImageElement|undefined} icon
|
28
|
+
* @property {Array<VcsAction>} actions
|
29
|
+
* @property {Array<TreeViewItem>} children
|
30
|
+
* @property {Array<TreeViewItem>} visibleChildren - computed property
|
31
|
+
* @property {function():Promise<void>} clicked
|
32
|
+
*/
|
33
|
+
|
34
|
+
/**
|
35
|
+
* @type {symbol}
|
36
|
+
*/
|
37
|
+
const actionWeightSymbol = Symbol('ActionWeight');
|
38
|
+
|
39
|
+
/**
|
40
|
+
* @type {ClassRegistry<ContentTreeItem>}
|
41
|
+
*/
|
42
|
+
export const contentTreeClassRegistry = new ClassRegistry();
|
43
|
+
|
44
|
+
/**
|
45
|
+
* @class
|
46
|
+
* @abstract
|
47
|
+
*/
|
48
|
+
class ContentTreeItem {
|
49
|
+
/**
|
50
|
+
* @type {string}
|
51
|
+
*/
|
52
|
+
static get className() { return 'ContentTreeItem'; }
|
53
|
+
|
54
|
+
/**
|
55
|
+
* @param {ContentTreeItemOptions} options
|
56
|
+
* @param {VcsUiApp} app
|
57
|
+
*/
|
58
|
+
constructor(options, app) {
|
59
|
+
/**
|
60
|
+
* @protected
|
61
|
+
* @type {VcsUiApp}
|
62
|
+
*/
|
63
|
+
this._app = app;
|
64
|
+
|
65
|
+
/**
|
66
|
+
* @type {import("@vue/composition-api").Ref<Array<VcsAction>>}
|
67
|
+
* @private
|
68
|
+
*/
|
69
|
+
this._actions = ref([]);
|
70
|
+
|
71
|
+
/**
|
72
|
+
* @type {string}
|
73
|
+
* @private
|
74
|
+
*/
|
75
|
+
this._name = options.name; // XXX ensure name is a string here?
|
76
|
+
|
77
|
+
/**
|
78
|
+
* Whether to display this item or not.
|
79
|
+
* @type {import("@vue/composition-api").Ref<boolean>}
|
80
|
+
* @private
|
81
|
+
*/
|
82
|
+
this._visible = ref(true);
|
83
|
+
|
84
|
+
/**
|
85
|
+
* Whether this item reacts to click events, e.g. with visual feedback
|
86
|
+
* @type {import("@vue/composition-api").Ref<boolean>}
|
87
|
+
* @private
|
88
|
+
*/
|
89
|
+
this._clickable = ref(true);
|
90
|
+
|
91
|
+
/**
|
92
|
+
* Whether this item should be displayed as disabled.
|
93
|
+
* @type {import("@vue/composition-api").Ref<boolean>}
|
94
|
+
* @private
|
95
|
+
*/
|
96
|
+
this._disabled = ref(false);
|
97
|
+
|
98
|
+
/**
|
99
|
+
* The state of this item. NONE if this item cannot have a state.
|
100
|
+
* @type {import("@vue/composition-api").Ref<StateActionState>}
|
101
|
+
* @private
|
102
|
+
*/
|
103
|
+
this._state = ref(StateActionState.NONE);
|
104
|
+
|
105
|
+
/**
|
106
|
+
* @type {function():void|null}
|
107
|
+
* @private
|
108
|
+
*/
|
109
|
+
this._stateActionListener = null;
|
110
|
+
|
111
|
+
/**
|
112
|
+
* @type {string|null}
|
113
|
+
* @private
|
114
|
+
*/
|
115
|
+
this._infoUrl = null;
|
116
|
+
this.infoUrl = options.infoUrl;
|
117
|
+
|
118
|
+
/**
|
119
|
+
* @type {import("@vue/composition-api").Ref<Object<string, string>|string|undefined>}
|
120
|
+
* @private
|
121
|
+
*/
|
122
|
+
this._title = ref(options.title);
|
123
|
+
|
124
|
+
/**
|
125
|
+
* An optional icon to display with this item. Can be an URL or HTMLElement.
|
126
|
+
* @type {import("@vue/composition-api").Ref<string|HTMLCanvasElement|HTMLImageElement|undefined>}
|
127
|
+
* @private
|
128
|
+
*/
|
129
|
+
this._icon = ref(options.icon);
|
130
|
+
|
131
|
+
/**
|
132
|
+
* @type {import("@vue/composition-api").Ref<Array<TreeViewItem>>}
|
133
|
+
* @protected
|
134
|
+
*/
|
135
|
+
this._children = ref([]);
|
136
|
+
|
137
|
+
/**
|
138
|
+
* @type {number}
|
139
|
+
* @private
|
140
|
+
*/
|
141
|
+
this._weight = parseNumber(options.weight, 0);
|
142
|
+
|
143
|
+
/**
|
144
|
+
* @type {boolean}
|
145
|
+
*/
|
146
|
+
this.initOpen = parseBoolean(options.initOpen, false);
|
147
|
+
|
148
|
+
/**
|
149
|
+
* @type {VcsEvent<number>}
|
150
|
+
*/
|
151
|
+
this.weightChanged = new VcsEvent();
|
152
|
+
}
|
153
|
+
|
154
|
+
/**
|
155
|
+
* @readonly
|
156
|
+
* @type {string}
|
157
|
+
*/
|
158
|
+
get className() {
|
159
|
+
return this.constructor.className;
|
160
|
+
}
|
161
|
+
|
162
|
+
/**
|
163
|
+
* @type {string}
|
164
|
+
* @readonly
|
165
|
+
*/
|
166
|
+
get name() {
|
167
|
+
return this._name;
|
168
|
+
}
|
169
|
+
|
170
|
+
/**
|
171
|
+
* A slice of the underlying actions array. Use add/removeAction to manipulate the actions array.
|
172
|
+
* @type {Array<VcsAction>}
|
173
|
+
* @readonly
|
174
|
+
*/
|
175
|
+
get actions() {
|
176
|
+
return this._actions.value.slice();
|
177
|
+
}
|
178
|
+
|
179
|
+
/**
|
180
|
+
* @type {boolean}
|
181
|
+
*/
|
182
|
+
get visible() {
|
183
|
+
return this._visible.value;
|
184
|
+
}
|
185
|
+
|
186
|
+
/**
|
187
|
+
* @param {boolean} visible
|
188
|
+
*/
|
189
|
+
set visible(visible) {
|
190
|
+
this._visible.value = !!visible;
|
191
|
+
}
|
192
|
+
|
193
|
+
/**
|
194
|
+
* @type {boolean}
|
195
|
+
*/
|
196
|
+
get clickable() {
|
197
|
+
return this._clickable.value;
|
198
|
+
}
|
199
|
+
|
200
|
+
/**
|
201
|
+
* @param {boolean} clickable
|
202
|
+
*/
|
203
|
+
set clickable(clickable) {
|
204
|
+
this._clickable.value = !!clickable;
|
205
|
+
}
|
206
|
+
|
207
|
+
/**
|
208
|
+
* @type {boolean}
|
209
|
+
*/
|
210
|
+
get disabled() {
|
211
|
+
return this._disabled.value;
|
212
|
+
}
|
213
|
+
|
214
|
+
/**
|
215
|
+
* @param {boolean} disabled
|
216
|
+
*/
|
217
|
+
set disabled(disabled) {
|
218
|
+
this._disabled.value = !!disabled;
|
219
|
+
}
|
220
|
+
|
221
|
+
/**
|
222
|
+
* @type {StateActionState}
|
223
|
+
*/
|
224
|
+
get state() {
|
225
|
+
return this._state.value;
|
226
|
+
}
|
227
|
+
|
228
|
+
/**
|
229
|
+
* @param {StateActionState} state
|
230
|
+
*/
|
231
|
+
set state(state) {
|
232
|
+
check(state, Object.values(StateActionState));
|
233
|
+
|
234
|
+
if (this._state.value !== state) {
|
235
|
+
this._state.value = state;
|
236
|
+
this._setStateAction();
|
237
|
+
}
|
238
|
+
}
|
239
|
+
|
240
|
+
/**
|
241
|
+
* @type {string|null}
|
242
|
+
*/
|
243
|
+
get infoUrl() { return this._infoUrl; }
|
244
|
+
|
245
|
+
/**
|
246
|
+
* @param {string} url
|
247
|
+
*/
|
248
|
+
set infoUrl(url) {
|
249
|
+
checkMaybe(url, String);
|
250
|
+
|
251
|
+
if (this._infoUrl !== url) {
|
252
|
+
this._infoUrl = url;
|
253
|
+
const name = 'infoUrl';
|
254
|
+
if (this._infoUrl) {
|
255
|
+
const action = createLinkAction({
|
256
|
+
name,
|
257
|
+
title: 'Info',
|
258
|
+
icon: '$vcsInfo',
|
259
|
+
}, this._infoUrl);
|
260
|
+
this.addAction(action, 6);
|
261
|
+
} else {
|
262
|
+
this.removeAction(name);
|
263
|
+
}
|
264
|
+
}
|
265
|
+
}
|
266
|
+
|
267
|
+
/**
|
268
|
+
* @type {string|Object<string>|undefined}
|
269
|
+
*/
|
270
|
+
get title() {
|
271
|
+
return this._title.value;
|
272
|
+
}
|
273
|
+
|
274
|
+
/**
|
275
|
+
* @param {string|Object<string>|undefined} title
|
276
|
+
*/
|
277
|
+
set title(title) {
|
278
|
+
checkMaybe(title, [String, Object]);
|
279
|
+
|
280
|
+
this._title.value = title;
|
281
|
+
}
|
282
|
+
|
283
|
+
/**
|
284
|
+
* @type {string|HTMLCanvasElement|HTMLImageElement|undefined}
|
285
|
+
*/
|
286
|
+
get icon() {
|
287
|
+
return this._icon.value;
|
288
|
+
}
|
289
|
+
|
290
|
+
/**
|
291
|
+
* @param {(string|HTMLCanvasElement|HTMLImageElement)=} icon
|
292
|
+
*/
|
293
|
+
set icon(icon) {
|
294
|
+
checkMaybe(icon, [String, HTMLElement]);
|
295
|
+
|
296
|
+
this._icon.value = icon;
|
297
|
+
}
|
298
|
+
|
299
|
+
/**
|
300
|
+
* @type {number}
|
301
|
+
*/
|
302
|
+
get weight() { return this._weight; }
|
303
|
+
|
304
|
+
/**
|
305
|
+
* @param {number} weight
|
306
|
+
*/
|
307
|
+
set weight(weight) {
|
308
|
+
check(weight, Number);
|
309
|
+
if (weight !== this._weight) {
|
310
|
+
this._weight = weight;
|
311
|
+
this.weightChanged.raiseEvent(weight);
|
312
|
+
}
|
313
|
+
}
|
314
|
+
|
315
|
+
/**
|
316
|
+
* @private
|
317
|
+
*/
|
318
|
+
_setStateAction() {
|
319
|
+
const name = 'stateAction';
|
320
|
+
if (this.state !== StateActionState.NONE && !this._stateActionListener) {
|
321
|
+
const { action, destroy } = createStateRefAction(
|
322
|
+
name,
|
323
|
+
this._state,
|
324
|
+
this.clicked.bind(this),
|
325
|
+
);
|
326
|
+
this.addAction(action, 0);
|
327
|
+
this._stateActionListener = () => {
|
328
|
+
this.removeAction(name);
|
329
|
+
destroy();
|
330
|
+
};
|
331
|
+
} else if (this._stateActionListener && this.state === StateActionState.NONE) {
|
332
|
+
this._stateActionListener();
|
333
|
+
this._stateActionListener = null;
|
334
|
+
}
|
335
|
+
}
|
336
|
+
|
337
|
+
/**
|
338
|
+
* @param {string} actionName
|
339
|
+
* @returns {number}
|
340
|
+
* @private
|
341
|
+
*/
|
342
|
+
_getActionIndex(actionName) {
|
343
|
+
return this._actions.value.findIndex(a => a.name === actionName);
|
344
|
+
}
|
345
|
+
|
346
|
+
/**
|
347
|
+
* Adds an action to this item. The predefined actions have the following weights:
|
348
|
+
* StateAction: 0
|
349
|
+
* GoToViewpoint: 2
|
350
|
+
* StyleSelector: 4
|
351
|
+
* InfoUrl: 6
|
352
|
+
* GoToExtent: 8
|
353
|
+
* The default weight is set to always push new actions past these.
|
354
|
+
* @param {VcsAction} action
|
355
|
+
* @param {number} [weight=0]
|
356
|
+
*/
|
357
|
+
addAction(action, weight = 11) {
|
358
|
+
check(action.name, String);
|
359
|
+
checkMaybe(weight, Number);
|
360
|
+
|
361
|
+
const index = this._getActionIndex(action.name);
|
362
|
+
if (index > -1) {
|
363
|
+
throw new Error('Action names must be unique');
|
364
|
+
}
|
365
|
+
action[actionWeightSymbol] = weight;
|
366
|
+
const insertIndex = this._actions.value.findIndex(a => a[actionWeightSymbol] > weight);
|
367
|
+
if (insertIndex > -1) {
|
368
|
+
this._actions.value.splice(insertIndex, 0, action);
|
369
|
+
} else {
|
370
|
+
this._actions.value.push(action);
|
371
|
+
}
|
372
|
+
}
|
373
|
+
|
374
|
+
/**
|
375
|
+
* @param {string} actionName
|
376
|
+
*/
|
377
|
+
removeAction(actionName) {
|
378
|
+
const index = this._getActionIndex(actionName);
|
379
|
+
if (index > -1) {
|
380
|
+
this._actions.value.splice(index, 1);
|
381
|
+
}
|
382
|
+
}
|
383
|
+
|
384
|
+
/**
|
385
|
+
* A callback called once the item is clicked.
|
386
|
+
* @returns {Promise<void>}
|
387
|
+
*/
|
388
|
+
// eslint-disable-next-line class-methods-use-this,no-empty-function
|
389
|
+
async clicked() {}
|
390
|
+
|
391
|
+
/**
|
392
|
+
* Returns a readonly TreeViewItem used for rendering the current item.
|
393
|
+
* @returns {TreeViewItem}
|
394
|
+
*/
|
395
|
+
getTreeViewItem() {
|
396
|
+
const clicked = this.clicked.bind(this);
|
397
|
+
return reactive({
|
398
|
+
name: this._name,
|
399
|
+
visible: this._visible,
|
400
|
+
clickable: this._clickable,
|
401
|
+
disabled: this._disabled,
|
402
|
+
state: this._state,
|
403
|
+
title: this._title,
|
404
|
+
icon: this._icon,
|
405
|
+
actions: this._actions,
|
406
|
+
children: this._children,
|
407
|
+
visibleChildren: computed(() => this._children.value.filter(c => c.visible)),
|
408
|
+
clicked,
|
409
|
+
});
|
410
|
+
}
|
411
|
+
|
412
|
+
/**
|
413
|
+
* @returns {ContentTreeItemOptions}
|
414
|
+
*/
|
415
|
+
toJSON() {
|
416
|
+
const config = {
|
417
|
+
type: this.className,
|
418
|
+
name: this.name,
|
419
|
+
};
|
420
|
+
|
421
|
+
if (this.title) {
|
422
|
+
config.title = this.title;
|
423
|
+
}
|
424
|
+
|
425
|
+
if (this.icon) {
|
426
|
+
config.icon = this.icon;
|
427
|
+
}
|
428
|
+
|
429
|
+
if (this.infoUrl) {
|
430
|
+
config.infoUrl = this.infoUrl;
|
431
|
+
}
|
432
|
+
|
433
|
+
if (this.initOpen) {
|
434
|
+
config.initOpen = this.initOpen;
|
435
|
+
}
|
436
|
+
|
437
|
+
if (this.weight) {
|
438
|
+
config.weight = this.weight;
|
439
|
+
}
|
440
|
+
|
441
|
+
return config;
|
442
|
+
}
|
443
|
+
|
444
|
+
/**
|
445
|
+
* Destroys this item and all its actions
|
446
|
+
*/
|
447
|
+
destroy() {
|
448
|
+
if (this._stateActionListener) {
|
449
|
+
this._stateActionListener();
|
450
|
+
}
|
451
|
+
this.actions.splice(0);
|
452
|
+
this._children.value.splice(0);
|
453
|
+
}
|
454
|
+
}
|
455
|
+
|
456
|
+
contentTreeClassRegistry.registerClass(ContentTreeItem.className, ContentTreeItem);
|
457
|
+
export default ContentTreeItem;
|
@@ -0,0 +1,67 @@
|
|
1
|
+
import { watch } from '@vue/composition-api';
|
2
|
+
import ContentTreeItem, { contentTreeClassRegistry } from './contentTreeItem.js';
|
3
|
+
import { StateActionState } from '../actions/stateRefAction.js';
|
4
|
+
|
5
|
+
/**
|
6
|
+
* A clickable group item. When clicked, every child with a state not NONE will also be clicked.
|
7
|
+
* @class
|
8
|
+
* @extends {ContentTreeItem}
|
9
|
+
*/
|
10
|
+
class GroupContentTreeItem extends ContentTreeItem {
|
11
|
+
/**
|
12
|
+
* @returns {string}
|
13
|
+
*/
|
14
|
+
static get className() { return 'GroupContentTreeItem'; }
|
15
|
+
|
16
|
+
/**
|
17
|
+
* @param {ContentTreeItemOptions} options
|
18
|
+
* @param {VcsUiApp} app
|
19
|
+
*/
|
20
|
+
constructor(options, app) {
|
21
|
+
super(options, app);
|
22
|
+
|
23
|
+
/**
|
24
|
+
* @type {function():void}
|
25
|
+
* @private
|
26
|
+
*/
|
27
|
+
this._childWatcher = watch(this._children, () => {
|
28
|
+
const children = this._children.value;
|
29
|
+
this.visible = children.some(c => c.visible);
|
30
|
+
if (children.every(c => c.state === StateActionState.NONE)) {
|
31
|
+
this.state = StateActionState.NONE;
|
32
|
+
} else {
|
33
|
+
const childrenWithState = children.filter(c => c.state !== StateActionState.NONE);
|
34
|
+
if (childrenWithState.every(c => c.state === StateActionState.ACTIVE)) {
|
35
|
+
this.state = StateActionState.ACTIVE;
|
36
|
+
} else if (childrenWithState.every(c => c.state === StateActionState.INACTIVE)) {
|
37
|
+
this.state = StateActionState.INACTIVE;
|
38
|
+
} else {
|
39
|
+
this.state = StateActionState.INDETERMINATE;
|
40
|
+
}
|
41
|
+
}
|
42
|
+
}, { deep: true });
|
43
|
+
}
|
44
|
+
|
45
|
+
async clicked() {
|
46
|
+
if (this.state === StateActionState.NONE) {
|
47
|
+
return;
|
48
|
+
}
|
49
|
+
|
50
|
+
const statePredicate = this.state === StateActionState.ACTIVE ?
|
51
|
+
state => state !== StateActionState.NONE :
|
52
|
+
state => state !== StateActionState.NONE && state !== StateActionState.ACTIVE;
|
53
|
+
|
54
|
+
const promises = this._children.value
|
55
|
+
.filter(c => c.visible && statePredicate(c.state))
|
56
|
+
.map(c => c.clicked());
|
57
|
+
await Promise.all(promises);
|
58
|
+
}
|
59
|
+
|
60
|
+
destroy() {
|
61
|
+
this._childWatcher();
|
62
|
+
super.destroy();
|
63
|
+
}
|
64
|
+
}
|
65
|
+
|
66
|
+
export default GroupContentTreeItem;
|
67
|
+
contentTreeClassRegistry.registerClass(GroupContentTreeItem.className, GroupContentTreeItem);
|