From 05edc424c47729cb487e9d706897b7087bd52da0 Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Mon, 16 Nov 2020 12:20:20 +0100 Subject: [PATCH 1/6] Add base climbing theme. --- Customizations/AllKnownLayouts.ts | 2 + assets/themes/climbing/climbing.json | 273 +++++++++++++++++++++++++++ 2 files changed, 275 insertions(+) create mode 100644 assets/themes/climbing/climbing.json diff --git a/Customizations/AllKnownLayouts.ts b/Customizations/AllKnownLayouts.ts index e00ca6c21..348d5431b 100644 --- a/Customizations/AllKnownLayouts.ts +++ b/Customizations/AllKnownLayouts.ts @@ -15,6 +15,7 @@ import * as benches from "../assets/themes/benches/benches.json"; import * as charging_stations from "../assets/themes/charging_stations/charging_stations.json" import * as widths from "../assets/themes/widths/width.json" import * as drinking_water from "../assets/themes/drinking_water/drinking_water.json" +import * as climbing from "../assets/themes/climbing/climbing.json" import LayerConfig from "./JSON/LayerConfig"; import SharedLayers from "./SharedLayers"; import * as personal from "../assets/themes/personalLayout/personalLayout.json" @@ -60,6 +61,7 @@ export class AllKnownLayouts { new LayoutConfig(widths), new LayoutConfig(buurtnatuur), new LayoutConfig(bike_monitoring_stations), + new LayoutConfig(climbing), ]; diff --git a/assets/themes/climbing/climbing.json b/assets/themes/climbing/climbing.json new file mode 100644 index 000000000..d2cb0c3b2 --- /dev/null +++ b/assets/themes/climbing/climbing.json @@ -0,0 +1,273 @@ +{ + "id": "climbing", + "title": { + "nl": "Open Klimkaart", + "de": "Offene Kletterkarte", + "en": "Open Climbing Map" + }, + "description": { + "nl": "Op deze kaart vind je verschillende klimgelegenheden, zoals klimzalen, bolderzalen en klimmen in de natuur", + "de": "Auf dieser Karte finden Sie verschiedene Klettermöglichkeiten wie Kletterhallen, Boulderhallen und Felsen in der Natur.", + "en": "On this map you will find various climbing opportunities such as climbing gyms, bouldering halls and rocks in nature." + }, + "language": [ + "nl", + "de", + "en" + ], + "maintainer": "Christian Neumann ", + "icon": "https://d30y9cdsu7xlg0.cloudfront.net/png/45246-200.png", + "version": "0", + "startLat": 0, + "startLon": 0, + "startZoom": 1, + "widenFactor": 0.05, + "socialImage": "", + "layers": [ + { + "id": "climbing", + "name": { + "nl": "Klimgelegenheiden", + "de": "Klettergelegenheiten", + "en": "Climbing opportunities" + }, + "minzoom": 10, + "overpassTags": { + "and": [ + "sport=climbing", + "climbing!~route" + ] + }, + "title": { + "render": { + "nl": "Klimgelegenheid", + "de": "Klettergelegenheit", + "en": "Climbing opportunity" + }, + "mappings": [ + { + "if": { + "and": [ + "leisure=sports_centre" + ] + }, + "then": { + "nl": "Klimzaal", + "de": "Kletterhalle", + "en": "Climbing gym" + } + } + ] + }, + "description": { + "nl": "Een klimgelegenheid", + "de": "Eine Klettergelegenheit", + "en": "A climbing opportunity" + }, + "tagRenderings": [ + { + "mappings": [ + { + "if": { + "and": [ + "climbing:boulder=yes" + ] + }, + "then": { + "nl": "Bolderen kan hier", + "de": "Hier kann gebouldert werden", + "en": "Bouldering is possible here" + } + } + ] + }, + { + "mappings": [ + { + "if": { + "and": [ + "climbing:toprope=yes" + ] + }, + "then": { + "nl": "Toprope klimmen kan hier", + "de": "Toprope ist hier möglich", + "en": "Toprope is possible here" + } + } + ] + } + ], + "hideUnderlayingFeaturesMinPercentage": 0, + "icon": { + "render": "https://d30y9cdsu7xlg0.cloudfront.net/png/45246-200.png" + }, + "width": { + "render": "8" + }, + "iconSize": { + "render": "40,40,center" + }, + "color": { + "render": "#00f" + }, + "presets": [], + "wayHandling": 2 + }, + { + "id": "routes", + "name": { + "en": "", + "nl": "", + "de": "" + }, + "minzoom": 18, + "overpassTags": { + "and": [ + "sport=climbing", + "climbing=route" + ] + }, + "title": { + "render": { + "nl": "Klimroute", + "de": "Kletterroute", + "en": "Climbing route" + }, + "mappings": [ + { + "if": { + "and": [ + "name~*" + ] + }, + "then": { + "nl": "Klimroute {name}", + "de": "Kletterroute {name}", + "en": "Climbing route {name}" + } + } + ] + }, + "description": { + "nl": "Individuele klimroutes", + "de": "Kletterrouten", + "en": "Climbing routes" + }, + "tagRenderings": [ + { + "render": { + "nl": "Moeilijkheidsgraad {climbing:grade:french}", + "en": "Difficulty level {climbing:grade:french}", + "de": "Schwierigkeitsgrad {climbing:grade:french}" + }, + "question": { + "nl": "Wat is de moelijkheidsgraad van dit parcour?", + "en": "What is the difficulty of this route?", + "de": "Was ist die Schwierigkeit dieser Route?" + }, + "freeform": { + "key": "climbing:grade:french" + } + }, + { + "render": { + "de": "", + "en": "", + "nl": "Lengte {climbing:length}" + }, + "question": { + "de": "", + "en": "", + "nl": "Wat is de lengte in meter (van de grond tot het katrol?)" + }, + "freeform": { + "key": "climbing:length", + "type": "nat" + } + }, + { + "freeform": { + "key": "climbing:bolted", + "type": "nat" + }, + "render": { + "de": "", + "en": "", + "nl": "Aantal tussenhaken {climbing:bolted}" + }, + "question": { + "de": "", + "en": "", + "nl": "Hoeveel tussenhaken zijn er hier?" + } + }, + { + "render": { + "de": "", + "en": "", + "nl": "Deze route heet {name}" + }, + "question": { + "de": "", + "en": "", + "nl": "Wat is de naam van deze route?" + }, + "freeform": { + "key": "name", + "addExtraTags": [ + "noname=" + ] + }, + "mappings": [ + { + "if": { + "and": [ + "noname=yes", + "name=" + ] + }, + "then": { + "de": "", + "en": "", + "nl": "Deze route heeft geen naam" + } + } + ] + } + ], + "hideUnderlayingFeaturesMinPercentage": 1, + "icon": { + "render": "https://upload.wikimedia.org/wikipedia/commons/5/50/Green_Arrow_Up.svg" + }, + "width": { + "render": "4" + }, + "iconSize": { + "render": "20,20,center" + }, + "color": { + "render": "#0f0" + }, + "presets": [ + { + "tags": [ + "sport=climbing", + "climbing=route" + ], + "title": { + "de": "", + "en": "", + "nl": "Klimroute" + }, + "description": { + "de": "", + "en": "", + "nl": "Een klimroute op rots" + } + } + ] + } + ], + "roamingRenderings": [] +} From ed5bf8a527036a87ed98450c0284d9eb614377a2 Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Wed, 18 Nov 2020 12:48:41 +0100 Subject: [PATCH 2/6] Change climbing theme icons. --- assets/themes/climbing/climbing.json | 146 +++++++++++++++----- assets/themes/climbing/climbing_no_rope.svg | 71 ++++++++++ assets/themes/climbing/climbing_rope.svg | 81 +++++++++++ assets/themes/climbing/climbing_route.svg | 85 ++++++++++++ 4 files changed, 350 insertions(+), 33 deletions(-) create mode 100644 assets/themes/climbing/climbing_no_rope.svg create mode 100644 assets/themes/climbing/climbing_rope.svg create mode 100644 assets/themes/climbing/climbing_route.svg diff --git a/assets/themes/climbing/climbing.json b/assets/themes/climbing/climbing.json index d2cb0c3b2..a3c20d1bc 100644 --- a/assets/themes/climbing/climbing.json +++ b/assets/themes/climbing/climbing.json @@ -11,12 +11,11 @@ "en": "On this map you will find various climbing opportunities such as climbing gyms, bouldering halls and rocks in nature." }, "language": [ - "nl", "de", "en" ], "maintainer": "Christian Neumann ", - "icon": "https://d30y9cdsu7xlg0.cloudfront.net/png/45246-200.png", + "icon": "./assets/themes/climbing/climbing_no_rope.svg", "version": "0", "startLat": 0, "startLon": 0, @@ -28,7 +27,7 @@ "id": "climbing", "name": { "nl": "Klimgelegenheiden", - "de": "Klettergelegenheiten", + "de": "Klettermöglichkeiten", "en": "Climbing opportunities" }, "minzoom": 10, @@ -40,9 +39,9 @@ }, "title": { "render": { + "en": "Climbing opportunity", "nl": "Klimgelegenheid", - "de": "Klettergelegenheit", - "en": "Climbing opportunity" + "de": "Klettermöglichkeit" }, "mappings": [ { @@ -66,18 +65,56 @@ }, "tagRenderings": [ { + "render": "{website}", + "freeform": { + "key": "website" + } + }, + { + "render": "{phone}", + "freeform": { + "key": "phone" + } + }, + { + "render": "{email}", + "freeform": { + "key": "email" + } + }, + { + "render": "{opening_hours_table(opening_hours)}", + "freeform": { + "key": "opening_hours" + } + }, + { + "question": { + "de": "Kann hier gebouldert werden?", + "en": "Is bouldering possible here?" + }, "mappings": [ { - "if": { - "and": [ - "climbing:boulder=yes" - ] - }, + "if": "climbing:boulder=yes", "then": { - "nl": "Bolderen kan hier", "de": "Hier kann gebouldert werden", "en": "Bouldering is possible here" } + }, + { + "if": "climbing:boulder=no", + "then": { + "de": "Hier kann nicht gebouldert werden", + "en": "Bouldering is not possible here" + } + }, + { + "if": "climbing:boulder~*", + "then": { + "de": "Hier gibt es {climbing:boulder} Boulder-Routen", + "en": "There are {climbing:boulder} boulder routes" + }, + "hideInAnswer": true } ] }, @@ -100,7 +137,7 @@ ], "hideUnderlayingFeaturesMinPercentage": 0, "icon": { - "render": "https://d30y9cdsu7xlg0.cloudfront.net/png/45246-200.png" + "render": "./assets/themes/climbing/climbing_no_rope.svg" }, "width": { "render": "8" @@ -111,7 +148,23 @@ "color": { "render": "#00f" }, - "presets": [], + "presets": [ + { + "tags": [ + "sport=climbing" + ], + "title": { + "de": "Klettermöglichkeit", + "en": "", + "nl": "Kletterkarte" + }, + "description": { + "de": "", + "en": "", + "nl": "Een klimroute op rots" + } + } + ], "wayHandling": 2 }, { @@ -124,7 +177,6 @@ "minzoom": 18, "overpassTags": { "and": [ - "sport=climbing", "climbing=route" ] }, @@ -170,22 +222,6 @@ "key": "climbing:grade:french" } }, - { - "render": { - "de": "", - "en": "", - "nl": "Lengte {climbing:length}" - }, - "question": { - "de": "", - "en": "", - "nl": "Wat is de lengte in meter (van de grond tot het katrol?)" - }, - "freeform": { - "key": "climbing:length", - "type": "nat" - } - }, { "freeform": { "key": "climbing:bolted", @@ -238,7 +274,7 @@ ], "hideUnderlayingFeaturesMinPercentage": 1, "icon": { - "render": "https://upload.wikimedia.org/wikipedia/commons/5/50/Green_Arrow_Up.svg" + "render": "./assets/themes/climbing/climbing_route.svg" }, "width": { "render": "4" @@ -252,7 +288,6 @@ "presets": [ { "tags": [ - "sport=climbing", "climbing=route" ], "title": { @@ -269,5 +304,50 @@ ] } ], - "roamingRenderings": [] + "roamingRenderings": [ + { + "render": { + "en": "Name: {name}", + "nl": "Naam: {name}", + "de": "Name: {name}" + }, + "question": { + "en": "What is the name of this climbing opportunity?", + "nl": "Wat is de naam van dit Klimgelegenheid?", + "de": "Wie heißt diese Klettergelegenheit?" + }, + "freeform": { + "key": "name" + }, + "mappings": [ + { + "if": { + "and": [ + "noname=yes", + "name=" + ] + }, + "then": { + "en": "This climbing opportunity doesn't have a name", + "nl": "Dit Klimgelegenheid heeft geen naam", + "de": "Diese Klettergelegenheit hat keinen Namen" + } + } + ] + }, + { + "render": { + "de": "Die Routen sind durchschnittlich {climbing:length}m lang", + "en": "The routes are {climbing:length}m long in average" + }, + "question": { + "de": "Wie lang sind die Routen (durchschnittlich) in Metern?", + "en": "What is the (average) length of the routes in meters?" + }, + "freeform": { + "key": "climbing:length", + "type": "pnat" + } + } + ] } diff --git a/assets/themes/climbing/climbing_no_rope.svg b/assets/themes/climbing/climbing_no_rope.svg new file mode 100644 index 000000000..3703f4b9f --- /dev/null +++ b/assets/themes/climbing/climbing_no_rope.svg @@ -0,0 +1,71 @@ + +image/svg+xml + + + + + + diff --git a/assets/themes/climbing/climbing_rope.svg b/assets/themes/climbing/climbing_rope.svg new file mode 100644 index 000000000..f225524a4 --- /dev/null +++ b/assets/themes/climbing/climbing_rope.svg @@ -0,0 +1,81 @@ + +image/svg+xml + + + + + + + + diff --git a/assets/themes/climbing/climbing_route.svg b/assets/themes/climbing/climbing_route.svg new file mode 100644 index 000000000..e1829a86b --- /dev/null +++ b/assets/themes/climbing/climbing_route.svg @@ -0,0 +1,85 @@ + +image/svg+xml + + + + + + + + From 7e686cf52bb24d5ea95f1603c13ea62da6e46f3b Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Wed, 18 Nov 2020 12:50:06 +0100 Subject: [PATCH 3/6] Fix user badge profile link. --- UI/UserBadge.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UI/UserBadge.ts b/UI/UserBadge.ts index 04ffcd9ac..614c5c541 100644 --- a/UI/UserBadge.ts +++ b/UI/UserBadge.ts @@ -109,7 +109,7 @@ export class UserBadge extends UIElement { const userName = new Link( new FixedUiElement(user.name), - `https://www.openstreetmap.org/user/${user.name}'`, + `https://www.openstreetmap.org/user/${user.name}`, true); From 55a37624127ee1e73c86d038fe0c70be4fbed4d3 Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Wed, 18 Nov 2020 12:50:28 +0100 Subject: [PATCH 4/6] Fix upload for maintainers with email. --- Logic/Osm/ChangesetHandler.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Logic/Osm/ChangesetHandler.ts b/Logic/Osm/ChangesetHandler.ts index a432bc08a..5c23ac5f1 100644 --- a/Logic/Osm/ChangesetHandler.ts +++ b/Logic/Osm/ChangesetHandler.ts @@ -1,3 +1,4 @@ +import escapeHtml from "escape-html"; import {OsmConnection, UserDetails} from "./OsmConnection"; import {UIEventSource} from "../UIEventSource"; import {ElementStorage} from "../ElementStorage"; @@ -105,7 +106,7 @@ export class ChangesetHandler { ``, ``, surveySource, - layout.maintainer !== undefined ? `` : "", + layout.maintainer !== undefined ? `` : "", ``].join("") }, function (err, response) { if (response === undefined) { From 6145000c6b8c19ff2ef9fb59af9b5b5db93c0aa3 Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Thu, 19 Nov 2020 10:05:10 +0100 Subject: [PATCH 5/6] Fix comment in LayerConfigJson. --- Customizations/JSON/LayerConfigJson.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Customizations/JSON/LayerConfigJson.ts b/Customizations/JSON/LayerConfigJson.ts index 98df035ff..caa19d5e3 100644 --- a/Customizations/JSON/LayerConfigJson.ts +++ b/Customizations/JSON/LayerConfigJson.ts @@ -91,8 +91,8 @@ export interface LayerConfigJson { /** * Wayhandling: should a way/area be displayed as: * 0) The way itself - * 1) The centerpoint and the way - * 2) Only the centerpoint + * 1) Only the centerpoint + * 2) The centerpoint and the way */ wayHandling?: number; From 17d03f2639e1d02a3dcf39c563379863abea07d2 Mon Sep 17 00:00:00 2001 From: Christian Neumann Date: Thu, 19 Nov 2020 12:44:35 +0100 Subject: [PATCH 6/6] Update climbing tags and icons. --- assets/questions/questions.json | 48 ++- assets/themes/climbing/climbing.json | 468 ++++++++++++++---------- assets/themes/climbing/climbing_gym.svg | 86 +++++ 3 files changed, 403 insertions(+), 199 deletions(-) create mode 100644 assets/themes/climbing/climbing_gym.svg diff --git a/assets/questions/questions.json b/assets/questions/questions.json index 2595eab2c..557f1add4 100644 --- a/assets/questions/questions.json +++ b/assets/questions/questions.json @@ -1,8 +1,31 @@ { + "email": { + "render": "{email}", + "freeform": { + "key": "email", + "type": "email" + } + }, + "images": { "render": "{image_carousel()}{image_upload()}" }, - + + "opening_hours": { + "question": { + "en": "What are the opening hours of {name}?", + "de": "Was sind die Öffnungszeiten von {name}?" + }, + "render": { + "de": "

Öffnungszeiten

{opening_hours_table(opening_hours)}", + "en": "

Opening hours

{opening_hours_table(opening_hours)}" + }, + "freeform": { + "key": "opening_hours", + "type": "opening_hours" + } + }, + "osmlink": { "render": "", "mappings":[{ @@ -11,6 +34,18 @@ }] }, + "phone": { + "question": { + "en": "What is the phone number of {name}?", + "de": "Was ist die Telefonnummer von {name}?" + }, + "render": "{phone}", + "freeform": { + "key": "phone", + "type": "phone" + } + }, + "wikipedialink": { "render": "WP", "condition": "wikipedia~*" @@ -18,10 +53,11 @@ "website": { "question": { - "en": "What is the website of {name}?", - "nl": "Wat is de website van {name}?", - "fr": "Quel est le site internet de {name}?", - "gl": "Cal é a páxina web de {name}?" + "en": "What is the officical website of {name}?", + "de": "Was ist die offizielle Website von {name}?", + "nl": "Wat is de officiële website van {name}?", + "fr": "Quel est le site internet officiel de {name}?", + "gl": "Cal é a páxina web official de {name}?" }, "render": "{website}", "freeform": { @@ -29,4 +65,4 @@ "type": "url" } } -} \ No newline at end of file +} diff --git a/assets/themes/climbing/climbing.json b/assets/themes/climbing/climbing.json index a3c20d1bc..2ff41f7d1 100644 --- a/assets/themes/climbing/climbing.json +++ b/assets/themes/climbing/climbing.json @@ -34,7 +34,8 @@ "overpassTags": { "and": [ "sport=climbing", - "climbing!~route" + "climbing!~route", + "leisure!~sports_centre" ] }, "title": { @@ -42,21 +43,7 @@ "en": "Climbing opportunity", "nl": "Klimgelegenheid", "de": "Klettermöglichkeit" - }, - "mappings": [ - { - "if": { - "and": [ - "leisure=sports_centre" - ] - }, - "then": { - "nl": "Klimzaal", - "de": "Kletterhalle", - "en": "Climbing gym" - } - } - ] + } }, "description": { "nl": "Een klimgelegenheid", @@ -65,71 +52,31 @@ }, "tagRenderings": [ { - "render": "{website}", - "freeform": { - "key": "website" - } - }, - { - "render": "{phone}", - "freeform": { - "key": "phone" - } - }, - { - "render": "{email}", - "freeform": { - "key": "email" - } - }, - { - "render": "{opening_hours_table(opening_hours)}", - "freeform": { - "key": "opening_hours" - } - }, - { - "question": { - "de": "Kann hier gebouldert werden?", - "en": "Is bouldering possible here?" + "render": { + "en": "{name}", + "nl": "{name}", + "de": "{name}" + }, + "question": { + "en": "What is the name of this climbing opportunity?", + "nl": "Wat is de naam van dit Klimgelegenheid?", + "de": "Wie heißt diese Klettergelegenheit?" + }, + "freeform": { + "key": "name" }, - "mappings": [ - { - "if": "climbing:boulder=yes", - "then": { - "de": "Hier kann gebouldert werden", - "en": "Bouldering is possible here" - } - }, - { - "if": "climbing:boulder=no", - "then": { - "de": "Hier kann nicht gebouldert werden", - "en": "Bouldering is not possible here" - } - }, - { - "if": "climbing:boulder~*", - "then": { - "de": "Hier gibt es {climbing:boulder} Boulder-Routen", - "en": "There are {climbing:boulder} boulder routes" - }, - "hideInAnswer": true - } - ] - }, - { "mappings": [ { "if": { "and": [ - "climbing:toprope=yes" + "noname=yes", + "name=" ] }, "then": { - "nl": "Toprope klimmen kan hier", - "de": "Toprope ist hier möglich", - "en": "Toprope is possible here" + "en": "This climbing opportunity doesn't have a name", + "nl": "Dit Klimgelegenheid heeft geen naam", + "de": "Diese Klettergelegenheit hat keinen Namen" } } ] @@ -154,25 +101,79 @@ "sport=climbing" ], "title": { - "de": "Klettermöglichkeit", - "en": "", - "nl": "Kletterkarte" + "en": "Climbing opportunity", + "nl": "Klimgelegenheid", + "de": "Klettermöglichkeit" }, "description": { - "de": "", - "en": "", - "nl": "Een klimroute op rots" + "nl": "Een klimgelegenheid", + "de": "Eine Klettergelegenheit", + "en": "A climbing opportunity" } } ], - "wayHandling": 2 + "wayHandling": 1 }, { - "id": "routes", + "id": "climbing_gym", "name": { - "en": "", - "nl": "", - "de": "" + "de": "Kletterhallen", + "en": "Climbing gyms" + }, + "minzoom": 10, + "overpassTags": { + "and": [ + "sport=climbing", + "leisure=sports_centre" + ] + }, + "title": { + "render": { + "nl": "Klimzaal", + "de": "Kletterhalle", + "en": "Climbing gym" + } + }, + "description": { + "de": "Eine Kletterhalle", + "en": "A climbing gym" + }, + "tagRenderings": [ + { + "render": { + "en": "{name}", + "nl": "{name}", + "de": "{name}" + }, + "question": { + "en": "What is the name of this climbing gym?", + "nl": "Wat is de naam van dit Klimzaal?", + "de": "Wie heißt diese Kletterhalle?" + }, + "freeform": { + "key": "name" + } + }, + "website", + "phone", + "email", + "opening_hours" + ], + "hideUnderlayingFeaturesMinPercentage": 0, + "icon": { + "render": "./assets/themes/climbing/climbing_gym.svg" + }, + "width": "0", + "iconSize": { + "render": "40,40,center" + }, + "wayHandling": 1 + }, + { + "id": "climbing_route", + "name": { + "en": "Climbing routes", + "de": "Kletterrouten" }, "minzoom": 18, "overpassTags": { @@ -182,78 +183,23 @@ }, "title": { "render": { - "nl": "Klimroute", - "de": "Kletterroute", + "de": "Kleterroute", "en": "Climbing route" - }, - "mappings": [ - { - "if": { - "and": [ - "name~*" - ] - }, - "then": { - "nl": "Klimroute {name}", - "de": "Kletterroute {name}", - "en": "Climbing route {name}" - } - } - ] - }, - "description": { - "nl": "Individuele klimroutes", - "de": "Kletterrouten", - "en": "Climbing routes" + } }, "tagRenderings": [ { "render": { - "nl": "Moeilijkheidsgraad {climbing:grade:french}", - "en": "Difficulty level {climbing:grade:french}", - "de": "Schwierigkeitsgrad {climbing:grade:french}" + "en": "{name}", + "nl": "{name}", + "de": "{name}" }, "question": { - "nl": "Wat is de moelijkheidsgraad van dit parcour?", - "en": "What is the difficulty of this route?", - "de": "Was ist die Schwierigkeit dieser Route?" + "en": "What is the name of this climbing route?", + "de": "Wie heißt diese Kletterroute?" }, "freeform": { - "key": "climbing:grade:french" - } - }, - { - "freeform": { - "key": "climbing:bolted", - "type": "nat" - }, - "render": { - "de": "", - "en": "", - "nl": "Aantal tussenhaken {climbing:bolted}" - }, - "question": { - "de": "", - "en": "", - "nl": "Hoeveel tussenhaken zijn er hier?" - } - }, - { - "render": { - "de": "", - "en": "", - "nl": "Deze route heet {name}" - }, - "question": { - "de": "", - "en": "", - "nl": "Wat is de naam van deze route?" - }, - "freeform": { - "key": "name", - "addExtraTags": [ - "noname=" - ] + "key": "name" }, "mappings": [ { @@ -264,9 +210,8 @@ ] }, "then": { - "de": "", - "en": "", - "nl": "Deze route heeft geen naam" + "en": "This climbing route doesn't have a name", + "de": "Diese Kletterroute hat keinen Namen" } } ] @@ -284,62 +229,43 @@ }, "color": { "render": "#0f0" - }, - "presets": [ - { - "tags": [ - "climbing=route" - ], - "title": { - "de": "", - "en": "", - "nl": "Klimroute" - }, - "description": { - "de": "", - "en": "", - "nl": "Een klimroute op rots" - } - } - ] + } } ], "roamingRenderings": [ { - "render": { - "en": "Name: {name}", - "nl": "Naam: {name}", - "de": "Name: {name}" - }, "question": { - "en": "What is the name of this climbing opportunity?", - "nl": "Wat is de naam van dit Klimgelegenheid?", - "de": "Wie heißt diese Klettergelegenheit?" + "en": "Is there a (unofficial) website with more informations (e.g. topos)?", + "de": "Gibt es eine (inoffizielle) Website mit mehr Informationen (z.B. Topos)?" }, + "condition": { + "and": [ + "leisure!~sports_centre", + "sport=climbing" + ] + }, + "render": "{url}", "freeform": { - "key": "name" - }, - "mappings": [ - { - "if": { - "and": [ - "noname=yes", - "name=" - ] - }, - "then": { - "en": "This climbing opportunity doesn't have a name", - "nl": "Dit Klimgelegenheid heeft geen naam", - "de": "Diese Klettergelegenheit hat keinen Namen" - } - } - ] + "key": "url", + "type": "url" + } }, { "render": { "de": "Die Routen sind durchschnittlich {climbing:length}m lang", "en": "The routes are {climbing:length}m long in average" }, + "condition": { + "and": [ + "climbing!~route", + { + "or": [ + "climbing=sport", + "climbing=traditional" + ] + } + ] + }, "question": { "de": "Wie lang sind die Routen (durchschnittlich) in Metern?", "en": "What is the (average) length of the routes in meters?" @@ -348,6 +274,162 @@ "key": "climbing:length", "type": "pnat" } + }, + { + "question": { + "de": "Kann hier gebouldert werden?", + "en": "Is bouldering possible here?" + }, + "mappings": [ + { + "if": "climbing:boulder=yes", + "then": { + "de": "Hier kann gebouldert werden", + "en": "Bouldering is possible here" + } + }, + { + "if": "climbing:boulder=no", + "then": { + "de": "Hier kann nicht gebouldert werden", + "en": "Bouldering is not possible here" + } + }, + { + "if": "climbing:boulder~*", + "then": { + "de": "Hier gibt es {climbing:boulder} Boulder-Routen", + "en": "There are {climbing:boulder} boulder routes" + }, + "hideInAnswer": true + } + ] + }, + { + "question": { + "de": "Ist Toprope-Klettern hier möglich?", + "en": "Is toprope climbing possible here?" + }, + "mappings": [ + { + "if": "climbing:toprope=yes", + "then": { + "de": "Toprope-Klettern ist hier möglich", + "en": "Toprope climbing is possible here" + } + }, + { + "if": "climbing:toprope=no", + "then": { + "de": "Toprope-Climbing ist hier nicht möglich", + "en": "Toprope climbing is not possible here" + } + }, + { + "if": "climbing:toprope~*", + "then": { + "de": "Hier gibt es {climbing:toprope} Toprope-Routen", + "en": "There are {climbing:toprope} toprope routes" + }, + "hideInAnswer": true + } + ] + }, + { + "question": { + "de": "Ist hier Sportklettern möglich (feste Ankerpunkte)?", + "en": "Is sport climbing possible here (fixed anchors)?" + }, + "mappings": [ + { + "if": "climbing:sport=yes", + "then": { + "de": "Sportklettern ist hier möglich", + "en": "Sport climbing is possible here" + } + }, + { + "if": "climbing:sport=no", + "then": { + "de": "Sportklettern ist hier nicht möglich", + "en": "Sport climbing is not possible here" + } + }, + { + "if": "climbing:sport~*", + "then": { + "de": "Hier gibt es {climbing:sport} Sportkletter-Routen", + "en": "There are {climbing:sport} sport climbing routes" + }, + "hideInAnswer": true + } + ] + }, + { + "question": { + "de": "Ist hier traditionelles Klettern möglich (eigene Sicherung z.B. mit Klemmkleilen)?", + "en": "Is traditional climbing possible here (using own gear e.g. chocks)?" + }, + "mappings": [ + { + "if": "climbing:traditional=yes", + "then": { + "de": "Traditionelles Klettern ist hier möglich", + "en": "Traditional climbing is possible here" + } + }, + { + "if": "climbing:traditional=no", + "then": { + "de": "Traditionelles Klettern ist hier nicht möglich", + "en": "Traditional climbing is not possible here" + } + }, + { + "if": "climbing:traditional~*", + "then": { + "de": "Hier gibt es {climbing:traditional} Routen für traditionelles Klettern", + "en": "There are {climbing:traditional} traditional climbing routes" + }, + "hideInAnswer": true + } + ] + }, + { + "question": { + "de": "Gibt es hier eine Speedkletter-Wand?", + "en": "Is there a speed climbing wall?" + }, + "condition": { + "and": [ + "leisure=sports_centre", + "climbing:sport=yes" + ] + }, + "mappings": [ + { + "if": "climbing:speed=yes", + "then": { + "de": "Hier gibt es eine Speedkletter-Wand", + "en": "There is a speed climbing wall" + } + }, + { + "if": "climbing:speed=no", + "then": { + "de": "Hier gibt es keine Speedkletter-Wand", + "en": "There is no speed climbing wall" + } + }, + { + "if": "climbing:speed~*", + "then": { + "de": "Hier gibt es {climbing:speed} Speedkletter-Routen", + "en": "There are {climbing:speed} speed climbing walls" + }, + "hideInAnswer": true + } + ] } ] } diff --git a/assets/themes/climbing/climbing_gym.svg b/assets/themes/climbing/climbing_gym.svg new file mode 100644 index 000000000..6818a8f19 --- /dev/null +++ b/assets/themes/climbing/climbing_gym.svg @@ -0,0 +1,86 @@ + +image/svg+xml + + + + + +