diff --git a/Docs/BuiltinIndex.md b/Docs/BuiltinIndex.md new file mode 100644 index 0000000000..adca9e3b77 --- /dev/null +++ b/Docs/BuiltinIndex.md @@ -0,0 +1,178 @@ +Index of builtin TagRendering +=============================== + +## Table of contents + +1. [Index of builtin TagRendering](#index-of-builtin-tagrendering) + +- [Existing builtin tagrenderings](#existing-builtin-tagrenderings) + + [images](#images) + + [website](#website) + + [phone](#phone) + + [email](#email) + + [opening_hours](#opening_hours) + + [description](#description) + + [level](#level) + + [bike_cleaning.bike_cleaning-service:bicycle:cleaning:charge](#bike_cleaningbike_cleaning-service:bicycle:cleaning:charge) + + [payment-options](#payment-options) + + [wheelchair-access](#wheelchair-access) + + [service:electricity](#serviceelectricity) + + [dog-access](#dog-access) + + [all_tags](#all_tags) + + [questions](#questions) + + [reviews](#reviews) + + [export_as_gpx](#export_as_gpx) + + [minimap](#minimap) + + [wikipedia](#wikipedia) + +Existing builtin tagrenderings +-------------------------------- + +### images + +- ambulancestation +- artwork +- bench +- bench_at_pt +- bicycle_library +- bicycle_tube_vending_machine +- bike_cafe +- bike_cleaning +- bike_parking +- bike_repair_station +- bike_shop +- bike_themed_object +- binocular +- birdhide +- cafe_pub +- charging_station +- defibrillator +- drinking_water +- entrance +- extinguisher +- fire_station +- food +- ghost_bike +- grass_in_parks +- hydrant +- information_board +- map +- nature_reserve +- observation_tower +- parking +- play_forest +- playground +- public_bookcase +- shops +- slow_roads +- sport_pitch +- surveillance_camera +- toilet +- trail +- tree_node +- viewpoint +- village_green +- watermill + +### website + +- bicycle_library +- bike_themed_object +- cafe_pub +- food +- observation_tower + +### phone + +- bicycle_library +- bike_themed_object +- cafe_pub +- food + +### email + +- bicycle_library +- bike_themed_object +- cafe_pub +- food + +### opening_hours + +- bicycle_library +- bike_themed_object +- cafe_pub +- food + +### description + +- bicycle_library +- bike_shop +- bike_themed_object +- toilet + +### level + +- bike_repair_station +- charging_station +- toilet + +### bike_cleaning.bike_cleaning-service:bicycle:cleaning:charge + +- bike_shop + +### payment-options + +- cafe_pub +- charging_station +- food +- observation_tower +- toilet + +### wheelchair-access + +- cafe_pub +- defibrillator +- food +- observation_tower + +### service:electricity + +- cafe_pub +- food + +### dog-access + +- cafe_pub +- food + +### all_tags + +- cluster_style + +### questions + +- etymology +- play_forest +- playground +- shops +- sport_pitch + +### reviews + +- food +- shops + +### export_as_gpx + +- gps_track + +### minimap + +- gps_track + +### wikipedia + +- nature_reserve +- observation_tower + +This document is autogenerated from assets/layers/*.json \ No newline at end of file diff --git a/Docs/Layers/ambulancestation.md b/Docs/Layers/ambulancestation.md index acd737657f..7ecef6e612 100644 --- a/Docs/Layers/ambulancestation.md +++ b/Docs/Layers/ambulancestation.md @@ -25,7 +25,6 @@ other medical supplies. #### Themes using this layer - [hailhydrant](https://mapcomplete.osm.be/hailhydrant) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/ambulancestation/ambulancestation.json) diff --git a/Docs/Layers/artwork.md b/Docs/Layers/artwork.md index 6e20a4754d..e9bebd45b9 100644 --- a/Docs/Layers/artwork.md +++ b/Docs/Layers/artwork.md @@ -23,7 +23,6 @@ Diverse pieces of artwork #### Themes using this layer - [artwork](https://mapcomplete.osm.be/artwork) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/artwork/artwork.json) diff --git a/Docs/Layers/barrier.md b/Docs/Layers/barrier.md index b57ec5627c..3e883576eb 100644 --- a/Docs/Layers/barrier.md +++ b/Docs/Layers/barrier.md @@ -32,7 +32,6 @@ Obstacles while cycling, such as bollards and cycle barriers #### Themes using this layer - [cycle_infra](https://mapcomplete.osm.be/cycle_infra) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/barrier/barrier.json) diff --git a/Docs/Layers/bench.md b/Docs/Layers/bench.md index e0e1fd3a5d..d195a3bf57 100644 --- a/Docs/Layers/bench.md +++ b/Docs/Layers/bench.md @@ -26,7 +26,6 @@ questions about them. #### Themes using this layer - [benches](https://mapcomplete.osm.be/benches) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bench/bench.json) diff --git a/Docs/Layers/bench_at_pt.md b/Docs/Layers/bench_at_pt.md index 979e1713b0..342bced382 100644 --- a/Docs/Layers/bench_at_pt.md +++ b/Docs/Layers/bench_at_pt.md @@ -21,7 +21,6 @@ A layer showing all public-transport-stops which do have a bench #### Themes using this layer - [benches](https://mapcomplete.osm.be/benches) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bench_at_pt/bench_at_pt.json) diff --git a/Docs/Layers/bicycle_library.md b/Docs/Layers/bicycle_library.md index 7e7a1045a0..32f80f433a 100644 --- a/Docs/Layers/bicycle_library.md +++ b/Docs/Layers/bicycle_library.md @@ -28,7 +28,6 @@ A facility where bicycles can be lent for longer period of times - [bicyclelib](https://mapcomplete.osm.be/bicyclelib) - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bicycle_library/bicycle_library.json) diff --git a/Docs/Layers/bicycle_tube_vending_machine.md b/Docs/Layers/bicycle_tube_vending_machine.md index 2e36758b04..77fdb716d8 100644 --- a/Docs/Layers/bicycle_tube_vending_machine.md +++ b/Docs/Layers/bicycle_tube_vending_machine.md @@ -27,7 +27,6 @@ vending machines with bicycle tubes and optionally additional bicycle related ob #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bicycle_tube_vending_machine/bicycle_tube_vending_machine.json) diff --git a/Docs/Layers/bike_cafe.md b/Docs/Layers/bike_cafe.md index c1c0c1da42..d1d3faad7c 100644 --- a/Docs/Layers/bike_cafe.md +++ b/Docs/Layers/bike_cafe.md @@ -28,7 +28,6 @@ decoration, ... #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_cafe/bike_cafe.json) diff --git a/Docs/Layers/bike_cleaning.md b/Docs/Layers/bike_cleaning.md index acdf4702c7..49467b7633 100644 --- a/Docs/Layers/bike_cleaning.md +++ b/Docs/Layers/bike_cleaning.md @@ -21,7 +21,6 @@ A layer showing facilities where one can clean their bike #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_cleaning/bike_cleaning.json) diff --git a/Docs/Layers/bike_parking.md b/Docs/Layers/bike_parking.md index 040263ed78..785d517cce 100644 --- a/Docs/Layers/bike_parking.md +++ b/Docs/Layers/bike_parking.md @@ -26,7 +26,6 @@ A layer showing where you can park your bike #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_parking/bike_parking.json) diff --git a/Docs/Layers/bike_repair_station.md b/Docs/Layers/bike_repair_station.md index 245639590d..eb1871ca69 100644 --- a/Docs/Layers/bike_repair_station.md +++ b/Docs/Layers/bike_repair_station.md @@ -32,7 +32,6 @@ A layer showing bicycle pumps and bicycle repair tool stands #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_repair_station/bike_repair_station.json) diff --git a/Docs/Layers/bike_shop.md b/Docs/Layers/bike_shop.md index 87f7a4e089..8584d22a31 100644 --- a/Docs/Layers/bike_shop.md +++ b/Docs/Layers/bike_shop.md @@ -35,7 +35,6 @@ A shop specifically selling bicycles or related items #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_shop/bike_shop.json) diff --git a/Docs/Layers/bike_themed_object.md b/Docs/Layers/bike_themed_object.md index 0c10faefab..b41a639dec 100644 --- a/Docs/Layers/bike_themed_object.md +++ b/Docs/Layers/bike_themed_object.md @@ -24,7 +24,6 @@ A layer with bike-themed objects but who don't match any other layer #### Themes using this layer - [cyclofix](https://mapcomplete.osm.be/cyclofix) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/bike_themed_object/bike_themed_object.json) diff --git a/Docs/Layers/binocular.md b/Docs/Layers/binocular.md index ff88c682c1..ff649d801e 100644 --- a/Docs/Layers/binocular.md +++ b/Docs/Layers/binocular.md @@ -21,7 +21,6 @@ Binoculas #### Themes using this layer - [binoculars](https://mapcomplete.osm.be/binoculars) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/binocular/binocular.json) diff --git a/Docs/Layers/birdhide.md b/Docs/Layers/birdhide.md index e0bf91153f..601e7faad8 100644 --- a/Docs/Layers/birdhide.md +++ b/Docs/Layers/birdhide.md @@ -22,7 +22,6 @@ Een vogelkijkhut #### Themes using this layer - [nature](https://mapcomplete.osm.be/nature) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/birdhide/birdhide.json) diff --git a/Docs/Layers/cafe_pub.md b/Docs/Layers/cafe_pub.md index e3c68e09ae..bb0e0b968e 100644 --- a/Docs/Layers/cafe_pub.md +++ b/Docs/Layers/cafe_pub.md @@ -29,7 +29,6 @@ A layer showing cafés and pubs where one can gather around a drink. The layer a #### Themes using this layer - [cafes_and_pubs](https://mapcomplete.osm.be/cafes_and_pubs) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/cafe_pub/cafe_pub.json) diff --git a/Docs/Layers/charging_station.md b/Docs/Layers/charging_station.md index 91e8a3f109..af10fc70b4 100644 --- a/Docs/Layers/charging_station.md +++ b/Docs/Layers/charging_station.md @@ -105,7 +105,6 @@ A charging station #### Themes using this layer - [charging_stations](https://mapcomplete.osm.be/charging_stations) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/charging_station/charging_station.json) diff --git a/Docs/Layers/crossings.md b/Docs/Layers/crossings.md index ebaa3bebbe..94b937b780 100644 --- a/Docs/Layers/crossings.md +++ b/Docs/Layers/crossings.md @@ -32,7 +32,6 @@ Crossings for pedestrians and cyclists #### Themes using this layer - [cycle_infra](https://mapcomplete.osm.be/cycle_infra) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/crossings/crossings.json) diff --git a/Docs/Layers/cycleways_and_roads.md b/Docs/Layers/cycleways_and_roads.md index 844da2dcb7..9c1799d900 100644 --- a/Docs/Layers/cycleways_and_roads.md +++ b/Docs/Layers/cycleways_and_roads.md @@ -40,7 +40,6 @@ All infrastructure that someone can cycle over, accompanied with questions about #### Themes using this layer - [cycle_infra](https://mapcomplete.osm.be/cycle_infra) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/cycleways_and_roads/cycleways_and_roads.json) diff --git a/Docs/Layers/defibrillator.md b/Docs/Layers/defibrillator.md index 4321a42b3f..f42f3e2b3e 100644 --- a/Docs/Layers/defibrillator.md +++ b/Docs/Layers/defibrillator.md @@ -39,7 +39,6 @@ defibrillators which might need staff to fetch the actual device #### Themes using this layer - [aed](https://mapcomplete.osm.be/aed) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/defibrillator/defibrillator.json) diff --git a/Docs/Layers/direction.md b/Docs/Layers/direction.md index 7af008f903..a132266ca2 100644 --- a/Docs/Layers/direction.md +++ b/Docs/Layers/direction.md @@ -21,7 +21,6 @@ This layer visualizes directions #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [surveillance](https://mapcomplete.osm.be/surveillance) [Go to the source code](../assets/layers/direction/direction.json) diff --git a/Docs/Layers/drinking_water.md b/Docs/Layers/drinking_water.md index 7e92ef1d1c..8629231e07 100644 --- a/Docs/Layers/drinking_water.md +++ b/Docs/Layers/drinking_water.md @@ -30,7 +30,6 @@ A layer showing drinking water fountains - [cyclofix](https://mapcomplete.osm.be/cyclofix) - [drinking_water](https://mapcomplete.osm.be/drinking_water) - [nature](https://mapcomplete.osm.be/nature) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/drinking_water/drinking_water.json) diff --git a/Docs/Layers/entrance.md b/Docs/Layers/entrance.md index 0990f73f4d..9b7d6e1657 100644 --- a/Docs/Layers/entrance.md +++ b/Docs/Layers/entrance.md @@ -30,7 +30,6 @@ users (but also bicycle users, people who want to deliver, ...) #### Themes using this layer - [entrances](https://mapcomplete.osm.be/entrances) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/entrance/entrance.json) diff --git a/Docs/Layers/etymology.md b/Docs/Layers/etymology.md index 06e6251b0d..7ecd0f6b28 100644 --- a/Docs/Layers/etymology.md +++ b/Docs/Layers/etymology.md @@ -27,7 +27,6 @@ All objects which have an etymology known #### Themes using this layer - [etymology](https://mapcomplete.osm.be/etymology) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/etymology/etymology.json) diff --git a/Docs/Layers/extinguisher.md b/Docs/Layers/extinguisher.md index d9ab423174..4ea5834869 100644 --- a/Docs/Layers/extinguisher.md +++ b/Docs/Layers/extinguisher.md @@ -20,7 +20,6 @@ Map layer to show fire hydrants. #### Themes using this layer - [hailhydrant](https://mapcomplete.osm.be/hailhydrant) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/extinguisher/extinguisher.json) diff --git a/Docs/Layers/fire_station.md b/Docs/Layers/fire_station.md index 9c6419ecd4..c360178ea0 100644 --- a/Docs/Layers/fire_station.md +++ b/Docs/Layers/fire_station.md @@ -24,7 +24,6 @@ Map layer to show fire stations. #### Themes using this layer - [hailhydrant](https://mapcomplete.osm.be/hailhydrant) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/fire_station/fire_station.json) diff --git a/Docs/Layers/food.md b/Docs/Layers/food.md index 25548feef4..e45da3f2d3 100644 --- a/Docs/Layers/food.md +++ b/Docs/Layers/food.md @@ -40,7 +40,6 @@ A layer showing restaurants and fast-food amenities (with a special rendering fo - [food](https://mapcomplete.osm.be/food) - [fritures](https://mapcomplete.osm.be/fritures) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/food/food.json) diff --git a/Docs/Layers/ghost_bike.md b/Docs/Layers/ghost_bike.md index c86cbb7829..7c20d28ebe 100644 --- a/Docs/Layers/ghost_bike.md +++ b/Docs/Layers/ghost_bike.md @@ -24,7 +24,6 @@ A layer showing memorials for cyclists, killed in road accidents #### Themes using this layer - [ghostbikes](https://mapcomplete.osm.be/ghostbikes) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/ghost_bike/ghost_bike.json) diff --git a/Docs/Layers/hydrant.md b/Docs/Layers/hydrant.md index 281c441205..400b8dda86 100644 --- a/Docs/Layers/hydrant.md +++ b/Docs/Layers/hydrant.md @@ -22,7 +22,6 @@ Map layer to show fire hydrants. #### Themes using this layer - [hailhydrant](https://mapcomplete.osm.be/hailhydrant) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/hydrant/hydrant.json) diff --git a/Docs/Layers/information_board.md b/Docs/Layers/information_board.md index 19e2fa1240..29ecf6eec3 100644 --- a/Docs/Layers/information_board.md +++ b/Docs/Layers/information_board.md @@ -20,7 +20,6 @@ feature, a map, ...) #### Themes using this layer - [nature](https://mapcomplete.osm.be/nature) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/information_board/information_board.json) diff --git a/Docs/Layers/map.md b/Docs/Layers/map.md index c59177385b..d6d592f368 100644 --- a/Docs/Layers/map.md +++ b/Docs/Layers/map.md @@ -22,7 +22,6 @@ A map, meant for tourists which is permanently installed in the public space - [maps](https://mapcomplete.osm.be/maps) - [nature](https://mapcomplete.osm.be/nature) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/map/map.json) diff --git a/Docs/Layers/nature_reserve.md b/Docs/Layers/nature_reserve.md index 60962dffd4..7fbcc36d7d 100644 --- a/Docs/Layers/nature_reserve.md +++ b/Docs/Layers/nature_reserve.md @@ -33,7 +33,6 @@ Natuurpunt of het Agentschap Natuur en Bos of zijn deze erkend door de overheid. #### Themes using this layer - [nature](https://mapcomplete.osm.be/nature) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/nature_reserve/nature_reserve.json) diff --git a/Docs/Layers/observation_tower.md b/Docs/Layers/observation_tower.md index 16ab80baa1..2753d820f8 100644 --- a/Docs/Layers/observation_tower.md +++ b/Docs/Layers/observation_tower.md @@ -27,7 +27,6 @@ Towers with a panoramic view #### Themes using this layer - [observation_towers](https://mapcomplete.osm.be/observation_towers) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/observation_tower/observation_tower.json) diff --git a/Docs/Layers/parking.md b/Docs/Layers/parking.md index 34f295b0e0..37b7dfa311 100644 --- a/Docs/Layers/parking.md +++ b/Docs/Layers/parking.md @@ -19,7 +19,6 @@ A layer showing car parkings #### Themes using this layer - [parkings](https://mapcomplete.osm.be/parkings) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/parking/parking.json) diff --git a/Docs/Layers/pedestrian_path.md b/Docs/Layers/pedestrian_path.md index 10300a0be7..4ba0222d2c 100644 --- a/Docs/Layers/pedestrian_path.md +++ b/Docs/Layers/pedestrian_path.md @@ -21,7 +21,6 @@ Pedestrian footpaths, especially used for indoor navigation and snapping entranc #### Themes using this layer - [entrances](https://mapcomplete.osm.be/entrances) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/pedestrian_path/pedestrian_path.json) diff --git a/Docs/Layers/picnic_table.md b/Docs/Layers/picnic_table.md index 0d6817eb5c..7ca533f517 100644 --- a/Docs/Layers/picnic_table.md +++ b/Docs/Layers/picnic_table.md @@ -19,7 +19,6 @@ The layer showing picnic tables #### Themes using this layer - [benches](https://mapcomplete.osm.be/benches) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/picnic_table/picnic_table.json) diff --git a/Docs/Layers/playground.md b/Docs/Layers/playground.md index 6747f04135..72143a7dd7 100644 --- a/Docs/Layers/playground.md +++ b/Docs/Layers/playground.md @@ -30,7 +30,6 @@ Playgrounds #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [playgrounds](https://mapcomplete.osm.be/playgrounds) [Go to the source code](../assets/layers/playground/playground.json) diff --git a/Docs/Layers/public_bookcase.md b/Docs/Layers/public_bookcase.md index bf92e47649..0ede4a6d17 100644 --- a/Docs/Layers/public_bookcase.md +++ b/Docs/Layers/public_bookcase.md @@ -32,7 +32,6 @@ A streetside cabinet with books, accessible to anyone #### Themes using this layer - [bookcases](https://mapcomplete.osm.be/bookcases) -- [personal](https://mapcomplete.osm.be/personal) [Go to the source code](../assets/layers/public_bookcase/public_bookcase.json) diff --git a/Docs/Layers/shops.md b/Docs/Layers/shops.md index 777ad3a3e1..704aed1766 100644 --- a/Docs/Layers/shops.md +++ b/Docs/Layers/shops.md @@ -26,7 +26,6 @@ A shop #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [shops](https://mapcomplete.osm.be/shops) [Go to the source code](../assets/layers/shops/shops.json) diff --git a/Docs/Layers/sport_pitch.md b/Docs/Layers/sport_pitch.md index 284f84d061..b2d97c3827 100644 --- a/Docs/Layers/sport_pitch.md +++ b/Docs/Layers/sport_pitch.md @@ -27,7 +27,6 @@ A sport pitch #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [sport_pitches](https://mapcomplete.osm.be/sport_pitches) [Go to the source code](../assets/layers/sport_pitch/sport_pitch.json) diff --git a/Docs/Layers/street_lamps.md b/Docs/Layers/street_lamps.md index 61182e0417..c0c2b14438 100644 --- a/Docs/Layers/street_lamps.md +++ b/Docs/Layers/street_lamps.md @@ -25,7 +25,6 @@ A layer showing street lights #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [street_lighting](https://mapcomplete.osm.be/street_lighting) [Go to the source code](../assets/layers/street_lamps/street_lamps.json) diff --git a/Docs/Layers/surveillance_camera.md b/Docs/Layers/surveillance_camera.md index 41d5caf6ea..299ab31212 100644 --- a/Docs/Layers/surveillance_camera.md +++ b/Docs/Layers/surveillance_camera.md @@ -30,7 +30,6 @@ This layer shows surveillance cameras and allows a contributor to update informa #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [surveillance](https://mapcomplete.osm.be/surveillance) [Go to the source code](../assets/layers/surveillance_camera/surveillance_camera.json) diff --git a/Docs/Layers/toilet.md b/Docs/Layers/toilet.md index 9673326429..db0b89e76a 100644 --- a/Docs/Layers/toilet.md +++ b/Docs/Layers/toilet.md @@ -31,7 +31,6 @@ A layer showing (public) toilets #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [toilets](https://mapcomplete.osm.be/toilets) [Go to the source code](../assets/layers/toilet/toilet.json) diff --git a/Docs/Layers/tree_node.md b/Docs/Layers/tree_node.md index ddb54c8f89..a1b023e73b 100644 --- a/Docs/Layers/tree_node.md +++ b/Docs/Layers/tree_node.md @@ -26,7 +26,6 @@ A layer showing trees #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [trees](https://mapcomplete.osm.be/trees) [Go to the source code](../assets/layers/tree_node/tree_node.json) diff --git a/Docs/Layers/walls_and_buildings.md b/Docs/Layers/walls_and_buildings.md index 7940feec6b..3632601e8f 100644 --- a/Docs/Layers/walls_and_buildings.md +++ b/Docs/Layers/walls_and_buildings.md @@ -29,7 +29,6 @@ default and not toggleable by the user. - [aed](https://mapcomplete.osm.be/aed) - [entrances](https://mapcomplete.osm.be/entrances) -- [personal](https://mapcomplete.osm.be/personal) - [surveillance](https://mapcomplete.osm.be/surveillance) [Go to the source code](../assets/layers/walls_and_buildings/walls_and_buildings.json) diff --git a/Docs/Layers/waste_basket.md b/Docs/Layers/waste_basket.md index 3357babede..fa8f865657 100644 --- a/Docs/Layers/waste_basket.md +++ b/Docs/Layers/waste_basket.md @@ -19,7 +19,6 @@ This is a public waste basket, thrash can, where you can throw away your thrash. #### Themes using this layer -- [personal](https://mapcomplete.osm.be/personal) - [waste_basket](https://mapcomplete.osm.be/waste_basket) [Go to the source code](../assets/layers/waste_basket/waste_basket.json) diff --git a/Docs/Schemas/AndOrTagConfigJsonJSC.ts b/Docs/Schemas/AndOrTagConfigJsonJSC.ts index 6600f85021..3da8b5b091 100644 --- a/Docs/Schemas/AndOrTagConfigJsonJSC.ts +++ b/Docs/Schemas/AndOrTagConfigJsonJSC.ts @@ -1,37 +1,37 @@ export default { - "$ref": "#/definitions/AndOrTagConfigJson", - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } + "$ref": "#/definitions/AndOrTagConfigJson", + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/DeleteConfigJsonJSC.ts b/Docs/Schemas/DeleteConfigJsonJSC.ts index bdc96c0c48..eb67718d7b 100644 --- a/Docs/Schemas/DeleteConfigJsonJSC.ts +++ b/Docs/Schemas/DeleteConfigJsonJSC.ts @@ -1,91 +1,91 @@ export default { - "type": "object", - "properties": { - "extraDeleteReasons": { - "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", - "type": "array", - "items": { - "type": "object", - "properties": { - "explanation": { - "description": "The text that will be shown to the user - translatable" - }, - "changesetMessage": { - "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", - "type": "string" - } + "type": "object", + "properties": { + "extraDeleteReasons": { + "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", + "type": "array", + "items": { + "type": "object", + "properties": { + "explanation": { + "description": "The text that will be shown to the user - translatable" + }, + "changesetMessage": { + "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", + "type": "string" + } + }, + "required": [ + "changesetMessage", + "explanation" + ] + } }, - "required": [ - "changesetMessage", - "explanation" - ] - } - }, - "nonDeleteMappings": { - "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - "then": {} + "nonDeleteMappings": { + "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + "then": {} + }, + "required": [ + "if", + "then" + ] + } }, - "required": [ - "if", - "then" - ] - } - }, - "softDeletionTags": { - "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "neededChangesets": { - "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", - "type": "number" - } - }, - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { + "softDeletionTags": { + "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } ] - } }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } + "neededChangesets": { + "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", + "type": "number" } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/FilterConfigJsonJSC.ts b/Docs/Schemas/FilterConfigJsonJSC.ts index 25ecaa851a..d20a3ef278 100644 --- a/Docs/Schemas/FilterConfigJsonJSC.ts +++ b/Docs/Schemas/FilterConfigJsonJSC.ts @@ -1,87 +1,87 @@ export default { - "type": "object", - "properties": { - "id": { - "description": "An id/name for this filter, used to set the URL parameters", - "type": "string" - }, - "options": { - "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", - "type": "array", - "items": { - "type": "object", - "properties": { - "question": {}, - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "fields": { + "type": "object", + "properties": { + "id": { + "description": "An id/name for this filter, used to set the URL parameters", + "type": "string" + }, + "options": { + "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", "type": "array", "items": { - "type": "object", - "properties": { - "name": { - "type": "string" + "type": "object", + "properties": { + "question": {}, + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "fields": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "name" + ] + } + } }, - "type": { - "type": "string" - } - }, - "required": [ - "name" - ] + "required": [ + "question" + ] } - } - }, - "required": [ - "question" - ] - } - } - }, - "required": [ - "id", - "options" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "required": [ + "id", + "options" + ], + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/LayerConfigJsonJSC.ts b/Docs/Schemas/LayerConfigJsonJSC.ts index 9c0286e609..f5bf8a7d18 100644 --- a/Docs/Schemas/LayerConfigJsonJSC.ts +++ b/Docs/Schemas/LayerConfigJsonJSC.ts @@ -1,932 +1,932 @@ export default { - "description": "Configuration for a single layer", - "type": "object", - "properties": { - "id": { - "description": "The id of this layer.\nThis should be a simple, lowercase, human readable string that is used to identify the layer.", - "type": "string" - }, - "name": { - "description": "The name of this layer\nUsed in the layer control panel and the 'Personal theme'.\n\nIf not given, will be hidden (and thus not toggable) in the layer control" - }, - "description": { - "description": "A description for this layer.\nShown in the layer selections and in the personel theme" - }, - "source": { - "description": "This determines where the data for the layer is fetched.\nThere are some options:\n\n# Query OSM directly\nsource: {osmTags: \"key=value\"}\n will fetch all objects with given tags from OSM.\n Currently, this will create a query to overpass and fetch the data - in the future this might fetch from the OSM API\n\n# Query OSM Via the overpass API with a custom script\nsource: {overpassScript: \"\"} when you want to do special things. _This should be really rare_.\n This means that the data will be pulled from overpass with this script, and will ignore the osmTags for the query\n However, for the rest of the pipeline, the OsmTags will _still_ be used. This is important to enable layers etc...\n\n\n# A single geojson-file\nsource: {geoJson: \"https://my.source.net/some-geo-data.geojson\"}\n fetches a geojson from a third party source\n\n# A tiled geojson source\nsource: {geoJson: \"https://my.source.net/some-tile-geojson-{layer}-{z}-{x}-{y}.geojson\", geoJsonZoomLevel: 14}\n to use a tiled geojson source. The web server must offer multiple geojsons. {z}, {x} and {y} are substituted by the location; {layer} is substituted with the id of the loaded layer\n\nSome API's use a BBOX instead of a tile, this can be used by specifying {y_min}, {y_max}, {x_min} and {x_max}\nSome API's use a mercator-projection (EPSG:900913) instead of WGS84. Set the flag `mercatorCrs: true` in the source for this\n\nNote that both geojson-options might set a flag 'isOsmCache' indicating that the data originally comes from OSM too\n\n\nNOTE: the previous format was 'overpassTags: AndOrTagConfigJson | string', which is interpreted as a shorthand for source: {osmTags: \"key=value\"}\n While still supported, this is considered deprecated", - "anyOf": [ - { - "allOf": [ - { - "type": "object", - "properties": { - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "overpassScript": { - "type": "string" - } - }, - "required": [ - "osmTags" - ] - }, - { - "type": "object", - "properties": { - "maxCacheAge": { - "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", - "type": "number" - } - } - } - ] + "description": "Configuration for a single layer", + "type": "object", + "properties": { + "id": { + "description": "The id of this layer.\nThis should be a simple, lowercase, human readable string that is used to identify the layer.", + "type": "string" }, - { - "allOf": [ - { - "type": "object", - "properties": { - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "geoJson": { - "type": "string" - }, - "geoJsonZoomLevel": { - "type": "number" - }, - "isOsmCache": { - "type": "boolean" - }, - "mercatorCrs": { - "type": "boolean" - } - }, - "required": [ - "geoJson", - "osmTags" - ] - }, - { - "type": "object", - "properties": { - "maxCacheAge": { - "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", - "type": "number" - } - } - } - ] - } - ] - }, - "calculatedTags": { - "description": "A list of extra tags to calculate, specified as \"keyToAssignTo=javascript-expression\".\nThere are a few extra functions available. Refer to Docs/CalculatedTags.md for more information\nThe functions will be run in order, e.g.\n[\n \"_max_overlap_m2=Math.max(...feat.overlapsWith(\"someOtherLayer\").map(o => o.overlap))\n \"_max_overlap_ratio=Number(feat._max_overlap_m2)/feat.area\n]\n\nThe specified tags are evaluated lazily. E.g. if a calculated tag is only used in the popup (e.g. the number of nearby features),\nthe expensive calculation will only be performed then for that feature. This avoids clogging up the contributors PC when all features are loaded.\n\nIf a tag has to be evaluated strictly, use ':=' instead:\n\n[\n\"_some_key:=some_javascript_expression\"\n]", - "type": "array", - "items": { - "type": "string" - } - }, - "doNotDownload": { - "description": "If set, this layer will not query overpass; but it'll still match the tags above which are by chance returned by other layers.\nWorks well together with 'passAllFeatures', to add decoration", - "type": "boolean" - }, - "isShown": { - "description": "This tag rendering should either be 'yes' or 'no'. If 'no' is returned, then the feature will be hidden from view.\nThis is useful to hide certain features from view.\n\nImportant: hiding features does not work dynamically, but is only calculated when the data is first renders.\nThis implies that it is not possible to hide a feature after a tagging change\n\nThe default value is 'yes'", - "$ref": "#/definitions/TagRenderingConfigJson" - }, - "minzoom": { - "description": "The minimum needed zoomlevel required before loading of the data start\nDefault: 0", - "type": "number" - }, - "shownByDefault": { - "description": "Indicates if this layer is shown by default;\ncan be used to hide a layer from start, or to load the layer but only to show it where appropriate (e.g. for snapping to it)", - "type": "boolean" - }, - "minzoomVisible": { - "description": "The zoom level at which point the data is hidden again\nDefault: 100 (thus: always visible", - "type": "number" - }, - "title": { - "description": "The title shown in a popup for elements of this layer.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" + "name": { + "description": "The name of this layer\nUsed in the layer control panel and the 'Personal theme'.\n\nIf not given, will be hidden (and thus not toggable) in the layer control" }, - { - "type": "string" - } - ] - }, - "titleIcons": { - "description": "Small icons shown next to the title.\nIf not specified, the OsmLink and wikipedia links will be used by default.\nUse an empty array to hide them.\nNote that \"defaults\" will insert all the default titleIcons (which are added automatically)", - "anyOf": [ - { - "type": "array", - "items": { + "description": { + "description": "A description for this layer.\nShown in the layer selections and in the personel theme" + }, + "source": { + "description": "This determines where the data for the layer is fetched.\nThere are some options:\n\n# Query OSM directly\nsource: {osmTags: \"key=value\"}\n will fetch all objects with given tags from OSM.\n Currently, this will create a query to overpass and fetch the data - in the future this might fetch from the OSM API\n\n# Query OSM Via the overpass API with a custom script\nsource: {overpassScript: \"\"} when you want to do special things. _This should be really rare_.\n This means that the data will be pulled from overpass with this script, and will ignore the osmTags for the query\n However, for the rest of the pipeline, the OsmTags will _still_ be used. This is important to enable layers etc...\n\n\n# A single geojson-file\nsource: {geoJson: \"https://my.source.net/some-geo-data.geojson\"}\n fetches a geojson from a third party source\n\n# A tiled geojson source\nsource: {geoJson: \"https://my.source.net/some-tile-geojson-{layer}-{z}-{x}-{y}.geojson\", geoJsonZoomLevel: 14}\n to use a tiled geojson source. The web server must offer multiple geojsons. {z}, {x} and {y} are substituted by the location; {layer} is substituted with the id of the loaded layer\n\nSome API's use a BBOX instead of a tile, this can be used by specifying {y_min}, {y_max}, {x_min} and {x_max}\nSome API's use a mercator-projection (EPSG:900913) instead of WGS84. Set the flag `mercatorCrs: true` in the source for this\n\nNote that both geojson-options might set a flag 'isOsmCache' indicating that the data originally comes from OSM too\n\n\nNOTE: the previous format was 'overpassTags: AndOrTagConfigJson | string', which is interpreted as a shorthand for source: {osmTags: \"key=value\"}\n While still supported, this is considered deprecated", "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } + { + "allOf": [ + { + "type": "object", + "properties": { + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "overpassScript": { + "type": "string" + } + }, + "required": [ + "osmTags" + ] + }, + { + "type": "object", + "properties": { + "maxCacheAge": { + "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", + "type": "number" + } + } + } + ] + }, + { + "allOf": [ + { + "type": "object", + "properties": { + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "geoJson": { + "type": "string" + }, + "geoJsonZoomLevel": { + "type": "number" + }, + "isOsmCache": { + "type": "boolean" + }, + "mercatorCrs": { + "type": "boolean" + } + }, + "required": [ + "geoJson", + "osmTags" + ] + }, + { + "type": "object", + "properties": { + "maxCacheAge": { + "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", + "type": "number" + } + } + } + ] + } ] - } }, - { - "type": "array", - "items": [ - { - "type": "string", - "enum": [ - "defaults" - ] - } - ], - "minItems": 1, - "maxItems": 1 - } - ] - }, - "mapRendering": { - "anyOf": [ - { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/default_3" - }, - { - "$ref": "#/definitions/default_4" - } - ] - } - }, - { - "type": "null" - } - ] - }, - "passAllFeatures": { - "description": "If set, this layer will pass all the features it receives onto the next layer.\nThis is ideal for decoration, e.g. directionss on cameras", - "type": "boolean" - }, - "presets": { - "description": "Presets for this layer.\nA preset shows up when clicking the map on a without data (or when right-clicking/long-pressing);\nit will prompt the user to add a new point.\n\nThe most important aspect are the tags, which define which tags the new point will have;\nThe title is shown in the dialog, along with the first sentence of the description.\n\nUpon confirmation, the full description is shown beneath the buttons - perfect to add pictures and examples.\n\nNote: the icon of the preset is determined automatically based on the tags and the icon above. Don't worry about that!\nNB: if no presets are defined, the popup to add new points doesn't show up at all", - "type": "array", - "items": { - "type": "object", - "properties": { - "title": { - "description": "The title - shown on the 'add-new'-button." - }, - "tags": { - "description": "The tags to add. It determines the icon too", + "calculatedTags": { + "description": "A list of extra tags to calculate, specified as \"keyToAssignTo=javascript-expression\".\nThere are a few extra functions available. Refer to Docs/CalculatedTags.md for more information\nThe functions will be run in order, e.g.\n[\n \"_max_overlap_m2=Math.max(...feat.overlapsWith(\"someOtherLayer\").map(o => o.overlap))\n \"_max_overlap_ratio=Number(feat._max_overlap_m2)/feat.area\n]\n\nThe specified tags are evaluated lazily. E.g. if a calculated tag is only used in the popup (e.g. the number of nearby features),\nthe expensive calculation will only be performed then for that feature. This avoids clogging up the contributors PC when all features are loaded.\n\nIf a tag has to be evaluated strictly, use ':=' instead:\n\n[\n\"_some_key:=some_javascript_expression\"\n]", "type": "array", "items": { - "type": "string" + "type": "string" } - }, - "description": { - "description": "The _first sentence_ of the description is shown on the button of the `add` menu.\nThe full description is shown in the confirmation dialog.\n\n(The first sentence is until the first '.'-character in the description)" - }, - "preciseInput": { - "description": "If set, the user will prompted to confirm the location before actually adding the data.\nThis will be with a 'drag crosshair'-method.\n\nIf 'preferredBackgroundCategory' is set, the element will attempt to pick a background layer of that category.", + }, + "doNotDownload": { + "description": "If set, this layer will not query overpass; but it'll still match the tags above which are by chance returned by other layers.\nWorks well together with 'passAllFeatures', to add decoration", + "type": "boolean" + }, + "isShown": { + "description": "This tag rendering should either be 'yes' or 'no'. If 'no' is returned, then the feature will be hidden from view.\nThis is useful to hide certain features from view.\n\nImportant: hiding features does not work dynamically, but is only calculated when the data is first renders.\nThis implies that it is not possible to hide a feature after a tagging change\n\nThe default value is 'yes'", + "$ref": "#/definitions/TagRenderingConfigJson" + }, + "minzoom": { + "description": "The minimum needed zoomlevel required before loading of the data start\nDefault: 0", + "type": "number" + }, + "shownByDefault": { + "description": "Indicates if this layer is shown by default;\ncan be used to hide a layer from start, or to load the layer but only to show it where appropriate (e.g. for snapping to it)", + "type": "boolean" + }, + "minzoomVisible": { + "description": "The zoom level at which point the data is hidden again\nDefault: 100 (thus: always visible", + "type": "number" + }, + "title": { + "description": "The title shown in a popup for elements of this layer.", "anyOf": [ - { + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "titleIcons": { + "description": "Small icons shown next to the title.\nIf not specified, the OsmLink and wikipedia links will be used by default.\nUse an empty array to hide them.\nNote that \"defaults\" will insert all the default titleIcons (which are added automatically)", + "anyOf": [ + { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + { + "type": "array", + "items": [ + { + "type": "string", + "enum": [ + "defaults" + ] + } + ], + "minItems": 1, + "maxItems": 1 + } + ] + }, + "mapRendering": { + "anyOf": [ + { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/default_3" + }, + { + "$ref": "#/definitions/default_4" + } + ] + } + }, + { + "type": "null" + } + ] + }, + "passAllFeatures": { + "description": "If set, this layer will pass all the features it receives onto the next layer.\nThis is ideal for decoration, e.g. directionss on cameras", + "type": "boolean" + }, + "presets": { + "description": "Presets for this layer.\nA preset shows up when clicking the map on a without data (or when right-clicking/long-pressing);\nit will prompt the user to add a new point.\n\nThe most important aspect are the tags, which define which tags the new point will have;\nThe title is shown in the dialog, along with the first sentence of the description.\n\nUpon confirmation, the full description is shown beneath the buttons - perfect to add pictures and examples.\n\nNote: the icon of the preset is determined automatically based on the tags and the icon above. Don't worry about that!\nNB: if no presets are defined, the popup to add new points doesn't show up at all", + "type": "array", + "items": { "type": "object", "properties": { - "preferredBackground": { - "description": "The type of background picture", - "anyOf": [ - { + "title": { + "description": "The title - shown on the 'add-new'-button." + }, + "tags": { + "description": "The tags to add. It determines the icon too", "type": "array", "items": { - "type": "string" + "type": "string" } - }, - { - "type": "string" - } - ] - }, - "snapToLayer": { - "description": "If specified, these layers will be shown to and the new point will be snapped towards it", - "anyOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "maxSnapDistance": { - "description": "If specified, a new point will only be snapped if it is within this range.\nDistance in meter\n\nDefault: 10", - "type": "number" - } + }, + "description": { + "description": "The _first sentence_ of the description is shown on the button of the `add` menu.\nThe full description is shown in the confirmation dialog.\n\n(The first sentence is until the first '.'-character in the description)" + }, + "preciseInput": { + "description": "If set, the user will prompted to confirm the location before actually adding the data.\nThis will be with a 'drag crosshair'-method.\n\nIf 'preferredBackgroundCategory' is set, the element will attempt to pick a background layer of that category.", + "anyOf": [ + { + "type": "object", + "properties": { + "preferredBackground": { + "description": "The type of background picture", + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] + }, + "snapToLayer": { + "description": "If specified, these layers will be shown to and the new point will be snapped towards it", + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] + }, + "maxSnapDistance": { + "description": "If specified, a new point will only be snapped if it is within this range.\nDistance in meter\n\nDefault: 10", + "type": "number" + } + }, + "required": [ + "preferredBackground" + ] + }, + { + "enum": [ + true + ], + "type": "boolean" + } + ] + } }, "required": [ - "preferredBackground" + "tags", + "title" ] - }, - { - "enum": [ - true - ], - "type": "boolean" - } - ] - } + } }, - "required": [ - "tags", - "title" - ] - } - }, - "tagRenderings": { - "description": "All the tag renderings.\nA tag rendering is a block that either shows the known value or asks a question.\n\nRefer to the class `TagRenderingConfigJson` to see the possibilities.\n\nNote that we can also use a string here - where the string refers to a tag rendering defined in `assets/questions/questions.json`,\nwhere a few very general questions are defined e.g. website, phone number, ...\n\nA special value is 'questions', which indicates the location of the questions box. If not specified, it'll be appended to the bottom of the featureInfobox.\n\nAt last, one can define a group of renderings where parts of all strings will be replaced by multiple other strings.\nThis is mainly create questions for a 'left' and a 'right' side of the road.\nThese will be grouped and questions will be asked together", - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "object", - "properties": { - "builtin": { - "type": "string" - }, - "override": {} - }, - "required": [ - "builtin", - "override" - ] - }, - { - "type": "object", - "properties": { - "rewrite": { - "type": "array", - "items": { - "type": "object", - "properties": { - "sourceString": { - "type": "string" - }, - "into": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "into", - "sourceString" - ] - } - }, - "renderings": { - "type": "array", - "items": { - "anyOf": [ + "tagRenderings": { + "description": "All the tag renderings.\nA tag rendering is a block that either shows the known value or asks a question.\n\nRefer to the class `TagRenderingConfigJson` to see the possibilities.\n\nNote that we can also use a string here - where the string refers to a tag rendering defined in `assets/questions/questions.json`,\nwhere a few very general questions are defined e.g. website, phone number, ...\n\nA special value is 'questions', which indicates the location of the questions box. If not specified, it'll be appended to the bottom of the featureInfobox.\n\nAt last, one can define a group of renderings where parts of all strings will be replaced by multiple other strings.\nThis is mainly create questions for a 'left' and a 'right' side of the road.\nThese will be grouped and questions will be asked together", + "type": "array", + "items": { + "anyOf": [ { - "$ref": "#/definitions/TagRenderingConfigJson" + "$ref": "#/definitions/TagRenderingConfigJson" }, { - "type": "object", - "properties": { - "builtin": { - "type": "string" + "type": "object", + "properties": { + "builtin": { + "type": "string" + }, + "override": {} }, - "override": {} - }, - "required": [ - "builtin", - "override" - ] + "required": [ + "builtin", + "override" + ] }, { - "type": "string" + "type": "object", + "properties": { + "rewrite": { + "type": "array", + "items": { + "type": "object", + "properties": { + "sourceString": { + "type": "string" + }, + "into": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "into", + "sourceString" + ] + } + }, + "renderings": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "object", + "properties": { + "builtin": { + "type": "string" + }, + "override": {} + }, + "required": [ + "builtin", + "override" + ] + }, + { + "type": "string" + } + ] + } + } + }, + "required": [ + "renderings", + "rewrite" + ] + }, + { + "type": "string" } - ] + ] + } + }, + "filter": { + "description": "All the extra questions for filtering", + "type": "array", + "items": { + "$ref": "#/definitions/default" + } + }, + "deletion": { + "description": "This block defines under what circumstances the delete dialog is shown for objects of this layer.\nIf set, a dialog is shown to the user to (soft) delete the point.\nThe dialog is built to be user friendly and to prevent mistakes.\nIf deletion is not possible, the dialog will hide itself and show the reason of non-deletability instead.\n\nTo configure, the following values are possible:\n\n- false: never ever show the delete button\n- true: show the default delete button\n- undefined: use the mapcomplete default to show deletion or not. Currently, this is the same as 'false' but this will change in the future\n- or: a hash with options (see below)\n\n The delete dialog\n =================\n\n\n\n#### Hard deletion if enough experience\n\nA feature can only be deleted from OpenStreetMap by mapcomplete if:\n\n- It is a node\n- No ways or relations use the node\n- The logged-in user has enough experience OR the user is the only one to have edited the point previously\n- The logged-in user has no unread messages (or has a ton of experience)\n- The user did not select one of the 'non-delete-options' (see below)\n\nIn all other cases, a 'soft deletion' is used.\n\n#### Soft deletion\n\nA 'soft deletion' is when the point isn't deleted from OSM but retagged so that it'll won't how up in the mapcomplete theme anymore.\nThis makes it look like it was deleted, without doing damage. A fixme will be added to the point.\n\nNote that a soft deletion is _only_ possible if these tags are provided by the theme creator, as they'll be different for every theme\n\n#### No-delete options\n\nIn some cases, the contributor might want to delete something for the wrong reason (e.g. someone who wants to have a path removed \"because the path is on their private property\").\nHowever, the path exists in reality and should thus be on OSM - otherwise the next contributor will pass by and notice \"hey, there is a path missing here! Let me redraw it in OSM!)\n\nThe correct approach is to retag the feature in such a way that it is semantically correct *and* that it doesn't show up on the theme anymore.\nA no-delete option is offered as 'reason to delete it', but secretly retags.", + "anyOf": [ + { + "$ref": "#/definitions/DeleteConfigJson" + }, + { + "type": "boolean" + } + ] + }, + "allowMove": { + "description": "Indicates if a point can be moved and configures the modalities.\n\nA feature can be moved by MapComplete if:\n\n- It is a point\n- The point is _not_ part of a way or a a relation.\n\nOff by default. Can be enabled by setting this flag or by configuring.", + "anyOf": [ + { + "$ref": "#/definitions/default_2" + }, + { + "type": "boolean" + } + ] + }, + "allowSplit": { + "description": "IF set, a 'split this road' button is shown", + "type": "boolean" + }, + "units": { + "description": "In some cases, a value is represented in a certain unit (such as meters for heigt/distance/..., km/h for speed, ...)\n\nSometimes, multiple denominations are possible (e.g. km/h vs mile/h; megawatt vs kilowatt vs gigawatt for power generators, ...)\n\nThis brings in some troubles, as there are multiple ways to write it (no denomitation, 'm' vs 'meter' 'metre', ...)\n\nNot only do we want to write consistent data to OSM, we also want to present this consistently to the user.\nThis is handled by defining units.\n\n# Rendering\n\nTo render a value with long (human) denomination, use {canonical(key)}\n\n# Usage\n\nFirst of all, you define which keys have units applied, for example:\n\n```\nunits: [\n appliesTo: [\"maxspeed\", \"maxspeed:hgv\", \"maxspeed:bus\"]\n applicableUnits: [\n ...\n ]\n]\n```\n\nApplicableUnits defines which is the canonical extension, how it is presented to the user, ...:\n\n```\napplicableUnits: [\n{\n canonicalDenomination: \"km/h\",\n alternativeDenomination: [\"km/u\", \"kmh\", \"kph\"]\n default: true,\n human: {\n en: \"kilometer/hour\",\n nl: \"kilometer/uur\"\n },\n humanShort: {\n en: \"km/h\",\n nl: \"km/u\"\n }\n},\n{\n canoncialDenomination: \"mph\",\n ... similar for miles an hour ...\n}\n]\n```\n\n\nIf this is defined, then every key which the denominations apply to (`maxspeed`, `maxspeed:hgv` and `maxspeed:bus`) will be rewritten at the metatagging stage:\nevery value will be parsed and the canonical extension will be added add presented to the other parts of the code.\n\nAlso, if a freeform text field is used, an extra dropdown with applicable denominations will be given", + "type": "array", + "items": { + "$ref": "#/definitions/default_1" + } + } + }, + "required": [ + "id", + "mapRendering", + "source" + ], + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + }, + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" } - } }, "required": [ - "renderings", - "rewrite" + "canonicalDenomination" ] - }, - { - "type": "string" - } - ] - } - }, - "filter": { - "description": "All the extra questions for filtering", - "type": "array", - "items": { - "$ref": "#/definitions/default" - } - }, - "deletion": { - "description": "This block defines under what circumstances the delete dialog is shown for objects of this layer.\nIf set, a dialog is shown to the user to (soft) delete the point.\nThe dialog is built to be user friendly and to prevent mistakes.\nIf deletion is not possible, the dialog will hide itself and show the reason of non-deletability instead.\n\nTo configure, the following values are possible:\n\n- false: never ever show the delete button\n- true: show the default delete button\n- undefined: use the mapcomplete default to show deletion or not. Currently, this is the same as 'false' but this will change in the future\n- or: a hash with options (see below)\n\n The delete dialog\n =================\n\n\n\n#### Hard deletion if enough experience\n\nA feature can only be deleted from OpenStreetMap by mapcomplete if:\n\n- It is a node\n- No ways or relations use the node\n- The logged-in user has enough experience OR the user is the only one to have edited the point previously\n- The logged-in user has no unread messages (or has a ton of experience)\n- The user did not select one of the 'non-delete-options' (see below)\n\nIn all other cases, a 'soft deletion' is used.\n\n#### Soft deletion\n\nA 'soft deletion' is when the point isn't deleted from OSM but retagged so that it'll won't how up in the mapcomplete theme anymore.\nThis makes it look like it was deleted, without doing damage. A fixme will be added to the point.\n\nNote that a soft deletion is _only_ possible if these tags are provided by the theme creator, as they'll be different for every theme\n\n#### No-delete options\n\nIn some cases, the contributor might want to delete something for the wrong reason (e.g. someone who wants to have a path removed \"because the path is on their private property\").\nHowever, the path exists in reality and should thus be on OSM - otherwise the next contributor will pass by and notice \"hey, there is a path missing here! Let me redraw it in OSM!)\n\nThe correct approach is to retag the feature in such a way that it is semantically correct *and* that it doesn't show up on the theme anymore.\nA no-delete option is offered as 'reason to delete it', but secretly retags.", - "anyOf": [ - { - "$ref": "#/definitions/DeleteConfigJson" }, - { - "type": "boolean" - } - ] - }, - "allowMove": { - "description": "Indicates if a point can be moved and configures the modalities.\n\nA feature can be moved by MapComplete if:\n\n- It is a point\n- The point is _not_ part of a way or a a relation.\n\nOff by default. Can be enabled by setting this flag or by configuring.", - "anyOf": [ - { - "$ref": "#/definitions/default_2" + "TagRenderingConfigJson": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", + "type": "string" + }, + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" + }, + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" + ] + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] + } + } + } }, - { - "type": "boolean" - } - ] - }, - "allowSplit": { - "description": "IF set, a 'split this road' button is shown", - "type": "boolean" - }, - "units": { - "description": "In some cases, a value is represented in a certain unit (such as meters for heigt/distance/..., km/h for speed, ...)\n\nSometimes, multiple denominations are possible (e.g. km/h vs mile/h; megawatt vs kilowatt vs gigawatt for power generators, ...)\n\nThis brings in some troubles, as there are multiple ways to write it (no denomitation, 'm' vs 'meter' 'metre', ...)\n\nNot only do we want to write consistent data to OSM, we also want to present this consistently to the user.\nThis is handled by defining units.\n\n# Rendering\n\nTo render a value with long (human) denomination, use {canonical(key)}\n\n# Usage\n\nFirst of all, you define which keys have units applied, for example:\n\n```\nunits: [\n appliesTo: [\"maxspeed\", \"maxspeed:hgv\", \"maxspeed:bus\"]\n applicableUnits: [\n ...\n ]\n]\n```\n\nApplicableUnits defines which is the canonical extension, how it is presented to the user, ...:\n\n```\napplicableUnits: [\n{\n canonicalDenomination: \"km/h\",\n alternativeDenomination: [\"km/u\", \"kmh\", \"kph\"]\n default: true,\n human: {\n en: \"kilometer/hour\",\n nl: \"kilometer/uur\"\n },\n humanShort: {\n en: \"km/h\",\n nl: \"km/u\"\n }\n},\n{\n canoncialDenomination: \"mph\",\n ... similar for miles an hour ...\n}\n]\n```\n\n\nIf this is defined, then every key which the denominations apply to (`maxspeed`, `maxspeed:hgv` and `maxspeed:bus`) will be rewritten at the metatagging stage:\nevery value will be parsed and the canonical extension will be added add presented to the other parts of the code.\n\nAlso, if a freeform text field is used, an extra dropdown with applicable denominations will be given", - "type": "array", - "items": { - "$ref": "#/definitions/default_1" - } - } - }, - "required": [ - "id", - "mapRendering", - "source" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } + "default_3": { + "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", + "type": "object", + "properties": { + "location": { + "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", + "type": "array", + "items": { + "type": "string" + } + }, + "icon": { + "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "iconBadges": { + "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "if", + "then" + ] + } + }, + "iconSize": { + "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "rotation": { + "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "label": { + "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "location" ] - } }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - } - } - }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" - }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" + "default_4": { + "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", + "type": "object", + "properties": { + "color": { + "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "width": { + "description": "The stroke-width for way-elements", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": [ + "string", + "number" + ] + } + ] + }, + "dashArray": { + "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "lineCap": { + "description": "The form at the end of a line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "fill": { + "description": "Wehter or not to fill polygons", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "enum": [ + "no", + "yes" + ], + "type": "string" + } + ] + }, + "fillColor": { + "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "offset": { + "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "number" + } + ] + } + } }, "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" - } - }, - "required": [ - "canonicalDenomination" - ] - }, - "TagRenderingConfigJson": { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { - "type": "string" - } - }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" - }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" - }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { "type": "object", "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { + "id": { + "description": "An id/name for this filter, used to set the URL parameters", "type": "string" - } - ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } - ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "if", - "then" - ] - } - } - } - }, - "default_3": { - "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", - "type": "object", - "properties": { - "location": { - "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", - "type": "array", - "items": { - "type": "string" - } - }, - "icon": { - "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "iconBadges": { - "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "if", - "then" - ] - } - }, - "iconSize": { - "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "rotation": { - "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "label": { - "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "location" - ] - }, - "default_4": { - "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", - "type": "object", - "properties": { - "color": { - "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "width": { - "description": "The stroke-width for way-elements", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": [ - "string", - "number" - ] - } - ] - }, - "dashArray": { - "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "lineCap": { - "description": "The form at the end of a line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "fill": { - "description": "Wehter or not to fill polygons", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "enum": [ - "no", - "yes" - ], - "type": "string" - } - ] - }, - "fillColor": { - "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "offset": { - "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "number" - } - ] - } - } - }, - "default": { - "type": "object", - "properties": { - "id": { - "description": "An id/name for this filter, used to set the URL parameters", - "type": "string" - }, - "options": { - "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", - "type": "array", - "items": { - "type": "object", - "properties": { - "question": {}, - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "fields": { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "type": { - "type": "string" + }, + "options": { + "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", + "type": "array", + "items": { + "type": "object", + "properties": { + "question": {}, + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "fields": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "name" + ] + } + } + }, + "required": [ + "question" + ] } - }, - "required": [ - "name" - ] } - } }, "required": [ - "question" + "id", + "options" ] - } - } - }, - "required": [ - "id", - "options" - ] - }, - "DeleteConfigJson": { - "type": "object", - "properties": { - "extraDeleteReasons": { - "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", - "type": "array", - "items": { + }, + "DeleteConfigJson": { "type": "object", "properties": { - "explanation": { - "description": "The text that will be shown to the user - translatable" - }, - "changesetMessage": { - "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", - "type": "string" - } - }, - "required": [ - "changesetMessage", - "explanation" - ] - } - }, - "nonDeleteMappings": { - "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - "then": {} - }, - "required": [ - "if", - "then" - ] - } - }, - "softDeletionTags": { - "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" + "extraDeleteReasons": { + "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", + "type": "array", + "items": { + "type": "object", + "properties": { + "explanation": { + "description": "The text that will be shown to the user - translatable" + }, + "changesetMessage": { + "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", + "type": "string" + } + }, + "required": [ + "changesetMessage", + "explanation" + ] + } + }, + "nonDeleteMappings": { + "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + "then": {} + }, + "required": [ + "if", + "then" + ] + } + }, + "softDeletionTags": { + "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "neededChangesets": { + "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", + "type": "number" + } } - ] }, - "neededChangesets": { - "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", - "type": "number" + "default_2": { + "type": "object", + "properties": { + "enableImproveAccuracy": { + "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", + "type": "boolean" + }, + "enableRelocation": { + "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", + "type": "boolean" + } + } + }, + "default_1": { + "type": "object", + "properties": { + "appliesToKey": { + "description": "Every key from this list will be normalized", + "type": "array", + "items": { + "type": "string" + } + }, + "eraseInvalidValues": { + "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", + "type": "boolean" + }, + "applicableUnits": { + "description": "The possible denominations", + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableUnitJson" + } + } + }, + "required": [ + "applicableUnits", + "appliesToKey" + ] } - } }, - "default_2": { - "type": "object", - "properties": { - "enableImproveAccuracy": { - "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", - "type": "boolean" - }, - "enableRelocation": { - "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", - "type": "boolean" - } - } - }, - "default_1": { - "type": "object", - "properties": { - "appliesToKey": { - "description": "Every key from this list will be normalized", - "type": "array", - "items": { - "type": "string" - } - }, - "eraseInvalidValues": { - "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", - "type": "boolean" - }, - "applicableUnits": { - "description": "The possible denominations", - "type": "array", - "items": { - "$ref": "#/definitions/ApplicableUnitJson" - } - } - }, - "required": [ - "applicableUnits", - "appliesToKey" - ] - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/LayoutConfigJsonJSC.ts b/Docs/Schemas/LayoutConfigJsonJSC.ts index 3c75a526e0..2dfadaaaa9 100644 --- a/Docs/Schemas/LayoutConfigJsonJSC.ts +++ b/Docs/Schemas/LayoutConfigJsonJSC.ts @@ -1,1240 +1,1240 @@ export default { - "description": "Defines the entire theme.\n\nA theme is the collection of the layers that are shown; the intro text, the icon, ...\nIt more or less defines the entire experience.\n\nMost of the fields defined here are metadata about the theme, such as its name, description, supported languages, default starting location, ...\n\nThe main chunk of the json will however be the 'layers'-array, where the details of your layers are.\n\nGeneral remark: a type (string | any) indicates either a fixed or a translatable string.", - "type": "object", - "properties": { - "id": { - "description": "The id of this layout.\n\nThis is used as hashtag in the changeset message, which will read something like \"Adding data with #mapcomplete for theme #\"\nMake sure it is something decent and descriptive, it should be a simple, lowercase string.\n\nOn official themes, it'll become the name of the page, e.g.\n'cyclestreets' which become 'cyclestreets.html'", - "type": "string" - }, - "credits": { - "description": "Who helped to create this theme and should be attributed?", - "type": "string" - }, - "maintainer": { - "description": "Who does maintian this preset?", - "type": "string" - }, - "version": { - "description": "A version number, either semantically or by date.\nShould be sortable, where the higher value is the later version", - "type": "string" - }, - "mustHaveLanguage": { - "description": "Only used in 'generateLayerOverview': if present, every translation will be checked to make sure it is fully translated.\n\nThis must be a list of two-letter, lowercase codes which identifies the language, e.g. \"en\", \"nl\", ...", - "type": "array", - "items": { - "type": "string" - } - }, - "title": { - "description": "The title, as shown in the welcome message and the more-screen." - }, - "shortDescription": { - "description": "A short description, showed as social description and in the 'more theme'-buttons.\nNote that if this one is not defined, the first sentence of 'description' is used" - }, - "description": { - "description": "The description, as shown in the welcome message and the more-screen" - }, - "descriptionTail": { - "description": "A part of the description, shown under the login-button." - }, - "icon": { - "description": "The icon representing this theme.\nUsed as logo in the more-screen and (for official themes) as favicon, webmanifest logo, ...\nEither a URL or a base64 encoded value (which should include 'data:image/svg+xml;base64)", - "type": "string" - }, - "socialImage": { - "description": "Link to a 'social image' which is included as og:image-tag on official themes.\nUseful to share the theme on social media.\nSee https://www.h3xed.com/web-and-internet/how-to-use-og-image-meta-tag-facebook-reddit for more information", - "type": "string" - }, - "startZoom": { - "description": "Default location and zoom to start.\nNote that this is barely used. Once the user has visited mapcomplete at least once, the previous location of the user will be used", - "type": "number" - }, - "startLat": { - "type": "number" - }, - "startLon": { - "type": "number" - }, - "widenFactor": { - "description": "When a query is run, the data within bounds of the visible map is loaded.\nHowever, users tend to pan and zoom a lot. It is pretty annoying if every single pan means a reloading of the data.\nFor this, the bounds are widened in order to make a small pan still within bounds of the loaded data.\n\nIF widenfactor is 1, this feature is disabled. A recommended value is between 1 and 3", - "type": "number" - }, - "overpassMaxZoom": { - "description": "At low zoom levels, overpass is used to query features.\nAt high zoom level, the OSM api is used to fetch one or more BBOX aligning with a slippy tile.\nThe overpassMaxZoom controls the flipoverpoint: if the zoom is this or lower, overpass is used.", - "type": "number" - }, - "osmApiTileSize": { - "description": "When the OSM-api is used to fetch features, it does so in a tiled fashion.\nThese tiles are using a ceratin zoom level, that can be controlled here\nDefault: overpassMaxZoom + 1", - "type": "number" - }, - "overrideAll": { - "description": "An override applied on all layers of the theme.\n\nE.g.: if there are two layers defined:\n```\n\"layers\":[\n {\"title\": ..., \"tagRenderings\": [...], \"osmSource\":{\"tags\": ...}},\n {\"title\", ..., \"tagRenderings\", [...], \"osmSource\":{\"tags\" ...}}\n]\n```\n\nand overrideAll is specified:\n```\n\"overrideAll\": {\n \"osmSource\":{\"geoJsonSource\":\"xyz\"}\n}\nthen the result will be that all the layers will have these properties applied and result in:\n\"layers\":[\n {\"title\": ..., \"tagRenderings\": [...], \"osmSource\":{\"tags\": ..., \"geoJsonSource\":\"xyz\"}},\n {\"title\", ..., \"tagRenderings\", [...], \"osmSource\":{\"tags\" ..., \"geoJsonSource\":\"xyz\"}}\n]\n```\n\nIf the overrideAll contains a list where the keys starts with a plus, the values will be appended (instead of discarding the old list), for example\n\n\"overrideAll\": {\n \"+tagRenderings\": [ { ... some tagrendering ... }]\n}\n\nIn the above scenario, `sometagrendering` will be added at the beginning of the tagrenderings of every layer" - }, - "defaultBackgroundId": { - "description": "The id of the default background. BY default: vanilla OSM", - "type": "string" - }, - "tileLayerSources": { - "description": "Define some (overlay) slippy map tilesources", - "type": "array", - "items": { - "$ref": "#/definitions/default_5" - } - }, - "layers": { - "description": "The layers to display.\n\nEvery layer contains a description of which feature to display - the overpassTags which are queried.\nInstead of running one query for every layer, the query is fused.\n\nAfterwards, every layer is given the list of features.\nEvery layer takes away the features that match with them*, and give the leftovers to the next layers.\n\nThis implies that the _order_ of the layers is important in the case of features with the same tags;\nas the later layers might never receive their feature.\n\n*layers can also remove 'leftover'-features if the leftovers overlap with a feature in the layer itself\n\nNote that builtin layers can be reused. Either put in the name of the layer to reuse, or use {builtin: \"layername\", override: ...}\n\nThe 'override'-object will be copied over the original values of the layer, which allows to change certain aspects of the layer\n\nFor example: If you would like to use layer nature reserves, but only from a specific operator (eg. Natuurpunt) you would use the following in your theme:\n\n```\n\"layer\": {\n \"builtin\": \"nature_reserve\",\n \"override\": {\"source\": \n {\"osmTags\": {\n \"+and\":[\"operator=Natuurpunt\"]\n }\n }\n }\n}\n```\n\nIt's also possible to load multiple layers at once, for example, if you would like for both drinking water and benches to start at the zoomlevel at 12, you would use the following:\n\n```\n\"layer\": {\n \"builtin\": [\"benches\", \"drinking_water\"],\n \"override\": {\"minzoom\": 12}\n}\n```", - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/LayerConfigJson" - }, - { - "type": "object", - "properties": { - "builtin": { - "anyOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "override": {} - }, - "required": [ - "builtin", - "override" - ] - }, - { + "description": "Defines the entire theme.\n\nA theme is the collection of the layers that are shown; the intro text, the icon, ...\nIt more or less defines the entire experience.\n\nMost of the fields defined here are metadata about the theme, such as its name, description, supported languages, default starting location, ...\n\nThe main chunk of the json will however be the 'layers'-array, where the details of your layers are.\n\nGeneral remark: a type (string | any) indicates either a fixed or a translatable string.", + "type": "object", + "properties": { + "id": { + "description": "The id of this layout.\n\nThis is used as hashtag in the changeset message, which will read something like \"Adding data with #mapcomplete for theme #\"\nMake sure it is something decent and descriptive, it should be a simple, lowercase string.\n\nOn official themes, it'll become the name of the page, e.g.\n'cyclestreets' which become 'cyclestreets.html'", "type": "string" - } - ] - } - }, - "clustering": { - "description": "If defined, data will be clustered.\nDefaults to {maxZoom: 16, minNeeded: 500}", - "anyOf": [ - { - "type": "object", - "properties": { - "maxZoom": { - "description": "All zoom levels above 'maxzoom' are not clustered anymore.\nDefaults to 18", - "type": "number" - }, - "minNeededElements": { - "description": "The number of elements per tile needed to start clustering\nIf clustering is defined, defaults to 25", - "type": "number" - } - } }, - { - "enum": [ - false - ], - "type": "boolean" - } - ] - }, - "customCss": { - "description": "The URL of a custom CSS stylesheet to modify the layout", - "type": "string" - }, - "hideFromOverview": { - "description": "If set to true, this layout will not be shown in the overview with more themes", - "type": "boolean" - }, - "lockLocation": { - "description": "If set to true, the basemap will not scroll outside of the area visible on initial zoom.\nIf set to [[lat0, lon0], [lat1, lon1]], the map will not scroll outside of those bounds.\nOff by default, which will enable panning to the entire world", - "anyOf": [ - { - "type": "array", - "items": [ - { - "type": "array", - "items": [ - { - "type": "number" - }, - { - "type": "number" - } - ], - "minItems": 2, - "maxItems": 2 - }, - { - "type": "array", - "items": [ - { - "type": "number" - }, - { - "type": "number" - } - ], - "minItems": 2, - "maxItems": 2 - } - ], - "minItems": 2, - "maxItems": 2 + "credits": { + "description": "Who helped to create this theme and should be attributed?", + "type": "string" }, - { - "type": "array", - "items": { + "maintainer": { + "description": "Who does maintian this preset?", + "type": "string" + }, + "version": { + "description": "A version number, either semantically or by date.\nShould be sortable, where the higher value is the later version", + "type": "string" + }, + "mustHaveLanguage": { + "description": "Only used in 'generateLayerOverview': if present, every translation will be checked to make sure it is fully translated.\n\nThis must be a list of two-letter, lowercase codes which identifies the language, e.g. \"en\", \"nl\", ...", "type": "array", "items": { - "type": "number" - } - } - }, - { - "type": "boolean" - } - ] - }, - "enableUserBadge": { - "type": "boolean" - }, - "enableShareScreen": { - "type": "boolean" - }, - "enableMoreQuests": { - "type": "boolean" - }, - "enableLayers": { - "type": "boolean" - }, - "enableSearch": { - "type": "boolean" - }, - "enableAddNewPoints": { - "type": "boolean" - }, - "enableGeolocation": { - "type": "boolean" - }, - "enableBackgroundLayerSelection": { - "type": "boolean" - }, - "enableShowAllQuestions": { - "type": "boolean" - }, - "enableDownload": { - "type": "boolean" - }, - "enablePdfDownload": { - "type": "boolean" - }, - "enableIframePopout": { - "type": "boolean" - }, - "overpassUrl": { - "description": "Set one or more overpass URLs to use for this theme..", - "anyOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "overpassTimeout": { - "description": "Set a different timeout for overpass queries - in seconds. Default: 30s", - "type": "number" - } - }, - "required": [ - "description", - "icon", - "id", - "layers", - "maintainer", - "startLat", - "startLon", - "startZoom", - "title", - "version" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - } - } - }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" - }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" - }, - "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" - } - }, - "required": [ - "canonicalDenomination" - ] - }, - "TagRenderingConfigJson": { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" } - ] - }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { - "type": "string" - } - }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" - }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" - }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } - ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "if", - "then" - ] - } - } - } - }, - "default_3": { - "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", - "type": "object", - "properties": { - "location": { - "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", - "type": "array", - "items": { - "type": "string" - } - }, - "icon": { - "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "iconBadges": { - "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "if", - "then" - ] - } - }, - "iconSize": { - "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "rotation": { - "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "label": { - "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "location" - ] - }, - "default_4": { - "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", - "type": "object", - "properties": { - "color": { - "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "width": { - "description": "The stroke-width for way-elements", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": [ - "string", - "number" - ] - } - ] - }, - "dashArray": { - "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "lineCap": { - "description": "The form at the end of a line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "fill": { - "description": "Wehter or not to fill polygons", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "enum": [ - "no", - "yes" - ], - "type": "string" - } - ] - }, - "fillColor": { - "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "offset": { - "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "number" - } - ] - } - } - }, - "default": { - "type": "object", - "properties": { - "id": { - "description": "An id/name for this filter, used to set the URL parameters", - "type": "string" - }, - "options": { - "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", - "type": "array", - "items": { - "type": "object", - "properties": { - "question": {}, - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "fields": { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "name" - ] - } - } - }, - "required": [ - "question" - ] - } - } - }, - "required": [ - "id", - "options" - ] - }, - "DeleteConfigJson": { - "type": "object", - "properties": { - "extraDeleteReasons": { - "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", - "type": "array", - "items": { - "type": "object", - "properties": { - "explanation": { - "description": "The text that will be shown to the user - translatable" - }, - "changesetMessage": { - "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", - "type": "string" - } - }, - "required": [ - "changesetMessage", - "explanation" - ] - } - }, - "nonDeleteMappings": { - "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - "then": {} - }, - "required": [ - "if", - "then" - ] - } - }, - "softDeletionTags": { - "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "neededChangesets": { - "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", - "type": "number" - } - } - }, - "default_2": { - "type": "object", - "properties": { - "enableImproveAccuracy": { - "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", - "type": "boolean" - }, - "enableRelocation": { - "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", - "type": "boolean" - } - } - }, - "default_1": { - "type": "object", - "properties": { - "appliesToKey": { - "description": "Every key from this list will be normalized", - "type": "array", - "items": { - "type": "string" - } - }, - "eraseInvalidValues": { - "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", - "type": "boolean" - }, - "applicableUnits": { - "description": "The possible denominations", - "type": "array", - "items": { - "$ref": "#/definitions/ApplicableUnitJson" - } - } - }, - "required": [ - "applicableUnits", - "appliesToKey" - ] - }, - "default_5": { - "description": "Configuration for a tilesource config", - "type": "object", - "properties": { - "id": { - "description": "Id of this overlay, used in the URL-parameters to set the state", - "type": "string" - }, - "source": { - "description": "The path, where {x}, {y} and {z} will be substituted", - "type": "string" - }, - "isOverlay": { - "description": "Wether or not this is an overlay. Default: true", - "type": "boolean" - }, - "name": { - "description": "How this will be shown in the selection menu.\nMake undefined if this may not be toggled" - }, - "minZoom": { - "description": "Only visible at this or a higher zoom level", - "type": "number" - }, - "maxZoom": { - "description": "Only visible at this or a lower zoom level", - "type": "number" - }, - "defaultState": { - "description": "The default state, set to false to hide by default", - "type": "boolean" - } - }, - "required": [ - "defaultState", - "id", - "source" - ] - }, - "LayerConfigJson": { - "description": "Configuration for a single layer", - "type": "object", - "properties": { - "id": { - "description": "The id of this layer.\nThis should be a simple, lowercase, human readable string that is used to identify the layer.", - "type": "string" - }, - "name": { - "description": "The name of this layer\nUsed in the layer control panel and the 'Personal theme'.\n\nIf not given, will be hidden (and thus not toggable) in the layer control" - }, - "description": { - "description": "A description for this layer.\nShown in the layer selections and in the personel theme" - }, - "source": { - "description": "This determines where the data for the layer is fetched.\nThere are some options:\n\n# Query OSM directly\nsource: {osmTags: \"key=value\"}\n will fetch all objects with given tags from OSM.\n Currently, this will create a query to overpass and fetch the data - in the future this might fetch from the OSM API\n\n# Query OSM Via the overpass API with a custom script\nsource: {overpassScript: \"\"} when you want to do special things. _This should be really rare_.\n This means that the data will be pulled from overpass with this script, and will ignore the osmTags for the query\n However, for the rest of the pipeline, the OsmTags will _still_ be used. This is important to enable layers etc...\n\n\n# A single geojson-file\nsource: {geoJson: \"https://my.source.net/some-geo-data.geojson\"}\n fetches a geojson from a third party source\n\n# A tiled geojson source\nsource: {geoJson: \"https://my.source.net/some-tile-geojson-{layer}-{z}-{x}-{y}.geojson\", geoJsonZoomLevel: 14}\n to use a tiled geojson source. The web server must offer multiple geojsons. {z}, {x} and {y} are substituted by the location; {layer} is substituted with the id of the loaded layer\n\nSome API's use a BBOX instead of a tile, this can be used by specifying {y_min}, {y_max}, {x_min} and {x_max}\nSome API's use a mercator-projection (EPSG:900913) instead of WGS84. Set the flag `mercatorCrs: true` in the source for this\n\nNote that both geojson-options might set a flag 'isOsmCache' indicating that the data originally comes from OSM too\n\n\nNOTE: the previous format was 'overpassTags: AndOrTagConfigJson | string', which is interpreted as a shorthand for source: {osmTags: \"key=value\"}\n While still supported, this is considered deprecated", - "anyOf": [ - { - "allOf": [ - { - "type": "object", - "properties": { - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "overpassScript": { - "type": "string" - } - }, - "required": [ - "osmTags" - ] - }, - { - "type": "object", - "properties": { - "maxCacheAge": { - "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", - "type": "number" - } - } - } - ] - }, - { - "allOf": [ - { - "type": "object", - "properties": { - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "geoJson": { - "type": "string" - }, - "geoJsonZoomLevel": { - "type": "number" - }, - "isOsmCache": { - "type": "boolean" - }, - "mercatorCrs": { - "type": "boolean" - } - }, - "required": [ - "geoJson", - "osmTags" - ] - }, - { - "type": "object", - "properties": { - "maxCacheAge": { - "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", - "type": "number" - } - } - } - ] - } - ] - }, - "calculatedTags": { - "description": "A list of extra tags to calculate, specified as \"keyToAssignTo=javascript-expression\".\nThere are a few extra functions available. Refer to Docs/CalculatedTags.md for more information\nThe functions will be run in order, e.g.\n[\n \"_max_overlap_m2=Math.max(...feat.overlapsWith(\"someOtherLayer\").map(o => o.overlap))\n \"_max_overlap_ratio=Number(feat._max_overlap_m2)/feat.area\n]\n\nThe specified tags are evaluated lazily. E.g. if a calculated tag is only used in the popup (e.g. the number of nearby features),\nthe expensive calculation will only be performed then for that feature. This avoids clogging up the contributors PC when all features are loaded.\n\nIf a tag has to be evaluated strictly, use ':=' instead:\n\n[\n\"_some_key:=some_javascript_expression\"\n]", - "type": "array", - "items": { - "type": "string" - } - }, - "doNotDownload": { - "description": "If set, this layer will not query overpass; but it'll still match the tags above which are by chance returned by other layers.\nWorks well together with 'passAllFeatures', to add decoration", - "type": "boolean" - }, - "isShown": { - "description": "This tag rendering should either be 'yes' or 'no'. If 'no' is returned, then the feature will be hidden from view.\nThis is useful to hide certain features from view.\n\nImportant: hiding features does not work dynamically, but is only calculated when the data is first renders.\nThis implies that it is not possible to hide a feature after a tagging change\n\nThe default value is 'yes'", - "$ref": "#/definitions/TagRenderingConfigJson" - }, - "minzoom": { - "description": "The minimum needed zoomlevel required before loading of the data start\nDefault: 0", - "type": "number" - }, - "shownByDefault": { - "description": "Indicates if this layer is shown by default;\ncan be used to hide a layer from start, or to load the layer but only to show it where appropriate (e.g. for snapping to it)", - "type": "boolean" - }, - "minzoomVisible": { - "description": "The zoom level at which point the data is hidden again\nDefault: 100 (thus: always visible", - "type": "number" }, "title": { - "description": "The title shown in a popup for elements of this layer.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" + "description": "The title, as shown in the welcome message and the more-screen." + }, + "shortDescription": { + "description": "A short description, showed as social description and in the 'more theme'-buttons.\nNote that if this one is not defined, the first sentence of 'description' is used" + }, + "description": { + "description": "The description, as shown in the welcome message and the more-screen" + }, + "descriptionTail": { + "description": "A part of the description, shown under the login-button." + }, + "icon": { + "description": "The icon representing this theme.\nUsed as logo in the more-screen and (for official themes) as favicon, webmanifest logo, ...\nEither a URL or a base64 encoded value (which should include 'data:image/svg+xml;base64)", + "type": "string" + }, + "socialImage": { + "description": "Link to a 'social image' which is included as og:image-tag on official themes.\nUseful to share the theme on social media.\nSee https://www.h3xed.com/web-and-internet/how-to-use-og-image-meta-tag-facebook-reddit for more information", + "type": "string" + }, + "startZoom": { + "description": "Default location and zoom to start.\nNote that this is barely used. Once the user has visited mapcomplete at least once, the previous location of the user will be used", + "type": "number" + }, + "startLat": { + "type": "number" + }, + "startLon": { + "type": "number" + }, + "widenFactor": { + "description": "When a query is run, the data within bounds of the visible map is loaded.\nHowever, users tend to pan and zoom a lot. It is pretty annoying if every single pan means a reloading of the data.\nFor this, the bounds are widened in order to make a small pan still within bounds of the loaded data.\n\nIF widenfactor is 1, this feature is disabled. A recommended value is between 1 and 3", + "type": "number" + }, + "overpassMaxZoom": { + "description": "At low zoom levels, overpass is used to query features.\nAt high zoom level, the OSM api is used to fetch one or more BBOX aligning with a slippy tile.\nThe overpassMaxZoom controls the flipoverpoint: if the zoom is this or lower, overpass is used.", + "type": "number" + }, + "osmApiTileSize": { + "description": "When the OSM-api is used to fetch features, it does so in a tiled fashion.\nThese tiles are using a ceratin zoom level, that can be controlled here\nDefault: overpassMaxZoom + 1", + "type": "number" + }, + "overrideAll": { + "description": "An override applied on all layers of the theme.\n\nE.g.: if there are two layers defined:\n```\n\"layers\":[\n {\"title\": ..., \"tagRenderings\": [...], \"osmSource\":{\"tags\": ...}},\n {\"title\", ..., \"tagRenderings\", [...], \"osmSource\":{\"tags\" ...}}\n]\n```\n\nand overrideAll is specified:\n```\n\"overrideAll\": {\n \"osmSource\":{\"geoJsonSource\":\"xyz\"}\n}\nthen the result will be that all the layers will have these properties applied and result in:\n\"layers\":[\n {\"title\": ..., \"tagRenderings\": [...], \"osmSource\":{\"tags\": ..., \"geoJsonSource\":\"xyz\"}},\n {\"title\", ..., \"tagRenderings\", [...], \"osmSource\":{\"tags\" ..., \"geoJsonSource\":\"xyz\"}}\n]\n```\n\nIf the overrideAll contains a list where the keys starts with a plus, the values will be appended (instead of discarding the old list), for example\n\n\"overrideAll\": {\n \"+tagRenderings\": [ { ... some tagrendering ... }]\n}\n\nIn the above scenario, `sometagrendering` will be added at the beginning of the tagrenderings of every layer" + }, + "defaultBackgroundId": { + "description": "The id of the default background. BY default: vanilla OSM", + "type": "string" + }, + "tileLayerSources": { + "description": "Define some (overlay) slippy map tilesources", + "type": "array", + "items": { + "$ref": "#/definitions/default_5" } - ] }, - "titleIcons": { - "description": "Small icons shown next to the title.\nIf not specified, the OsmLink and wikipedia links will be used by default.\nUse an empty array to hide them.\nNote that \"defaults\" will insert all the default titleIcons (which are added automatically)", - "anyOf": [ - { - "type": "array", - "items": { + "layers": { + "description": "The layers to display.\n\nEvery layer contains a description of which feature to display - the overpassTags which are queried.\nInstead of running one query for every layer, the query is fused.\n\nAfterwards, every layer is given the list of features.\nEvery layer takes away the features that match with them*, and give the leftovers to the next layers.\n\nThis implies that the _order_ of the layers is important in the case of features with the same tags;\nas the later layers might never receive their feature.\n\n*layers can also remove 'leftover'-features if the leftovers overlap with a feature in the layer itself\n\nNote that builtin layers can be reused. Either put in the name of the layer to reuse, or use {builtin: \"layername\", override: ...}\n\nThe 'override'-object will be copied over the original values of the layer, which allows to change certain aspects of the layer\n\nFor example: If you would like to use layer nature reserves, but only from a specific operator (eg. Natuurpunt) you would use the following in your theme:\n\n```\n\"layer\": {\n \"builtin\": \"nature_reserve\",\n \"override\": {\"source\": \n {\"osmTags\": {\n \"+and\":[\"operator=Natuurpunt\"]\n }\n }\n }\n}\n```\n\nIt's also possible to load multiple layers at once, for example, if you would like for both drinking water and benches to start at the zoomlevel at 12, you would use the following:\n\n```\n\"layer\": {\n \"builtin\": [\"benches\", \"drinking_water\"],\n \"override\": {\"minzoom\": 12}\n}\n```", + "type": "array", + "items": { "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - { - "type": "array", - "items": [ - { - "type": "string", - "enum": [ - "defaults" - ] - } - ], - "minItems": 1, - "maxItems": 1 - } - ] - }, - "mapRendering": { - "anyOf": [ - { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/default_3" - }, - { - "$ref": "#/definitions/default_4" - } - ] - } - }, - { - "type": "null" - } - ] - }, - "passAllFeatures": { - "description": "If set, this layer will pass all the features it receives onto the next layer.\nThis is ideal for decoration, e.g. directionss on cameras", - "type": "boolean" - }, - "presets": { - "description": "Presets for this layer.\nA preset shows up when clicking the map on a without data (or when right-clicking/long-pressing);\nit will prompt the user to add a new point.\n\nThe most important aspect are the tags, which define which tags the new point will have;\nThe title is shown in the dialog, along with the first sentence of the description.\n\nUpon confirmation, the full description is shown beneath the buttons - perfect to add pictures and examples.\n\nNote: the icon of the preset is determined automatically based on the tags and the icon above. Don't worry about that!\nNB: if no presets are defined, the popup to add new points doesn't show up at all", - "type": "array", - "items": { - "type": "object", - "properties": { - "title": { - "description": "The title - shown on the 'add-new'-button." - }, - "tags": { - "description": "The tags to add. It determines the icon too", - "type": "array", - "items": { - "type": "string" - } - }, - "description": { - "description": "The _first sentence_ of the description is shown on the button of the `add` menu.\nThe full description is shown in the confirmation dialog.\n\n(The first sentence is until the first '.'-character in the description)" - }, - "preciseInput": { - "description": "If set, the user will prompted to confirm the location before actually adding the data.\nThis will be with a 'drag crosshair'-method.\n\nIf 'preferredBackgroundCategory' is set, the element will attempt to pick a background layer of that category.", - "anyOf": [ - { - "type": "object", - "properties": { - "preferredBackground": { - "description": "The type of background picture", - "anyOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "snapToLayer": { - "description": "If specified, these layers will be shown to and the new point will be snapped towards it", - "anyOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "maxSnapDistance": { - "description": "If specified, a new point will only be snapped if it is within this range.\nDistance in meter\n\nDefault: 10", - "type": "number" - } + { + "$ref": "#/definitions/LayerConfigJson" }, - "required": [ - "preferredBackground" - ] - }, - { - "enum": [ - true - ], - "type": "boolean" - } - ] - } - }, - "required": [ - "tags", - "title" - ] - } - }, - "tagRenderings": { - "description": "All the tag renderings.\nA tag rendering is a block that either shows the known value or asks a question.\n\nRefer to the class `TagRenderingConfigJson` to see the possibilities.\n\nNote that we can also use a string here - where the string refers to a tag rendering defined in `assets/questions/questions.json`,\nwhere a few very general questions are defined e.g. website, phone number, ...\n\nA special value is 'questions', which indicates the location of the questions box. If not specified, it'll be appended to the bottom of the featureInfobox.\n\nAt last, one can define a group of renderings where parts of all strings will be replaced by multiple other strings.\nThis is mainly create questions for a 'left' and a 'right' side of the road.\nThese will be grouped and questions will be asked together", - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "object", - "properties": { - "builtin": { - "type": "string" - }, - "override": {} - }, - "required": [ - "builtin", - "override" - ] - }, - { - "type": "object", - "properties": { - "rewrite": { - "type": "array", - "items": { - "type": "object", - "properties": { - "sourceString": { - "type": "string" - }, - "into": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "into", - "sourceString" - ] - } - }, - "renderings": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "object", - "properties": { + { + "type": "object", + "properties": { "builtin": { - "type": "string" + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] }, "override": {} - }, - "required": [ + }, + "required": [ "builtin", "override" - ] + ] + }, + { + "type": "string" + } + ] + } + }, + "clustering": { + "description": "If defined, data will be clustered.\nDefaults to {maxZoom: 16, minNeeded: 500}", + "anyOf": [ + { + "type": "object", + "properties": { + "maxZoom": { + "description": "All zoom levels above 'maxzoom' are not clustered anymore.\nDefaults to 18", + "type": "number" + }, + "minNeededElements": { + "description": "The number of elements per tile needed to start clustering\nIf clustering is defined, defaults to 25", + "type": "number" + } + } + }, + { + "enum": [ + false + ], + "type": "boolean" + } + ] + }, + "customCss": { + "description": "The URL of a custom CSS stylesheet to modify the layout", + "type": "string" + }, + "hideFromOverview": { + "description": "If set to true, this layout will not be shown in the overview with more themes", + "type": "boolean" + }, + "lockLocation": { + "description": "If set to true, the basemap will not scroll outside of the area visible on initial zoom.\nIf set to [[lat0, lon0], [lat1, lon1]], the map will not scroll outside of those bounds.\nOff by default, which will enable panning to the entire world", + "anyOf": [ + { + "type": "array", + "items": [ + { + "type": "array", + "items": [ + { + "type": "number" + }, + { + "type": "number" + } + ], + "minItems": 2, + "maxItems": 2 }, { - "type": "string" + "type": "array", + "items": [ + { + "type": "number" + }, + { + "type": "number" + } + ], + "minItems": 2, + "maxItems": 2 } - ] - } - } + ], + "minItems": 2, + "maxItems": 2 }, - "required": [ - "renderings", - "rewrite" - ] - }, - { - "type": "string" - } + { + "type": "array", + "items": { + "type": "array", + "items": { + "type": "number" + } + } + }, + { + "type": "boolean" + } ] - } }, - "filter": { - "description": "All the extra questions for filtering", - "type": "array", - "items": { - "$ref": "#/definitions/default" - } + "enableUserBadge": { + "type": "boolean" }, - "deletion": { - "description": "This block defines under what circumstances the delete dialog is shown for objects of this layer.\nIf set, a dialog is shown to the user to (soft) delete the point.\nThe dialog is built to be user friendly and to prevent mistakes.\nIf deletion is not possible, the dialog will hide itself and show the reason of non-deletability instead.\n\nTo configure, the following values are possible:\n\n- false: never ever show the delete button\n- true: show the default delete button\n- undefined: use the mapcomplete default to show deletion or not. Currently, this is the same as 'false' but this will change in the future\n- or: a hash with options (see below)\n\n The delete dialog\n =================\n\n\n\n#### Hard deletion if enough experience\n\nA feature can only be deleted from OpenStreetMap by mapcomplete if:\n\n- It is a node\n- No ways or relations use the node\n- The logged-in user has enough experience OR the user is the only one to have edited the point previously\n- The logged-in user has no unread messages (or has a ton of experience)\n- The user did not select one of the 'non-delete-options' (see below)\n\nIn all other cases, a 'soft deletion' is used.\n\n#### Soft deletion\n\nA 'soft deletion' is when the point isn't deleted from OSM but retagged so that it'll won't how up in the mapcomplete theme anymore.\nThis makes it look like it was deleted, without doing damage. A fixme will be added to the point.\n\nNote that a soft deletion is _only_ possible if these tags are provided by the theme creator, as they'll be different for every theme\n\n#### No-delete options\n\nIn some cases, the contributor might want to delete something for the wrong reason (e.g. someone who wants to have a path removed \"because the path is on their private property\").\nHowever, the path exists in reality and should thus be on OSM - otherwise the next contributor will pass by and notice \"hey, there is a path missing here! Let me redraw it in OSM!)\n\nThe correct approach is to retag the feature in such a way that it is semantically correct *and* that it doesn't show up on the theme anymore.\nA no-delete option is offered as 'reason to delete it', but secretly retags.", - "anyOf": [ - { - "$ref": "#/definitions/DeleteConfigJson" - }, - { - "type": "boolean" - } - ] + "enableShareScreen": { + "type": "boolean" }, - "allowMove": { - "description": "Indicates if a point can be moved and configures the modalities.\n\nA feature can be moved by MapComplete if:\n\n- It is a point\n- The point is _not_ part of a way or a a relation.\n\nOff by default. Can be enabled by setting this flag or by configuring.", - "anyOf": [ - { - "$ref": "#/definitions/default_2" - }, - { - "type": "boolean" - } - ] + "enableMoreQuests": { + "type": "boolean" }, - "allowSplit": { - "description": "IF set, a 'split this road' button is shown", - "type": "boolean" + "enableLayers": { + "type": "boolean" }, - "units": { - "description": "In some cases, a value is represented in a certain unit (such as meters for heigt/distance/..., km/h for speed, ...)\n\nSometimes, multiple denominations are possible (e.g. km/h vs mile/h; megawatt vs kilowatt vs gigawatt for power generators, ...)\n\nThis brings in some troubles, as there are multiple ways to write it (no denomitation, 'm' vs 'meter' 'metre', ...)\n\nNot only do we want to write consistent data to OSM, we also want to present this consistently to the user.\nThis is handled by defining units.\n\n# Rendering\n\nTo render a value with long (human) denomination, use {canonical(key)}\n\n# Usage\n\nFirst of all, you define which keys have units applied, for example:\n\n```\nunits: [\n appliesTo: [\"maxspeed\", \"maxspeed:hgv\", \"maxspeed:bus\"]\n applicableUnits: [\n ...\n ]\n]\n```\n\nApplicableUnits defines which is the canonical extension, how it is presented to the user, ...:\n\n```\napplicableUnits: [\n{\n canonicalDenomination: \"km/h\",\n alternativeDenomination: [\"km/u\", \"kmh\", \"kph\"]\n default: true,\n human: {\n en: \"kilometer/hour\",\n nl: \"kilometer/uur\"\n },\n humanShort: {\n en: \"km/h\",\n nl: \"km/u\"\n }\n},\n{\n canoncialDenomination: \"mph\",\n ... similar for miles an hour ...\n}\n]\n```\n\n\nIf this is defined, then every key which the denominations apply to (`maxspeed`, `maxspeed:hgv` and `maxspeed:bus`) will be rewritten at the metatagging stage:\nevery value will be parsed and the canonical extension will be added add presented to the other parts of the code.\n\nAlso, if a freeform text field is used, an extra dropdown with applicable denominations will be given", - "type": "array", - "items": { - "$ref": "#/definitions/default_1" - } + "enableSearch": { + "type": "boolean" + }, + "enableAddNewPoints": { + "type": "boolean" + }, + "enableGeolocation": { + "type": "boolean" + }, + "enableBackgroundLayerSelection": { + "type": "boolean" + }, + "enableShowAllQuestions": { + "type": "boolean" + }, + "enableDownload": { + "type": "boolean" + }, + "enablePdfDownload": { + "type": "boolean" + }, + "enableIframePopout": { + "type": "boolean" + }, + "overpassUrl": { + "description": "Set one or more overpass URLs to use for this theme..", + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] + }, + "overpassTimeout": { + "description": "Set a different timeout for overpass queries - in seconds. Default: 30s", + "type": "number" } - }, - "required": [ + }, + "required": [ + "description", + "icon", "id", - "mapRendering", - "source" - ] - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + "layers", + "maintainer", + "startLat", + "startLon", + "startZoom", + "title", + "version" + ], + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + }, + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" + } + }, + "required": [ + "canonicalDenomination" + ] + }, + "TagRenderingConfigJson": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", + "type": "string" + }, + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" + }, + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" + ] + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] + } + } + } + }, + "default_3": { + "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", + "type": "object", + "properties": { + "location": { + "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", + "type": "array", + "items": { + "type": "string" + } + }, + "icon": { + "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "iconBadges": { + "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "if", + "then" + ] + } + }, + "iconSize": { + "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "rotation": { + "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "label": { + "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "location" + ] + }, + "default_4": { + "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", + "type": "object", + "properties": { + "color": { + "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "width": { + "description": "The stroke-width for way-elements", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": [ + "string", + "number" + ] + } + ] + }, + "dashArray": { + "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "lineCap": { + "description": "The form at the end of a line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "fill": { + "description": "Wehter or not to fill polygons", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "enum": [ + "no", + "yes" + ], + "type": "string" + } + ] + }, + "fillColor": { + "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "offset": { + "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "number" + } + ] + } + } + }, + "default": { + "type": "object", + "properties": { + "id": { + "description": "An id/name for this filter, used to set the URL parameters", + "type": "string" + }, + "options": { + "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", + "type": "array", + "items": { + "type": "object", + "properties": { + "question": {}, + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "fields": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "name" + ] + } + } + }, + "required": [ + "question" + ] + } + } + }, + "required": [ + "id", + "options" + ] + }, + "DeleteConfigJson": { + "type": "object", + "properties": { + "extraDeleteReasons": { + "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", + "type": "array", + "items": { + "type": "object", + "properties": { + "explanation": { + "description": "The text that will be shown to the user - translatable" + }, + "changesetMessage": { + "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", + "type": "string" + } + }, + "required": [ + "changesetMessage", + "explanation" + ] + } + }, + "nonDeleteMappings": { + "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + "then": {} + }, + "required": [ + "if", + "then" + ] + } + }, + "softDeletionTags": { + "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "neededChangesets": { + "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", + "type": "number" + } + } + }, + "default_2": { + "type": "object", + "properties": { + "enableImproveAccuracy": { + "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", + "type": "boolean" + }, + "enableRelocation": { + "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", + "type": "boolean" + } + } + }, + "default_1": { + "type": "object", + "properties": { + "appliesToKey": { + "description": "Every key from this list will be normalized", + "type": "array", + "items": { + "type": "string" + } + }, + "eraseInvalidValues": { + "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", + "type": "boolean" + }, + "applicableUnits": { + "description": "The possible denominations", + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableUnitJson" + } + } + }, + "required": [ + "applicableUnits", + "appliesToKey" + ] + }, + "default_5": { + "description": "Configuration for a tilesource config", + "type": "object", + "properties": { + "id": { + "description": "Id of this overlay, used in the URL-parameters to set the state", + "type": "string" + }, + "source": { + "description": "The path, where {x}, {y} and {z} will be substituted", + "type": "string" + }, + "isOverlay": { + "description": "Wether or not this is an overlay. Default: true", + "type": "boolean" + }, + "name": { + "description": "How this will be shown in the selection menu.\nMake undefined if this may not be toggled" + }, + "minZoom": { + "description": "Only visible at this or a higher zoom level", + "type": "number" + }, + "maxZoom": { + "description": "Only visible at this or a lower zoom level", + "type": "number" + }, + "defaultState": { + "description": "The default state, set to false to hide by default", + "type": "boolean" + } + }, + "required": [ + "defaultState", + "id", + "source" + ] + }, + "LayerConfigJson": { + "description": "Configuration for a single layer", + "type": "object", + "properties": { + "id": { + "description": "The id of this layer.\nThis should be a simple, lowercase, human readable string that is used to identify the layer.", + "type": "string" + }, + "name": { + "description": "The name of this layer\nUsed in the layer control panel and the 'Personal theme'.\n\nIf not given, will be hidden (and thus not toggable) in the layer control" + }, + "description": { + "description": "A description for this layer.\nShown in the layer selections and in the personel theme" + }, + "source": { + "description": "This determines where the data for the layer is fetched.\nThere are some options:\n\n# Query OSM directly\nsource: {osmTags: \"key=value\"}\n will fetch all objects with given tags from OSM.\n Currently, this will create a query to overpass and fetch the data - in the future this might fetch from the OSM API\n\n# Query OSM Via the overpass API with a custom script\nsource: {overpassScript: \"\"} when you want to do special things. _This should be really rare_.\n This means that the data will be pulled from overpass with this script, and will ignore the osmTags for the query\n However, for the rest of the pipeline, the OsmTags will _still_ be used. This is important to enable layers etc...\n\n\n# A single geojson-file\nsource: {geoJson: \"https://my.source.net/some-geo-data.geojson\"}\n fetches a geojson from a third party source\n\n# A tiled geojson source\nsource: {geoJson: \"https://my.source.net/some-tile-geojson-{layer}-{z}-{x}-{y}.geojson\", geoJsonZoomLevel: 14}\n to use a tiled geojson source. The web server must offer multiple geojsons. {z}, {x} and {y} are substituted by the location; {layer} is substituted with the id of the loaded layer\n\nSome API's use a BBOX instead of a tile, this can be used by specifying {y_min}, {y_max}, {x_min} and {x_max}\nSome API's use a mercator-projection (EPSG:900913) instead of WGS84. Set the flag `mercatorCrs: true` in the source for this\n\nNote that both geojson-options might set a flag 'isOsmCache' indicating that the data originally comes from OSM too\n\n\nNOTE: the previous format was 'overpassTags: AndOrTagConfigJson | string', which is interpreted as a shorthand for source: {osmTags: \"key=value\"}\n While still supported, this is considered deprecated", + "anyOf": [ + { + "allOf": [ + { + "type": "object", + "properties": { + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "overpassScript": { + "type": "string" + } + }, + "required": [ + "osmTags" + ] + }, + { + "type": "object", + "properties": { + "maxCacheAge": { + "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", + "type": "number" + } + } + } + ] + }, + { + "allOf": [ + { + "type": "object", + "properties": { + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "geoJson": { + "type": "string" + }, + "geoJsonZoomLevel": { + "type": "number" + }, + "isOsmCache": { + "type": "boolean" + }, + "mercatorCrs": { + "type": "boolean" + } + }, + "required": [ + "geoJson", + "osmTags" + ] + }, + { + "type": "object", + "properties": { + "maxCacheAge": { + "description": "The maximum amount of seconds that a tile is allowed to linger in the cache", + "type": "number" + } + } + } + ] + } + ] + }, + "calculatedTags": { + "description": "A list of extra tags to calculate, specified as \"keyToAssignTo=javascript-expression\".\nThere are a few extra functions available. Refer to Docs/CalculatedTags.md for more information\nThe functions will be run in order, e.g.\n[\n \"_max_overlap_m2=Math.max(...feat.overlapsWith(\"someOtherLayer\").map(o => o.overlap))\n \"_max_overlap_ratio=Number(feat._max_overlap_m2)/feat.area\n]\n\nThe specified tags are evaluated lazily. E.g. if a calculated tag is only used in the popup (e.g. the number of nearby features),\nthe expensive calculation will only be performed then for that feature. This avoids clogging up the contributors PC when all features are loaded.\n\nIf a tag has to be evaluated strictly, use ':=' instead:\n\n[\n\"_some_key:=some_javascript_expression\"\n]", + "type": "array", + "items": { + "type": "string" + } + }, + "doNotDownload": { + "description": "If set, this layer will not query overpass; but it'll still match the tags above which are by chance returned by other layers.\nWorks well together with 'passAllFeatures', to add decoration", + "type": "boolean" + }, + "isShown": { + "description": "This tag rendering should either be 'yes' or 'no'. If 'no' is returned, then the feature will be hidden from view.\nThis is useful to hide certain features from view.\n\nImportant: hiding features does not work dynamically, but is only calculated when the data is first renders.\nThis implies that it is not possible to hide a feature after a tagging change\n\nThe default value is 'yes'", + "$ref": "#/definitions/TagRenderingConfigJson" + }, + "minzoom": { + "description": "The minimum needed zoomlevel required before loading of the data start\nDefault: 0", + "type": "number" + }, + "shownByDefault": { + "description": "Indicates if this layer is shown by default;\ncan be used to hide a layer from start, or to load the layer but only to show it where appropriate (e.g. for snapping to it)", + "type": "boolean" + }, + "minzoomVisible": { + "description": "The zoom level at which point the data is hidden again\nDefault: 100 (thus: always visible", + "type": "number" + }, + "title": { + "description": "The title shown in a popup for elements of this layer.", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "titleIcons": { + "description": "Small icons shown next to the title.\nIf not specified, the OsmLink and wikipedia links will be used by default.\nUse an empty array to hide them.\nNote that \"defaults\" will insert all the default titleIcons (which are added automatically)", + "anyOf": [ + { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + { + "type": "array", + "items": [ + { + "type": "string", + "enum": [ + "defaults" + ] + } + ], + "minItems": 1, + "maxItems": 1 + } + ] + }, + "mapRendering": { + "anyOf": [ + { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/default_3" + }, + { + "$ref": "#/definitions/default_4" + } + ] + } + }, + { + "type": "null" + } + ] + }, + "passAllFeatures": { + "description": "If set, this layer will pass all the features it receives onto the next layer.\nThis is ideal for decoration, e.g. directionss on cameras", + "type": "boolean" + }, + "presets": { + "description": "Presets for this layer.\nA preset shows up when clicking the map on a without data (or when right-clicking/long-pressing);\nit will prompt the user to add a new point.\n\nThe most important aspect are the tags, which define which tags the new point will have;\nThe title is shown in the dialog, along with the first sentence of the description.\n\nUpon confirmation, the full description is shown beneath the buttons - perfect to add pictures and examples.\n\nNote: the icon of the preset is determined automatically based on the tags and the icon above. Don't worry about that!\nNB: if no presets are defined, the popup to add new points doesn't show up at all", + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "description": "The title - shown on the 'add-new'-button." + }, + "tags": { + "description": "The tags to add. It determines the icon too", + "type": "array", + "items": { + "type": "string" + } + }, + "description": { + "description": "The _first sentence_ of the description is shown on the button of the `add` menu.\nThe full description is shown in the confirmation dialog.\n\n(The first sentence is until the first '.'-character in the description)" + }, + "preciseInput": { + "description": "If set, the user will prompted to confirm the location before actually adding the data.\nThis will be with a 'drag crosshair'-method.\n\nIf 'preferredBackgroundCategory' is set, the element will attempt to pick a background layer of that category.", + "anyOf": [ + { + "type": "object", + "properties": { + "preferredBackground": { + "description": "The type of background picture", + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] + }, + "snapToLayer": { + "description": "If specified, these layers will be shown to and the new point will be snapped towards it", + "anyOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "type": "string" + } + ] + }, + "maxSnapDistance": { + "description": "If specified, a new point will only be snapped if it is within this range.\nDistance in meter\n\nDefault: 10", + "type": "number" + } + }, + "required": [ + "preferredBackground" + ] + }, + { + "enum": [ + true + ], + "type": "boolean" + } + ] + } + }, + "required": [ + "tags", + "title" + ] + } + }, + "tagRenderings": { + "description": "All the tag renderings.\nA tag rendering is a block that either shows the known value or asks a question.\n\nRefer to the class `TagRenderingConfigJson` to see the possibilities.\n\nNote that we can also use a string here - where the string refers to a tag rendering defined in `assets/questions/questions.json`,\nwhere a few very general questions are defined e.g. website, phone number, ...\n\nA special value is 'questions', which indicates the location of the questions box. If not specified, it'll be appended to the bottom of the featureInfobox.\n\nAt last, one can define a group of renderings where parts of all strings will be replaced by multiple other strings.\nThis is mainly create questions for a 'left' and a 'right' side of the road.\nThese will be grouped and questions will be asked together", + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "object", + "properties": { + "builtin": { + "type": "string" + }, + "override": {} + }, + "required": [ + "builtin", + "override" + ] + }, + { + "type": "object", + "properties": { + "rewrite": { + "type": "array", + "items": { + "type": "object", + "properties": { + "sourceString": { + "type": "string" + }, + "into": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "into", + "sourceString" + ] + } + }, + "renderings": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "object", + "properties": { + "builtin": { + "type": "string" + }, + "override": {} + }, + "required": [ + "builtin", + "override" + ] + }, + { + "type": "string" + } + ] + } + } + }, + "required": [ + "renderings", + "rewrite" + ] + }, + { + "type": "string" + } + ] + } + }, + "filter": { + "description": "All the extra questions for filtering", + "type": "array", + "items": { + "$ref": "#/definitions/default" + } + }, + "deletion": { + "description": "This block defines under what circumstances the delete dialog is shown for objects of this layer.\nIf set, a dialog is shown to the user to (soft) delete the point.\nThe dialog is built to be user friendly and to prevent mistakes.\nIf deletion is not possible, the dialog will hide itself and show the reason of non-deletability instead.\n\nTo configure, the following values are possible:\n\n- false: never ever show the delete button\n- true: show the default delete button\n- undefined: use the mapcomplete default to show deletion or not. Currently, this is the same as 'false' but this will change in the future\n- or: a hash with options (see below)\n\n The delete dialog\n =================\n\n\n\n#### Hard deletion if enough experience\n\nA feature can only be deleted from OpenStreetMap by mapcomplete if:\n\n- It is a node\n- No ways or relations use the node\n- The logged-in user has enough experience OR the user is the only one to have edited the point previously\n- The logged-in user has no unread messages (or has a ton of experience)\n- The user did not select one of the 'non-delete-options' (see below)\n\nIn all other cases, a 'soft deletion' is used.\n\n#### Soft deletion\n\nA 'soft deletion' is when the point isn't deleted from OSM but retagged so that it'll won't how up in the mapcomplete theme anymore.\nThis makes it look like it was deleted, without doing damage. A fixme will be added to the point.\n\nNote that a soft deletion is _only_ possible if these tags are provided by the theme creator, as they'll be different for every theme\n\n#### No-delete options\n\nIn some cases, the contributor might want to delete something for the wrong reason (e.g. someone who wants to have a path removed \"because the path is on their private property\").\nHowever, the path exists in reality and should thus be on OSM - otherwise the next contributor will pass by and notice \"hey, there is a path missing here! Let me redraw it in OSM!)\n\nThe correct approach is to retag the feature in such a way that it is semantically correct *and* that it doesn't show up on the theme anymore.\nA no-delete option is offered as 'reason to delete it', but secretly retags.", + "anyOf": [ + { + "$ref": "#/definitions/DeleteConfigJson" + }, + { + "type": "boolean" + } + ] + }, + "allowMove": { + "description": "Indicates if a point can be moved and configures the modalities.\n\nA feature can be moved by MapComplete if:\n\n- It is a point\n- The point is _not_ part of a way or a a relation.\n\nOff by default. Can be enabled by setting this flag or by configuring.", + "anyOf": [ + { + "$ref": "#/definitions/default_2" + }, + { + "type": "boolean" + } + ] + }, + "allowSplit": { + "description": "IF set, a 'split this road' button is shown", + "type": "boolean" + }, + "units": { + "description": "In some cases, a value is represented in a certain unit (such as meters for heigt/distance/..., km/h for speed, ...)\n\nSometimes, multiple denominations are possible (e.g. km/h vs mile/h; megawatt vs kilowatt vs gigawatt for power generators, ...)\n\nThis brings in some troubles, as there are multiple ways to write it (no denomitation, 'm' vs 'meter' 'metre', ...)\n\nNot only do we want to write consistent data to OSM, we also want to present this consistently to the user.\nThis is handled by defining units.\n\n# Rendering\n\nTo render a value with long (human) denomination, use {canonical(key)}\n\n# Usage\n\nFirst of all, you define which keys have units applied, for example:\n\n```\nunits: [\n appliesTo: [\"maxspeed\", \"maxspeed:hgv\", \"maxspeed:bus\"]\n applicableUnits: [\n ...\n ]\n]\n```\n\nApplicableUnits defines which is the canonical extension, how it is presented to the user, ...:\n\n```\napplicableUnits: [\n{\n canonicalDenomination: \"km/h\",\n alternativeDenomination: [\"km/u\", \"kmh\", \"kph\"]\n default: true,\n human: {\n en: \"kilometer/hour\",\n nl: \"kilometer/uur\"\n },\n humanShort: {\n en: \"km/h\",\n nl: \"km/u\"\n }\n},\n{\n canoncialDenomination: \"mph\",\n ... similar for miles an hour ...\n}\n]\n```\n\n\nIf this is defined, then every key which the denominations apply to (`maxspeed`, `maxspeed:hgv` and `maxspeed:bus`) will be rewritten at the metatagging stage:\nevery value will be parsed and the canonical extension will be added add presented to the other parts of the code.\n\nAlso, if a freeform text field is used, an extra dropdown with applicable denominations will be given", + "type": "array", + "items": { + "$ref": "#/definitions/default_1" + } + } + }, + "required": [ + "id", + "mapRendering", + "source" + ] + } + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/LineRenderingConfigJsonJSC.ts b/Docs/Schemas/LineRenderingConfigJsonJSC.ts index 2b2274fe10..5323b7933b 100644 --- a/Docs/Schemas/LineRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/LineRenderingConfigJsonJSC.ts @@ -1,292 +1,292 @@ export default { - "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", - "type": "object", - "properties": { - "color": { - "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "width": { - "description": "The stroke-width for way-elements", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": [ - "string", - "number" - ] - } - ] - }, - "dashArray": { - "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "lineCap": { - "description": "The form at the end of a line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "fill": { - "description": "Wehter or not to fill polygons", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "enum": [ - "no", - "yes" - ], - "type": "string" - } - ] - }, - "fillColor": { - "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "offset": { - "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "number" - } - ] - } - }, - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { + "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", + "type": "object", + "properties": { + "color": { + "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } ] - } }, - "or": { - "type": "array", - "items": { + "width": { + "description": "The stroke-width for way-elements", "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": [ + "string", + "number" + ] + } + ] + }, + "dashArray": { + "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "lineCap": { + "description": "The form at the end of a line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "fill": { + "description": "Wehter or not to fill polygons", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "enum": [ + "no", + "yes" + ], + "type": "string" + } + ] + }, + "fillColor": { + "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "offset": { + "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "number" + } ] - } } - } }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" - }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" - }, - "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" - } - }, - "required": [ - "canonicalDenomination" - ] - }, - "TagRenderingConfigJson": { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { - "type": "string" - } - }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" - }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" - }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { + "definitions": { + "AndOrTagConfigJson": { "type": "object", "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } - ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", - "type": "array", - "items": { - "type": "string" + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + }, + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" } - } }, "required": [ - "if", - "then" + "canonicalDenomination" ] - } + }, + "TagRenderingConfigJson": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", + "type": "string" + }, + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" + }, + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" + ] + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] + } + } + } } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/MoveConfigJsonJSC.ts b/Docs/Schemas/MoveConfigJsonJSC.ts index 23f191109b..0d7dede65a 100644 --- a/Docs/Schemas/MoveConfigJsonJSC.ts +++ b/Docs/Schemas/MoveConfigJsonJSC.ts @@ -1,84 +1,84 @@ export default { - "type": "object", - "properties": { - "enableImproveAccuracy": { - "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", - "type": "boolean" - }, - "enableRelocation": { - "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", - "type": "boolean" - } - }, - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } + "type": "object", + "properties": { + "enableImproveAccuracy": { + "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", + "type": "boolean" }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } + "enableRelocation": { + "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", + "type": "boolean" } - } }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" - }, - "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" + } + }, + "required": [ + "canonicalDenomination" + ] } - }, - "required": [ - "canonicalDenomination" - ] - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/PointRenderingConfigJsonJSC.ts b/Docs/Schemas/PointRenderingConfigJsonJSC.ts index 994576def3..38f96bbb0d 100644 --- a/Docs/Schemas/PointRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/PointRenderingConfigJsonJSC.ts @@ -1,295 +1,295 @@ export default { - "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", - "type": "object", - "properties": { - "location": { - "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", - "type": "array", - "items": { - "type": "string" - } - }, - "icon": { - "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "iconBadges": { - "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { + "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", + "type": "object", + "properties": { + "location": { + "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", + "type": "array", + "items": { "type": "string" - } - ] - }, - "then": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "if", - "then" - ] - } - }, - "iconSize": { - "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "rotation": { - "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "label": { - "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "location" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - } - } - }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" - }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" - }, - "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" - } - }, - "required": [ - "canonicalDenomination" - ] - }, - "TagRenderingConfigJson": { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" } - ] }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { - "type": "string" - } - }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" - }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" + "icon": { + "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "iconBadges": { + "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "if", + "then" + ] } - }, - "required": [ - "key" - ] }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" + "iconSize": { + "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { + "rotation": { + "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "label": { + "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "location" + ], + "definitions": { + "AndOrTagConfigJson": { "type": "object", "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } - ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", - "type": "array", - "items": { - "type": "string" + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + }, + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" } - } }, "required": [ - "if", - "then" + "canonicalDenomination" ] - } + }, + "TagRenderingConfigJson": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", + "type": "string" + }, + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" + }, + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" + ] + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] + } + } + } } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/TagRenderingConfigJsonJSC.ts b/Docs/Schemas/TagRenderingConfigJsonJSC.ts index e9decfe53e..653e30dd02 100644 --- a/Docs/Schemas/TagRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/TagRenderingConfigJsonJSC.ts @@ -1,165 +1,165 @@ export default { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", "type": "string" - } }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" - }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", "type": "array", "items": { - "type": "string" + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] } - } - }, - "required": [ - "if", - "then" - ] - } - } - }, - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } } - } - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/TilesourceConfigJsonJSC.ts b/Docs/Schemas/TilesourceConfigJsonJSC.ts index 1034221448..b3b7420693 100644 --- a/Docs/Schemas/TilesourceConfigJsonJSC.ts +++ b/Docs/Schemas/TilesourceConfigJsonJSC.ts @@ -1,573 +1,573 @@ export default { - "description": "Configuration for a tilesource config", - "type": "object", - "properties": { - "id": { - "description": "Id of this overlay, used in the URL-parameters to set the state", - "type": "string" - }, - "source": { - "description": "The path, where {x}, {y} and {z} will be substituted", - "type": "string" - }, - "isOverlay": { - "description": "Wether or not this is an overlay. Default: true", - "type": "boolean" - }, - "name": { - "description": "How this will be shown in the selection menu.\nMake undefined if this may not be toggled" - }, - "minZoom": { - "description": "Only visible at this or a higher zoom level", - "type": "number" - }, - "maxZoom": { - "description": "Only visible at this or a lower zoom level", - "type": "number" - }, - "defaultState": { - "description": "The default state, set to false to hide by default", - "type": "boolean" - } - }, - "required": [ - "defaultState", - "id", - "source" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } - } - } - }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" - }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { + "description": "Configuration for a tilesource config", + "type": "object", + "properties": { + "id": { + "description": "Id of this overlay, used in the URL-parameters to set the state", "type": "string" - } }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + "source": { + "description": "The path, where {x}, {y} and {z} will be substituted", + "type": "string" }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + "isOverlay": { + "description": "Wether or not this is an overlay. Default: true", + "type": "boolean" }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" + "name": { + "description": "How this will be shown in the selection menu.\nMake undefined if this may not be toggled" + }, + "minZoom": { + "description": "Only visible at this or a higher zoom level", + "type": "number" + }, + "maxZoom": { + "description": "Only visible at this or a lower zoom level", + "type": "number" + }, + "defaultState": { + "description": "The default state, set to false to hide by default", + "type": "boolean" + } + }, + "required": [ + "defaultState", + "id", + "source" + ], + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } + }, + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" + } + }, + "required": [ + "canonicalDenomination" + ] + }, + "TagRenderingConfigJson": { + "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", + "type": "object", + "properties": { + "id": { + "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", + "type": "string" + }, + "group": { + "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", + "type": "string" + }, + "render": { + "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" + }, + "question": { + "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" + }, + "condition": { + "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "freeform": { + "description": "Allow freeform text input from the user", + "type": "object", + "properties": { + "key": { + "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", + "type": "string" + }, + "type": { + "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", + "type": "string" + }, + "helperArgs": { + "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", + "type": "array", + "items": {} + }, + "addExtraTags": { + "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", + "type": "array", + "items": { + "type": "string" + } + }, + "inline": { + "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", + "type": "boolean" + }, + "default": { + "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", + "type": "string" + } + }, + "required": [ + "key" + ] + }, + "multiAnswer": { + "description": "If true, use checkboxes instead of radio buttons when asking the question", + "type": "boolean" + }, + "mappings": { + "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" + }, + "hideInAnswer": { + "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": [ + "string", + "boolean" + ] + } + ] + }, + "ifnot": { + "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "addExtraTags": { + "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "if", + "then" + ] + } + } + } + }, + "default_3": { + "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", + "type": "object", + "properties": { + "location": { + "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", + "type": "array", + "items": { + "type": "string" + } + }, + "icon": { + "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "iconBadges": { + "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "then": { + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "if", + "then" + ] + } + }, + "iconSize": { + "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "rotation": { + "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "label": { + "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "required": [ + "location" + ] + }, + "default_4": { + "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", + "type": "object", + "properties": { + "color": { + "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "width": { + "description": "The stroke-width for way-elements", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": [ + "string", + "number" + ] + } + ] + }, + "dashArray": { + "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "lineCap": { + "description": "The form at the end of a line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "fill": { + "description": "Wehter or not to fill polygons", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "enum": [ + "no", + "yes" + ], + "type": "string" + } + ] + }, + "fillColor": { + "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "string" + } + ] + }, + "offset": { + "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", + "anyOf": [ + { + "$ref": "#/definitions/TagRenderingConfigJson" + }, + { + "type": "number" + } + ] + } + } }, "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" - } - }, - "required": [ - "canonicalDenomination" - ] - }, - "TagRenderingConfigJson": { - "description": "A TagRenderingConfigJson is a single piece of code which converts one ore more tags into a HTML-snippet.\nIf the desired tags are missing and a question is defined, a question will be shown instead.", - "type": "object", - "properties": { - "id": { - "description": "The id of the tagrendering, should be an unique string.\nUsed to keep the translations in sync. Only used in the tagRenderings-array of a layerConfig, not requered otherwise.\n\nUse 'questions' to trigger the question box of this group (if a group is defined)", - "type": "string" - }, - "group": { - "description": "If 'group' is defined on many tagRenderings, these are grouped together when shown. The questions are grouped together as well.\nThe first tagRendering of a group will always be a sticky element.", - "type": "string" - }, - "render": { - "description": "Renders this value. Note that \"{key}\"-parts are substituted by the corresponding values of the element.\nIf neither 'textFieldQuestion' nor 'mappings' are defined, this text is simply shown as default value.\n\nNote that this is a HTML-interpreted value, so you can add links as e.g. '{website}' or include images such as `This is of type A
`" - }, - "question": { - "description": "If it turns out that this tagRendering doesn't match _any_ value, then we show this question.\nIf undefined, the question is never asked and this tagrendering is read-only" - }, - "condition": { - "description": "Only show this question if the object also matches the following tags.\n\nThis is useful to ask a follow-up question. E.g. if there is a diaper table, then ask a follow-up question on diaper tables...", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "freeform": { - "description": "Allow freeform text input from the user", - "type": "object", - "properties": { - "key": { - "description": "If this key is present, then 'render' is used to display the value.\nIf this is undefined, the rendering is _always_ shown", - "type": "string" - }, - "type": { - "description": "The type of the text-field, e.g. 'string', 'nat', 'float', 'date',...\nSee Docs/SpecialInputElements.md and UI/Input/ValidatedTextField.ts for supported values", - "type": "string" - }, - "helperArgs": { - "description": "Extra parameters to initialize the input helper arguments.\nFor semantics, see the 'SpecialInputElements.md'", - "type": "array", - "items": {} - }, - "addExtraTags": { - "description": "If a value is added with the textfield, these extra tag is addded.\nUseful to add a 'fixme=freeform textfield used - to be checked'", - "type": "array", - "items": { - "type": "string" - } - }, - "inline": { - "description": "When set, influences the way a question is asked.\nInstead of showing a full-widht text field, the text field will be shown within the rendering of the question.\n\nThis combines badly with special input elements, as it'll distort the layout.", - "type": "boolean" - }, - "default": { - "description": "default value to enter if no previous tagging is present.\nNormally undefined (aka do not enter anything)", - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "multiAnswer": { - "description": "If true, use checkboxes instead of radio buttons when asking the question", - "type": "boolean" - }, - "mappings": { - "description": "Allows fixed-tag inputs, shown either as radiobuttons or as checkboxes", - "type": "array", - "items": { "type": "object", "properties": { - "if": { - "description": "If this condition is met, then the text under `then` will be shown.\nIf no value matches, and the user selects this mapping as an option, then these tags will be uploaded to OSM.\n\nFor example: {'if': 'diet:vegetarion=yes', 'then':'A vegetarian option is offered here'}\n\nThis can be an substituting-tag as well, e.g. {'if': 'addr:street:={_calculated_nearby_streetname}', 'then': '{_calculated_nearby_streetname}'}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { + "id": { + "description": "An id/name for this filter, used to set the URL parameters", "type": "string" - } - ] - }, - "then": { - "description": "If the condition `if` is met, the text `then` will be rendered.\nIf not known yet, the user will be presented with `then` as an option" - }, - "hideInAnswer": { - "description": "In some cases, multiple taggings exist (e.g. a default assumption, or a commonly mapped abbreviation and a fully written variation).\n\nIn the latter case, a correct text should be shown, but only a single, canonical tagging should be selectable by the user.\nIn this case, one of the mappings can be hiden by setting this flag.\n\nTo demonstrate an example making a default assumption:\n\nmappings: [\n {\n if: \"access=\", -- no access tag present, we assume accessible\n then: \"Accessible to the general public\",\n hideInAnswer: true\n },\n {\n if: \"access=yes\",\n then: \"Accessible to the general public\", -- the user selected this, we add that to OSM\n },\n {\n if: \"access=no\",\n then: \"Not accessible to the public\"\n }\n]\n\n\nFor example, for an operator, we have `operator=Agentschap Natuur en Bos`, which is often abbreviated to `operator=ANB`.\nThen, we would add two mappings:\n{\n if: \"operator=Agentschap Natuur en Bos\" -- the non-abbreviated version which should be uploaded\n then: \"Maintained by Agentschap Natuur en Bos\"\n},\n{\n if: \"operator=ANB\", -- we don't want to upload abbreviations\n then: \"Maintained by Agentschap Natuur en Bos\"\n hideInAnswer: true\n}\n\nHide in answer can also be a tagsfilter, e.g. to make sure an option is only shown when appropriate.\nKeep in mind that this is reverse logic: it will be hidden in the answer if the condition is true, it will thus only show in the case of a mismatch\n\ne.g., for toilets: if \"wheelchair=no\", we know there is no wheelchair dedicated room.\nFor the location of the changing table, the option \"in the wheelchair accessible toilet is weird\", so we write:\n\n{\n \"question\": \"Where is the changing table located?\"\n \"mappings\": [\n {\"if\":\"changing_table:location=female\",\"then\":\"In the female restroom\"},\n {\"if\":\"changing_table:location=male\",\"then\":\"In the male restroom\"},\n {\"if\":\"changing_table:location=wheelchair\",\"then\":\"In the wheelchair accessible restroom\", \"hideInAnswer\": \"wheelchair=no\"},\n \n ]\n}\n\nAlso have a look for the meta-tags\n{\n if: \"operator=Agentschap Natuur en Bos\",\n then: \"Maintained by Agentschap Natuur en Bos\",\n hideInAnswer: \"_country!=be\"\n}", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": [ - "string", - "boolean" - ] - } - ] - }, - "ifnot": { - "description": "Only applicable if 'multiAnswer' is set.\nThis is for situations such as:\n`accepts:coins=no` where one can select all the possible payment methods. However, we want to make explicit that some options _were not_ selected.\nThis can be done with `ifnot`\nNote that we can not explicitly render this negative case to the user, we cannot show `does _not_ accept coins`.\nIf this is important to your usecase, consider using multiple radiobutton-fields without `multiAnswer`", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "addExtraTags": { - "description": "If chosen as answer, these tags will be applied as well onto the object.\nNot compatible with multiAnswer", - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "if", - "then" - ] - } - } - } - }, - "default_3": { - "description": "The PointRenderingConfig gives all details onto how to render a single point of a feature.\n\nThis can be used if:\n\n- The feature is a point\n- To render something at the centroid of an area, or at the start, end or projected centroid of a way", - "type": "object", - "properties": { - "location": { - "description": "All the locations that this point should be rendered at.\nUsing `location: [\"point\", \"centroid\"] will always render centerpoint", - "type": "array", - "items": { - "type": "string" - } - }, - "icon": { - "description": "The icon for an element.\nNote that this also doubles as the icon for this layer (rendered with the overpass-tags) ánd the icon in the presets.\n\nThe result of the icon is rendered as follows:\nthe resulting string is interpreted as a _list_ of items, separated by \";\". The bottommost layer is the first layer.\nAs a result, on could use a generic pin, then overlay it with a specific icon.\nTo make things even more practical, one can use all SVG's from the folder \"assets/svg\" and _substitute the color_ in it.\nE.g. to draw a red pin, use \"pin:#f00\", to have a green circle with your icon on top, use `circle:#0f0;`", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "iconBadges": { - "description": "A list of extra badges to show next to the icon as small badge\nThey will be added as a 25% height icon at the bottom right of the icon, with all the badges in a flex layout.\n\nNote: strings are interpreted as icons, so layering and substituting is supported. You can use `circle:white;./my_icon.svg` to add a background circle", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "then": { - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "if", - "then" - ] - } - }, - "iconSize": { - "description": "A string containing \"width,height\" or \"width,height,anchorpoint\" where anchorpoint is any of 'center', 'top', 'bottom', 'left', 'right', 'bottomleft','topright', ...\nDefault is '40,40,center'", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "rotation": { - "description": "The rotation of an icon, useful for e.g. directions.\nUsage: as if it were a css property for 'rotate', thus has to end with 'deg', e.g. `90deg`, `{direction}deg`, `calc(90deg - {camera:direction}deg)``", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "label": { - "description": "A HTML-fragment that is shown below the icon, for example:\n
{name}
\n\nIf the icon is undefined, then the label is shown in the center of the feature.\nNote that, if the wayhandling hides the icon then no label is shown as well.", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "location" - ] - }, - "default_4": { - "description": "The LineRenderingConfig gives all details onto how to render a single line of a feature.\n\nThis can be used if:\n\n- The feature is a line\n- The feature is an area", - "type": "object", - "properties": { - "color": { - "description": "The color for way-elements and SVG-elements.\nIf the value starts with \"--\", the style of the body element will be queried for the corresponding variable instead", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "width": { - "description": "The stroke-width for way-elements", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": [ - "string", - "number" - ] - } - ] - }, - "dashArray": { - "description": "A dasharray, e.g. \"5 6\"\nThe dasharray defines 'pixels of line, pixels of gap, pixels of line, pixels of gap',\nDefault value: \"\" (empty string == full line)", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "lineCap": { - "description": "The form at the end of a line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "fill": { - "description": "Wehter or not to fill polygons", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "enum": [ - "no", - "yes" - ], - "type": "string" - } - ] - }, - "fillColor": { - "description": "The color to fill a polygon with.\nIf undefined, this will be slightly more opaque version of the stroke line", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "string" - } - ] - }, - "offset": { - "description": "The number of pixels this line should be moved.\nUse a positive numbe to move to the right, a negative to move to the left (left/right as defined by the drawing direction of the line).\n\nIMPORTANT: MapComplete will already normalize 'key:both:property' and 'key:both' into the corresponding 'key:left' and 'key:right' tagging (same for 'sidewalk=left/right/both' which is rewritten to 'sidewalk:left' and 'sidewalk:right')\nThis simplifies programming. Refer to the CalculatedTags.md-documentation for more details", - "anyOf": [ - { - "$ref": "#/definitions/TagRenderingConfigJson" - }, - { - "type": "number" - } - ] - } - } - }, - "default": { - "type": "object", - "properties": { - "id": { - "description": "An id/name for this filter, used to set the URL parameters", - "type": "string" - }, - "options": { - "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", - "type": "array", - "items": { - "type": "object", - "properties": { - "question": {}, - "osmTags": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - }, - "fields": { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "type": { - "type": "string" + }, + "options": { + "description": "The options for a filter\nIf there are multiple options these will be a list of radio buttons\nIf there is only one option this will be a checkbox\nFiltering is done based on the given osmTags that are compared to the objects in that layer.", + "type": "array", + "items": { + "type": "object", + "properties": { + "question": {}, + "osmTags": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "fields": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "name" + ] + } + } + }, + "required": [ + "question" + ] } - }, - "required": [ - "name" - ] } - } }, "required": [ - "question" + "id", + "options" ] - } - } - }, - "required": [ - "id", - "options" - ] - }, - "DeleteConfigJson": { - "type": "object", - "properties": { - "extraDeleteReasons": { - "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", - "type": "array", - "items": { + }, + "DeleteConfigJson": { "type": "object", "properties": { - "explanation": { - "description": "The text that will be shown to the user - translatable" - }, - "changesetMessage": { - "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", - "type": "string" - } - }, - "required": [ - "changesetMessage", - "explanation" - ] - } - }, - "nonDeleteMappings": { - "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", - "type": "array", - "items": { - "type": "object", - "properties": { - "if": { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - "then": {} - }, - "required": [ - "if", - "then" - ] - } - }, - "softDeletionTags": { - "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" + "extraDeleteReasons": { + "description": "*\nBy default, three reasons to delete a point are shown:\n\n- The point does not exist anymore\n- The point was a testing point\n- THe point could not be found\n\nHowever, for some layers, there might be different or more specific reasons for deletion which can be user friendly to set, e.g.:\n\n- the shop has closed\n- the climbing route has been closed of for nature conservation reasons\n- ...\n\nThese reasons can be stated here and will be shown in the list of options the user can choose from", + "type": "array", + "items": { + "type": "object", + "properties": { + "explanation": { + "description": "The text that will be shown to the user - translatable" + }, + "changesetMessage": { + "description": "The text that will be uploaded into the changeset or will be used in the fixme in case of a soft deletion\nShould be a few words, in english", + "type": "string" + } + }, + "required": [ + "changesetMessage", + "explanation" + ] + } + }, + "nonDeleteMappings": { + "description": "In some cases, a (starting) contributor might wish to delete a feature even though deletion is not appropriate.\n(The most relevant case are small paths running over private property. These should be marked as 'private' instead of deleted, as the community might trace the path again from aerial imagery, gettting us back to the original situation).\n\nBy adding a 'nonDeleteMapping', an option can be added into the list which will retag the feature.\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!", + "type": "array", + "items": { + "type": "object", + "properties": { + "if": { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + "then": {} + }, + "required": [ + "if", + "then" + ] + } + }, + "softDeletionTags": { + "description": "In some cases, the contributor is not allowed to delete the current feature (e.g. because it isn't a point, the point is referenced by a relation or the user isn't experienced enough).\nTo still offer the user a 'delete'-option, the feature is retagged with these tags. This is a soft deletion, as the point isn't actually removed from OSM but rather marked as 'disused'\nIt is important that the feature will be retagged in such a way that it won't be picked up by the layer anymore!\n\nExample (note that \"amenity=\" erases the 'amenity'-key alltogether):\n```\n{\n \"and\": [\"disussed:amenity=public_bookcase\", \"amenity=\"]\n}\n```\n\nor (notice the use of the ':='-tag to copy the old value of 'shop=*' into 'disused:shop='):\n```\n{\n \"and\": [\"disused:shop:={shop}\", \"shop=\"]\n}\n```", + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + }, + "neededChangesets": { + "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", + "type": "number" + } } - ] }, - "neededChangesets": { - "description": "*\nBy default, the contributor needs 20 previous changesets to delete points edited by others.\nFor some small features (e.g. bicycle racks) this is too much and this requirement can be lowered or dropped, which can be done here.", - "type": "number" + "default_2": { + "type": "object", + "properties": { + "enableImproveAccuracy": { + "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", + "type": "boolean" + }, + "enableRelocation": { + "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", + "type": "boolean" + } + } + }, + "default_1": { + "type": "object", + "properties": { + "appliesToKey": { + "description": "Every key from this list will be normalized", + "type": "array", + "items": { + "type": "string" + } + }, + "eraseInvalidValues": { + "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", + "type": "boolean" + }, + "applicableUnits": { + "description": "The possible denominations", + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableUnitJson" + } + } + }, + "required": [ + "applicableUnits", + "appliesToKey" + ] } - } }, - "default_2": { - "type": "object", - "properties": { - "enableImproveAccuracy": { - "description": "One default reason to move a point is to improve accuracy.\nSet to false to disable this reason", - "type": "boolean" - }, - "enableRelocation": { - "description": "One default reason to move a point is because it has relocated\nSet to false to disable this reason", - "type": "boolean" - } - } - }, - "default_1": { - "type": "object", - "properties": { - "appliesToKey": { - "description": "Every key from this list will be normalized", - "type": "array", - "items": { - "type": "string" - } - }, - "eraseInvalidValues": { - "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", - "type": "boolean" - }, - "applicableUnits": { - "description": "The possible denominations", - "type": "array", - "items": { - "$ref": "#/definitions/ApplicableUnitJson" - } - } - }, - "required": [ - "applicableUnits", - "appliesToKey" - ] - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/Schemas/UnitConfigJsonJSC.ts b/Docs/Schemas/UnitConfigJsonJSC.ts index 9e8fa3c0d1..8c141bffe5 100644 --- a/Docs/Schemas/UnitConfigJsonJSC.ts +++ b/Docs/Schemas/UnitConfigJsonJSC.ts @@ -1,98 +1,98 @@ export default { - "type": "object", - "properties": { - "appliesToKey": { - "description": "Every key from this list will be normalized", - "type": "array", - "items": { - "type": "string" - } - }, - "eraseInvalidValues": { - "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", - "type": "boolean" - }, - "applicableUnits": { - "description": "The possible denominations", - "type": "array", - "items": { - "$ref": "#/definitions/ApplicableUnitJson" - } - } - }, - "required": [ - "applicableUnits", - "appliesToKey" - ], - "definitions": { - "AndOrTagConfigJson": { - "type": "object", - "properties": { - "and": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { + "type": "object", + "properties": { + "appliesToKey": { + "description": "Every key from this list will be normalized", + "type": "array", + "items": { "type": "string" - } - ] - } + } }, - "or": { - "type": "array", - "items": { - "anyOf": [ - { - "$ref": "#/definitions/AndOrTagConfigJson" - }, - { - "type": "string" - } - ] - } + "eraseInvalidValues": { + "description": "If set, invalid values will be erased in the MC application (but not in OSM of course!)\nBe careful with setting this", + "type": "boolean" + }, + "applicableUnits": { + "description": "The possible denominations", + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableUnitJson" + } } - } }, - "ApplicableUnitJson": { - "type": "object", - "properties": { - "canonicalDenomination": { - "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", - "type": "string" + "required": [ + "applicableUnits", + "appliesToKey" + ], + "definitions": { + "AndOrTagConfigJson": { + "type": "object", + "properties": { + "and": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + }, + "or": { + "type": "array", + "items": { + "anyOf": [ + { + "$ref": "#/definitions/AndOrTagConfigJson" + }, + { + "type": "string" + } + ] + } + } + } }, - "canonicalDenominationSingular": { - "description": "The canonical denomination in the case that the unit is precisely '1'", - "type": "string" - }, - "alternativeDenomination": { - "description": "A list of alternative values which can occur in the OSM database - used for parsing.", - "type": "array", - "items": { - "type": "string" - } - }, - "human": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" - }, - "humanSingular": { - "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" - }, - "prefix": { - "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", - "type": "boolean" - }, - "default": { - "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", - "type": "boolean" + "ApplicableUnitJson": { + "type": "object", + "properties": { + "canonicalDenomination": { + "description": "The canonical value which will be added to the text.\ne.g. \"m\" for meters\nIf the user inputs '42', the canonical value will be added and it'll become '42m'", + "type": "string" + }, + "canonicalDenominationSingular": { + "description": "The canonical denomination in the case that the unit is precisely '1'", + "type": "string" + }, + "alternativeDenomination": { + "description": "A list of alternative values which can occur in the OSM database - used for parsing.", + "type": "array", + "items": { + "type": "string" + } + }, + "human": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"meter\",\n \"fr\": \"metre\"\n}" + }, + "humanSingular": { + "description": "The value for humans in the dropdown. This should not use abbreviations and should be translated, e.g.\n{\n \"en\": \"minute\",\n \"nl\": \"minuut\"x²\n}" + }, + "prefix": { + "description": "If set, then the canonical value will be prefixed instead, e.g. for '€'\nNote that if all values use 'prefix', the dropdown might move to before the text field", + "type": "boolean" + }, + "default": { + "description": "The default interpretation - only one can be set.\nIf none is set, the first unit will be considered the default interpretation of a value without a unit", + "type": "boolean" + } + }, + "required": [ + "canonicalDenomination" + ] } - }, - "required": [ - "canonicalDenomination" - ] - } - }, - "$schema": "http://json-schema.org/draft-07/schema#" + }, + "$schema": "http://json-schema.org/draft-07/schema#" } \ No newline at end of file diff --git a/Docs/SpecialRenderings.md b/Docs/SpecialRenderings.md index f104e8dac7..22a3625099 100644 --- a/Docs/SpecialRenderings.md +++ b/Docs/SpecialRenderings.md @@ -165,7 +165,6 @@ name | default | description ------ | --------- | ------------- key | opening_hours | The tagkey from which the table is constructed. prefix | _empty string_ | Remove this string from the start of the value before parsing. __Note: use `&LPARENs` to - indicate `(` if needed__ postfix | _empty string_ | Remove this string from the end of the value before parsing. __Note: use `&RPARENs` to indicate `)` if needed__ @@ -493,9 +492,7 @@ tags_to_apply | _undefined_ | A specification of the tags to apply message | _undefined_ | The text to show to the contributor image | _undefined_ | An image to show to the contributor on the button id_of_object_to_apply_this_one | _undefined_ | If specified, applies the the tags onto _ - -another_ object. The id will be read from properties[id_of_object_to_apply_this_one] of the selected object. The tags -are still calculated based on the tags of the _ +another_ object. The id will be read from properties[id_of_object_to_apply_this_one] of the selected object. The tags are still calculated based on the tags of the _ selected_ element #### Example usage of tag_apply diff --git a/Docs/TagInfo/mapcomplete_bicycle_rental.json b/Docs/TagInfo/mapcomplete_bicycle_rental.json new file mode 100644 index 0000000000..eb9508d5f5 --- /dev/null +++ b/Docs/TagInfo/mapcomplete_bicycle_rental.json @@ -0,0 +1,102 @@ +{ + "data_format": 1, + "project": { + "name": "MapComplete Bicycle rental", + "description": "A map with biyccle rental stations and bicycle rental shops", + "project_url": "https://mapcomplete.osm.be/bicycle_rental", + "doc_url": "https://github.com/pietervdvn/MapComplete/tree/master/assets/themes/", + "icon_url": "https://mapcomplete.osm.be/assets/themes/bicycle_rental/logo.svg", + "contact_name": "Pieter Vander Vennet, ", + "contact_email": "pietervdvn@posteo.net" + }, + "tags": [ + { + "key": "amenity", + "description": "The MapComplete theme Bicycle rental has a layer Bicycle rental showing features with this tag", + "value": "bicycle_rental" + }, + { + "key": "bicycle_rental", + "description": "The MapComplete theme Bicycle rental has a layer Bicycle rental showing features with this tag" + }, + { + "key": "service:bicycle:rental", + "description": "The MapComplete theme Bicycle rental has a layer Bicycle rental showing features with this tag", + "value": "yes" + }, + { + "key": "service:bicycle:rental", + "description": "Layer 'Bicycle rental' shows service:bicycle:rental=yes&shop=bicycle with a fixed text, namely 'This is a shop which sells or repairs bicycles, but also rents out bicycles' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "yes" + }, + { + "key": "shop", + "description": "Layer 'Bicycle rental' shows service:bicycle:rental=yes&shop=bicycle with a fixed text, namely 'This is a shop which sells or repairs bicycles, but also rents out bicycles' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "bicycle" + }, + { + "key": "shop", + "description": "Layer 'Bicycle rental' shows shop=bicycle_rental&bicycle_rental=shop with a fixed text, namely 'This is a shop whose main focus is bicycle rental' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "bicycle_rental" + }, + { + "key": "bicycle_rental", + "description": "Layer 'Bicycle rental' shows shop=bicycle_rental&bicycle_rental=shop with a fixed text, namely 'This is a shop whose main focus is bicycle rental' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "shop" + }, + { + "key": "bicycle_rental", + "description": "Layer 'Bicycle rental' shows bicycle_rental=docking_station with a fixed text, namely 'This is an automated docking station, where a bicycle is mechanically locked into a structure' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "docking_station" + }, + { + "key": "bicycle_rental", + "description": "Layer 'Bicycle rental' shows bicycle_rental=key_dispensing_machine with a fixed text, namely 'A machine is present which dispenses and accepts keys, eventually after authentication and/or payment. The bicycles are parked nearby' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "key_dispensing_machine" + }, + { + "key": "bicycle_rental", + "description": "Layer 'Bicycle rental' shows bicycle_rental=dropoff_point with a fixed text, namely 'This is a dropoff point: a designated bicycle parking for this cycle rental' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "dropoff_point" + }, + { + "key": "website", + "description": "Layer 'Bicycle rental' shows and asks freeform values for key 'website' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "contact:website", + "description": "Layer 'Bicycle rental' shows contact:website~^..*$ with a fixed text, namely '{contact:website}' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "email", + "description": "Layer 'Bicycle rental' shows and asks freeform values for key 'email' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "contact:email", + "description": "Layer 'Bicycle rental' shows contact:email~^..*$ with a fixed text, namely '{contact:email}' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "phone", + "description": "Layer 'Bicycle rental' shows and asks freeform values for key 'phone' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "contact:phone", + "description": "Layer 'Bicycle rental' shows contact:phone~^..*$ with a fixed text, namely '{contact:phone}' (in the MapComplete.osm.be theme 'Bicycle rental')" + }, + { + "key": "payment:cash", + "description": "Layer 'Bicycle rental' shows payment:cash=yes with a fixed text, namely 'Cash is accepted here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "yes" + }, + { + "key": "payment:cards", + "description": "Layer 'Bicycle rental' shows payment:cards=yes with a fixed text, namely 'Payment cards are accepted here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Bicycle rental')", + "value": "yes" + }, + { + "key": "id", + "description": "The MapComplete theme Bicycle rental has a layer Your track showing features with this tag", + "value": "location_track" + } + ] +} \ No newline at end of file diff --git a/Docs/TagInfo/mapcomplete_bookcases.json b/Docs/TagInfo/mapcomplete_bookcases.json index ddba7cb5d9..2d1dc542d9 100644 --- a/Docs/TagInfo/mapcomplete_bookcases.json +++ b/Docs/TagInfo/mapcomplete_bookcases.json @@ -144,10 +144,6 @@ "key": "website", "description": "Layer 'Bookcases' shows and asks freeform values for key 'website' (in the MapComplete.osm.be theme 'Open Bookcase Map')" }, - { - "key": "id", - "description": "The MapComplete theme Open Bookcase Map has a layer Possible bookcases showing features with this tag" - }, { "key": "id", "description": "The MapComplete theme Open Bookcase Map has a layer Your track showing features with this tag", diff --git a/Docs/TagInfo/mapcomplete_campersite.json b/Docs/TagInfo/mapcomplete_campersite.json index 959fc26873..a38dc78530 100644 --- a/Docs/TagInfo/mapcomplete_campersite.json +++ b/Docs/TagInfo/mapcomplete_campersite.json @@ -136,6 +136,20 @@ "key": "description", "description": "Layer 'Camper sites' shows and asks freeform values for key 'description' (in the MapComplete.osm.be theme 'Campersites')" }, + { + "key": "operator", + "description": "Layer 'Camper sites' shows and asks freeform values for key 'operator' (in the MapComplete.osm.be theme 'Campersites')" + }, + { + "key": "power_supply", + "description": "Layer 'Camper sites' shows power_supply=yes with a fixed text, namely 'This place has a power supply' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Campersites')", + "value": "yes" + }, + { + "key": "power_supply", + "description": "Layer 'Camper sites' shows power_supply=no with a fixed text, namely 'This place does not have power supply' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Campersites')", + "value": "no" + }, { "key": "amenity", "description": "The MapComplete theme Campersites has a layer Sanitary dump stations showing features with this tag", @@ -225,6 +239,20 @@ "key": "network", "description": "Layer 'Sanitary dump stations' shows and asks freeform values for key 'network' (in the MapComplete.osm.be theme 'Campersites')" }, + { + "key": "operator", + "description": "Layer 'Sanitary dump stations' shows and asks freeform values for key 'operator' (in the MapComplete.osm.be theme 'Campersites')" + }, + { + "key": "power_supply", + "description": "Layer 'Sanitary dump stations' shows power_supply=yes with a fixed text, namely 'This place has a power supply' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Campersites')", + "value": "yes" + }, + { + "key": "power_supply", + "description": "Layer 'Sanitary dump stations' shows power_supply=no with a fixed text, namely 'This place does not have power supply' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Campersites')", + "value": "no" + }, { "key": "id", "description": "The MapComplete theme Campersites has a layer Your track showing features with this tag", diff --git a/Docs/TagInfo/mapcomplete_charging_stations.json b/Docs/TagInfo/mapcomplete_charging_stations.json index 4fdb903d94..40fff0b290 100644 --- a/Docs/TagInfo/mapcomplete_charging_stations.json +++ b/Docs/TagInfo/mapcomplete_charging_stations.json @@ -967,6 +967,16 @@ "description": "Layer 'Charging stations' shows payment:cards=yes with a fixed text, namely 'Payment cards are accepted here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Charging stations')", "value": "yes" }, + { + "key": "payment:app", + "description": "Layer 'Charging stations' shows payment:app=yes with a fixed text, namely 'Payment is done using a dedicated app' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Charging stations')", + "value": "yes" + }, + { + "key": "payment:membership_card", + "description": "Layer 'Charging stations' shows payment:membership_card=yes with a fixed text, namely 'Payment is done using a membership card' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Charging stations')", + "value": "yes" + }, { "key": "authentication:membership_card", "description": "Layer 'Charging stations' shows authentication:membership_card=yes with a fixed text, namely 'Authentication by a membership card' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Charging stations')", diff --git a/Docs/TagInfo/mapcomplete_climbing.json b/Docs/TagInfo/mapcomplete_climbing.json index 022b0b987f..c073f6ad10 100644 --- a/Docs/TagInfo/mapcomplete_climbing.json +++ b/Docs/TagInfo/mapcomplete_climbing.json @@ -60,6 +60,126 @@ "key": "opening_hours", "description": "Layer 'Climbing club' shows and asks freeform values for key 'opening_hours' (in the MapComplete.osm.be theme 'Open Climbing Map')" }, + { + "key": "url", + "description": "Layer 'Climbing club' shows and asks freeform values for key 'url' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "access", + "description": "Layer 'Climbing club' shows access=yes with a fixed text, namely 'Publicly accessible to anyone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "access", + "description": "Layer 'Climbing club' shows access=permit with a fixed text, namely 'You need a permit to access here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "permit" + }, + { + "key": "access", + "description": "Layer 'Climbing club' shows access=customers with a fixed text, namely 'Only custumers' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "customers" + }, + { + "key": "access", + "description": "Layer 'Climbing club' shows access=members with a fixed text, namely 'Only club members' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "members" + }, + { + "key": "access", + "description": "Layer 'Climbing club' shows access=no with a fixed text, namely 'Not accessible' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "access:description", + "description": "Layer 'Climbing club' shows values with key 'access:description' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:length", + "description": "Layer 'Climbing club' shows and asks freeform values for key 'climbing:length' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:min", + "description": "Layer 'Climbing club' shows and asks freeform values for key 'climbing:grade:french:min' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:max", + "description": "Layer 'Climbing club' shows and asks freeform values for key 'climbing:grade:french:max' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing club' shows climbing:boulder=yes with a fixed text, namely 'Bouldering is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing club' shows climbing:boulder=no with a fixed text, namely 'Bouldering is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing club' shows climbing:boulder=limited with a fixed text, namely 'Bouldering is possible, allthough there are only a few routes' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "limited" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing club' shows climbing:boulder~^..*$ with a fixed text, namely 'There are {climbing:boulder} boulder routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing club' shows climbing:toprope=yes with a fixed text, namely 'Toprope climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing club' shows climbing:toprope=no with a fixed text, namely 'Toprope climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing club' shows climbing:toprope~^..*$ with a fixed text, namely 'There are {climbing:toprope} toprope routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing club' shows climbing:sport=yes with a fixed text, namely 'Sport climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing club' shows climbing:sport=no with a fixed text, namely 'Sport climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing club' shows climbing:sport~^..*$ with a fixed text, namely 'There are {climbing:sport} sport climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing club' shows climbing:traditional=yes with a fixed text, namely 'Traditional climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing club' shows climbing:traditional=no with a fixed text, namely 'Traditional climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing club' shows climbing:traditional~^..*$ with a fixed text, namely 'There are {climbing:traditional} traditional climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing club' shows climbing:speed=yes with a fixed text, namely 'There is a speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing club' shows climbing:speed=no with a fixed text, namely 'There is no speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing club' shows climbing:speed~^..*$ with a fixed text, namely 'There are {climbing:speed} speed climbing walls' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, { "key": "sport", "description": "The MapComplete theme Open Climbing Map has a layer Climbing gyms showing features with this tag", @@ -118,6 +238,126 @@ "key": "opening_hours", "description": "Layer 'Climbing gyms' shows and asks freeform values for key 'opening_hours' (in the MapComplete.osm.be theme 'Open Climbing Map')" }, + { + "key": "url", + "description": "Layer 'Climbing gyms' shows and asks freeform values for key 'url' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "access", + "description": "Layer 'Climbing gyms' shows access=yes with a fixed text, namely 'Publicly accessible to anyone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "access", + "description": "Layer 'Climbing gyms' shows access=permit with a fixed text, namely 'You need a permit to access here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "permit" + }, + { + "key": "access", + "description": "Layer 'Climbing gyms' shows access=customers with a fixed text, namely 'Only custumers' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "customers" + }, + { + "key": "access", + "description": "Layer 'Climbing gyms' shows access=members with a fixed text, namely 'Only club members' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "members" + }, + { + "key": "access", + "description": "Layer 'Climbing gyms' shows access=no with a fixed text, namely 'Not accessible' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "access:description", + "description": "Layer 'Climbing gyms' shows values with key 'access:description' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:length", + "description": "Layer 'Climbing gyms' shows and asks freeform values for key 'climbing:length' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:min", + "description": "Layer 'Climbing gyms' shows and asks freeform values for key 'climbing:grade:french:min' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:max", + "description": "Layer 'Climbing gyms' shows and asks freeform values for key 'climbing:grade:french:max' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing gyms' shows climbing:boulder=yes with a fixed text, namely 'Bouldering is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing gyms' shows climbing:boulder=no with a fixed text, namely 'Bouldering is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing gyms' shows climbing:boulder=limited with a fixed text, namely 'Bouldering is possible, allthough there are only a few routes' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "limited" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing gyms' shows climbing:boulder~^..*$ with a fixed text, namely 'There are {climbing:boulder} boulder routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing gyms' shows climbing:toprope=yes with a fixed text, namely 'Toprope climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing gyms' shows climbing:toprope=no with a fixed text, namely 'Toprope climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing gyms' shows climbing:toprope~^..*$ with a fixed text, namely 'There are {climbing:toprope} toprope routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing gyms' shows climbing:sport=yes with a fixed text, namely 'Sport climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing gyms' shows climbing:sport=no with a fixed text, namely 'Sport climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing gyms' shows climbing:sport~^..*$ with a fixed text, namely 'There are {climbing:sport} sport climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing gyms' shows climbing:traditional=yes with a fixed text, namely 'Traditional climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing gyms' shows climbing:traditional=no with a fixed text, namely 'Traditional climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing gyms' shows climbing:traditional~^..*$ with a fixed text, namely 'There are {climbing:traditional} traditional climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing gyms' shows climbing:speed=yes with a fixed text, namely 'There is a speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing gyms' shows climbing:speed=no with a fixed text, namely 'There is no speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing gyms' shows climbing:speed~^..*$ with a fixed text, namely 'There are {climbing:speed} speed climbing walls' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, { "key": "climbing", "description": "The MapComplete theme Open Climbing Map has a layer Climbing routes showing features with this tag", @@ -179,6 +419,126 @@ "key": "description", "description": "Layer 'Climbing routes' shows and asks freeform values for key 'description' (in the MapComplete.osm.be theme 'Open Climbing Map')" }, + { + "key": "url", + "description": "Layer 'Climbing routes' shows and asks freeform values for key 'url' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "access", + "description": "Layer 'Climbing routes' shows access=yes with a fixed text, namely 'Publicly accessible to anyone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "access", + "description": "Layer 'Climbing routes' shows access=permit with a fixed text, namely 'You need a permit to access here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "permit" + }, + { + "key": "access", + "description": "Layer 'Climbing routes' shows access=customers with a fixed text, namely 'Only custumers' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "customers" + }, + { + "key": "access", + "description": "Layer 'Climbing routes' shows access=members with a fixed text, namely 'Only club members' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "members" + }, + { + "key": "access", + "description": "Layer 'Climbing routes' shows access=no with a fixed text, namely 'Not accessible' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "access:description", + "description": "Layer 'Climbing routes' shows values with key 'access:description' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:length", + "description": "Layer 'Climbing routes' shows and asks freeform values for key 'climbing:length' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:min", + "description": "Layer 'Climbing routes' shows and asks freeform values for key 'climbing:grade:french:min' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:max", + "description": "Layer 'Climbing routes' shows and asks freeform values for key 'climbing:grade:french:max' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing routes' shows climbing:boulder=yes with a fixed text, namely 'Bouldering is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing routes' shows climbing:boulder=no with a fixed text, namely 'Bouldering is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing routes' shows climbing:boulder=limited with a fixed text, namely 'Bouldering is possible, allthough there are only a few routes' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "limited" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing routes' shows climbing:boulder~^..*$ with a fixed text, namely 'There are {climbing:boulder} boulder routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing routes' shows climbing:toprope=yes with a fixed text, namely 'Toprope climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing routes' shows climbing:toprope=no with a fixed text, namely 'Toprope climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing routes' shows climbing:toprope~^..*$ with a fixed text, namely 'There are {climbing:toprope} toprope routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing routes' shows climbing:sport=yes with a fixed text, namely 'Sport climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing routes' shows climbing:sport=no with a fixed text, namely 'Sport climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing routes' shows climbing:sport~^..*$ with a fixed text, namely 'There are {climbing:sport} sport climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing routes' shows climbing:traditional=yes with a fixed text, namely 'Traditional climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing routes' shows climbing:traditional=no with a fixed text, namely 'Traditional climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing routes' shows climbing:traditional~^..*$ with a fixed text, namely 'There are {climbing:traditional} traditional climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing routes' shows climbing:speed=yes with a fixed text, namely 'There is a speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing routes' shows climbing:speed=no with a fixed text, namely 'There is no speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing routes' shows climbing:speed~^..*$ with a fixed text, namely 'There are {climbing:speed} speed climbing walls' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, { "key": "sport", "description": "The MapComplete theme Open Climbing Map has a layer Climbing opportunities showing features with this tag", @@ -238,6 +598,126 @@ "description": "Layer 'Climbing opportunities' shows rock=limestone with a fixed text, namely 'Limestone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", "value": "limestone" }, + { + "key": "url", + "description": "Layer 'Climbing opportunities' shows and asks freeform values for key 'url' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities' shows access=yes with a fixed text, namely 'Publicly accessible to anyone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities' shows access=permit with a fixed text, namely 'You need a permit to access here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "permit" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities' shows access=customers with a fixed text, namely 'Only custumers' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "customers" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities' shows access=members with a fixed text, namely 'Only club members' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "members" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities' shows access=no with a fixed text, namely 'Not accessible' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "access:description", + "description": "Layer 'Climbing opportunities' shows values with key 'access:description' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:length", + "description": "Layer 'Climbing opportunities' shows and asks freeform values for key 'climbing:length' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:min", + "description": "Layer 'Climbing opportunities' shows and asks freeform values for key 'climbing:grade:french:min' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:max", + "description": "Layer 'Climbing opportunities' shows and asks freeform values for key 'climbing:grade:french:max' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities' shows climbing:boulder=yes with a fixed text, namely 'Bouldering is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities' shows climbing:boulder=no with a fixed text, namely 'Bouldering is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities' shows climbing:boulder=limited with a fixed text, namely 'Bouldering is possible, allthough there are only a few routes' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "limited" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities' shows climbing:boulder~^..*$ with a fixed text, namely 'There are {climbing:boulder} boulder routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities' shows climbing:toprope=yes with a fixed text, namely 'Toprope climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities' shows climbing:toprope=no with a fixed text, namely 'Toprope climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities' shows climbing:toprope~^..*$ with a fixed text, namely 'There are {climbing:toprope} toprope routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities' shows climbing:sport=yes with a fixed text, namely 'Sport climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities' shows climbing:sport=no with a fixed text, namely 'Sport climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities' shows climbing:sport~^..*$ with a fixed text, namely 'There are {climbing:sport} sport climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities' shows climbing:traditional=yes with a fixed text, namely 'Traditional climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities' shows climbing:traditional=no with a fixed text, namely 'Traditional climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities' shows climbing:traditional~^..*$ with a fixed text, namely 'There are {climbing:traditional} traditional climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities' shows climbing:speed=yes with a fixed text, namely 'There is a speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities' shows climbing:speed=no with a fixed text, namely 'There is no speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities' shows climbing:speed~^..*$ with a fixed text, namely 'There are {climbing:speed} speed climbing walls' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, { "key": "leisure", "description": "The MapComplete theme Open Climbing Map has a layer Climbing opportunities? showing features with this tag", @@ -283,6 +763,126 @@ "description": "Layer 'Climbing opportunities?' shows climbing=no with a fixed text, namely 'Climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", "value": "no" }, + { + "key": "url", + "description": "Layer 'Climbing opportunities?' shows and asks freeform values for key 'url' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities?' shows access=yes with a fixed text, namely 'Publicly accessible to anyone' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities?' shows access=permit with a fixed text, namely 'You need a permit to access here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "permit" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities?' shows access=customers with a fixed text, namely 'Only custumers' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "customers" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities?' shows access=members with a fixed text, namely 'Only club members' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "members" + }, + { + "key": "access", + "description": "Layer 'Climbing opportunities?' shows access=no with a fixed text, namely 'Not accessible' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "access:description", + "description": "Layer 'Climbing opportunities?' shows values with key 'access:description' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:length", + "description": "Layer 'Climbing opportunities?' shows and asks freeform values for key 'climbing:length' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:min", + "description": "Layer 'Climbing opportunities?' shows and asks freeform values for key 'climbing:grade:french:min' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:grade:french:max", + "description": "Layer 'Climbing opportunities?' shows and asks freeform values for key 'climbing:grade:french:max' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities?' shows climbing:boulder=yes with a fixed text, namely 'Bouldering is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities?' shows climbing:boulder=no with a fixed text, namely 'Bouldering is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities?' shows climbing:boulder=limited with a fixed text, namely 'Bouldering is possible, allthough there are only a few routes' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "limited" + }, + { + "key": "climbing:boulder", + "description": "Layer 'Climbing opportunities?' shows climbing:boulder~^..*$ with a fixed text, namely 'There are {climbing:boulder} boulder routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities?' shows climbing:toprope=yes with a fixed text, namely 'Toprope climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities?' shows climbing:toprope=no with a fixed text, namely 'Toprope climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:toprope", + "description": "Layer 'Climbing opportunities?' shows climbing:toprope~^..*$ with a fixed text, namely 'There are {climbing:toprope} toprope routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities?' shows climbing:sport=yes with a fixed text, namely 'Sport climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities?' shows climbing:sport=no with a fixed text, namely 'Sport climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:sport", + "description": "Layer 'Climbing opportunities?' shows climbing:sport~^..*$ with a fixed text, namely 'There are {climbing:sport} sport climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities?' shows climbing:traditional=yes with a fixed text, namely 'Traditional climbing is possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities?' shows climbing:traditional=no with a fixed text, namely 'Traditional climbing is not possible here' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:traditional", + "description": "Layer 'Climbing opportunities?' shows climbing:traditional~^..*$ with a fixed text, namely 'There are {climbing:traditional} traditional climbing routes' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities?' shows climbing:speed=yes with a fixed text, namely 'There is a speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "yes" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities?' shows climbing:speed=no with a fixed text, namely 'There is no speed climbing wall' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Open Climbing Map')", + "value": "no" + }, + { + "key": "climbing:speed", + "description": "Layer 'Climbing opportunities?' shows climbing:speed~^..*$ with a fixed text, namely 'There are {climbing:speed} speed climbing walls' (in the MapComplete.osm.be theme 'Open Climbing Map')" + }, { "key": "id", "description": "The MapComplete theme Open Climbing Map has a layer Your track showing features with this tag", diff --git a/Docs/TagInfo/mapcomplete_cyclestreets.json b/Docs/TagInfo/mapcomplete_cyclestreets.json index f661dbf580..1b90cca1a4 100644 --- a/Docs/TagInfo/mapcomplete_cyclestreets.json +++ b/Docs/TagInfo/mapcomplete_cyclestreets.json @@ -31,6 +31,65 @@ "key": "wikipedia", "description": "The layer 'Cyclestreets allows to upload images and adds them under the 'image'-tag (and image:0, image:1, ... for multiple images). Furhtermore, this layer shows images based on the keys image, wikidata, wikipedia, wikimedia_commons and mapillary" }, + { + "key": "cyclestreet", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "maxspeed", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "30" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "no" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Cyclestreets' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'Cyclestreets' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Cyclestreets' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "cyclestreet", + "description": "Layer 'Cyclestreets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Cyclestreets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'Cyclestreets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key overtaking:motor_vehicle.", + "value": "" + }, + { + "key": "cyclestreet:start_date", + "description": "Layer 'Cyclestreets' shows and asks freeform values for key 'cyclestreet:start_date' (in the MapComplete.osm.be theme 'Cyclestreets')" + }, { "key": "proposed:cyclestreet", "description": "The MapComplete theme Cyclestreets has a layer Future cyclestreet showing features with this tag", @@ -52,6 +111,65 @@ "key": "wikipedia", "description": "The layer 'Future cyclestreet allows to upload images and adds them under the 'image'-tag (and image:0, image:1, ... for multiple images). Furhtermore, this layer shows images based on the keys image, wikidata, wikipedia, wikimedia_commons and mapillary" }, + { + "key": "cyclestreet", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "maxspeed", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "30" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "no" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Future cyclestreet' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'Future cyclestreet' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Future cyclestreet' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "cyclestreet", + "description": "Layer 'Future cyclestreet' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'Future cyclestreet' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'Future cyclestreet' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key overtaking:motor_vehicle.", + "value": "" + }, + { + "key": "cyclestreet:start_date", + "description": "Layer 'Future cyclestreet' shows and asks freeform values for key 'cyclestreet:start_date' (in the MapComplete.osm.be theme 'Cyclestreets')" + }, { "key": "highway", "description": "The MapComplete theme Cyclestreets has a layer All streets showing features with this tag", @@ -83,6 +201,65 @@ "key": "wikipedia", "description": "The layer 'All streets allows to upload images and adds them under the 'image'-tag (and image:0, image:1, ... for multiple images). Furhtermore, this layer shows images based on the keys image, wikidata, wikipedia, wikimedia_commons and mapillary" }, + { + "key": "cyclestreet", + "description": "Layer 'All streets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "maxspeed", + "description": "Layer 'All streets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "30" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'All streets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "no" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'All streets' shows cyclestreet=yes&maxspeed=30&overtaking:motor_vehicle=no with a fixed text, namely 'This street is a cyclestreet (and has a speed limit of 30 km/h)' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'All streets' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'All streets' shows cyclestreet=yes with a fixed text, namely 'This street is a cyclestreet' (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "cyclestreet", + "description": "Layer 'All streets' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'All streets' shows proposed:cyclestreet=yes with a fixed text, namely 'This street will become a cyclstreet soon' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets')", + "value": "yes" + }, + { + "key": "cyclestreet", + "description": "Layer 'All streets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key cyclestreet.", + "value": "" + }, + { + "key": "proposed:cyclestreet", + "description": "Layer 'All streets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key proposed:cyclestreet.", + "value": "" + }, + { + "key": "overtaking:motor_vehicle", + "description": "Layer 'All streets' shows with a fixed text, namely 'This street is not a cyclestreet' and allows to pick this as a default answer (in the MapComplete.osm.be theme 'Cyclestreets') Picking this answer will delete the key overtaking:motor_vehicle.", + "value": "" + }, + { + "key": "cyclestreet:start_date", + "description": "Layer 'All streets' shows and asks freeform values for key 'cyclestreet:start_date' (in the MapComplete.osm.be theme 'Cyclestreets')" + }, { "key": "id", "description": "The MapComplete theme Cyclestreets has a layer Your track showing features with this tag", diff --git a/Docs/TagInfo/mapcomplete_cyclofix.json b/Docs/TagInfo/mapcomplete_cyclofix.json index 22513e9520..be98905344 100644 --- a/Docs/TagInfo/mapcomplete_cyclofix.json +++ b/Docs/TagInfo/mapcomplete_cyclofix.json @@ -50,6 +50,10 @@ "description": "The MapComplete theme Cyclofix - an open map for cyclists has a layer Bike cafe showing features with this tag", "value": "bicycle" }, + { + "key": "service:bicycle:.*", + "description": "The MapComplete theme Cyclofix - an open map for cyclists has a layer Bike cafe showing features with this tag" + }, { "key": "image", "description": "The layer 'Bike cafe allows to upload images and adds them under the 'image'-tag (and image:0, image:1, ... for multiple images). Furhtermore, this layer shows images based on the keys image, wikidata, wikipedia, wikimedia_commons and mapillary" diff --git a/Docs/TagInfo/mapcomplete_postboxes.json b/Docs/TagInfo/mapcomplete_postboxes.json index 58dbc0fb4a..882b8842d8 100644 --- a/Docs/TagInfo/mapcomplete_postboxes.json +++ b/Docs/TagInfo/mapcomplete_postboxes.json @@ -6,7 +6,7 @@ "project_url": "https://mapcomplete.osm.be/postboxes", "doc_url": "https://github.com/pietervdvn/MapComplete/tree/master/assets/themes/", "icon_url": "https://mapcomplete.osm.be/assets/themes/postboxes/postbox.svg", - "contact_name": "Pieter Vander Vennet, ", + "contact_name": "Pieter Vander Vennet, nicolelaine", "contact_email": "pietervdvn@posteo.net" }, "tags": [ diff --git a/Docs/TagInfo/mapcomplete_trees.json b/Docs/TagInfo/mapcomplete_trees.json index 0e6f4fe95d..55d685c341 100644 --- a/Docs/TagInfo/mapcomplete_trees.json +++ b/Docs/TagInfo/mapcomplete_trees.json @@ -33,7 +33,7 @@ }, { "key": "height", - "description": "Layer 'Tree' shows height~^^[0-9.]+$$ with a fixed text, namely 'Height: {height} m' (in the MapComplete.osm.be theme 'Trees')" + "description": "Layer 'Tree' shows height~^[0-9.]+$ with a fixed text, namely 'Height: {height} m' (in the MapComplete.osm.be theme 'Trees')" }, { "key": "leaf_type", diff --git a/assets/svg/nfc_card.svg b/assets/svg/nfc_card.svg new file mode 100644 index 0000000000..240a6be153 --- /dev/null +++ b/assets/svg/nfc_card.svg @@ -0,0 +1 @@ + diff --git a/assets/svg/payment_card.svg b/assets/svg/payment_card.svg new file mode 100644 index 0000000000..bd9392d330 --- /dev/null +++ b/assets/svg/payment_card.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/assets/themes/bicycle_rental/bicycle_rental.json b/assets/themes/bicycle_rental/bicycle_rental.json new file mode 100644 index 0000000000..e69de29bb2