From 2742f03ebfd2b70b7b779c4af7628c61f7ab69d5 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Thu, 17 Feb 2022 23:58:03 +0100 Subject: [PATCH 01/24] First fixes for charging station theme --- .../charging_station/charging_station.json | 1089 +++++++++++------ assets/layers/charging_station/csvToJson.ts | 38 +- 2 files changed, 747 insertions(+), 380 deletions(-) diff --git a/assets/layers/charging_station/charging_station.json b/assets/layers/charging_station/charging_station.json index 7058dac84..33c290f16 100644 --- a/assets/layers/charging_station/charging_station.json +++ b/assets/layers/charging_station/charging_station.json @@ -2,8 +2,7 @@ "id": "charging_station", "name": { "en": "Charging stations", - "nl": "Oplaadpunten", - "de": "Ladestationen" + "nl": "Oplaadpunten" }, "minzoom": 10, "source": { @@ -39,7 +38,7 @@ ] }, "then": { - "en": "Charging station for ebikes", + "en": "Charging station for electrical bicycles", "nl": "Oplaadpunt voor elektrische fietsen" } }, @@ -64,8 +63,7 @@ }, "description": { "en": "A charging station", - "nl": "Oplaadpunten", - "de": "Eine Ladestation" + "nl": "Oplaadpunten" }, "tagRenderings": [ "images", @@ -74,9 +72,7 @@ "#": "Allowed vehicle types", "question": { "en": "Which vehicles are allowed to charge here?", - "nl": "Welke voertuigen kunnen hier opgeladen worden?", - "de": "Welche Fahrzeuge dürfen hier laden?", - "es": "¿A qué vehículos se permite la carga aquí?" + "nl": "Welke voertuigen kunnen hier opgeladen worden?" }, "multiAnswer": true, "mappings": [ @@ -85,8 +81,7 @@ "ifnot": "bicycle=no", "then": { "en": "Bicycles can be charged here", - "nl": "Elektrische fietsen kunnen hier opgeladen worden", - "de": "Fahrräder können hier geladen werden" + "nl": "Elektrische fietsen kunnen hier opgeladen worden" } }, { @@ -94,8 +89,7 @@ "ifnot": "motorcar=no", "then": { "en": "Cars can be charged here", - "nl": "Elektrische auto's kunnen hier opgeladen worden", - "de": "Autos können hier geladen werden" + "nl": "Elektrische auto's kunnen hier opgeladen worden" } }, { @@ -103,8 +97,7 @@ "ifnot": "scooter=no", "then": { "en": "Scooters can be charged here", - "nl": "Elektrische scooters (snorfiets of bromfiets) kunnen hier opgeladen worden", - "de": "Roller können hier geladen werden" + "nl": "Elektrische scooters (snorfiets of bromfiets) kunnen hier opgeladen worden" } }, { @@ -112,8 +105,7 @@ "ifnot": "hgv=no", "then": { "en": "Heavy good vehicles (such as trucks) can be charged here", - "nl": "Vrachtwagens kunnen hier opgeladen worden", - "de": "LKW können hier geladen werden" + "nl": "Vrachtwagens kunnen hier opgeladen worden" } }, { @@ -121,8 +113,7 @@ "ifnot": "bus=no", "then": { "en": "Buses can be charged here", - "nl": "Bussen kunnen hier opgeladen worden", - "de": "Busse können hier geladen werden" + "nl": "Bussen kunnen hier opgeladen worden" } } ] @@ -199,8 +190,7 @@ "id": "Available_charging_stations (generated)", "question": { "en": "Which charging connections are available here?", - "nl": "Welke aansluitingen zijn hier beschikbaar?", - "de": "Welche Ladeanschlüsse gibt es hier?" + "nl": "Welke aansluitingen zijn hier beschikbaar?" }, "multiAnswer": true, "mappings": [ @@ -208,8 +198,12 @@ "if": "socket:schuko=1", "ifnot": "socket:schuko=", "then": { - "en": "
Schuko wall plug without ground pin (CEE7/4 type F)
", - "nl": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
" + "en": "Schuko wall plug without ground pin (CEE7/4 type F)", + "nl": "Schuko stekker zonder aardingspin (CEE7/4 type F)" + }, + "icon": { + "path": "./assets/layers/charging_station/CEE7_4F.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -232,17 +226,25 @@ ] }, "then": { - "en": "
Schuko wall plug without ground pin (CEE7/4 type F)
", - "nl": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
" + "en": "Schuko wall plug without ground pin (CEE7/4 type F)", + "nl": "Schuko stekker zonder aardingspin (CEE7/4 type F)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "CEE7_4F.svg", + "class": "medium" + } }, { "if": "socket:typee=1", "ifnot": "socket:typee=", "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
" + "en": "European wall plug with ground pin (CEE7/4 type E)", + "nl": "Europese stekker met aardingspin (CEE7/4 type E)" + }, + "icon": { + "path": "./assets/layers/charging_station/TypeE.svg", + "class": "medium" } }, { @@ -253,17 +255,25 @@ ] }, "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
" + "en": "European wall plug with ground pin (CEE7/4 type E)", + "nl": "Europese stekker met aardingspin (CEE7/4 type E)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "TypeE.svg", + "class": "medium" + } }, { "if": "socket:chademo=1", "ifnot": "socket:chademo=", "then": { - "en": "
Chademo
", - "nl": "
Chademo
" + "en": "Chademo", + "nl": "Chademo" + }, + "icon": { + "path": "./assets/layers/charging_station/Chademo_type4.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -300,17 +310,25 @@ ] }, "then": { - "en": "
Chademo
", - "nl": "
Chademo
" + "en": "Chademo", + "nl": "Chademo" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Chademo_type4.svg", + "class": "medium" + } }, { "if": "socket:type1_cable=1", "ifnot": "socket:type1_cable=", "then": { - "en": "
Type 1 with cable (J1772)
", - "nl": "
Type 1 met kabel (J1772)
" + "en": "Type 1 with cable (J1772)", + "nl": "Type 1 met kabel (J1772)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -347,17 +365,25 @@ ] }, "then": { - "en": "
Type 1 with cable (J1772)
", - "nl": "
Type 1 met kabel (J1772)
" + "en": "Type 1 with cable (J1772)", + "nl": "Type 1 met kabel (J1772)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type1_J1772.svg", + "class": "medium" + } }, { "if": "socket:type1=1", "ifnot": "socket:type1=", "then": { - "en": "
Type 1 without cable (J1772)
", - "nl": "
Type 1 zonder kabel (J1772)
" + "en": "Type 1 without cable (J1772)", + "nl": "Type 1 zonder kabel (J1772)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -394,17 +420,25 @@ ] }, "then": { - "en": "
Type 1 without cable (J1772)
", - "nl": "
Type 1 zonder kabel (J1772)
" + "en": "Type 1 without cable (J1772)", + "nl": "Type 1 zonder kabel (J1772)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type1_J1772.svg", + "class": "medium" + } }, { "if": "socket:type1_combo=1", "ifnot": "socket:type1_combo=", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
" + "en": "Type 1 CCS (aka Type 1 Combo)", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -441,17 +475,25 @@ ] }, "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
" + "en": "Type 1 CCS (aka Type 1 Combo)", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type1-ccs.svg", + "class": "medium" + } }, { "if": "socket:tesla_supercharger=1", "ifnot": "socket:tesla_supercharger=", "then": { - "en": "
Tesla Supercharger
", - "nl": "
Tesla Supercharger
" + "en": "Tesla Supercharger", + "nl": "Tesla Supercharger" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -488,17 +530,25 @@ ] }, "then": { - "en": "
Tesla Supercharger
", - "nl": "
Tesla Supercharger
" + "en": "Tesla Supercharger", + "nl": "Tesla Supercharger" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Tesla-hpwc-model-s.svg", + "class": "medium" + } }, { "if": "socket:type2=1", "ifnot": "socket:type2=", "then": { - "en": "
Type 2 (mennekes)
", - "nl": "
Type 2 (mennekes)
" + "en": "Type 2 (mennekes)", + "nl": "Type 2 (mennekes)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -535,17 +585,25 @@ ] }, "then": { - "en": "
Type 2 (mennekes)
", - "nl": "
Type 2 (mennekes)
" + "en": "Type 2 (mennekes)", + "nl": "Type 2 (mennekes)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type2_socket.svg", + "class": "medium" + } }, { "if": "socket:type2_combo=1", "ifnot": "socket:type2_combo=", "then": { - "en": "
Type 2 CCS (mennekes)
", - "nl": "
Type 2 CCS (mennekes)
" + "en": "Type 2 CCS (mennekes)", + "nl": "Type 2 CCS (mennekes)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -582,17 +640,25 @@ ] }, "then": { - "en": "
Type 2 CCS (mennekes)
", - "nl": "
Type 2 CCS (mennekes)
" + "en": "Type 2 CCS (mennekes)", + "nl": "Type 2 CCS (mennekes)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type2_CCS.svg", + "class": "medium" + } }, { "if": "socket:type2_cable=1", "ifnot": "socket:type2_cable=", "then": { - "en": "
Type 2 with cable (mennekes)
", - "nl": "
Type 2 met kabel (J1772)
" + "en": "Type 2 with cable (mennekes)", + "nl": "Type 2 met kabel (J1772)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -629,17 +695,25 @@ ] }, "then": { - "en": "
Type 2 with cable (mennekes)
", - "nl": "
Type 2 met kabel (J1772)
" + "en": "Type 2 with cable (mennekes)", + "nl": "Type 2 met kabel (J1772)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type2_tethered.svg", + "class": "medium" + } }, { "if": "socket:tesla_supercharger_ccs=1", "ifnot": "socket:tesla_supercharger_ccs=", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
" + "en": "Tesla Supercharger CCS (a branded type2_css)", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -676,17 +750,25 @@ ] }, "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
" + "en": "Tesla Supercharger CCS (a branded type2_css)", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type2_CCS.svg", + "class": "medium" + } }, { "if": "socket:tesla_destination=1", "ifnot": "socket:tesla_destination=", "then": { - "en": "
Tesla Supercharger (destination)
", - "nl": "
Tesla Supercharger (destination)
" + "en": "Tesla Supercharger (destination)", + "nl": "Tesla Supercharger (destination)" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -729,17 +811,25 @@ ] }, "then": { - "en": "
Tesla Supercharger (destination)
", - "nl": "
Tesla Supercharger (destination)
" + "en": "Tesla Supercharger (destination)", + "nl": "Tesla Supercharger (destination)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Tesla-hpwc-model-s.svg", + "class": "medium" + } }, { "if": "socket:tesla_destination=1", "ifnot": "socket:tesla_destination=", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla)", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -782,17 +872,25 @@ ] }, "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla)", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "Type2_tethered.svg", + "class": "medium" + } }, { "if": "socket:USB-A=1", "ifnot": "socket:USB-A=", "then": { - "en": "
USB to charge phones and small electronics
", - "nl": "
USB om GSMs en kleine electronica op te laden
" + "en": "USB to charge phones and small electronics", + "nl": "USB om GSMs en kleine electronica op te laden" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } }, { @@ -803,17 +901,25 @@ ] }, "then": { - "en": "
USB to charge phones and small electronics
", - "nl": "
USB om GSMs en kleine electronica op te laden
" + "en": "USB to charge phones and small electronics", + "nl": "USB om GSMs en kleine electronica op te laden" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "usb_port.svg", + "class": "medium" + } }, { "if": "socket:bosch_3pin=1", "ifnot": "socket:bosch_3pin=", "then": { - "en": "
Bosch Active Connect with 3 pins and cable
", - "nl": "
Bosch Active Connect met 3 pinnen aan een kabel
" + "en": "Bosch Active Connect with 3 pins and cable", + "nl": "Bosch Active Connect met 3 pinnen aan een kabel" + }, + "icon": { + "path": "./assets/layers/charging_station/bosch-3pin.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -846,17 +952,25 @@ ] }, "then": { - "en": "
Bosch Active Connect with 3 pins and cable
", - "nl": "
Bosch Active Connect met 3 pinnen aan een kabel
" + "en": "Bosch Active Connect with 3 pins and cable", + "nl": "Bosch Active Connect met 3 pinnen aan een kabel" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "bosch-3pin.svg", + "class": "medium" + } }, { "if": "socket:bosch_5pin=1", "ifnot": "socket:bosch_5pin=", "then": { - "en": "
Bosch Active Connect with 5 pins and cable
", - "nl": "
Bosch Active Connect met 5 pinnen aan een kabel
" + "en": "Bosch Active Connect with 5 pins and cable", + "nl": "Bosch Active Connect met 5 pinnen aan een kabel" + }, + "icon": { + "path": "./assets/layers/charging_station/bosch-5pin.svg", + "class": "medium" }, "hideInAnswer": { "or": [ @@ -889,10 +1003,14 @@ ] }, "then": { - "en": "
Bosch Active Connect with 5 pins and cable
", - "nl": "
Bosch Active Connect met 5 pinnen aan een kabel
" + "en": "Bosch Active Connect with 5 pins and cable", + "nl": "Bosch Active Connect met 5 pinnen aan een kabel" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "bosch-5pin.svg", + "class": "medium" + } } ] }, @@ -1251,8 +1369,12 @@ { "if": "socket:socket:schuko:voltage=230 V", "then": { - "en": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs 230 volt", - "nl": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
heeft een spanning van 230 volt" + "en": "Schuko wall plug without ground pin (CEE7/4 type F) outputs 230 volt", + "nl": "Schuko stekker zonder aardingspin (CEE7/4 type F) heeft een spanning van 230 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/CEE7_4F.svg", + "class": "medium" } } ], @@ -1282,8 +1404,12 @@ { "if": "socket:socket:schuko:current=16 A", "then": { - "en": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs at most 16 A", - "nl": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
levert een stroom van maximaal 16 A" + "en": "Schuko wall plug without ground pin (CEE7/4 type F) outputs at most 16 A", + "nl": "Schuko stekker zonder aardingspin (CEE7/4 type F) levert een stroom van maximaal 16 A" + }, + "icon": { + "path": "./assets/layers/charging_station/CEE7_4F.svg", + "class": "medium" } } ], @@ -1313,8 +1439,12 @@ { "if": "socket:socket:schuko:output=3.6 kw", "then": { - "en": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs at most 3.6 kw", - "nl": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
levert een vermogen van maximaal 3.6 kw" + "en": "Schuko wall plug without ground pin (CEE7/4 type F) outputs at most 3.6 kw A", + "nl": "Schuko stekker zonder aardingspin (CEE7/4 type F) levert een vermogen van maximaal 3.6 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/CEE7_4F.svg", + "class": "medium" } } ], @@ -1344,8 +1474,12 @@ { "if": "socket:socket:typee:voltage=230 V", "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
outputs 230 volt", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
heeft een spanning van 230 volt" + "en": "European wall plug with ground pin (CEE7/4 type E) outputs 230 volt", + "nl": "Europese stekker met aardingspin (CEE7/4 type E) heeft een spanning van 230 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/TypeE.svg", + "class": "medium" } } ], @@ -1375,8 +1509,12 @@ { "if": "socket:socket:typee:current=16 A", "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 16 A", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een stroom van maximaal 16 A" + "en": "European wall plug with ground pin (CEE7/4 type E) outputs at most 16 A", + "nl": "Europese stekker met aardingspin (CEE7/4 type E) levert een stroom van maximaal 16 A" + }, + "icon": { + "path": "./assets/layers/charging_station/TypeE.svg", + "class": "medium" } } ], @@ -1406,15 +1544,23 @@ { "if": "socket:socket:typee:output=3 kw", "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 3 kw", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een vermogen van maximaal 3 kw" + "en": "European wall plug with ground pin (CEE7/4 type E) outputs at most 3 kw A", + "nl": "Europese stekker met aardingspin (CEE7/4 type E) levert een vermogen van maximaal 3 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/TypeE.svg", + "class": "medium" } }, { "if": "socket:socket:typee:output=22 kw", "then": { - "en": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 22 kw", - "nl": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een vermogen van maximaal 22 kw" + "en": "European wall plug with ground pin (CEE7/4 type E) outputs at most 22 kw A", + "nl": "Europese stekker met aardingspin (CEE7/4 type E) levert een vermogen van maximaal 22 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/TypeE.svg", + "class": "medium" } } ], @@ -1444,8 +1590,12 @@ { "if": "socket:socket:chademo:voltage=500 V", "then": { - "en": "
Chademo
outputs 500 volt", - "nl": "
Chademo
heeft een spanning van 500 volt" + "en": "Chademo outputs 500 volt", + "nl": "Chademo heeft een spanning van 500 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Chademo_type4.svg", + "class": "medium" } } ], @@ -1475,8 +1625,12 @@ { "if": "socket:socket:chademo:current=120 A", "then": { - "en": "
Chademo
outputs at most 120 A", - "nl": "
Chademo
levert een stroom van maximaal 120 A" + "en": "Chademo outputs at most 120 A", + "nl": "Chademo levert een stroom van maximaal 120 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Chademo_type4.svg", + "class": "medium" } } ], @@ -1506,8 +1660,12 @@ { "if": "socket:socket:chademo:output=50 kw", "then": { - "en": "
Chademo
outputs at most 50 kw", - "nl": "
Chademo
levert een vermogen van maximaal 50 kw" + "en": "Chademo outputs at most 50 kw A", + "nl": "Chademo levert een vermogen van maximaal 50 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Chademo_type4.svg", + "class": "medium" } } ], @@ -1537,15 +1695,23 @@ { "if": "socket:socket:type1_cable:voltage=200 V", "then": { - "en": "
Type 1 with cable (J1772)
outputs 200 volt", - "nl": "
Type 1 met kabel (J1772)
heeft een spanning van 200 volt" + "en": "Type 1 with cable (J1772) outputs 200 volt", + "nl": "Type 1 met kabel (J1772) heeft een spanning van 200 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1_cable:voltage=240 V", "then": { - "en": "
Type 1 with cable (J1772)
outputs 240 volt", - "nl": "
Type 1 met kabel (J1772)
heeft een spanning van 240 volt" + "en": "Type 1 with cable (J1772) outputs 240 volt", + "nl": "Type 1 met kabel (J1772) heeft een spanning van 240 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1575,8 +1741,12 @@ { "if": "socket:socket:type1_cable:current=32 A", "then": { - "en": "
Type 1 with cable (J1772)
outputs at most 32 A", - "nl": "
Type 1 met kabel (J1772)
levert een stroom van maximaal 32 A" + "en": "Type 1 with cable (J1772) outputs at most 32 A", + "nl": "Type 1 met kabel (J1772) levert een stroom van maximaal 32 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1606,15 +1776,23 @@ { "if": "socket:socket:type1_cable:output=3.7 kw", "then": { - "en": "
Type 1 with cable (J1772)
outputs at most 3.7 kw", - "nl": "
Type 1 met kabel (J1772)
levert een vermogen van maximaal 3.7 kw" + "en": "Type 1 with cable (J1772) outputs at most 3.7 kw A", + "nl": "Type 1 met kabel (J1772) levert een vermogen van maximaal 3.7 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1_cable:output=7 kw", "then": { - "en": "
Type 1 with cable (J1772)
outputs at most 7 kw", - "nl": "
Type 1 met kabel (J1772)
levert een vermogen van maximaal 7 kw" + "en": "Type 1 with cable (J1772) outputs at most 7 kw A", + "nl": "Type 1 met kabel (J1772) levert een vermogen van maximaal 7 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1644,15 +1822,23 @@ { "if": "socket:socket:type1:voltage=200 V", "then": { - "en": "
Type 1 without cable (J1772)
outputs 200 volt", - "nl": "
Type 1 zonder kabel (J1772)
heeft een spanning van 200 volt" + "en": "Type 1 without cable (J1772) outputs 200 volt", + "nl": "Type 1 zonder kabel (J1772) heeft een spanning van 200 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1:voltage=240 V", "then": { - "en": "
Type 1 without cable (J1772)
outputs 240 volt", - "nl": "
Type 1 zonder kabel (J1772)
heeft een spanning van 240 volt" + "en": "Type 1 without cable (J1772) outputs 240 volt", + "nl": "Type 1 zonder kabel (J1772) heeft een spanning van 240 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1682,8 +1868,12 @@ { "if": "socket:socket:type1:current=32 A", "then": { - "en": "
Type 1 without cable (J1772)
outputs at most 32 A", - "nl": "
Type 1 zonder kabel (J1772)
levert een stroom van maximaal 32 A" + "en": "Type 1 without cable (J1772) outputs at most 32 A", + "nl": "Type 1 zonder kabel (J1772) levert een stroom van maximaal 32 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1713,29 +1903,45 @@ { "if": "socket:socket:type1:output=3.7 kw", "then": { - "en": "
Type 1 without cable (J1772)
outputs at most 3.7 kw", - "nl": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 3.7 kw" + "en": "Type 1 without cable (J1772) outputs at most 3.7 kw A", + "nl": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 3.7 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1:output=6.6 kw", "then": { - "en": "
Type 1 without cable (J1772)
outputs at most 6.6 kw", - "nl": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 6.6 kw" + "en": "Type 1 without cable (J1772) outputs at most 6.6 kw A", + "nl": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 6.6 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1:output=7 kw", "then": { - "en": "
Type 1 without cable (J1772)
outputs at most 7 kw", - "nl": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 7 kw" + "en": "Type 1 without cable (J1772) outputs at most 7 kw A", + "nl": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 7 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } }, { "if": "socket:socket:type1:output=7.2 kw", "then": { - "en": "
Type 1 without cable (J1772)
outputs at most 7.2 kw", - "nl": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 7.2 kw" + "en": "Type 1 without cable (J1772) outputs at most 7.2 kw A", + "nl": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 7.2 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1_J1772.svg", + "class": "medium" } } ], @@ -1765,15 +1971,23 @@ { "if": "socket:socket:type1_combo:voltage=400 V", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs 400 volt", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
heeft een spanning van 400 volt" + "en": "Type 1 CCS (aka Type 1 Combo) outputs 400 volt", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) heeft een spanning van 400 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } }, { "if": "socket:socket:type1_combo:voltage=1000 V", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs 1000 volt", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
heeft een spanning van 1000 volt" + "en": "Type 1 CCS (aka Type 1 Combo) outputs 1000 volt", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) heeft een spanning van 1000 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } } ], @@ -1803,15 +2017,23 @@ { "if": "socket:socket:type1_combo:current=50 A", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 50 A", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een stroom van maximaal 50 A" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 50 A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een stroom van maximaal 50 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } }, { "if": "socket:socket:type1_combo:current=125 A", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 125 A", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een stroom van maximaal 125 A" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 125 A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een stroom van maximaal 125 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } } ], @@ -1841,29 +2063,45 @@ { "if": "socket:socket:type1_combo:output=50 kw", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 50 kw", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 50 kw" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 50 kw A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 50 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } }, { "if": "socket:socket:type1_combo:output=62.5 kw", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 62.5 kw", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 62.5 kw" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 62.5 kw A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 62.5 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } }, { "if": "socket:socket:type1_combo:output=150 kw", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 150 kw", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 150 kw" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 150 kw A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 150 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } }, { "if": "socket:socket:type1_combo:output=350 kw", "then": { - "en": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 350 kw", - "nl": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 350 kw" + "en": "Type 1 CCS (aka Type 1 Combo) outputs at most 350 kw A", + "nl": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 350 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type1-ccs.svg", + "class": "medium" } } ], @@ -1893,8 +2131,12 @@ { "if": "socket:socket:tesla_supercharger:voltage=480 V", "then": { - "en": "
Tesla Supercharger
outputs 480 volt", - "nl": "
Tesla Supercharger
heeft een spanning van 480 volt" + "en": "Tesla Supercharger outputs 480 volt", + "nl": "Tesla Supercharger heeft een spanning van 480 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -1924,15 +2166,23 @@ { "if": "socket:socket:tesla_supercharger:current=125 A", "then": { - "en": "
Tesla Supercharger
outputs at most 125 A", - "nl": "
Tesla Supercharger
levert een stroom van maximaal 125 A" + "en": "Tesla Supercharger outputs at most 125 A", + "nl": "Tesla Supercharger levert een stroom van maximaal 125 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_supercharger:current=350 A", "then": { - "en": "
Tesla Supercharger
outputs at most 350 A", - "nl": "
Tesla Supercharger
levert een stroom van maximaal 350 A" + "en": "Tesla Supercharger outputs at most 350 A", + "nl": "Tesla Supercharger levert een stroom van maximaal 350 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -1962,22 +2212,34 @@ { "if": "socket:socket:tesla_supercharger:output=120 kw", "then": { - "en": "
Tesla Supercharger
outputs at most 120 kw", - "nl": "
Tesla Supercharger
levert een vermogen van maximaal 120 kw" + "en": "Tesla Supercharger outputs at most 120 kw A", + "nl": "Tesla Supercharger levert een vermogen van maximaal 120 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_supercharger:output=150 kw", "then": { - "en": "
Tesla Supercharger
outputs at most 150 kw", - "nl": "
Tesla Supercharger
levert een vermogen van maximaal 150 kw" + "en": "Tesla Supercharger outputs at most 150 kw A", + "nl": "Tesla Supercharger levert een vermogen van maximaal 150 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_supercharger:output=250 kw", "then": { - "en": "
Tesla Supercharger
outputs at most 250 kw", - "nl": "
Tesla Supercharger
levert een vermogen van maximaal 250 kw" + "en": "Tesla Supercharger outputs at most 250 kw A", + "nl": "Tesla Supercharger levert een vermogen van maximaal 250 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -2007,15 +2269,23 @@ { "if": "socket:socket:type2:voltage=230 V", "then": { - "en": "
Type 2 (mennekes)
outputs 230 volt", - "nl": "
Type 2 (mennekes)
heeft een spanning van 230 volt" + "en": "Type 2 (mennekes) outputs 230 volt", + "nl": "Type 2 (mennekes) heeft een spanning van 230 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } }, { "if": "socket:socket:type2:voltage=400 V", "then": { - "en": "
Type 2 (mennekes)
outputs 400 volt", - "nl": "
Type 2 (mennekes)
heeft een spanning van 400 volt" + "en": "Type 2 (mennekes) outputs 400 volt", + "nl": "Type 2 (mennekes) heeft een spanning van 400 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } } ], @@ -2045,15 +2315,23 @@ { "if": "socket:socket:type2:current=16 A", "then": { - "en": "
Type 2 (mennekes)
outputs at most 16 A", - "nl": "
Type 2 (mennekes)
levert een stroom van maximaal 16 A" + "en": "Type 2 (mennekes) outputs at most 16 A", + "nl": "Type 2 (mennekes) levert een stroom van maximaal 16 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } }, { "if": "socket:socket:type2:current=32 A", "then": { - "en": "
Type 2 (mennekes)
outputs at most 32 A", - "nl": "
Type 2 (mennekes)
levert een stroom van maximaal 32 A" + "en": "Type 2 (mennekes) outputs at most 32 A", + "nl": "Type 2 (mennekes) levert een stroom van maximaal 32 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } } ], @@ -2083,15 +2361,23 @@ { "if": "socket:socket:type2:output=11 kw", "then": { - "en": "
Type 2 (mennekes)
outputs at most 11 kw", - "nl": "
Type 2 (mennekes)
levert een vermogen van maximaal 11 kw" + "en": "Type 2 (mennekes) outputs at most 11 kw A", + "nl": "Type 2 (mennekes) levert een vermogen van maximaal 11 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } }, { "if": "socket:socket:type2:output=22 kw", "then": { - "en": "
Type 2 (mennekes)
outputs at most 22 kw", - "nl": "
Type 2 (mennekes)
levert een vermogen van maximaal 22 kw" + "en": "Type 2 (mennekes) outputs at most 22 kw A", + "nl": "Type 2 (mennekes) levert een vermogen van maximaal 22 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_socket.svg", + "class": "medium" } } ], @@ -2121,15 +2407,23 @@ { "if": "socket:socket:type2_combo:voltage=500 V", "then": { - "en": "
Type 2 CCS (mennekes)
outputs 500 volt", - "nl": "
Type 2 CCS (mennekes)
heeft een spanning van 500 volt" + "en": "Type 2 CCS (mennekes) outputs 500 volt", + "nl": "Type 2 CCS (mennekes) heeft een spanning van 500 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } }, { "if": "socket:socket:type2_combo:voltage=920 V", "then": { - "en": "
Type 2 CCS (mennekes)
outputs 920 volt", - "nl": "
Type 2 CCS (mennekes)
heeft een spanning van 920 volt" + "en": "Type 2 CCS (mennekes) outputs 920 volt", + "nl": "Type 2 CCS (mennekes) heeft een spanning van 920 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2159,15 +2453,23 @@ { "if": "socket:socket:type2_combo:current=125 A", "then": { - "en": "
Type 2 CCS (mennekes)
outputs at most 125 A", - "nl": "
Type 2 CCS (mennekes)
levert een stroom van maximaal 125 A" + "en": "Type 2 CCS (mennekes) outputs at most 125 A", + "nl": "Type 2 CCS (mennekes) levert een stroom van maximaal 125 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } }, { "if": "socket:socket:type2_combo:current=350 A", "then": { - "en": "
Type 2 CCS (mennekes)
outputs at most 350 A", - "nl": "
Type 2 CCS (mennekes)
levert een stroom van maximaal 350 A" + "en": "Type 2 CCS (mennekes) outputs at most 350 A", + "nl": "Type 2 CCS (mennekes) levert een stroom van maximaal 350 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2197,8 +2499,12 @@ { "if": "socket:socket:type2_combo:output=50 kw", "then": { - "en": "
Type 2 CCS (mennekes)
outputs at most 50 kw", - "nl": "
Type 2 CCS (mennekes)
levert een vermogen van maximaal 50 kw" + "en": "Type 2 CCS (mennekes) outputs at most 50 kw A", + "nl": "Type 2 CCS (mennekes) levert een vermogen van maximaal 50 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2228,15 +2534,23 @@ { "if": "socket:socket:type2_cable:voltage=230 V", "then": { - "en": "
Type 2 with cable (mennekes)
outputs 230 volt", - "nl": "
Type 2 met kabel (J1772)
heeft een spanning van 230 volt" + "en": "Type 2 with cable (mennekes) outputs 230 volt", + "nl": "Type 2 met kabel (J1772) heeft een spanning van 230 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:type2_cable:voltage=400 V", "then": { - "en": "
Type 2 with cable (mennekes)
outputs 400 volt", - "nl": "
Type 2 met kabel (J1772)
heeft een spanning van 400 volt" + "en": "Type 2 with cable (mennekes) outputs 400 volt", + "nl": "Type 2 met kabel (J1772) heeft een spanning van 400 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2266,15 +2580,23 @@ { "if": "socket:socket:type2_cable:current=16 A", "then": { - "en": "
Type 2 with cable (mennekes)
outputs at most 16 A", - "nl": "
Type 2 met kabel (J1772)
levert een stroom van maximaal 16 A" + "en": "Type 2 with cable (mennekes) outputs at most 16 A", + "nl": "Type 2 met kabel (J1772) levert een stroom van maximaal 16 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:type2_cable:current=32 A", "then": { - "en": "
Type 2 with cable (mennekes)
outputs at most 32 A", - "nl": "
Type 2 met kabel (J1772)
levert een stroom van maximaal 32 A" + "en": "Type 2 with cable (mennekes) outputs at most 32 A", + "nl": "Type 2 met kabel (J1772) levert een stroom van maximaal 32 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2304,15 +2626,23 @@ { "if": "socket:socket:type2_cable:output=11 kw", "then": { - "en": "
Type 2 with cable (mennekes)
outputs at most 11 kw", - "nl": "
Type 2 met kabel (J1772)
levert een vermogen van maximaal 11 kw" + "en": "Type 2 with cable (mennekes) outputs at most 11 kw A", + "nl": "Type 2 met kabel (J1772) levert een vermogen van maximaal 11 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:type2_cable:output=22 kw", "then": { - "en": "
Type 2 with cable (mennekes)
outputs at most 22 kw", - "nl": "
Type 2 met kabel (J1772)
levert een vermogen van maximaal 22 kw" + "en": "Type 2 with cable (mennekes) outputs at most 22 kw A", + "nl": "Type 2 met kabel (J1772) levert een vermogen van maximaal 22 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2342,15 +2672,23 @@ { "if": "socket:socket:tesla_supercharger_ccs:voltage=500 V", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
outputs 500 volt", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
heeft een spanning van 500 volt" + "en": "Tesla Supercharger CCS (a branded type2_css) outputs 500 volt", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) heeft een spanning van 500 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_supercharger_ccs:voltage=920 V", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
outputs 920 volt", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
heeft een spanning van 920 volt" + "en": "Tesla Supercharger CCS (a branded type2_css) outputs 920 volt", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) heeft een spanning van 920 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2380,15 +2718,23 @@ { "if": "socket:socket:tesla_supercharger_ccs:current=125 A", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 125 A", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een stroom van maximaal 125 A" + "en": "Tesla Supercharger CCS (a branded type2_css) outputs at most 125 A", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een stroom van maximaal 125 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_supercharger_ccs:current=350 A", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 350 A", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een stroom van maximaal 350 A" + "en": "Tesla Supercharger CCS (a branded type2_css) outputs at most 350 A", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een stroom van maximaal 350 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2418,8 +2764,12 @@ { "if": "socket:socket:tesla_supercharger_ccs:output=50 kw", "then": { - "en": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 50 kw", - "nl": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een vermogen van maximaal 50 kw" + "en": "Tesla Supercharger CCS (a branded type2_css) outputs at most 50 kw A", + "nl": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een vermogen van maximaal 50 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_CCS.svg", + "class": "medium" } } ], @@ -2449,8 +2799,12 @@ { "if": "socket:socket:tesla_destination:voltage=480 V", "then": { - "en": "
Tesla Supercharger (destination)
outputs 480 volt", - "nl": "
Tesla Supercharger (destination)
heeft een spanning van 480 volt" + "en": "Tesla Supercharger (destination) outputs 480 volt", + "nl": "Tesla Supercharger (destination) heeft een spanning van 480 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -2480,15 +2834,23 @@ { "if": "socket:socket:tesla_destination:current=125 A", "then": { - "en": "
Tesla Supercharger (destination)
outputs at most 125 A", - "nl": "
Tesla Supercharger (destination)
levert een stroom van maximaal 125 A" + "en": "Tesla Supercharger (destination) outputs at most 125 A", + "nl": "Tesla Supercharger (destination) levert een stroom van maximaal 125 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:current=350 A", "then": { - "en": "
Tesla Supercharger (destination)
outputs at most 350 A", - "nl": "
Tesla Supercharger (destination)
levert een stroom van maximaal 350 A" + "en": "Tesla Supercharger (destination) outputs at most 350 A", + "nl": "Tesla Supercharger (destination) levert een stroom van maximaal 350 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -2518,22 +2880,34 @@ { "if": "socket:socket:tesla_destination:output=120 kw", "then": { - "en": "
Tesla Supercharger (destination)
outputs at most 120 kw", - "nl": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 120 kw" + "en": "Tesla Supercharger (destination) outputs at most 120 kw A", + "nl": "Tesla Supercharger (destination) levert een vermogen van maximaal 120 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:output=150 kw", "then": { - "en": "
Tesla Supercharger (destination)
outputs at most 150 kw", - "nl": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 150 kw" + "en": "Tesla Supercharger (destination) outputs at most 150 kw A", + "nl": "Tesla Supercharger (destination) levert een vermogen van maximaal 150 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:output=250 kw", "then": { - "en": "
Tesla Supercharger (destination)
outputs at most 250 kw", - "nl": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 250 kw" + "en": "Tesla Supercharger (destination) outputs at most 250 kw A", + "nl": "Tesla Supercharger (destination) levert een vermogen van maximaal 250 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", + "class": "medium" } } ], @@ -2563,15 +2937,23 @@ { "if": "socket:socket:tesla_destination:voltage=230 V", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs 230 volt", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
heeft een spanning van 230 volt" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs 230 volt", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) heeft een spanning van 230 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:voltage=400 V", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs 400 volt", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
heeft een spanning van 400 volt" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs 400 volt", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) heeft een spanning van 400 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2601,15 +2983,23 @@ { "if": "socket:socket:tesla_destination:current=16 A", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 16 A", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal 16 A" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 16 A", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een stroom van maximaal 16 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:current=32 A", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 32 A", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal 32 A" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 32 A", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een stroom van maximaal 32 A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2639,15 +3029,23 @@ { "if": "socket:socket:tesla_destination:output=11 kw", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 11 kw", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een vermogen van maximaal 11 kw" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 11 kw A", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een vermogen van maximaal 11 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } }, { "if": "socket:socket:tesla_destination:output=22 kw", "then": { - "en": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 22 kw", - "nl": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een vermogen van maximaal 22 kw" + "en": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 22 kw A", + "nl": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een vermogen van maximaal 22 kw A" + }, + "icon": { + "path": "./assets/layers/charging_station/Type2_tethered.svg", + "class": "medium" } } ], @@ -2677,8 +3075,12 @@ { "if": "socket:socket:USB-A:voltage=5 V", "then": { - "en": "
USB to charge phones and small electronics
outputs 5 volt", - "nl": "
USB om GSMs en kleine electronica op te laden
heeft een spanning van 5 volt" + "en": "USB to charge phones and small electronics outputs 5 volt", + "nl": "USB om GSMs en kleine electronica op te laden heeft een spanning van 5 volt" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } } ], @@ -2708,15 +3110,23 @@ { "if": "socket:socket:USB-A:current=1 A", "then": { - "en": "
USB to charge phones and small electronics
outputs at most 1 A", - "nl": "
USB om GSMs en kleine electronica op te laden
levert een stroom van maximaal 1 A" + "en": "USB to charge phones and small electronics outputs at most 1 A", + "nl": "USB om GSMs en kleine electronica op te laden levert een stroom van maximaal 1 A" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } }, { "if": "socket:socket:USB-A:current=2 A", "then": { - "en": "
USB to charge phones and small electronics
outputs at most 2 A", - "nl": "
USB om GSMs en kleine electronica op te laden
levert een stroom van maximaal 2 A" + "en": "USB to charge phones and small electronics outputs at most 2 A", + "nl": "USB om GSMs en kleine electronica op te laden levert een stroom van maximaal 2 A" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } } ], @@ -2746,15 +3156,23 @@ { "if": "socket:socket:USB-A:output=5w", "then": { - "en": "
USB to charge phones and small electronics
outputs at most 5w", - "nl": "
USB om GSMs en kleine electronica op te laden
levert een vermogen van maximaal 5w" + "en": "USB to charge phones and small electronics outputs at most 5w A", + "nl": "USB om GSMs en kleine electronica op te laden levert een vermogen van maximaal 5w A" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } }, { "if": "socket:socket:USB-A:output=10w", "then": { - "en": "
USB to charge phones and small electronics
outputs at most 10w", - "nl": "
USB om GSMs en kleine electronica op te laden
levert een vermogen van maximaal 10w" + "en": "USB to charge phones and small electronics outputs at most 10w A", + "nl": "USB om GSMs en kleine electronica op te laden levert een vermogen van maximaal 10w A" + }, + "icon": { + "path": "./assets/layers/charging_station/usb_port.svg", + "class": "medium" } } ], @@ -2912,18 +3330,14 @@ }, "question": { "en": "When is this charging station opened?", - "nl": "Wanneer is dit oplaadpunt beschikbaar??", - "de": "Wann ist diese Ladestation geöffnet?", - "es": "¿Cuándo abre esta estación de carga?" + "nl": "Wanneer is dit oplaadpunt beschikbaar??" }, "mappings": [ { "if": "opening_hours=24/7", "then": { "en": "24/7 opened (including holidays)", - "nl": "24/7 open - ook tijdens vakanties", - "de": "durchgehend geöffnet (einschließlich Feiertage)", - "es": "Abre 24/7 (incluidos días festivos)" + "nl": "24/7 open - ook tijdens vakanties" } } ] @@ -3033,9 +3447,7 @@ "#": "In some cases, charging is free but one has to be authenticated. We only ask for authentication if fee is no (or unset). By default one sees the questions for either the payment options or the authentication options, but normally not both", "question": { "en": "What kind of authentication is available at the charging station?", - "nl": "Hoe kan men zich aanmelden aan dit oplaadstation?", - "de": "Welche Art der Authentifizierung ist an der Ladestation möglich?", - "fr": "Quelle sorte d'authentification est disponible à cette station de charge ?" + "nl": "Hoe kan men zich aanmelden aan dit oplaadstation?" }, "multiAnswer": true, "mappings": [ @@ -3044,10 +3456,7 @@ "ifnot": "authentication:membership_card=no", "then": { "en": "Authentication by a membership card", - "nl": "Aanmelden met een lidkaart is mogelijk", - "de": "Authentifizierung per Mitgliedskarte", - "es": "Autenticación mediante tarjeta de membresía", - "fr": "Authentification par carte de membre" + "nl": "Aanmelden met een lidkaart is mogelijk" } }, { @@ -3055,10 +3464,7 @@ "ifnot": "authentication:app=no", "then": { "en": "Authentication by an app", - "nl": "Aanmelden via een applicatie is mogelijk", - "de": "Authentifizierung per App", - "es": "Autenticación mediante aplicación", - "fr": "Authentification par une app" + "nl": "Aanmelden via een applicatie is mogelijk" } }, { @@ -3066,10 +3472,7 @@ "ifnot": "authentication:phone_call=no", "then": { "en": "Authentication via phone call is available", - "nl": "Aanmelden door te bellen naar een telefoonnummer is mogelijk", - "de": "Authentifizierung per Anruf ist möglich", - "es": "Autenticación mediante llamada telefónica disponible", - "fr": "Authentification par appel téléphonique est disponible" + "nl": "Aanmelden door te bellen naar een telefoonnummer is mogelijk" } }, { @@ -3077,10 +3480,7 @@ "ifnot": "authentication:short_message=no", "then": { "en": "Authentication via SMS is available", - "nl": "Aanmelden via SMS is mogelijk", - "de": "Authentifizierung per SMS ist möglich", - "es": "Autenticación mediante SMS disponible", - "fr": "Authentification par SMS est disponible" + "nl": "Aanmelden via SMS is mogelijk" } }, { @@ -3088,10 +3488,7 @@ "ifnot": "authentication:nfc=no", "then": { "en": "Authentication via NFC is available", - "nl": "Aanmelden via NFC is mogelijk", - "de": "Authentifizierung per NFC ist möglich", - "es": "Autenticación mediante NFC disponible", - "fr": "Authentification par NFC est disponible" + "nl": "Aanmelden via NFC is mogelijk" } }, { @@ -3099,9 +3496,7 @@ "ifnot": "authentication:money_card=no", "then": { "en": "Authentication via Money Card is available", - "nl": "Aanmelden met Money Card is mogelijk", - "de": "Authentifizierung per Geldkarte ist möglich", - "es": "Autenticación mediante Money Card disponible" + "nl": "Aanmelden met Money Card is mogelijk" } }, { @@ -3109,10 +3504,7 @@ "ifnot": "authentication:debit_card=no", "then": { "en": "Authentication via debit card is available", - "nl": "Aanmelden met een betaalkaart is mogelijk", - "de": "Authentifizierung per Kreditkarte ist möglich", - "es": "Autenticación mediante tarjeta de débito disponible", - "fr": "Authentification par carte de débit est disponible" + "nl": "Aanmelden met een betaalkaart is mogelijk" } }, { @@ -3120,9 +3512,7 @@ "ifnot": "authentication:none=no", "then": { "en": "Charging here is (also) possible without authentication", - "nl": "Hier opladen is (ook) mogelijk zonder aan te melden", - "de": "Das Laden ist hier (auch) ohne Authentifizierung möglich", - "fr": "Charger ici est (aussi) possible sans authentification" + "nl": "Hier opladen is (ook) mogelijk zonder aan te melden" } } ], @@ -3189,15 +3579,11 @@ "id": "Network", "render": { "en": "Part of the network {network}", - "nl": "Maakt deel uit van het {network}-netwerk", - "de": "Teil des Netzwerks {network}", - "es": "Parte de la red {network}" + "nl": "Maakt deel uit van het {network}-netwerk" }, "question": { "en": "Is this charging station part of a network?", - "nl": "Is dit oplaadpunt deel van een groter netwerk?", - "de": "Ist diese Ladestation Teil eines Netzwerks?", - "es": "¿Esta estación de carga forma parte de una red?" + "nl": "Is dit oplaadpunt deel van een groter netwerk?" }, "freeform": { "key": "network" @@ -3207,17 +3593,14 @@ "if": "no:network=yes", "then": { "en": "Not part of a bigger network, e.g. because the charging station is maintained by a local business", - "nl": "Maakt geen deel uit van een groter netwerk, een lokale zaak of organisatie beheert dit oplaadpunt", - "de": "Nicht Teil eines größeren Netzwerks, z. B. weil die Ladestation von einem lokalen Unternehmen betrieben wird" + "nl": "Maakt geen deel uit van een groter netwerk, een lokale zaak of organisatie beheert dit oplaadpunt" } }, { "if": "network=none", "then": { "en": "Not part of a bigger network", - "nl": "Maakt geen deel uit van een groter netwerk", - "de": "Nicht Teil eines größeren Netzwerks", - "es": "No forma parte de una red mayor" + "nl": "Maakt geen deel uit van een groter netwerk" }, "hideInAnswer": true }, @@ -3263,13 +3646,11 @@ "id": "Operator", "question": { "en": "Who is the operator of this charging station?", - "nl": "Wie beheert dit oplaadpunt?", - "de": "Wer ist der Betreiber dieser Ladestation?" + "nl": "Wie beheert dit oplaadpunt?" }, "render": { "en": "This charging station is operated by {operator}", - "nl": "Wordt beheerd door {operator}", - "de": "Diese Ladestation wird betrieben von {operator}" + "nl": "Wordt beheerd door {operator}" }, "freeform": { "key": "operator" @@ -3283,8 +3664,7 @@ }, "then": { "en": "Actually, {operator} is the network", - "nl": "Eigenlijk is {operator} het netwerk waarvan het deel uitmaakt", - "de": "Eigentlich ist {operator} das Netzwerk" + "nl": "Eigenlijk is {operator} het netwerk waarvan het deel uitmaakt" }, "addExtraTags": [ "operator=" @@ -3360,8 +3740,7 @@ "id": "Operational status", "question": { "en": "Is this charging point in use?", - "nl": "Is dit oplaadpunt operationeel?", - "de": "Ist dieser Ladepunkt in Betrieb?" + "nl": "Is dit oplaadpunt operationeel?" }, "mappings": [ { @@ -3376,8 +3755,7 @@ }, "then": { "en": "This charging station works", - "nl": "Dit oplaadpunt werkt", - "de": "Diese Ladestation ist betriebsbereit" + "nl": "Dit oplaadpunt werkt" } }, { @@ -3392,8 +3770,7 @@ }, "then": { "en": "This charging station is broken", - "nl": "Dit oplaadpunt is kapot", - "de": "Diese Ladestation ist defekt" + "nl": "Dit oplaadpunt is kapot" } }, { @@ -3408,8 +3785,7 @@ }, "then": { "en": "A charging station is planned here", - "nl": "Hier zal binnenkort een oplaadpunt gebouwd worden", - "de": "Hier ist eine Ladestation geplant" + "nl": "Hier zal binnenkort een oplaadpunt gebouwd worden" } }, { @@ -3424,8 +3800,7 @@ }, "then": { "en": "A charging station is constructed here", - "nl": "Hier wordt op dit moment een oplaadpunt gebouwd", - "de": "Hier wird eine Ladestation errichtet" + "nl": "Hier wordt op dit moment een oplaadpunt gebouwd" } }, { @@ -3440,8 +3815,7 @@ }, "then": { "en": "This charging station has beed permanently disabled and is not in use anymore but is still visible", - "nl": "Dit oplaadpunt is niet meer in gebruik maar is wel nog aanwezig", - "de": "Diese Ladestation wurde dauerhaft geschlossen und wird nicht mehr benutzt, ist aber noch sichtbar" + "nl": "Dit oplaadpunt is niet meer in gebruik maar is wel nog aanwezig" } } ] @@ -3450,24 +3824,21 @@ "id": "Parking:fee", "question": { "en": "Does one have to pay a parking fee while charging?", - "nl": "Moet men parkeergeld betalen tijdens het opladen?", - "de": "Muss man während des Ladens eine Parkgebühr bezahlen?" + "nl": "Moet men parkeergeld betalen tijdens het opladen?" }, "mappings": [ { "if": "parking:fee=no", "then": { "en": "No additional parking cost while charging", - "nl": "Geen extra parkeerkost tijdens het opladen", - "de": "Keine zusätzlichen Parkkosten während des Ladens" + "nl": "Geen extra parkeerkost tijdens het opladen" } }, { "if": "parking:fee=yes", "then": { "en": "An additional parking fee should be paid while charging", - "nl": "Tijdens het opladen moet er parkeergeld betaald worden", - "de": "Während des Ladens ist eine zusätzliche Parkgebühr zu entrichten" + "nl": "Tijdens het opladen moet er parkeergeld betaald worden" } } ], @@ -3565,8 +3936,8 @@ "socket:typee=1" ], "title": { - "en": "charging station with a normal european wall plug (meant to charge electrical bikes)", - "nl": "laadpunt voor elektrische fietsen met gewone stekker(s)" + "en": "charging station for electrical bikes with a normal european wall plug (meant to charge electrical bikes)", + "nl": "oplaadpunt voor elektrische fietsen" }, "preciseInput": { "preferredBackground": "map" @@ -3580,8 +3951,7 @@ ], "title": { "en": "charging station for cars", - "nl": "oplaadstation voor elektrische auto's", - "de": "Ladestation für e-bikes" + "nl": "oplaadstation voor elektrische auto's" }, "preciseInput": { "preferredBackground": "map" @@ -3595,26 +3965,20 @@ { "question": { "en": "All vehicle types", - "nl": "Alle voertuigen", - "de": "Alle Fahrzeugtypen", - "fr": "Tout type de véhicule" + "nl": "Alle voertuigen" } }, { "question": { "en": "Charging station for bicycles", - "nl": "Oplaadpunten voor fietsen", - "de": "Ladestation für Fahrräder", - "fr": "Station de charge pour vélos" + "nl": "Oplaadpunten voor fietsen" }, "osmTags": "bicycle=yes" }, { "question": { "en": "Charging station for cars", - "nl": "Oplaadpunten voor auto's", - "de": "Ladestation für Autos", - "fr": "Station de charge pour automobiles" + "nl": "Oplaadpunten voor auto's" }, "osmTags": { "or": [ @@ -3631,8 +3995,7 @@ { "question": { "en": "Only working charging stations", - "nl": "Enkel werkende oplaadpunten", - "de": "Nur funktionierende Ladestationen" + "nl": "Enkel werkende oplaadpunten" }, "osmTags": { "and": [ @@ -3649,15 +4012,13 @@ { "question": { "en": "All connectors", - "nl": "Alle types", - "de": "Alle Anschlüsse" + "nl": "Alle types" } }, { "question": { "en": "Has a
Schuko wall plug without ground pin (CEE7/4 type F)
connector", - "nl": "Heeft een
Schuko stekker zonder aardingspin (CEE7/4 type F)
", - "de": "Verfügt über einen
Schuko-Stecker ohne Erdungsstift (CEE7/4 Typ F)
" + "nl": "Heeft een
Schuko stekker zonder aardingspin (CEE7/4 type F)
" }, "osmTags": "socket:schuko~*" }, @@ -3671,40 +4032,35 @@ { "question": { "en": "Has a
Chademo
connector", - "nl": "Heeft een
Chademo
", - "de": "Verfügt über einen
Chademo
Stecker" + "nl": "Heeft een
Chademo
" }, "osmTags": "socket:chademo~*" }, { "question": { "en": "Has a
Type 1 with cable (J1772)
connector", - "nl": "Heeft een
Type 1 met kabel (J1772)
", - "de": "Verfügt über einen
Typ 1 (J1772)
Stecker mit Kabel" + "nl": "Heeft een
Type 1 met kabel (J1772)
" }, "osmTags": "socket:type1_cable~*" }, { "question": { "en": "Has a
Type 1 without cable (J1772)
connector", - "nl": "Heeft een
Type 1 zonder kabel (J1772)
", - "de": "Verfügt über einen
Typ 1 (J1772)
Stecker ohne Kabel" + "nl": "Heeft een
Type 1 zonder kabel (J1772)
" }, "osmTags": "socket:type1~*" }, { "question": { "en": "Has a
Type 1 CCS (aka Type 1 Combo)
connector", - "nl": "Heeft een
Type 1 CCS (ook gekend als Type 1 Combo)
", - "de": "Verfügt über einen
Typ 1 CCS
Stecker, auch bekannt als Typ 1 Combo" + "nl": "Heeft een
Type 1 CCS (ook gekend als Type 1 Combo)
" }, "osmTags": "socket:type1_combo~*" }, { "question": { "en": "Has a
Tesla Supercharger
connector", - "nl": "Heeft een
Tesla Supercharger
", - "de": "Verfügt über einen
Tesla Supercharger
Stecker" + "nl": "Heeft een
Tesla Supercharger
" }, "osmTags": "socket:tesla_supercharger~*" }, @@ -3792,13 +4148,11 @@ ], "human": { "en": " minutes", - "nl": " minuten", - "ru": " минут" + "nl": " minuten" }, "humanSingular": { "en": " minute", - "nl": " minuut", - "ru": " минута" + "nl": " minuut" } }, { @@ -3814,13 +4168,11 @@ ], "human": { "en": " hours", - "nl": " uren", - "ru": " часов" + "nl": " uren" }, "humanSingular": { "en": " hour", - "nl": " uur", - "ru": " час" + "nl": " uur" } }, { @@ -3833,13 +4185,11 @@ ], "human": { "en": " days", - "nl": " day", - "ru": " дней" + "nl": " day" }, "humanSingular": { "en": " day", - "nl": " dag", - "ru": " день" + "nl": " dag" } } ] @@ -3875,8 +4225,7 @@ ], "human": { "en": "Volts", - "nl": "volt", - "ru": "Вольт" + "nl": "volt" } } ], @@ -3945,8 +4294,7 @@ ], "human": { "en": "kilowatt", - "nl": "kilowatt", - "ru": "киловатт" + "nl": "kilowatt" } }, { @@ -3956,8 +4304,7 @@ ], "human": { "en": "megawatt", - "nl": "megawatt", - "ru": "мегаватт" + "nl": "megawatt" } } ], diff --git a/assets/layers/charging_station/csvToJson.ts b/assets/layers/charging_station/csvToJson.ts index 7d918eccb..e138243f7 100644 --- a/assets/layers/charging_station/csvToJson.ts +++ b/assets/layers/charging_station/csvToJson.ts @@ -72,13 +72,17 @@ function run(file, protojson) { for (let i = 0; i < entries.length; i++) { const e = entries[i]; const txt = { - en: `
${e.description.get("en")}
`, - nl: `
${e.description.get("nl")}
` + en: e.description.get("en"), + nl: e.description.get("nl") } const json = { if: `${e.key}=1`, ifnot: `${e.key}=`, then: txt, + icon:{ + path:"./assets/layers/charging_station/" + e.image, + class:"medium" + } } if (e.countryWhiteList.length > 0 && e.countryBlackList.length > 0) { @@ -125,7 +129,11 @@ function run(file, protojson) { and:Utils.NoEmpty( [`${e.key}~*`, `${e.key}!=1`, ...e.extraVisualisationCondition.split(";")]) }, then: txt, - hideInAnswer: true + hideInAnswer: true, + icon:{ + path: e.image, + class:"medium" + } } overview_question_answers.push(no_ask_json) @@ -170,8 +178,12 @@ function run(file, protojson) { return { if: `socket:${e.key}:voltage=${voltage} V`, then: { - en: `${descrWithImage_en} outputs ${voltage} volt`, - nl: `${descrWithImage_nl} heeft een spanning van ${voltage} volt` + en: `${e.description.get("en")} outputs ${voltage} volt`, + nl: `${e.description.get("nl")} heeft een spanning van ${voltage} volt` + }, + icon: { + path: `./assets/layers/charging_station/${e.image}`, + class:"medium" } } }), @@ -200,8 +212,12 @@ function run(file, protojson) { return { if: `socket:${e.key}:current=${current} A`, then: { - en: `${descrWithImage_en} outputs at most ${current} A`, - nl: `${descrWithImage_nl} levert een stroom van maximaal ${current} A` + en: `${e.description.get("en")} outputs at most ${current} A`, + nl: `${e.description.get("nl")} levert een stroom van maximaal ${current} A` + }, + icon: { + path: `./assets/layers/charging_station/${e.image}`, + class:"medium" } } }), @@ -230,8 +246,12 @@ function run(file, protojson) { return { if: `socket:${e.key}:output=${output}`, then: { - en: `${descrWithImage_en} outputs at most ${output}`, - nl: `${descrWithImage_nl} levert een vermogen van maximaal ${output}` + en: `${e.description.get("en")} outputs at most ${output} A`, + nl: `${e.description.get("nl")} levert een vermogen van maximaal ${output} A` + }, + icon: { + path: `./assets/layers/charging_station/${e.image}`, + class:"medium" } } }), From a947a2f2d357801d2706a76a35223858c90ad235 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 03:54:21 +0100 Subject: [PATCH 02/24] Version bump --- Models/Constants.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Models/Constants.ts b/Models/Constants.ts index 3e13e2b77..c76a77f17 100644 --- a/Models/Constants.ts +++ b/Models/Constants.ts @@ -2,7 +2,7 @@ import {Utils} from "../Utils"; export default class Constants { - public static vNumber = "0.16.0"; + public static vNumber = "0.16.1"; public static ImgurApiKey = '7070e7167f0a25a' public static readonly mapillary_client_token_v4 = "MLY|4441509239301885|b40ad2d3ea105435bd40c7e76993ae85" From 7bde86098ad0d011c185702bd77455b0488dbdf1 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:01:22 +0100 Subject: [PATCH 03/24] Update of charging station translations --- langs/layers/nl.json | 216 +++++++++++++++++++++---------------------- 1 file changed, 108 insertions(+), 108 deletions(-) diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 4a3f4109a..46d32efab 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -1360,7 +1360,7 @@ "name": "Oplaadpunten", "presets": { "0": { - "title": "laadpunt voor elektrische fietsen met gewone stekker(s)" + "title": "oplaadpunt voor elektrische fietsen" }, "1": { "title": "oplaadstation voor elektrische auto's" @@ -1403,100 +1403,100 @@ "Available_charging_stations (generated)": { "mappings": { "0": { - "then": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
" + "then": "Schuko stekker zonder aardingspin (CEE7/4 type F)" }, "1": { - "then": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
" + "then": "Schuko stekker zonder aardingspin (CEE7/4 type F)" }, "2": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
" + "then": "Europese stekker met aardingspin (CEE7/4 type E)" }, "3": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
" + "then": "Europese stekker met aardingspin (CEE7/4 type E)" }, "4": { - "then": "
Chademo
" + "then": "Chademo" }, "5": { - "then": "
Chademo
" + "then": "Chademo" }, "6": { - "then": "
Type 1 met kabel (J1772)
" + "then": "Type 1 met kabel (J1772)" }, "7": { - "then": "
Type 1 met kabel (J1772)
" + "then": "Type 1 met kabel (J1772)" }, "8": { - "then": "
Type 1 zonder kabel (J1772)
" + "then": "Type 1 zonder kabel (J1772)" }, "9": { - "then": "
Type 1 zonder kabel (J1772)
" + "then": "Type 1 zonder kabel (J1772)" }, "10": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
" + "then": "Type 1 CCS (ook gekend als Type 1 Combo)" }, "11": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
" + "then": "Type 1 CCS (ook gekend als Type 1 Combo)" }, "12": { - "then": "
Tesla Supercharger
" + "then": "Tesla Supercharger" }, "13": { - "then": "
Tesla Supercharger
" + "then": "Tesla Supercharger" }, "14": { - "then": "
Type 2 (mennekes)
" + "then": "Type 2 (mennekes)" }, "15": { - "then": "
Type 2 (mennekes)
" + "then": "Type 2 (mennekes)" }, "16": { - "then": "
Type 2 CCS (mennekes)
" + "then": "Type 2 CCS (mennekes)" }, "17": { - "then": "
Type 2 CCS (mennekes)
" + "then": "Type 2 CCS (mennekes)" }, "18": { - "then": "
Type 2 met kabel (J1772)
" + "then": "Type 2 met kabel (J1772)" }, "19": { - "then": "
Type 2 met kabel (J1772)
" + "then": "Type 2 met kabel (J1772)" }, "20": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo)" }, "21": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo)" }, "22": { - "then": "
Tesla Supercharger (destination)
" + "then": "Tesla Supercharger (destination)" }, "23": { - "then": "
Tesla Supercharger (destination)
" + "then": "Tesla Supercharger (destination)" }, "24": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)" }, "25": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)" }, "26": { - "then": "
USB om GSMs en kleine electronica op te laden
" + "then": "USB om GSMs en kleine electronica op te laden" }, "27": { - "then": "
USB om GSMs en kleine electronica op te laden
" + "then": "USB om GSMs en kleine electronica op te laden" }, "28": { - "then": "
Bosch Active Connect met 3 pinnen aan een kabel
" + "then": "Bosch Active Connect met 3 pinnen aan een kabel" }, "29": { - "then": "
Bosch Active Connect met 3 pinnen aan een kabel
" + "then": "Bosch Active Connect met 3 pinnen aan een kabel" }, "30": { - "then": "
Bosch Active Connect met 5 pinnen aan een kabel
" + "then": "Bosch Active Connect met 5 pinnen aan een kabel" }, "31": { - "then": "
Bosch Active Connect met 5 pinnen aan een kabel
" + "then": "Bosch Active Connect met 5 pinnen aan een kabel" } }, "question": "Welke aansluitingen zijn hier beschikbaar?" @@ -1610,7 +1610,7 @@ "current-0": { "mappings": { "0": { - "then": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
levert een stroom van maximaal 16 A" + "then": "Schuko stekker zonder aardingspin (CEE7/4 type F) levert een stroom van maximaal 16 A" } }, "question": "Welke stroom levert de stekker van type
Schuko stekker zonder aardingspin (CEE7/4 type F)
?", @@ -1619,7 +1619,7 @@ "current-1": { "mappings": { "0": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een stroom van maximaal 16 A" + "then": "Europese stekker met aardingspin (CEE7/4 type E) levert een stroom van maximaal 16 A" } }, "question": "Welke stroom levert de stekker van type
Europese stekker met aardingspin (CEE7/4 type E)
?", @@ -1628,10 +1628,10 @@ "current-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een stroom van maximaal 125 A" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een stroom van maximaal 125 A" }, "1": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een stroom van maximaal 350 A" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een stroom van maximaal 350 A" } }, "question": "Welke stroom levert de stekker van type
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
?", @@ -1640,10 +1640,10 @@ "current-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
levert een stroom van maximaal 125 A" + "then": "Tesla Supercharger (destination) levert een stroom van maximaal 125 A" }, "1": { - "then": "
Tesla Supercharger (destination)
levert een stroom van maximaal 350 A" + "then": "Tesla Supercharger (destination) levert een stroom van maximaal 350 A" } }, "question": "Welke stroom levert de stekker van type
Tesla Supercharger (destination)
?", @@ -1652,10 +1652,10 @@ "current-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal 16 A" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een stroom van maximaal 16 A" }, "1": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal 32 A" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een stroom van maximaal 32 A" } }, "question": "Welke stroom levert de stekker van type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
?", @@ -1664,10 +1664,10 @@ "current-13": { "mappings": { "0": { - "then": "
USB om GSMs en kleine electronica op te laden
levert een stroom van maximaal 1 A" + "then": "USB om GSMs en kleine electronica op te laden levert een stroom van maximaal 1 A" }, "1": { - "then": "
USB om GSMs en kleine electronica op te laden
levert een stroom van maximaal 2 A" + "then": "USB om GSMs en kleine electronica op te laden levert een stroom van maximaal 2 A" } }, "question": "Welke stroom levert de stekker van type
USB om GSMs en kleine electronica op te laden
?", @@ -1684,7 +1684,7 @@ "current-2": { "mappings": { "0": { - "then": "
Chademo
levert een stroom van maximaal 120 A" + "then": "Chademo levert een stroom van maximaal 120 A" } }, "question": "Welke stroom levert de stekker van type
Chademo
?", @@ -1693,7 +1693,7 @@ "current-3": { "mappings": { "0": { - "then": "
Type 1 met kabel (J1772)
levert een stroom van maximaal 32 A" + "then": "Type 1 met kabel (J1772) levert een stroom van maximaal 32 A" } }, "question": "Welke stroom levert de stekker van type
Type 1 met kabel (J1772)
?", @@ -1702,7 +1702,7 @@ "current-4": { "mappings": { "0": { - "then": "
Type 1 zonder kabel (J1772)
levert een stroom van maximaal 32 A" + "then": "Type 1 zonder kabel (J1772) levert een stroom van maximaal 32 A" } }, "question": "Welke stroom levert de stekker van type
Type 1 zonder kabel (J1772)
?", @@ -1711,10 +1711,10 @@ "current-5": { "mappings": { "0": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een stroom van maximaal 50 A" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een stroom van maximaal 50 A" }, "1": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een stroom van maximaal 125 A" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een stroom van maximaal 125 A" } }, "question": "Welke stroom levert de stekker van type
Type 1 CCS (ook gekend als Type 1 Combo)
?", @@ -1723,10 +1723,10 @@ "current-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
levert een stroom van maximaal 125 A" + "then": "Tesla Supercharger levert een stroom van maximaal 125 A" }, "1": { - "then": "
Tesla Supercharger
levert een stroom van maximaal 350 A" + "then": "Tesla Supercharger levert een stroom van maximaal 350 A" } }, "question": "Welke stroom levert de stekker van type
Tesla Supercharger
?", @@ -1735,10 +1735,10 @@ "current-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
levert een stroom van maximaal 16 A" + "then": "Type 2 (mennekes) levert een stroom van maximaal 16 A" }, "1": { - "then": "
Type 2 (mennekes)
levert een stroom van maximaal 32 A" + "then": "Type 2 (mennekes) levert een stroom van maximaal 32 A" } }, "question": "Welke stroom levert de stekker van type
Type 2 (mennekes)
?", @@ -1747,10 +1747,10 @@ "current-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
levert een stroom van maximaal 125 A" + "then": "Type 2 CCS (mennekes) levert een stroom van maximaal 125 A" }, "1": { - "then": "
Type 2 CCS (mennekes)
levert een stroom van maximaal 350 A" + "then": "Type 2 CCS (mennekes) levert een stroom van maximaal 350 A" } }, "question": "Welke stroom levert de stekker van type
Type 2 CCS (mennekes)
?", @@ -1759,10 +1759,10 @@ "current-9": { "mappings": { "0": { - "then": "
Type 2 met kabel (J1772)
levert een stroom van maximaal 16 A" + "then": "Type 2 met kabel (J1772) levert een stroom van maximaal 16 A" }, "1": { - "then": "
Type 2 met kabel (J1772)
levert een stroom van maximaal 32 A" + "then": "Type 2 met kabel (J1772) levert een stroom van maximaal 32 A" } }, "question": "Welke stroom levert de stekker van type
Type 2 met kabel (J1772)
?", @@ -1872,7 +1872,7 @@ "power-output-0": { "mappings": { "0": { - "then": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
levert een vermogen van maximaal 3.6 kw" + "then": "Schuko stekker zonder aardingspin (CEE7/4 type F) levert een vermogen van maximaal 3.6 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Schuko stekker zonder aardingspin (CEE7/4 type F)
?", @@ -1881,10 +1881,10 @@ "power-output-1": { "mappings": { "0": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een vermogen van maximaal 3 kw" + "then": "Europese stekker met aardingspin (CEE7/4 type E) levert een vermogen van maximaal 3 kw A" }, "1": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
levert een vermogen van maximaal 22 kw" + "then": "Europese stekker met aardingspin (CEE7/4 type E) levert een vermogen van maximaal 22 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Europese stekker met aardingspin (CEE7/4 type E)
?", @@ -1893,7 +1893,7 @@ "power-output-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
levert een vermogen van maximaal 50 kw" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) levert een vermogen van maximaal 50 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
?", @@ -1902,13 +1902,13 @@ "power-output-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 120 kw" + "then": "Tesla Supercharger (destination) levert een vermogen van maximaal 120 kw A" }, "1": { - "then": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 150 kw" + "then": "Tesla Supercharger (destination) levert een vermogen van maximaal 150 kw A" }, "2": { - "then": "
Tesla Supercharger (destination)
levert een vermogen van maximaal 250 kw" + "then": "Tesla Supercharger (destination) levert een vermogen van maximaal 250 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Tesla Supercharger (destination)
?", @@ -1917,10 +1917,10 @@ "power-output-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een vermogen van maximaal 11 kw" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een vermogen van maximaal 11 kw A" }, "1": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een vermogen van maximaal 22 kw" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een vermogen van maximaal 22 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
?", @@ -1929,10 +1929,10 @@ "power-output-13": { "mappings": { "0": { - "then": "
USB om GSMs en kleine electronica op te laden
levert een vermogen van maximaal 5w" + "then": "USB om GSMs en kleine electronica op te laden levert een vermogen van maximaal 5w A" }, "1": { - "then": "
USB om GSMs en kleine electronica op te laden
levert een vermogen van maximaal 10w" + "then": "USB om GSMs en kleine electronica op te laden levert een vermogen van maximaal 10w A" } }, "question": "Welk vermogen levert een enkele stekker van type
USB om GSMs en kleine electronica op te laden
?", @@ -1949,7 +1949,7 @@ "power-output-2": { "mappings": { "0": { - "then": "
Chademo
levert een vermogen van maximaal 50 kw" + "then": "Chademo levert een vermogen van maximaal 50 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Chademo
?", @@ -1958,10 +1958,10 @@ "power-output-3": { "mappings": { "0": { - "then": "
Type 1 met kabel (J1772)
levert een vermogen van maximaal 3.7 kw" + "then": "Type 1 met kabel (J1772) levert een vermogen van maximaal 3.7 kw A" }, "1": { - "then": "
Type 1 met kabel (J1772)
levert een vermogen van maximaal 7 kw" + "then": "Type 1 met kabel (J1772) levert een vermogen van maximaal 7 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 1 met kabel (J1772)
?", @@ -1970,16 +1970,16 @@ "power-output-4": { "mappings": { "0": { - "then": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 3.7 kw" + "then": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 3.7 kw A" }, "1": { - "then": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 6.6 kw" + "then": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 6.6 kw A" }, "2": { - "then": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 7 kw" + "then": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 7 kw A" }, "3": { - "then": "
Type 1 zonder kabel (J1772)
levert een vermogen van maximaal 7.2 kw" + "then": "Type 1 zonder kabel (J1772) levert een vermogen van maximaal 7.2 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 1 zonder kabel (J1772)
?", @@ -1988,16 +1988,16 @@ "power-output-5": { "mappings": { "0": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 50 kw" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 50 kw A" }, "1": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 62.5 kw" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 62.5 kw A" }, "2": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 150 kw" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 150 kw A" }, "3": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
levert een vermogen van maximaal 350 kw" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) levert een vermogen van maximaal 350 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 1 CCS (ook gekend als Type 1 Combo)
?", @@ -2006,13 +2006,13 @@ "power-output-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
levert een vermogen van maximaal 120 kw" + "then": "Tesla Supercharger levert een vermogen van maximaal 120 kw A" }, "1": { - "then": "
Tesla Supercharger
levert een vermogen van maximaal 150 kw" + "then": "Tesla Supercharger levert een vermogen van maximaal 150 kw A" }, "2": { - "then": "
Tesla Supercharger
levert een vermogen van maximaal 250 kw" + "then": "Tesla Supercharger levert een vermogen van maximaal 250 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Tesla Supercharger
?", @@ -2021,10 +2021,10 @@ "power-output-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
levert een vermogen van maximaal 11 kw" + "then": "Type 2 (mennekes) levert een vermogen van maximaal 11 kw A" }, "1": { - "then": "
Type 2 (mennekes)
levert een vermogen van maximaal 22 kw" + "then": "Type 2 (mennekes) levert een vermogen van maximaal 22 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 2 (mennekes)
?", @@ -2033,7 +2033,7 @@ "power-output-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
levert een vermogen van maximaal 50 kw" + "then": "Type 2 CCS (mennekes) levert een vermogen van maximaal 50 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 2 CCS (mennekes)
?", @@ -2042,10 +2042,10 @@ "power-output-9": { "mappings": { "0": { - "then": "
Type 2 met kabel (J1772)
levert een vermogen van maximaal 11 kw" + "then": "Type 2 met kabel (J1772) levert een vermogen van maximaal 11 kw A" }, "1": { - "then": "
Type 2 met kabel (J1772)
levert een vermogen van maximaal 22 kw" + "then": "Type 2 met kabel (J1772) levert een vermogen van maximaal 22 kw A" } }, "question": "Welk vermogen levert een enkele stekker van type
Type 2 met kabel (J1772)
?", @@ -2061,7 +2061,7 @@ "voltage-0": { "mappings": { "0": { - "then": "
Schuko stekker zonder aardingspin (CEE7/4 type F)
heeft een spanning van 230 volt" + "then": "Schuko stekker zonder aardingspin (CEE7/4 type F) heeft een spanning van 230 volt" } }, "question": "Welke spanning levert de stekker van type
Schuko stekker zonder aardingspin (CEE7/4 type F)
", @@ -2070,7 +2070,7 @@ "voltage-1": { "mappings": { "0": { - "then": "
Europese stekker met aardingspin (CEE7/4 type E)
heeft een spanning van 230 volt" + "then": "Europese stekker met aardingspin (CEE7/4 type E) heeft een spanning van 230 volt" } }, "question": "Welke spanning levert de stekker van type
Europese stekker met aardingspin (CEE7/4 type E)
", @@ -2079,10 +2079,10 @@ "voltage-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
heeft een spanning van 500 volt" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) heeft een spanning van 500 volt" }, "1": { - "then": "
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
heeft een spanning van 920 volt" + "then": "Tesla Supercharger CCS (een type2 CCS met Tesla-logo) heeft een spanning van 920 volt" } }, "question": "Welke spanning levert de stekker van type
Tesla Supercharger CCS (een type2 CCS met Tesla-logo)
", @@ -2091,7 +2091,7 @@ "voltage-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
heeft een spanning van 480 volt" + "then": "Tesla Supercharger (destination) heeft een spanning van 480 volt" } }, "question": "Welke spanning levert de stekker van type
Tesla Supercharger (destination)
", @@ -2100,10 +2100,10 @@ "voltage-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
heeft een spanning van 230 volt" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) heeft een spanning van 230 volt" }, "1": { - "then": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
heeft een spanning van 400 volt" + "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) heeft een spanning van 400 volt" } }, "question": "Welke spanning levert de stekker van type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
", @@ -2112,7 +2112,7 @@ "voltage-13": { "mappings": { "0": { - "then": "
USB om GSMs en kleine electronica op te laden
heeft een spanning van 5 volt" + "then": "USB om GSMs en kleine electronica op te laden heeft een spanning van 5 volt" } }, "question": "Welke spanning levert de stekker van type
USB om GSMs en kleine electronica op te laden
", @@ -2129,7 +2129,7 @@ "voltage-2": { "mappings": { "0": { - "then": "
Chademo
heeft een spanning van 500 volt" + "then": "Chademo heeft een spanning van 500 volt" } }, "question": "Welke spanning levert de stekker van type
Chademo
", @@ -2138,10 +2138,10 @@ "voltage-3": { "mappings": { "0": { - "then": "
Type 1 met kabel (J1772)
heeft een spanning van 200 volt" + "then": "Type 1 met kabel (J1772) heeft een spanning van 200 volt" }, "1": { - "then": "
Type 1 met kabel (J1772)
heeft een spanning van 240 volt" + "then": "Type 1 met kabel (J1772) heeft een spanning van 240 volt" } }, "question": "Welke spanning levert de stekker van type
Type 1 met kabel (J1772)
", @@ -2150,10 +2150,10 @@ "voltage-4": { "mappings": { "0": { - "then": "
Type 1 zonder kabel (J1772)
heeft een spanning van 200 volt" + "then": "Type 1 zonder kabel (J1772) heeft een spanning van 200 volt" }, "1": { - "then": "
Type 1 zonder kabel (J1772)
heeft een spanning van 240 volt" + "then": "Type 1 zonder kabel (J1772) heeft een spanning van 240 volt" } }, "question": "Welke spanning levert de stekker van type
Type 1 zonder kabel (J1772)
", @@ -2162,10 +2162,10 @@ "voltage-5": { "mappings": { "0": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
heeft een spanning van 400 volt" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) heeft een spanning van 400 volt" }, "1": { - "then": "
Type 1 CCS (ook gekend als Type 1 Combo)
heeft een spanning van 1000 volt" + "then": "Type 1 CCS (ook gekend als Type 1 Combo) heeft een spanning van 1000 volt" } }, "question": "Welke spanning levert de stekker van type
Type 1 CCS (ook gekend als Type 1 Combo)
", @@ -2174,7 +2174,7 @@ "voltage-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
heeft een spanning van 480 volt" + "then": "Tesla Supercharger heeft een spanning van 480 volt" } }, "question": "Welke spanning levert de stekker van type
Tesla Supercharger
", @@ -2183,10 +2183,10 @@ "voltage-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
heeft een spanning van 230 volt" + "then": "Type 2 (mennekes) heeft een spanning van 230 volt" }, "1": { - "then": "
Type 2 (mennekes)
heeft een spanning van 400 volt" + "then": "Type 2 (mennekes) heeft een spanning van 400 volt" } }, "question": "Welke spanning levert de stekker van type
Type 2 (mennekes)
", @@ -2195,10 +2195,10 @@ "voltage-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
heeft een spanning van 500 volt" + "then": "Type 2 CCS (mennekes) heeft een spanning van 500 volt" }, "1": { - "then": "
Type 2 CCS (mennekes)
heeft een spanning van 920 volt" + "then": "Type 2 CCS (mennekes) heeft een spanning van 920 volt" } }, "question": "Welke spanning levert de stekker van type
Type 2 CCS (mennekes)
", @@ -2207,10 +2207,10 @@ "voltage-9": { "mappings": { "0": { - "then": "
Type 2 met kabel (J1772)
heeft een spanning van 230 volt" + "then": "Type 2 met kabel (J1772) heeft een spanning van 230 volt" }, "1": { - "then": "
Type 2 met kabel (J1772)
heeft een spanning van 400 volt" + "then": "Type 2 met kabel (J1772) heeft een spanning van 400 volt" } }, "question": "Welke spanning levert de stekker van type
Type 2 met kabel (J1772)
", From ec25b887dead9db6b96045bf82072267e4f181c7 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:01:56 +0100 Subject: [PATCH 04/24] Update of charging stations translations --- langs/layers/en.json | 218 +++++++++++++++++++++---------------------- 1 file changed, 109 insertions(+), 109 deletions(-) diff --git a/langs/layers/en.json b/langs/layers/en.json index 797ae3439..809de500a 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -1351,7 +1351,7 @@ "name": "Charging stations", "presets": { "0": { - "title": "charging station with a normal european wall plug (meant to charge electrical bikes)" + "title": "charging station for electrical bikes with a normal european wall plug (meant to charge electrical bikes)" }, "1": { "title": "charging station for cars" @@ -1394,100 +1394,100 @@ "Available_charging_stations (generated)": { "mappings": { "0": { - "then": "
Schuko wall plug without ground pin (CEE7/4 type F)
" + "then": "Schuko wall plug without ground pin (CEE7/4 type F)" }, "1": { - "then": "
Schuko wall plug without ground pin (CEE7/4 type F)
" + "then": "Schuko wall plug without ground pin (CEE7/4 type F)" }, "2": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
" + "then": "European wall plug with ground pin (CEE7/4 type E)" }, "3": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
" + "then": "European wall plug with ground pin (CEE7/4 type E)" }, "4": { - "then": "
Chademo
" + "then": "Chademo" }, "5": { - "then": "
Chademo
" + "then": "Chademo" }, "6": { - "then": "
Type 1 with cable (J1772)
" + "then": "Type 1 with cable (J1772)" }, "7": { - "then": "
Type 1 with cable (J1772)
" + "then": "Type 1 with cable (J1772)" }, "8": { - "then": "
Type 1 without cable (J1772)
" + "then": "Type 1 without cable (J1772)" }, "9": { - "then": "
Type 1 without cable (J1772)
" + "then": "Type 1 without cable (J1772)" }, "10": { - "then": "
Type 1 CCS (aka Type 1 Combo)
" + "then": "Type 1 CCS (aka Type 1 Combo)" }, "11": { - "then": "
Type 1 CCS (aka Type 1 Combo)
" + "then": "Type 1 CCS (aka Type 1 Combo)" }, "12": { - "then": "
Tesla Supercharger
" + "then": "Tesla Supercharger" }, "13": { - "then": "
Tesla Supercharger
" + "then": "Tesla Supercharger" }, "14": { - "then": "
Type 2 (mennekes)
" + "then": "Type 2 (mennekes)" }, "15": { - "then": "
Type 2 (mennekes)
" + "then": "Type 2 (mennekes)" }, "16": { - "then": "
Type 2 CCS (mennekes)
" + "then": "Type 2 CCS (mennekes)" }, "17": { - "then": "
Type 2 CCS (mennekes)
" + "then": "Type 2 CCS (mennekes)" }, "18": { - "then": "
Type 2 with cable (mennekes)
" + "then": "Type 2 with cable (mennekes)" }, "19": { - "then": "
Type 2 with cable (mennekes)
" + "then": "Type 2 with cable (mennekes)" }, "20": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
" + "then": "Tesla Supercharger CCS (a branded type2_css)" }, "21": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
" + "then": "Tesla Supercharger CCS (a branded type2_css)" }, "22": { - "then": "
Tesla Supercharger (destination)
" + "then": "Tesla Supercharger (destination)" }, "23": { - "then": "
Tesla Supercharger (destination)
" + "then": "Tesla Supercharger (destination)" }, "24": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla)" }, "25": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla)" }, "26": { - "then": "
USB to charge phones and small electronics
" + "then": "USB to charge phones and small electronics" }, "27": { - "then": "
USB to charge phones and small electronics
" + "then": "USB to charge phones and small electronics" }, "28": { - "then": "
Bosch Active Connect with 3 pins and cable
" + "then": "Bosch Active Connect with 3 pins and cable" }, "29": { - "then": "
Bosch Active Connect with 3 pins and cable
" + "then": "Bosch Active Connect with 3 pins and cable" }, "30": { - "then": "
Bosch Active Connect with 5 pins and cable
" + "then": "Bosch Active Connect with 5 pins and cable" }, "31": { - "then": "
Bosch Active Connect with 5 pins and cable
" + "then": "Bosch Active Connect with 5 pins and cable" } }, "question": "Which charging connections are available here?" @@ -1601,7 +1601,7 @@ "current-0": { "mappings": { "0": { - "then": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs at most 16 A" + "then": "Schuko wall plug without ground pin (CEE7/4 type F) outputs at most 16 A" } }, "question": "What current do the plugs with
Schuko wall plug without ground pin (CEE7/4 type F)
offer?", @@ -1610,7 +1610,7 @@ "current-1": { "mappings": { "0": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 16 A" + "then": "European wall plug with ground pin (CEE7/4 type E) outputs at most 16 A" } }, "question": "What current do the plugs with
European wall plug with ground pin (CEE7/4 type E)
offer?", @@ -1619,10 +1619,10 @@ "current-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 125 A" + "then": "Tesla Supercharger CCS (a branded type2_css) outputs at most 125 A" }, "1": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 350 A" + "then": "Tesla Supercharger CCS (a branded type2_css) outputs at most 350 A" } }, "question": "What current do the plugs with
Tesla Supercharger CCS (a branded type2_css)
offer?", @@ -1631,10 +1631,10 @@ "current-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
outputs at most 125 A" + "then": "Tesla Supercharger (destination) outputs at most 125 A" }, "1": { - "then": "
Tesla Supercharger (destination)
outputs at most 350 A" + "then": "Tesla Supercharger (destination) outputs at most 350 A" } }, "question": "What current do the plugs with
Tesla Supercharger (destination)
offer?", @@ -1643,10 +1643,10 @@ "current-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 16 A" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 16 A" }, "1": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 32 A" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 32 A" } }, "question": "What current do the plugs with
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
offer?", @@ -1655,10 +1655,10 @@ "current-13": { "mappings": { "0": { - "then": "
USB to charge phones and small electronics
outputs at most 1 A" + "then": "USB to charge phones and small electronics outputs at most 1 A" }, "1": { - "then": "
USB to charge phones and small electronics
outputs at most 2 A" + "then": "USB to charge phones and small electronics outputs at most 2 A" } }, "question": "What current do the plugs with
USB to charge phones and small electronics
offer?", @@ -1675,7 +1675,7 @@ "current-2": { "mappings": { "0": { - "then": "
Chademo
outputs at most 120 A" + "then": "Chademo outputs at most 120 A" } }, "question": "What current do the plugs with
Chademo
offer?", @@ -1684,7 +1684,7 @@ "current-3": { "mappings": { "0": { - "then": "
Type 1 with cable (J1772)
outputs at most 32 A" + "then": "Type 1 with cable (J1772) outputs at most 32 A" } }, "question": "What current do the plugs with
Type 1 with cable (J1772)
offer?", @@ -1693,7 +1693,7 @@ "current-4": { "mappings": { "0": { - "then": "
Type 1 without cable (J1772)
outputs at most 32 A" + "then": "Type 1 without cable (J1772) outputs at most 32 A" } }, "question": "What current do the plugs with
Type 1 without cable (J1772)
offer?", @@ -1702,10 +1702,10 @@ "current-5": { "mappings": { "0": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 50 A" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 50 A" }, "1": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 125 A" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 125 A" } }, "question": "What current do the plugs with
Type 1 CCS (aka Type 1 Combo)
offer?", @@ -1714,10 +1714,10 @@ "current-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
outputs at most 125 A" + "then": "Tesla Supercharger outputs at most 125 A" }, "1": { - "then": "
Tesla Supercharger
outputs at most 350 A" + "then": "Tesla Supercharger outputs at most 350 A" } }, "question": "What current do the plugs with
Tesla Supercharger
offer?", @@ -1726,10 +1726,10 @@ "current-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
outputs at most 16 A" + "then": "Type 2 (mennekes) outputs at most 16 A" }, "1": { - "then": "
Type 2 (mennekes)
outputs at most 32 A" + "then": "Type 2 (mennekes) outputs at most 32 A" } }, "question": "What current do the plugs with
Type 2 (mennekes)
offer?", @@ -1738,10 +1738,10 @@ "current-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
outputs at most 125 A" + "then": "Type 2 CCS (mennekes) outputs at most 125 A" }, "1": { - "then": "
Type 2 CCS (mennekes)
outputs at most 350 A" + "then": "Type 2 CCS (mennekes) outputs at most 350 A" } }, "question": "What current do the plugs with
Type 2 CCS (mennekes)
offer?", @@ -1750,10 +1750,10 @@ "current-9": { "mappings": { "0": { - "then": "
Type 2 with cable (mennekes)
outputs at most 16 A" + "then": "Type 2 with cable (mennekes) outputs at most 16 A" }, "1": { - "then": "
Type 2 with cable (mennekes)
outputs at most 32 A" + "then": "Type 2 with cable (mennekes) outputs at most 32 A" } }, "question": "What current do the plugs with
Type 2 with cable (mennekes)
offer?", @@ -1863,7 +1863,7 @@ "power-output-0": { "mappings": { "0": { - "then": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs at most 3.6 kw" + "then": "Schuko wall plug without ground pin (CEE7/4 type F) outputs at most 3.6 kw A" } }, "question": "What power output does a single plug of type
Schuko wall plug without ground pin (CEE7/4 type F)
offer?", @@ -1872,10 +1872,10 @@ "power-output-1": { "mappings": { "0": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 3 kw" + "then": "European wall plug with ground pin (CEE7/4 type E) outputs at most 3 kw A" }, "1": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
outputs at most 22 kw" + "then": "European wall plug with ground pin (CEE7/4 type E) outputs at most 22 kw A" } }, "question": "What power output does a single plug of type
European wall plug with ground pin (CEE7/4 type E)
offer?", @@ -1884,7 +1884,7 @@ "power-output-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
outputs at most 50 kw" + "then": "Tesla Supercharger CCS (a branded type2_css) outputs at most 50 kw A" } }, "question": "What power output does a single plug of type
Tesla Supercharger CCS (a branded type2_css)
offer?", @@ -1893,13 +1893,13 @@ "power-output-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
outputs at most 120 kw" + "then": "Tesla Supercharger (destination) outputs at most 120 kw A" }, "1": { - "then": "
Tesla Supercharger (destination)
outputs at most 150 kw" + "then": "Tesla Supercharger (destination) outputs at most 150 kw A" }, "2": { - "then": "
Tesla Supercharger (destination)
outputs at most 250 kw" + "then": "Tesla Supercharger (destination) outputs at most 250 kw A" } }, "question": "What power output does a single plug of type
Tesla Supercharger (destination)
offer?", @@ -1908,10 +1908,10 @@ "power-output-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 11 kw" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 11 kw A" }, "1": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs at most 22 kw" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs at most 22 kw A" } }, "question": "What power output does a single plug of type
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
offer?", @@ -1920,10 +1920,10 @@ "power-output-13": { "mappings": { "0": { - "then": "
USB to charge phones and small electronics
outputs at most 5w" + "then": "USB to charge phones and small electronics outputs at most 5w A" }, "1": { - "then": "
USB to charge phones and small electronics
outputs at most 10w" + "then": "USB to charge phones and small electronics outputs at most 10w A" } }, "question": "What power output does a single plug of type
USB to charge phones and small electronics
offer?", @@ -1940,7 +1940,7 @@ "power-output-2": { "mappings": { "0": { - "then": "
Chademo
outputs at most 50 kw" + "then": "Chademo outputs at most 50 kw A" } }, "question": "What power output does a single plug of type
Chademo
offer?", @@ -1949,10 +1949,10 @@ "power-output-3": { "mappings": { "0": { - "then": "
Type 1 with cable (J1772)
outputs at most 3.7 kw" + "then": "Type 1 with cable (J1772) outputs at most 3.7 kw A" }, "1": { - "then": "
Type 1 with cable (J1772)
outputs at most 7 kw" + "then": "Type 1 with cable (J1772) outputs at most 7 kw A" } }, "question": "What power output does a single plug of type
Type 1 with cable (J1772)
offer?", @@ -1961,16 +1961,16 @@ "power-output-4": { "mappings": { "0": { - "then": "
Type 1 without cable (J1772)
outputs at most 3.7 kw" + "then": "Type 1 without cable (J1772) outputs at most 3.7 kw A" }, "1": { - "then": "
Type 1 without cable (J1772)
outputs at most 6.6 kw" + "then": "Type 1 without cable (J1772) outputs at most 6.6 kw A" }, "2": { - "then": "
Type 1 without cable (J1772)
outputs at most 7 kw" + "then": "Type 1 without cable (J1772) outputs at most 7 kw A" }, "3": { - "then": "
Type 1 without cable (J1772)
outputs at most 7.2 kw" + "then": "Type 1 without cable (J1772) outputs at most 7.2 kw A" } }, "question": "What power output does a single plug of type
Type 1 without cable (J1772)
offer?", @@ -1979,16 +1979,16 @@ "power-output-5": { "mappings": { "0": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 50 kw" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 50 kw A" }, "1": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 62.5 kw" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 62.5 kw A" }, "2": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 150 kw" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 150 kw A" }, "3": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs at most 350 kw" + "then": "Type 1 CCS (aka Type 1 Combo) outputs at most 350 kw A" } }, "question": "What power output does a single plug of type
Type 1 CCS (aka Type 1 Combo)
offer?", @@ -1997,13 +1997,13 @@ "power-output-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
outputs at most 120 kw" + "then": "Tesla Supercharger outputs at most 120 kw A" }, "1": { - "then": "
Tesla Supercharger
outputs at most 150 kw" + "then": "Tesla Supercharger outputs at most 150 kw A" }, "2": { - "then": "
Tesla Supercharger
outputs at most 250 kw" + "then": "Tesla Supercharger outputs at most 250 kw A" } }, "question": "What power output does a single plug of type
Tesla Supercharger
offer?", @@ -2012,10 +2012,10 @@ "power-output-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
outputs at most 11 kw" + "then": "Type 2 (mennekes) outputs at most 11 kw A" }, "1": { - "then": "
Type 2 (mennekes)
outputs at most 22 kw" + "then": "Type 2 (mennekes) outputs at most 22 kw A" } }, "question": "What power output does a single plug of type
Type 2 (mennekes)
offer?", @@ -2024,7 +2024,7 @@ "power-output-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
outputs at most 50 kw" + "then": "Type 2 CCS (mennekes) outputs at most 50 kw A" } }, "question": "What power output does a single plug of type
Type 2 CCS (mennekes)
offer?", @@ -2033,10 +2033,10 @@ "power-output-9": { "mappings": { "0": { - "then": "
Type 2 with cable (mennekes)
outputs at most 11 kw" + "then": "Type 2 with cable (mennekes) outputs at most 11 kw A" }, "1": { - "then": "
Type 2 with cable (mennekes)
outputs at most 22 kw" + "then": "Type 2 with cable (mennekes) outputs at most 22 kw A" } }, "question": "What power output does a single plug of type
Type 2 with cable (mennekes)
offer?", @@ -2052,7 +2052,7 @@ "voltage-0": { "mappings": { "0": { - "then": "
Schuko wall plug without ground pin (CEE7/4 type F)
outputs 230 volt" + "then": "Schuko wall plug without ground pin (CEE7/4 type F) outputs 230 volt" } }, "question": "What voltage do the plugs with
Schuko wall plug without ground pin (CEE7/4 type F)
offer?", @@ -2061,7 +2061,7 @@ "voltage-1": { "mappings": { "0": { - "then": "
European wall plug with ground pin (CEE7/4 type E)
outputs 230 volt" + "then": "European wall plug with ground pin (CEE7/4 type E) outputs 230 volt" } }, "question": "What voltage do the plugs with
European wall plug with ground pin (CEE7/4 type E)
offer?", @@ -2070,10 +2070,10 @@ "voltage-10": { "mappings": { "0": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
outputs 500 volt" + "then": "Tesla Supercharger CCS (a branded type2_css) outputs 500 volt" }, "1": { - "then": "
Tesla Supercharger CCS (a branded type2_css)
outputs 920 volt" + "then": "Tesla Supercharger CCS (a branded type2_css) outputs 920 volt" } }, "question": "What voltage do the plugs with
Tesla Supercharger CCS (a branded type2_css)
offer?", @@ -2082,7 +2082,7 @@ "voltage-11": { "mappings": { "0": { - "then": "
Tesla Supercharger (destination)
outputs 480 volt" + "then": "Tesla Supercharger (destination) outputs 480 volt" } }, "question": "What voltage do the plugs with
Tesla Supercharger (destination)
offer?", @@ -2091,10 +2091,10 @@ "voltage-12": { "mappings": { "0": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs 230 volt" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs 230 volt" }, "1": { - "then": "
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
outputs 400 volt" + "then": "Tesla supercharger (destination) (A Type 2 with cable branded as tesla) outputs 400 volt" } }, "question": "What voltage do the plugs with
Tesla supercharger (destination) (A Type 2 with cable branded as tesla)
offer?", @@ -2103,7 +2103,7 @@ "voltage-13": { "mappings": { "0": { - "then": "
USB to charge phones and small electronics
outputs 5 volt" + "then": "USB to charge phones and small electronics outputs 5 volt" } }, "question": "What voltage do the plugs with
USB to charge phones and small electronics
offer?", @@ -2120,7 +2120,7 @@ "voltage-2": { "mappings": { "0": { - "then": "
Chademo
outputs 500 volt" + "then": "Chademo outputs 500 volt" } }, "question": "What voltage do the plugs with
Chademo
offer?", @@ -2129,10 +2129,10 @@ "voltage-3": { "mappings": { "0": { - "then": "
Type 1 with cable (J1772)
outputs 200 volt" + "then": "Type 1 with cable (J1772) outputs 200 volt" }, "1": { - "then": "
Type 1 with cable (J1772)
outputs 240 volt" + "then": "Type 1 with cable (J1772) outputs 240 volt" } }, "question": "What voltage do the plugs with
Type 1 with cable (J1772)
offer?", @@ -2141,10 +2141,10 @@ "voltage-4": { "mappings": { "0": { - "then": "
Type 1 without cable (J1772)
outputs 200 volt" + "then": "Type 1 without cable (J1772) outputs 200 volt" }, "1": { - "then": "
Type 1 without cable (J1772)
outputs 240 volt" + "then": "Type 1 without cable (J1772) outputs 240 volt" } }, "question": "What voltage do the plugs with
Type 1 without cable (J1772)
offer?", @@ -2153,10 +2153,10 @@ "voltage-5": { "mappings": { "0": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs 400 volt" + "then": "Type 1 CCS (aka Type 1 Combo) outputs 400 volt" }, "1": { - "then": "
Type 1 CCS (aka Type 1 Combo)
outputs 1000 volt" + "then": "Type 1 CCS (aka Type 1 Combo) outputs 1000 volt" } }, "question": "What voltage do the plugs with
Type 1 CCS (aka Type 1 Combo)
offer?", @@ -2165,7 +2165,7 @@ "voltage-6": { "mappings": { "0": { - "then": "
Tesla Supercharger
outputs 480 volt" + "then": "Tesla Supercharger outputs 480 volt" } }, "question": "What voltage do the plugs with
Tesla Supercharger
offer?", @@ -2174,10 +2174,10 @@ "voltage-7": { "mappings": { "0": { - "then": "
Type 2 (mennekes)
outputs 230 volt" + "then": "Type 2 (mennekes) outputs 230 volt" }, "1": { - "then": "
Type 2 (mennekes)
outputs 400 volt" + "then": "Type 2 (mennekes) outputs 400 volt" } }, "question": "What voltage do the plugs with
Type 2 (mennekes)
offer?", @@ -2186,10 +2186,10 @@ "voltage-8": { "mappings": { "0": { - "then": "
Type 2 CCS (mennekes)
outputs 500 volt" + "then": "Type 2 CCS (mennekes) outputs 500 volt" }, "1": { - "then": "
Type 2 CCS (mennekes)
outputs 920 volt" + "then": "Type 2 CCS (mennekes) outputs 920 volt" } }, "question": "What voltage do the plugs with
Type 2 CCS (mennekes)
offer?", @@ -2198,10 +2198,10 @@ "voltage-9": { "mappings": { "0": { - "then": "
Type 2 with cable (mennekes)
outputs 230 volt" + "then": "Type 2 with cable (mennekes) outputs 230 volt" }, "1": { - "then": "
Type 2 with cable (mennekes)
outputs 400 volt" + "then": "Type 2 with cable (mennekes) outputs 400 volt" } }, "question": "What voltage do the plugs with
Type 2 with cable (mennekes)
offer?", @@ -2215,7 +2215,7 @@ "title": { "mappings": { "0": { - "then": "Charging station for ebikes" + "then": "Charging station for electrical bicycles" }, "1": { "then": "Charging station for cars" From 32c9f53ff111e7eca174a41a7293e8782cbf04f7 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:06:43 +0100 Subject: [PATCH 05/24] Translation sync --- .../charging_station/charging_station.json | 195 +++++++++++++----- 1 file changed, 138 insertions(+), 57 deletions(-) diff --git a/assets/layers/charging_station/charging_station.json b/assets/layers/charging_station/charging_station.json index 33c290f16..38926d2d9 100644 --- a/assets/layers/charging_station/charging_station.json +++ b/assets/layers/charging_station/charging_station.json @@ -2,7 +2,8 @@ "id": "charging_station", "name": { "en": "Charging stations", - "nl": "Oplaadpunten" + "nl": "Oplaadpunten", + "de": "Ladestationen" }, "minzoom": 10, "source": { @@ -63,7 +64,8 @@ }, "description": { "en": "A charging station", - "nl": "Oplaadpunten" + "nl": "Oplaadpunten", + "de": "Eine Ladestation" }, "tagRenderings": [ "images", @@ -72,7 +74,9 @@ "#": "Allowed vehicle types", "question": { "en": "Which vehicles are allowed to charge here?", - "nl": "Welke voertuigen kunnen hier opgeladen worden?" + "nl": "Welke voertuigen kunnen hier opgeladen worden?", + "de": "Welche Fahrzeuge dürfen hier laden?", + "es": "¿A qué vehículos se permite la carga aquí?" }, "multiAnswer": true, "mappings": [ @@ -81,7 +85,8 @@ "ifnot": "bicycle=no", "then": { "en": "Bicycles can be charged here", - "nl": "Elektrische fietsen kunnen hier opgeladen worden" + "nl": "Elektrische fietsen kunnen hier opgeladen worden", + "de": "Fahrräder können hier geladen werden" } }, { @@ -89,7 +94,8 @@ "ifnot": "motorcar=no", "then": { "en": "Cars can be charged here", - "nl": "Elektrische auto's kunnen hier opgeladen worden" + "nl": "Elektrische auto's kunnen hier opgeladen worden", + "de": "Autos können hier geladen werden" } }, { @@ -97,7 +103,8 @@ "ifnot": "scooter=no", "then": { "en": "Scooters can be charged here", - "nl": "Elektrische scooters (snorfiets of bromfiets) kunnen hier opgeladen worden" + "nl": "Elektrische scooters (snorfiets of bromfiets) kunnen hier opgeladen worden", + "de": "Roller können hier geladen werden" } }, { @@ -105,7 +112,8 @@ "ifnot": "hgv=no", "then": { "en": "Heavy good vehicles (such as trucks) can be charged here", - "nl": "Vrachtwagens kunnen hier opgeladen worden" + "nl": "Vrachtwagens kunnen hier opgeladen worden", + "de": "LKW können hier geladen werden" } }, { @@ -113,7 +121,8 @@ "ifnot": "bus=no", "then": { "en": "Buses can be charged here", - "nl": "Bussen kunnen hier opgeladen worden" + "nl": "Bussen kunnen hier opgeladen worden", + "de": "Busse können hier geladen werden" } } ] @@ -190,7 +199,8 @@ "id": "Available_charging_stations (generated)", "question": { "en": "Which charging connections are available here?", - "nl": "Welke aansluitingen zijn hier beschikbaar?" + "nl": "Welke aansluitingen zijn hier beschikbaar?", + "de": "Welche Ladeanschlüsse gibt es hier?" }, "multiAnswer": true, "mappings": [ @@ -3330,14 +3340,18 @@ }, "question": { "en": "When is this charging station opened?", - "nl": "Wanneer is dit oplaadpunt beschikbaar??" + "nl": "Wanneer is dit oplaadpunt beschikbaar??", + "de": "Wann ist diese Ladestation geöffnet?", + "es": "¿Cuándo abre esta estación de carga?" }, "mappings": [ { "if": "opening_hours=24/7", "then": { "en": "24/7 opened (including holidays)", - "nl": "24/7 open - ook tijdens vakanties" + "nl": "24/7 open - ook tijdens vakanties", + "de": "durchgehend geöffnet (einschließlich Feiertage)", + "es": "Abre 24/7 (incluidos días festivos)" } } ] @@ -3447,7 +3461,9 @@ "#": "In some cases, charging is free but one has to be authenticated. We only ask for authentication if fee is no (or unset). By default one sees the questions for either the payment options or the authentication options, but normally not both", "question": { "en": "What kind of authentication is available at the charging station?", - "nl": "Hoe kan men zich aanmelden aan dit oplaadstation?" + "nl": "Hoe kan men zich aanmelden aan dit oplaadstation?", + "de": "Welche Art der Authentifizierung ist an der Ladestation möglich?", + "fr": "Quelle sorte d'authentification est disponible à cette station de charge ?" }, "multiAnswer": true, "mappings": [ @@ -3456,7 +3472,10 @@ "ifnot": "authentication:membership_card=no", "then": { "en": "Authentication by a membership card", - "nl": "Aanmelden met een lidkaart is mogelijk" + "nl": "Aanmelden met een lidkaart is mogelijk", + "de": "Authentifizierung per Mitgliedskarte", + "es": "Autenticación mediante tarjeta de membresía", + "fr": "Authentification par carte de membre" } }, { @@ -3464,7 +3483,10 @@ "ifnot": "authentication:app=no", "then": { "en": "Authentication by an app", - "nl": "Aanmelden via een applicatie is mogelijk" + "nl": "Aanmelden via een applicatie is mogelijk", + "de": "Authentifizierung per App", + "es": "Autenticación mediante aplicación", + "fr": "Authentification par une app" } }, { @@ -3472,7 +3494,10 @@ "ifnot": "authentication:phone_call=no", "then": { "en": "Authentication via phone call is available", - "nl": "Aanmelden door te bellen naar een telefoonnummer is mogelijk" + "nl": "Aanmelden door te bellen naar een telefoonnummer is mogelijk", + "de": "Authentifizierung per Anruf ist möglich", + "es": "Autenticación mediante llamada telefónica disponible", + "fr": "Authentification par appel téléphonique est disponible" } }, { @@ -3480,7 +3505,10 @@ "ifnot": "authentication:short_message=no", "then": { "en": "Authentication via SMS is available", - "nl": "Aanmelden via SMS is mogelijk" + "nl": "Aanmelden via SMS is mogelijk", + "de": "Authentifizierung per SMS ist möglich", + "es": "Autenticación mediante SMS disponible", + "fr": "Authentification par SMS est disponible" } }, { @@ -3488,7 +3516,10 @@ "ifnot": "authentication:nfc=no", "then": { "en": "Authentication via NFC is available", - "nl": "Aanmelden via NFC is mogelijk" + "nl": "Aanmelden via NFC is mogelijk", + "de": "Authentifizierung per NFC ist möglich", + "es": "Autenticación mediante NFC disponible", + "fr": "Authentification par NFC est disponible" } }, { @@ -3496,7 +3527,9 @@ "ifnot": "authentication:money_card=no", "then": { "en": "Authentication via Money Card is available", - "nl": "Aanmelden met Money Card is mogelijk" + "nl": "Aanmelden met Money Card is mogelijk", + "de": "Authentifizierung per Geldkarte ist möglich", + "es": "Autenticación mediante Money Card disponible" } }, { @@ -3504,7 +3537,10 @@ "ifnot": "authentication:debit_card=no", "then": { "en": "Authentication via debit card is available", - "nl": "Aanmelden met een betaalkaart is mogelijk" + "nl": "Aanmelden met een betaalkaart is mogelijk", + "de": "Authentifizierung per Kreditkarte ist möglich", + "es": "Autenticación mediante tarjeta de débito disponible", + "fr": "Authentification par carte de débit est disponible" } }, { @@ -3512,7 +3548,9 @@ "ifnot": "authentication:none=no", "then": { "en": "Charging here is (also) possible without authentication", - "nl": "Hier opladen is (ook) mogelijk zonder aan te melden" + "nl": "Hier opladen is (ook) mogelijk zonder aan te melden", + "de": "Das Laden ist hier (auch) ohne Authentifizierung möglich", + "fr": "Charger ici est (aussi) possible sans authentification" } } ], @@ -3579,11 +3617,15 @@ "id": "Network", "render": { "en": "Part of the network {network}", - "nl": "Maakt deel uit van het {network}-netwerk" + "nl": "Maakt deel uit van het {network}-netwerk", + "de": "Teil des Netzwerks {network}", + "es": "Parte de la red {network}" }, "question": { "en": "Is this charging station part of a network?", - "nl": "Is dit oplaadpunt deel van een groter netwerk?" + "nl": "Is dit oplaadpunt deel van een groter netwerk?", + "de": "Ist diese Ladestation Teil eines Netzwerks?", + "es": "¿Esta estación de carga forma parte de una red?" }, "freeform": { "key": "network" @@ -3593,14 +3635,17 @@ "if": "no:network=yes", "then": { "en": "Not part of a bigger network, e.g. because the charging station is maintained by a local business", - "nl": "Maakt geen deel uit van een groter netwerk, een lokale zaak of organisatie beheert dit oplaadpunt" + "nl": "Maakt geen deel uit van een groter netwerk, een lokale zaak of organisatie beheert dit oplaadpunt", + "de": "Nicht Teil eines größeren Netzwerks, z. B. weil die Ladestation von einem lokalen Unternehmen betrieben wird" } }, { "if": "network=none", "then": { "en": "Not part of a bigger network", - "nl": "Maakt geen deel uit van een groter netwerk" + "nl": "Maakt geen deel uit van een groter netwerk", + "de": "Nicht Teil eines größeren Netzwerks", + "es": "No forma parte de una red mayor" }, "hideInAnswer": true }, @@ -3646,11 +3691,13 @@ "id": "Operator", "question": { "en": "Who is the operator of this charging station?", - "nl": "Wie beheert dit oplaadpunt?" + "nl": "Wie beheert dit oplaadpunt?", + "de": "Wer ist der Betreiber dieser Ladestation?" }, "render": { "en": "This charging station is operated by {operator}", - "nl": "Wordt beheerd door {operator}" + "nl": "Wordt beheerd door {operator}", + "de": "Diese Ladestation wird betrieben von {operator}" }, "freeform": { "key": "operator" @@ -3664,7 +3711,8 @@ }, "then": { "en": "Actually, {operator} is the network", - "nl": "Eigenlijk is {operator} het netwerk waarvan het deel uitmaakt" + "nl": "Eigenlijk is {operator} het netwerk waarvan het deel uitmaakt", + "de": "Eigentlich ist {operator} das Netzwerk" }, "addExtraTags": [ "operator=" @@ -3740,7 +3788,8 @@ "id": "Operational status", "question": { "en": "Is this charging point in use?", - "nl": "Is dit oplaadpunt operationeel?" + "nl": "Is dit oplaadpunt operationeel?", + "de": "Ist dieser Ladepunkt in Betrieb?" }, "mappings": [ { @@ -3755,7 +3804,8 @@ }, "then": { "en": "This charging station works", - "nl": "Dit oplaadpunt werkt" + "nl": "Dit oplaadpunt werkt", + "de": "Diese Ladestation ist betriebsbereit" } }, { @@ -3770,7 +3820,8 @@ }, "then": { "en": "This charging station is broken", - "nl": "Dit oplaadpunt is kapot" + "nl": "Dit oplaadpunt is kapot", + "de": "Diese Ladestation ist defekt" } }, { @@ -3785,7 +3836,8 @@ }, "then": { "en": "A charging station is planned here", - "nl": "Hier zal binnenkort een oplaadpunt gebouwd worden" + "nl": "Hier zal binnenkort een oplaadpunt gebouwd worden", + "de": "Hier ist eine Ladestation geplant" } }, { @@ -3800,7 +3852,8 @@ }, "then": { "en": "A charging station is constructed here", - "nl": "Hier wordt op dit moment een oplaadpunt gebouwd" + "nl": "Hier wordt op dit moment een oplaadpunt gebouwd", + "de": "Hier wird eine Ladestation errichtet" } }, { @@ -3815,7 +3868,8 @@ }, "then": { "en": "This charging station has beed permanently disabled and is not in use anymore but is still visible", - "nl": "Dit oplaadpunt is niet meer in gebruik maar is wel nog aanwezig" + "nl": "Dit oplaadpunt is niet meer in gebruik maar is wel nog aanwezig", + "de": "Diese Ladestation wurde dauerhaft geschlossen und wird nicht mehr benutzt, ist aber noch sichtbar" } } ] @@ -3824,21 +3878,24 @@ "id": "Parking:fee", "question": { "en": "Does one have to pay a parking fee while charging?", - "nl": "Moet men parkeergeld betalen tijdens het opladen?" + "nl": "Moet men parkeergeld betalen tijdens het opladen?", + "de": "Muss man während des Ladens eine Parkgebühr bezahlen?" }, "mappings": [ { "if": "parking:fee=no", "then": { "en": "No additional parking cost while charging", - "nl": "Geen extra parkeerkost tijdens het opladen" + "nl": "Geen extra parkeerkost tijdens het opladen", + "de": "Keine zusätzlichen Parkkosten während des Ladens" } }, { "if": "parking:fee=yes", "then": { "en": "An additional parking fee should be paid while charging", - "nl": "Tijdens het opladen moet er parkeergeld betaald worden" + "nl": "Tijdens het opladen moet er parkeergeld betaald worden", + "de": "Während des Ladens ist eine zusätzliche Parkgebühr zu entrichten" } } ], @@ -3951,7 +4008,8 @@ ], "title": { "en": "charging station for cars", - "nl": "oplaadstation voor elektrische auto's" + "nl": "oplaadstation voor elektrische auto's", + "de": "Ladestation für e-bikes" }, "preciseInput": { "preferredBackground": "map" @@ -3965,20 +4023,26 @@ { "question": { "en": "All vehicle types", - "nl": "Alle voertuigen" + "nl": "Alle voertuigen", + "de": "Alle Fahrzeugtypen", + "fr": "Tout type de véhicule" } }, { "question": { "en": "Charging station for bicycles", - "nl": "Oplaadpunten voor fietsen" + "nl": "Oplaadpunten voor fietsen", + "de": "Ladestation für Fahrräder", + "fr": "Station de charge pour vélos" }, "osmTags": "bicycle=yes" }, { "question": { "en": "Charging station for cars", - "nl": "Oplaadpunten voor auto's" + "nl": "Oplaadpunten voor auto's", + "de": "Ladestation für Autos", + "fr": "Station de charge pour automobiles" }, "osmTags": { "or": [ @@ -3995,7 +4059,8 @@ { "question": { "en": "Only working charging stations", - "nl": "Enkel werkende oplaadpunten" + "nl": "Enkel werkende oplaadpunten", + "de": "Nur funktionierende Ladestationen" }, "osmTags": { "and": [ @@ -4012,13 +4077,15 @@ { "question": { "en": "All connectors", - "nl": "Alle types" + "nl": "Alle types", + "de": "Alle Anschlüsse" } }, { "question": { "en": "Has a
Schuko wall plug without ground pin (CEE7/4 type F)
connector", - "nl": "Heeft een
Schuko stekker zonder aardingspin (CEE7/4 type F)
" + "nl": "Heeft een
Schuko stekker zonder aardingspin (CEE7/4 type F)
", + "de": "Verfügt über einen
Schuko-Stecker ohne Erdungsstift (CEE7/4 Typ F)
" }, "osmTags": "socket:schuko~*" }, @@ -4032,35 +4099,40 @@ { "question": { "en": "Has a
Chademo
connector", - "nl": "Heeft een
Chademo
" + "nl": "Heeft een
Chademo
", + "de": "Verfügt über einen
Chademo
Stecker" }, "osmTags": "socket:chademo~*" }, { "question": { "en": "Has a
Type 1 with cable (J1772)
connector", - "nl": "Heeft een
Type 1 met kabel (J1772)
" + "nl": "Heeft een
Type 1 met kabel (J1772)
", + "de": "Verfügt über einen
Typ 1 (J1772)
Stecker mit Kabel" }, "osmTags": "socket:type1_cable~*" }, { "question": { "en": "Has a
Type 1 without cable (J1772)
connector", - "nl": "Heeft een
Type 1 zonder kabel (J1772)
" + "nl": "Heeft een
Type 1 zonder kabel (J1772)
", + "de": "Verfügt über einen
Typ 1 (J1772)
Stecker ohne Kabel" }, "osmTags": "socket:type1~*" }, { "question": { "en": "Has a
Type 1 CCS (aka Type 1 Combo)
connector", - "nl": "Heeft een
Type 1 CCS (ook gekend als Type 1 Combo)
" + "nl": "Heeft een
Type 1 CCS (ook gekend als Type 1 Combo)
", + "de": "Verfügt über einen
Typ 1 CCS
Stecker, auch bekannt als Typ 1 Combo" }, "osmTags": "socket:type1_combo~*" }, { "question": { "en": "Has a
Tesla Supercharger
connector", - "nl": "Heeft een
Tesla Supercharger
" + "nl": "Heeft een
Tesla Supercharger
", + "de": "Verfügt über einen
Tesla Supercharger
Stecker" }, "osmTags": "socket:tesla_supercharger~*" }, @@ -4148,11 +4220,13 @@ ], "human": { "en": " minutes", - "nl": " minuten" + "nl": " minuten", + "ru": " минут" }, "humanSingular": { "en": " minute", - "nl": " minuut" + "nl": " minuut", + "ru": " минута" } }, { @@ -4168,11 +4242,13 @@ ], "human": { "en": " hours", - "nl": " uren" + "nl": " uren", + "ru": " часов" }, "humanSingular": { "en": " hour", - "nl": " uur" + "nl": " uur", + "ru": " час" } }, { @@ -4185,11 +4261,13 @@ ], "human": { "en": " days", - "nl": " day" + "nl": " day", + "ru": " дней" }, "humanSingular": { "en": " day", - "nl": " dag" + "nl": " dag", + "ru": " день" } } ] @@ -4225,7 +4303,8 @@ ], "human": { "en": "Volts", - "nl": "volt" + "nl": "volt", + "ru": "Вольт" } } ], @@ -4294,7 +4373,8 @@ ], "human": { "en": "kilowatt", - "nl": "kilowatt" + "nl": "kilowatt", + "ru": "киловатт" } }, { @@ -4304,7 +4384,8 @@ ], "human": { "en": "megawatt", - "nl": "megawatt" + "nl": "megawatt", + "ru": "мегаватт" } } ], From f4a47732f8cad8b5447c53d1283a459cdbe2dac8 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:09:43 +0100 Subject: [PATCH 06/24] Small fixes to fixImage script --- scripts/fixImagesInTagRenderings.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/fixImagesInTagRenderings.ts b/scripts/fixImagesInTagRenderings.ts index 52e2d3b27..704896521 100644 --- a/scripts/fixImagesInTagRenderings.ts +++ b/scripts/fixImagesInTagRenderings.ts @@ -3,7 +3,6 @@ import {DesugaringStep} from "../Models/ThemeConfig/Conversion/Conversion"; import {LayerConfigJson} from "../Models/ThemeConfig/Json/LayerConfigJson"; import {Utils} from "../Utils"; import Translations from "../UI/i18n/Translations"; -import TagRenderingConfig from "../Models/ThemeConfig/TagRenderingConfig"; class ConvertImagesToIcon extends DesugaringStep { private _iconClass: string; @@ -32,7 +31,7 @@ class ConvertImagesToIcon extends DesugaringStep { } information.push("Replaced image " + images[0]) const replaced = then.OnEveryLanguage((s) => { - return s.replace(/(
]*>)?]*> ?/, "").replace(/<\/div>$/, "") + return s.replace(/(
]*>)?]*> ?/, "").replace(/<\/div>$/, "").trim() }) mapping.then = replaced.translations From 8508c86c39c522efdcb8fdb16a0423a62b52c292 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:10:23 +0100 Subject: [PATCH 07/24] Extract images in barrier.json --- assets/layers/barrier/barrier.json | 54 +++++++++++++++++++----------- langs/layers/de.json | 8 ++--- langs/layers/en.json | 8 ++--- langs/layers/fr.json | 6 ++-- langs/layers/hu.json | 8 ++--- langs/layers/nl.json | 8 ++--- 6 files changed, 54 insertions(+), 38 deletions(-) diff --git a/assets/layers/barrier/barrier.json b/assets/layers/barrier/barrier.json index 499a2157f..9bb38a52f 100644 --- a/assets/layers/barrier/barrier.json +++ b/assets/layers/barrier/barrier.json @@ -246,41 +246,57 @@ { "if": "cycle_barrier=single", "then": { - "en": "Single, just two barriers with a space inbetween ", - "nl": "Enkelvoudig, slechts twee hekjes met ruimte ertussen ", - "de": "Einfach, nur zwei Barrieren mit einem Zwischenraum ", - "hu": "Egyszeres: csak két korlát, közöttük térköz ", - "fr": "Simple, deux barrières côte à côte " + "en": "Single, just two barriers with a space inbetween", + "nl": "Enkelvoudig, slechts twee hekjes met ruimte ertussen", + "de": "Einfach, nur zwei Barrieren mit einem Zwischenraum", + "hu": "Egyszeres: csak két korlát, közöttük térköz", + "fr": "Simple, deux barrières côte à côte" + }, + "icon": { + "path": "./assets/themes/cycle_infra/Cycle_barrier_single.png", + "class": "large" } }, { "if": "cycle_barrier=double", "then": { - "en": "Double, two barriers behind each other ", - "nl": "Dubbel, twee hekjes achter elkaar ", - "de": "Doppelt, zwei Barrieren hintereinander ", - "hu": "Kétszeres: két, egymáshoz képest eltolt korlát egymás után ", + "en": "Double, two barriers behind each other", + "nl": "Dubbel, twee hekjes achter elkaar", + "de": "Doppelt, zwei Barrieren hintereinander", + "hu": "Kétszeres: két, egymáshoz képest eltolt korlát egymás után", "fr": "Double, deux barrières successives" + }, + "icon": { + "path": "./assets/themes/cycle_infra/Cycle_barrier_double.svg", + "class": "large" } }, { "if": "cycle_barrier=triple", "then": { - "en": "Triple, three barriers behind each other ", - "nl": "Drievoudig, drie hekjes achter elkaar ", - "de": "Dreifach, drei Barrieren hintereinander ", - "hu": "Háromszoros: három, egymáshoz képest eltolt korlát egymás után ", - "fr": "Triple, trois barrières successives " + "en": "Triple, three barriers behind each other", + "nl": "Drievoudig, drie hekjes achter elkaar", + "de": "Dreifach, drei Barrieren hintereinander", + "hu": "Háromszoros: három, egymáshoz képest eltolt korlát egymás után", + "fr": "Triple, trois barrières successives" + }, + "icon": { + "path": "./assets/themes/cycle_infra/Cycle_barrier_triple.png", + "class": "large" } }, { "if": "cycle_barrier=squeeze", "then": { - "en": "Squeeze gate, gap is smaller at top, than at the bottom ", - "nl": "Knijppoort, ruimte is smaller aan de top, dan aan de bodem ", - "de": "Eine Durchfahrtsbeschränkung, Durchfahrtsbreite ist oben kleiner als unten ", - "hu": "Szűkítőkapu: a rés felül keskenyebb, mint alul ", - "fr": "Poire, l’espace en hauteur est plus faible qu’au sol " + "en": "Squeeze gate, gap is smaller at top, than at the bottom", + "nl": "Knijppoort, ruimte is smaller aan de top, dan aan de bodem", + "de": "Eine Durchfahrtsbeschränkung, Durchfahrtsbreite ist oben kleiner als unten", + "hu": "Szűkítőkapu: a rés felül keskenyebb, mint alul", + "fr": "Poire, l’espace en hauteur est plus faible qu’au sol" + }, + "icon": { + "path": "./assets/themes/cycle_infra/Cycle_barrier_squeeze.png", + "class": "large" } } ], diff --git a/langs/layers/de.json b/langs/layers/de.json index c33afc891..ec39ff127 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -183,16 +183,16 @@ "Cycle barrier type": { "mappings": { "0": { - "then": "Einfach, nur zwei Barrieren mit einem Zwischenraum " + "then": "Einfach, nur zwei Barrieren mit einem Zwischenraum" }, "1": { - "then": "Doppelt, zwei Barrieren hintereinander " + "then": "Doppelt, zwei Barrieren hintereinander" }, "2": { - "then": "Dreifach, drei Barrieren hintereinander " + "then": "Dreifach, drei Barrieren hintereinander" }, "3": { - "then": "Eine Durchfahrtsbeschränkung, Durchfahrtsbreite ist oben kleiner als unten " + "then": "Eine Durchfahrtsbeschränkung, Durchfahrtsbreite ist oben kleiner als unten" } }, "question": "Um welche Art Fahrradhindernis handelt es sich?" diff --git a/langs/layers/en.json b/langs/layers/en.json index 809de500a..4e6a0a2ed 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -183,16 +183,16 @@ "Cycle barrier type": { "mappings": { "0": { - "then": "Single, just two barriers with a space inbetween " + "then": "Single, just two barriers with a space inbetween" }, "1": { - "then": "Double, two barriers behind each other " + "then": "Double, two barriers behind each other" }, "2": { - "then": "Triple, three barriers behind each other " + "then": "Triple, three barriers behind each other" }, "3": { - "then": "Squeeze gate, gap is smaller at top, than at the bottom " + "then": "Squeeze gate, gap is smaller at top, than at the bottom" } }, "question": "What kind of cycling barrier is this?" diff --git a/langs/layers/fr.json b/langs/layers/fr.json index c802184b5..1d7c4bd76 100644 --- a/langs/layers/fr.json +++ b/langs/layers/fr.json @@ -183,16 +183,16 @@ "Cycle barrier type": { "mappings": { "0": { - "then": "Simple, deux barrières côte à côte " + "then": "Simple, deux barrières côte à côte" }, "1": { "then": "Double, deux barrières successives" }, "2": { - "then": "Triple, trois barrières successives " + "then": "Triple, trois barrières successives" }, "3": { - "then": "Poire, l’espace en hauteur est plus faible qu’au sol " + "then": "Poire, l’espace en hauteur est plus faible qu’au sol" } }, "question": "Quel est ce type de barrière cyclable ?" diff --git a/langs/layers/hu.json b/langs/layers/hu.json index 6cbee3e47..eb6752e03 100644 --- a/langs/layers/hu.json +++ b/langs/layers/hu.json @@ -183,16 +183,16 @@ "Cycle barrier type": { "mappings": { "0": { - "then": "Egyszeres: csak két korlát, közöttük térköz " + "then": "Egyszeres: csak két korlát, közöttük térköz" }, "1": { - "then": "Kétszeres: két, egymáshoz képest eltolt korlát egymás után " + "then": "Kétszeres: két, egymáshoz képest eltolt korlát egymás után" }, "2": { - "then": "Háromszoros: három, egymáshoz képest eltolt korlát egymás után " + "then": "Háromszoros: három, egymáshoz képest eltolt korlát egymás után" }, "3": { - "then": "Szűkítőkapu: a rés felül keskenyebb, mint alul " + "then": "Szűkítőkapu: a rés felül keskenyebb, mint alul" } }, "question": "Milyen fajta kerékpárakadály ez?" diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 46d32efab..1c8791054 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -183,16 +183,16 @@ "Cycle barrier type": { "mappings": { "0": { - "then": "Enkelvoudig, slechts twee hekjes met ruimte ertussen " + "then": "Enkelvoudig, slechts twee hekjes met ruimte ertussen" }, "1": { - "then": "Dubbel, twee hekjes achter elkaar " + "then": "Dubbel, twee hekjes achter elkaar" }, "2": { - "then": "Drievoudig, drie hekjes achter elkaar " + "then": "Drievoudig, drie hekjes achter elkaar" }, "3": { - "then": "Knijppoort, ruimte is smaller aan de top, dan aan de bodem " + "then": "Knijppoort, ruimte is smaller aan de top, dan aan de bodem" } }, "question": "Wat voor fietshekjes zijn dit?" From 628cffbf0bd2b81abf429ee0a92b139fc7e0a373 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:12:31 +0100 Subject: [PATCH 08/24] Extract images from bike_parking.json --- assets/layers/bike_parking/bike_parking.json | 138 +++++++++++-------- langs/layers/de.json | 14 +- langs/layers/en.json | 14 +- langs/layers/fr.json | 14 +- langs/layers/gl.json | 12 +- langs/layers/hu.json | 8 +- langs/layers/it.json | 14 +- langs/layers/nl.json | 14 +- langs/layers/ru.json | 6 +- langs/layers/zh_Hant.json | 14 +- 10 files changed, 138 insertions(+), 110 deletions(-) diff --git a/assets/layers/bike_parking/bike_parking.json b/assets/layers/bike_parking/bike_parking.json index 00b6d02d6..7e7f91c3f 100644 --- a/assets/layers/bike_parking/bike_parking.json +++ b/assets/layers/bike_parking/bike_parking.json @@ -100,91 +100,119 @@ { "if": "bicycle_parking=stands", "then": { - "en": "Staple racks ", - "nl": "Nietjes ", - "fr": "Arceaux ", - "gl": "De roda (Stands) ", - "de": "Fahrradbügel ", - "hu": "Korlát ", - "it": "Archetti ", - "zh_Hant": "單車架 " + "en": "Staple racks", + "nl": "Nietjes", + "fr": "Arceaux", + "gl": "De roda (Stands)", + "de": "Fahrradbügel", + "hu": "Korlát", + "it": "Archetti", + "zh_Hant": "單車架" + }, + "icon": { + "path": "./assets/layers/bike_parking/staple.svg", + "class": "large" } }, { "if": "bicycle_parking=wall_loops", "then": { - "en": "Wheel rack/loops ", - "nl": "Wielrek/lussen ", - "fr": "Pinces-roues ", - "gl": "Aros ", - "de": "Metallgestänge ", - "hu": "Kerékbefogó hurok ", - "it": "Scolapiatti ", - "zh_Hant": "車輪架/圓圈 " + "en": "Wheel rack/loops", + "nl": "Wielrek/lussen", + "fr": "Pinces-roues", + "gl": "Aros", + "de": "Metallgestänge", + "hu": "Kerékbefogó hurok", + "it": "Scolapiatti", + "zh_Hant": "車輪架/圓圈" + }, + "icon": { + "path": "./assets/layers/bike_parking/wall_loops.svg", + "class": "large" } }, { "if": "bicycle_parking=handlebar_holder", "then": { - "en": "Handlebar holder ", - "nl": "Stuurhouder ", - "fr": "Support guidon ", - "gl": "Cadeado para guiador ", - "de": "Halter für Fahrradlenker ", - "it": "Blocca manubrio ", - "zh_Hant": "車把架 " + "en": "Handlebar holder", + "nl": "Stuurhouder", + "fr": "Support guidon", + "gl": "Cadeado para guiador", + "de": "Halter für Fahrradlenker", + "it": "Blocca manubrio", + "zh_Hant": "車把架" + }, + "icon": { + "path": "./assets/layers/bike_parking/handlebar_holder.svg", + "class": "large" } }, { "if": "bicycle_parking=rack", "then": { - "en": "Rack ", - "nl": "Rek ", - "fr": "Râtelier ", - "gl": "Cremalleira ", - "de": "Gestell ", - "zh_Hant": "車架", - "it": "Rastrelliera ", - "ru": "Стойка " + "en": "Rack", + "nl": "Rek", + "fr": "Râtelier", + "gl": "Cremalleira", + "de": "Gestell", + "zh_Hant": "車架", + "it": "Rastrelliera", + "ru": "Стойка" + }, + "icon": { + "path": "./assets/layers/bike_parking/rack.svg", + "class": "large" } }, { "if": "bicycle_parking=two_tier", "then": { - "en": "Two-tiered ", - "nl": "Dubbel (twee verdiepingen) ", - "fr": "Superposé ", - "gl": "Dobre cremalleira ", - "de": "Zweistufig ", - "hu": "Kétszintű ", - "zh_Hant": "兩層", - "it": "A due piani ", - "ru": "Двухуровневая " + "en": "Two-tiered", + "nl": "Dubbel (twee verdiepingen)", + "fr": "Superposé", + "gl": "Dobre cremalleira", + "de": "Zweistufig", + "hu": "Kétszintű", + "zh_Hant": "兩層", + "it": "A due piani", + "ru": "Двухуровневая" + }, + "icon": { + "path": "./assets/layers/bike_parking/two_tier.svg", + "class": "large" } }, { "if": "bicycle_parking=shed", "then": { - "en": "Shed ", - "nl": "Schuur ", - "fr": "Abri ", - "gl": "Abeiro ", - "de": "Schuppen ", - "hu": "Fészer ", - "zh_Hant": "車棚 ", - "it": "Rimessa ", - "ru": "Навес " + "en": "Shed", + "nl": "Schuur", + "fr": "Abri", + "gl": "Abeiro", + "de": "Schuppen", + "hu": "Fészer", + "zh_Hant": "車棚", + "it": "Rimessa", + "ru": "Навес" + }, + "icon": { + "path": "./assets/layers/bike_parking/shed.svg", + "class": "large" } }, { "if": "bicycle_parking=bollard", "then": { - "en": "Bollard ", - "nl": "Paal met ring ", - "fr": "Potelet ", - "it": "Colonnina ", - "de": "Poller ", - "zh_Hant": "柱子 " + "en": "Bollard", + "nl": "Paal met ring", + "fr": "Potelet", + "it": "Colonnina", + "de": "Poller", + "zh_Hant": "柱子" + }, + "icon": { + "path": "./assets/layers/bike_parking/bollard.svg", + "class": "large" } }, { diff --git a/langs/layers/de.json b/langs/layers/de.json index ec39ff127..82174c489 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -574,25 +574,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Fahrradbügel " + "then": "Fahrradbügel" }, "1": { - "then": "Metallgestänge " + "then": "Metallgestänge" }, "2": { - "then": "Halter für Fahrradlenker " + "then": "Halter für Fahrradlenker" }, "3": { - "then": "Gestell " + "then": "Gestell" }, "4": { - "then": "Zweistufig " + "then": "Zweistufig" }, "5": { - "then": "Schuppen " + "then": "Schuppen" }, "6": { - "then": "Poller " + "then": "Poller" }, "7": { "then": "Ein Bereich auf dem Boden, der für das Abstellen von Fahrrädern gekennzeichnet ist" diff --git a/langs/layers/en.json b/langs/layers/en.json index 4e6a0a2ed..cabaf4b8c 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -687,25 +687,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Staple racks " + "then": "Staple racks" }, "1": { - "then": "Wheel rack/loops " + "then": "Wheel rack/loops" }, "2": { - "then": "Handlebar holder " + "then": "Handlebar holder" }, "3": { - "then": "Rack " + "then": "Rack" }, "4": { - "then": "Two-tiered " + "then": "Two-tiered" }, "5": { - "then": "Shed " + "then": "Shed" }, "6": { - "then": "Bollard " + "then": "Bollard" }, "7": { "then": "An area on the floor which is marked for bicycle parking" diff --git a/langs/layers/fr.json b/langs/layers/fr.json index 1d7c4bd76..79c03d20c 100644 --- a/langs/layers/fr.json +++ b/langs/layers/fr.json @@ -539,25 +539,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Arceaux " + "then": "Arceaux" }, "1": { - "then": "Pinces-roues " + "then": "Pinces-roues" }, "2": { - "then": "Support guidon " + "then": "Support guidon" }, "3": { - "then": "Râtelier " + "then": "Râtelier" }, "4": { - "then": "Superposé " + "then": "Superposé" }, "5": { - "then": "Abri " + "then": "Abri" }, "6": { - "then": "Potelet " + "then": "Potelet" }, "7": { "then": "Zone au sol qui est marquée pour le stationnement des vélos" diff --git a/langs/layers/gl.json b/langs/layers/gl.json index 33e42935a..be5f07945 100644 --- a/langs/layers/gl.json +++ b/langs/layers/gl.json @@ -89,22 +89,22 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "De roda (Stands) " + "then": "De roda (Stands)" }, "1": { - "then": "Aros " + "then": "Aros" }, "2": { - "then": "Cadeado para guiador " + "then": "Cadeado para guiador" }, "3": { - "then": "Cremalleira " + "then": "Cremalleira" }, "4": { - "then": "Dobre cremalleira " + "then": "Dobre cremalleira" }, "5": { - "then": "Abeiro " + "then": "Abeiro" } }, "question": "Que tipo de aparcadoiro de bicicletas é?", diff --git a/langs/layers/hu.json b/langs/layers/hu.json index eb6752e03..05fe688fa 100644 --- a/langs/layers/hu.json +++ b/langs/layers/hu.json @@ -397,16 +397,16 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Korlát " + "then": "Korlát" }, "1": { - "then": "Kerékbefogó hurok " + "then": "Kerékbefogó hurok" }, "4": { - "then": "Kétszintű " + "then": "Kétszintű" }, "5": { - "then": "Fészer " + "then": "Fészer" } }, "question": "Milyen típusú ez a kerékpártároló?", diff --git a/langs/layers/it.json b/langs/layers/it.json index 29a38b616..814431ad8 100644 --- a/langs/layers/it.json +++ b/langs/layers/it.json @@ -419,25 +419,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Archetti " + "then": "Archetti" }, "1": { - "then": "Scolapiatti " + "then": "Scolapiatti" }, "2": { - "then": "Blocca manubrio " + "then": "Blocca manubrio" }, "3": { - "then": "Rastrelliera " + "then": "Rastrelliera" }, "4": { - "then": "A due piani " + "then": "A due piani" }, "5": { - "then": "Rimessa " + "then": "Rimessa" }, "6": { - "then": "Colonnina " + "then": "Colonnina" }, "7": { "then": "Una zona del pavimento che è marcata per il parcheggio delle bici" diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 1c8791054..2e501ef8a 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -687,25 +687,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "Nietjes " + "then": "Nietjes" }, "1": { - "then": "Wielrek/lussen " + "then": "Wielrek/lussen" }, "2": { - "then": "Stuurhouder " + "then": "Stuurhouder" }, "3": { - "then": "Rek " + "then": "Rek" }, "4": { - "then": "Dubbel (twee verdiepingen) " + "then": "Dubbel (twee verdiepingen)" }, "5": { - "then": "Schuur " + "then": "Schuur" }, "6": { - "then": "Paal met ring " + "then": "Paal met ring" }, "7": { "then": "Een oppervlakte die gemarkeerd is om fietsen te parkeren" diff --git a/langs/layers/ru.json b/langs/layers/ru.json index 0d78ee075..90e13fc43 100644 --- a/langs/layers/ru.json +++ b/langs/layers/ru.json @@ -420,13 +420,13 @@ "Bicycle parking type": { "mappings": { "3": { - "then": "Стойка " + "then": "Стойка" }, "4": { - "then": "Двухуровневая " + "then": "Двухуровневая" }, "5": { - "then": "Навес " + "then": "Навес" } }, "question": "К какому типу относится эта велопарковка?", diff --git a/langs/layers/zh_Hant.json b/langs/layers/zh_Hant.json index 1245e609a..f1e931d5d 100644 --- a/langs/layers/zh_Hant.json +++ b/langs/layers/zh_Hant.json @@ -379,25 +379,25 @@ "Bicycle parking type": { "mappings": { "0": { - "then": "單車架 " + "then": "單車架" }, "1": { - "then": "車輪架/圓圈 " + "then": "車輪架/圓圈" }, "2": { - "then": "車把架 " + "then": "車把架" }, "3": { - "then": "車架" + "then": "車架" }, "4": { - "then": "兩層" + "then": "兩層" }, "5": { - "then": "車棚 " + "then": "車棚" }, "6": { - "then": "柱子 " + "then": "柱子" }, "7": { "then": "樓層當中標示為單車停車場的區域" From 78c60ad549a17883e1bbaadb9f3c2b664de7cf5f Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:22:09 +0100 Subject: [PATCH 09/24] Fix images in cycleways_and_roads.json --- .../cycleways_and_roads.json | 225 ++++++++++++------ langs/layers/de.json | 19 +- langs/layers/en.json | 52 +--- langs/layers/id.json | 10 +- langs/layers/nl.json | 40 ++-- 5 files changed, 187 insertions(+), 159 deletions(-) diff --git a/assets/layers/cycleways_and_roads/cycleways_and_roads.json b/assets/layers/cycleways_and_roads/cycleways_and_roads.json index 61093a5a4..66c16eb2f 100644 --- a/assets/layers/cycleways_and_roads/cycleways_and_roads.json +++ b/assets/layers/cycleways_and_roads/cycleways_and_roads.json @@ -805,50 +805,66 @@ { "if": "cycleway:traffic_sign=BE:D7", "then": { - "en": "Compulsory cycleway ", - "nl": "Verplicht fietspad ", - "de": "Vorgeschriebener Radweg ", - "id": "Jalur sepeda wajib " + "en": "Compulsory cycleway", + "nl": "Verplicht fietspad", + "de": "Vorgeschriebener Radweg", + "id": "Jalur sepeda wajib" }, - "hideInAnswer": "_country!=be" + "hideInAnswer": "_country!=be", + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D07.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign~BE:D7;.*", "then": { - "en": "Compulsory cycleway (with supplementary sign)
", - "nl": "Verplicht fietspad (met onderbord)
", - "de": "Vorgeschriebener Radweg (mit Zusatzschild)
", - "id": "Jalur sepeda wajib (dengan tanda tambahan)
" + "en": "Compulsory cycleway (with supplementary sign)
", + "nl": "Verplicht fietspad (met onderbord)
", + "de": "Vorgeschriebener Radweg (mit Zusatzschild)
", + "id": "Jalur sepeda wajib (dengan tanda tambahan)
" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D07.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D9", "then": { - "en": "Segregated foot/cycleway ", - "nl": "Afgescheiden voet-/fietspad ", - "de": "Getrennter Fuß-/Radweg ", - "id": "Jalur pejalan kaki/sepeda terpisah " + "en": "Segregated foot/cycleway", + "nl": "Afgescheiden voet-/fietspad", + "de": "Getrennter Fuß-/Radweg", + "id": "Jalur pejalan kaki/sepeda terpisah" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:foot=designated", "cycleway:segregated=yes" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D09.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D10", "then": { - "en": "Unsegregated foot/cycleway ", - "nl": "Gedeeld voet-/fietspad ", - "de": "Gemeinsamer Fuß-/Radweg ", - "id": "Jalur pejalan kaki/sepeda tidak terpisah " + "en": "Unsegregated foot/cycleway", + "nl": "Gedeeld voet-/fietspad", + "de": "Gemeinsamer Fuß-/Radweg", + "id": "Jalur pejalan kaki/sepeda tidak terpisah" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:foot=designated", "cycleway:segregated=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D10.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=none", @@ -878,10 +894,10 @@ { "if": "traffic_sign=BE:D7", "then": { - "en": "Compulsory cycleway ", - "nl": "Verplicht fietspad ", - "de": "Vorgeschriebener Radweg ", - "id": "Jalur sepeda wajib " + "en": "Compulsory cycleway", + "nl": "Verplicht fietspad", + "de": "Vorgeschriebener Radweg", + "id": "Jalur sepeda wajib" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -889,23 +905,31 @@ "mofa=designated", "moped=yes", "speed_pedelec=yes" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D07.svg", + "class": "medium" + } }, { "if": "traffic_sign~BE:D7;.*", "then": { - "en": "Compulsory cycleway (with supplementary sign)
", - "nl": "Verplicht fietspad (met onderbord)
", - "de": "Vorgeschriebener Radweg (mit Zusatzschild)
" + "en": "Compulsory cycleway (with supplementary sign)
", + "nl": "Verplicht fietspad (met onderbord)
", + "de": "Vorgeschriebener Radweg (mit Zusatzschild)
" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D07.svg", + "class": "medium" + } }, { "if": "traffic_sign=BE:D9", "then": { - "en": "Segregated foot/cycleway ", - "nl": "Afgescheiden voet-/fietspad ", - "de": "Getrennter Fuß-/Radweg " + "en": "Segregated foot/cycleway", + "nl": "Afgescheiden voet-/fietspad", + "de": "Getrennter Fuß-/Radweg" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -915,14 +939,18 @@ "moped=no", "speed_pedelec=no", "segregated=yes" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D09.svg", + "class": "medium" + } }, { "if": "traffic_sign=BE:D10", "then": { - "en": "Unsegregated foot/cycleway ", - "nl": "Gedeeld voet-/fietspad ", - "de": "Gemeinsamer Fuß-/Radweg " + "en": "Unsegregated foot/cycleway", + "nl": "Gedeeld voet-/fietspad", + "de": "Gemeinsamer Fuß-/Radweg" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -932,7 +960,11 @@ "moped=no", "speed_pedelec=no", "segregated=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_road_sign_D10.svg", + "class": "medium" + } }, { "if": "traffic_sign=none", @@ -961,70 +993,88 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M6", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets Klass B verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:moped=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M6.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D7;BE:M13", "then": { - "en": "", - "nl": "" + "nl": "Speedpedelec (Bromfiets klasse P) verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:speed_pedelec=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M13.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D7;BE:M14", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:moped=designated", "cycleway:speed_pedelec=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M14.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D7;BE:M7", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:moped=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M7.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D7;BE:M15", "then": { - "en": "", - "nl": "" + "nl": "Speedpedelec (bromfiets klasse P) verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:speed_pedelec=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M15.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign=BE:D7;BE:M16", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B en speedpedelec (klasse P) verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "cycleway:moped=designated", "cycleway:speed_pedelec=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M16.svg", + "class": "medium" + } }, { "if": "cycleway:traffic_sign:supplementary=none", @@ -1053,71 +1103,88 @@ { "if": "traffic_sign=BE:D7;BE:M6", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "moped=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M6.svg", + "class": "medium" + } }, { "if": "traffic_sign=BE:D7;BE:M13", "then": { - "en": "", - "nl": "", - "de": "" + "nl": "Speedpedelc (klasse P) verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "speed_pedelec=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M13.svg", + "class": "medium" + } }, { "if": "traffic_sign=BE:D7;BE:M14", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B en speedpedelec (klasse P) verplicht" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "moped=designated", "speed_pedelec=designated" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M14.svg", + "class": "medium" + } }, { "if": "traffic_sign=BE:D7;BE:M7", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ "moped=no" - ] + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M7.svg", + "class": "medium" + } }, { - "if": ":traffic_sign=BE:D7;BE:M15", + "if": "cycleway:traffic_sign=BE:D7;BE:M15", "then": { - "en": "", - "nl": "" + "nl": "Speedpedelec (bromfiets klasse P) verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ - "speed_pedelec=no" - ] + "cycleway:speed_pedelec=no" + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M15.svg", + "class": "medium" + } }, { - "if": "traffic_sign=BE:D7;BE:M16", + "if": "cycleway:traffic_sign=BE:D7;BE:M16", "then": { - "en": "", - "nl": "" + "nl": "Bromfiets klasse B en speedpedelec (klasse P) verboden" }, "hideInAnswer": "_country!=be", "addExtraTags": [ - "moped=designated", - "speed_pedelec=no" - ] + "cycleway:moped=designated", + "cycleway:speed_pedelec=no" + ], + "icon": { + "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M16.svg", + "class": "medium" + } }, { "if": "traffic_sign:supplementary=none", diff --git a/langs/layers/de.json b/langs/layers/de.json index 82174c489..701e086e3 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -1559,16 +1559,16 @@ "cycleway-lane-track-traffic-signs": { "mappings": { "0": { - "then": "Vorgeschriebener Radweg " + "then": "Vorgeschriebener Radweg" }, "1": { - "then": "Vorgeschriebener Radweg (mit Zusatzschild)
" + "then": "Vorgeschriebener Radweg (mit Zusatzschild)
" }, "2": { - "then": "Getrennter Fuß-/Radweg " + "then": "Getrennter Fuß-/Radweg" }, "3": { - "then": "Gemeinsamer Fuß-/Radweg " + "then": "Gemeinsamer Fuß-/Radweg" }, "4": { "then": "Kein Verkehrsschild vorhanden" @@ -1596,16 +1596,16 @@ "cycleway-traffic-signs": { "mappings": { "0": { - "then": "Vorgeschriebener Radweg " + "then": "Vorgeschriebener Radweg" }, "1": { - "then": "Vorgeschriebener Radweg (mit Zusatzschild)
" + "then": "Vorgeschriebener Radweg (mit Zusatzschild)
" }, "2": { - "then": "Getrennter Fuß-/Radweg " + "then": "Getrennter Fuß-/Radweg" }, "3": { - "then": "Gemeinsamer Fuß-/Radweg " + "then": "Gemeinsamer Fuß-/Radweg" }, "4": { "then": "Kein Verkehrsschild vorhanden" @@ -1615,9 +1615,6 @@ }, "cycleway-traffic-signs-D7-supplementary": { "mappings": { - "1": { - "then": "" - }, "6": { "then": "Kein zusätzliches Verkehrszeichen vorhanden" } diff --git a/langs/layers/en.json b/langs/layers/en.json index cabaf4b8c..40d20b5e3 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -2626,16 +2626,16 @@ "cycleway-lane-track-traffic-signs": { "mappings": { "0": { - "then": "Compulsory cycleway " + "then": "Compulsory cycleway" }, "1": { - "then": "Compulsory cycleway (with supplementary sign)
" + "then": "Compulsory cycleway (with supplementary sign)
" }, "2": { - "then": "Segregated foot/cycleway " + "then": "Segregated foot/cycleway" }, "3": { - "then": "Unsegregated foot/cycleway " + "then": "Unsegregated foot/cycleway" }, "4": { "then": "No traffic sign present" @@ -2663,16 +2663,16 @@ "cycleway-traffic-signs": { "mappings": { "0": { - "then": "Compulsory cycleway " + "then": "Compulsory cycleway" }, "1": { - "then": "Compulsory cycleway (with supplementary sign)
" + "then": "Compulsory cycleway (with supplementary sign)
" }, "2": { - "then": "Segregated foot/cycleway " + "then": "Segregated foot/cycleway" }, "3": { - "then": "Unsegregated foot/cycleway " + "then": "Unsegregated foot/cycleway" }, "4": { "then": "No traffic sign present" @@ -2682,24 +2682,6 @@ }, "cycleway-traffic-signs-D7-supplementary": { "mappings": { - "0": { - "then": "" - }, - "1": { - "then": "" - }, - "2": { - "then": "" - }, - "3": { - "then": "" - }, - "4": { - "then": "" - }, - "5": { - "then": "" - }, "6": { "then": "No supplementary traffic sign present" } @@ -2708,24 +2690,6 @@ }, "cycleway-traffic-signs-supplementary": { "mappings": { - "0": { - "then": "" - }, - "1": { - "then": "" - }, - "2": { - "then": "" - }, - "3": { - "then": "" - }, - "4": { - "then": "" - }, - "5": { - "then": "" - }, "6": { "then": "No supplementary traffic sign present" } diff --git a/langs/layers/id.json b/langs/layers/id.json index d697ec9b1..408033c98 100644 --- a/langs/layers/id.json +++ b/langs/layers/id.json @@ -228,16 +228,16 @@ "cycleway-lane-track-traffic-signs": { "mappings": { "0": { - "then": "Jalur sepeda wajib " + "then": "Jalur sepeda wajib" }, "1": { - "then": "Jalur sepeda wajib (dengan tanda tambahan)
" + "then": "Jalur sepeda wajib (dengan tanda tambahan)
" }, "2": { - "then": "Jalur pejalan kaki/sepeda terpisah " + "then": "Jalur pejalan kaki/sepeda terpisah" }, "3": { - "then": "Jalur pejalan kaki/sepeda tidak terpisah " + "then": "Jalur pejalan kaki/sepeda tidak terpisah" }, "4": { "then": "Tidak ada rambu lalu lintas" @@ -265,7 +265,7 @@ "cycleway-traffic-signs": { "mappings": { "0": { - "then": "Jalur sepeda wajib " + "then": "Jalur sepeda wajib" } } } diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 2e501ef8a..3204cd289 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -2642,16 +2642,16 @@ "cycleway-lane-track-traffic-signs": { "mappings": { "0": { - "then": "Verplicht fietspad " + "then": "Verplicht fietspad" }, "1": { - "then": "Verplicht fietspad (met onderbord)
" + "then": "Verplicht fietspad (met onderbord)
" }, "2": { - "then": "Afgescheiden voet-/fietspad " + "then": "Afgescheiden voet-/fietspad" }, "3": { - "then": "Gedeeld voet-/fietspad " + "then": "Gedeeld voet-/fietspad" }, "4": { "then": "Geen verkeersbord aanwezig" @@ -2679,16 +2679,16 @@ "cycleway-traffic-signs": { "mappings": { "0": { - "then": "Verplicht fietspad " + "then": "Verplicht fietspad" }, "1": { - "then": "Verplicht fietspad (met onderbord)
" + "then": "Verplicht fietspad (met onderbord)
" }, "2": { - "then": "Afgescheiden voet-/fietspad " + "then": "Afgescheiden voet-/fietspad" }, "3": { - "then": "Gedeeld voet-/fietspad " + "then": "Gedeeld voet-/fietspad" }, "4": { "then": "Geen verkeersbord aanwezig" @@ -2699,22 +2699,22 @@ "cycleway-traffic-signs-D7-supplementary": { "mappings": { "0": { - "then": "" + "then": "Bromfiets klasse B verplicht" }, "1": { - "then": "" + "then": "Speedpedelc (klasse P) verplicht" }, "2": { - "then": "" + "then": "Bromfiets klasse B en speedpedelec (klasse P) verplicht" }, "3": { - "then": "" + "then": "Bromfiets klasse B verboden" }, "4": { - "then": "" + "then": "Speedpedelec (bromfiets klasse P) verboden" }, "5": { - "then": "" + "then": "Bromfiets klasse B en speedpedelec (klasse P) verboden" }, "6": { "then": "Geen onderbord aanwezig" @@ -2725,22 +2725,22 @@ "cycleway-traffic-signs-supplementary": { "mappings": { "0": { - "then": "" + "then": "Bromfiets Klass B verplicht" }, "1": { - "then": "" + "then": "Speedpedelec (Bromfiets klasse P) verplicht" }, "2": { - "then": "" + "then": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht" }, "3": { - "then": "" + "then": "Bromfiets klasse B verboden" }, "4": { - "then": "" + "then": "Speedpedelec (bromfiets klasse P) verboden" }, "5": { - "then": "" + "then": "Bromfiets klasse B en speedpedelec (klasse P) verboden" }, "6": { "then": "Geen onderbord aanwezig" From 4ab3d5645252397cd53ce41bba57b988a506457b Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:29:41 +0100 Subject: [PATCH 10/24] Remove duplicate question, fix english translations --- .../cycleways_and_roads.json | 122 ++---------------- langs/layers/de.json | 8 -- langs/layers/en.json | 26 ++-- langs/layers/nl.json | 32 +---- 4 files changed, 30 insertions(+), 158 deletions(-) diff --git a/assets/layers/cycleways_and_roads/cycleways_and_roads.json b/assets/layers/cycleways_and_roads/cycleways_and_roads.json index 66c16eb2f..a0b7327c1 100644 --- a/assets/layers/cycleways_and_roads/cycleways_and_roads.json +++ b/assets/layers/cycleways_and_roads/cycleways_and_roads.json @@ -993,7 +993,8 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M6", "then": { - "nl": "Bromfiets Klass B verplicht" + "en": "Mopeds must use the cycleway", + "nl": "Bromfiets Klass B verplicht op het fietspad" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -1007,7 +1008,8 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M13", "then": { - "nl": "Speedpedelec (Bromfiets klasse P) verplicht" + "en": "Speedpedelecs must use the cycleway", + "nl": "Speedpedelec (Bromfiets klasse P) verplicht op het fietspad" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -1021,7 +1023,8 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M14", "then": { - "nl": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht" + "en": "Mopeds and speedpedelecs must use the cycleway", + "nl": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht op het fietspad" }, "hideInAnswer": "_country!=be", "addExtraTags": [ @@ -1036,6 +1039,7 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M7", "then": { + "en": "Mopeds are not allowed", "nl": "Bromfiets klasse B verboden" }, "hideInAnswer": "_country!=be", @@ -1050,6 +1054,7 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M15", "then": { + "en": "Speedpedelecs are not allowed", "nl": "Speedpedelec (bromfiets klasse P) verboden" }, "hideInAnswer": "_country!=be", @@ -1064,6 +1069,7 @@ { "if": "cycleway:traffic_sign=BE:D7;BE:M16", "then": { + "en": "Mopeds and speedpedelecs are not allowed", "nl": "Bromfiets klasse B en speedpedelec (klasse P) verboden" }, "hideInAnswer": "_country!=be", @@ -1086,116 +1092,6 @@ } ] }, - { - "id": "cycleway-traffic-signs-D7-supplementary", - "question": { - "en": "Does the traffic sign D7 () have a supplementary sign?", - "nl": "Heeft het verkeersbord D7 () een onderbord?", - "de": "Hat das Verkehrszeichen D7 () ein Zusatzzeichen?" - }, - "condition": { - "or": [ - "traffic_sign=BE:D7", - "traffic_sign~BE:D7;.*" - ] - }, - "mappings": [ - { - "if": "traffic_sign=BE:D7;BE:M6", - "then": { - "nl": "Bromfiets klasse B verplicht" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "moped=designated" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M6.svg", - "class": "medium" - } - }, - { - "if": "traffic_sign=BE:D7;BE:M13", - "then": { - "nl": "Speedpedelc (klasse P) verplicht" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "speed_pedelec=designated" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M13.svg", - "class": "medium" - } - }, - { - "if": "traffic_sign=BE:D7;BE:M14", - "then": { - "nl": "Bromfiets klasse B en speedpedelec (klasse P) verplicht" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "moped=designated", - "speed_pedelec=designated" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M14.svg", - "class": "medium" - } - }, - { - "if": "traffic_sign=BE:D7;BE:M7", - "then": { - "nl": "Bromfiets klasse B verboden" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "moped=no" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M7.svg", - "class": "medium" - } - }, - { - "if": "cycleway:traffic_sign=BE:D7;BE:M15", - "then": { - "nl": "Speedpedelec (bromfiets klasse P) verboden" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "cycleway:speed_pedelec=no" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M15.svg", - "class": "medium" - } - }, - { - "if": "cycleway:traffic_sign=BE:D7;BE:M16", - "then": { - "nl": "Bromfiets klasse B en speedpedelec (klasse P) verboden" - }, - "hideInAnswer": "_country!=be", - "addExtraTags": [ - "cycleway:moped=designated", - "cycleway:speed_pedelec=no" - ], - "icon": { - "path": "./assets/themes/cycle_infra/Belgian_traffic_sign_M16.svg", - "class": "medium" - } - }, - { - "if": "traffic_sign:supplementary=none", - "then": { - "en": "No supplementary traffic sign present", - "nl": "Geen onderbord aanwezig", - "de": "Kein zusätzliches Verkehrszeichen vorhanden" - } - } - ] - }, { "render": { "en": "The buffer besides this cycleway is {cycleway:buffer} m", diff --git a/langs/layers/de.json b/langs/layers/de.json index 701e086e3..3a27f2dd9 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -1613,14 +1613,6 @@ }, "question": "Welches Verkehrszeichen hat dieser Radweg?" }, - "cycleway-traffic-signs-D7-supplementary": { - "mappings": { - "6": { - "then": "Kein zusätzliches Verkehrszeichen vorhanden" - } - }, - "question": "Hat das Verkehrszeichen D7 () ein Zusatzzeichen?" - }, "cycleway-traffic-signs-supplementary": { "mappings": { "6": { diff --git a/langs/layers/en.json b/langs/layers/en.json index 40d20b5e3..b4d6b78b5 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -2680,16 +2680,26 @@ }, "question": "What traffic sign does this cycleway have?" }, - "cycleway-traffic-signs-D7-supplementary": { - "mappings": { - "6": { - "then": "No supplementary traffic sign present" - } - }, - "question": "Does the traffic sign D7 () have a supplementary sign?" - }, "cycleway-traffic-signs-supplementary": { "mappings": { + "0": { + "then": "Mopeds must use the cycleway" + }, + "1": { + "then": "Speedpedelecs must use the cycleway" + }, + "2": { + "then": "Mopeds and speedpedelecs must use the cycleway" + }, + "3": { + "then": "Mopeds are not allowed" + }, + "4": { + "then": "Speedpedelecs are not allowed" + }, + "5": { + "then": "Mopeds and speedpedelecs are not allowed" + }, "6": { "then": "No supplementary traffic sign present" } diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 3204cd289..4ec425d43 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -2696,42 +2696,16 @@ }, "question": "Welk verkeersbord heeft dit fietspad?" }, - "cycleway-traffic-signs-D7-supplementary": { - "mappings": { - "0": { - "then": "Bromfiets klasse B verplicht" - }, - "1": { - "then": "Speedpedelc (klasse P) verplicht" - }, - "2": { - "then": "Bromfiets klasse B en speedpedelec (klasse P) verplicht" - }, - "3": { - "then": "Bromfiets klasse B verboden" - }, - "4": { - "then": "Speedpedelec (bromfiets klasse P) verboden" - }, - "5": { - "then": "Bromfiets klasse B en speedpedelec (klasse P) verboden" - }, - "6": { - "then": "Geen onderbord aanwezig" - } - }, - "question": "Heeft het verkeersbord D7 () een onderbord?" - }, "cycleway-traffic-signs-supplementary": { "mappings": { "0": { - "then": "Bromfiets Klass B verplicht" + "then": "Bromfiets Klass B verplicht op het fietspad" }, "1": { - "then": "Speedpedelec (Bromfiets klasse P) verplicht" + "then": "Speedpedelec (Bromfiets klasse P) verplicht op het fietspad" }, "2": { - "then": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht" + "then": "Bromfiets klasse B en speedpedelec (Klasse P) verplicht op het fietspad" }, "3": { "then": "Bromfiets klasse B verboden" From 5ab2e8eabe8fdf3c731b160fb823a1c026b5f422 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 04:31:36 +0100 Subject: [PATCH 11/24] Extract images for hydrant.json --- assets/layers/hydrant/hydrant.json | 60 +++++++++++++++++++----------- langs/layers/de.json | 8 ++-- langs/layers/en.json | 8 ++-- langs/layers/fr.json | 8 ++-- langs/layers/id.json | 2 +- langs/layers/it.json | 8 ++-- langs/layers/ja.json | 8 ++-- langs/layers/ru.json | 2 +- 8 files changed, 60 insertions(+), 44 deletions(-) diff --git a/assets/layers/hydrant/hydrant.json b/assets/layers/hydrant/hydrant.json index ae47c2cc9..af931bc9b 100644 --- a/assets/layers/hydrant/hydrant.json +++ b/assets/layers/hydrant/hydrant.json @@ -157,11 +157,15 @@ ] }, "then": { - "en": " Pillar type.", - "ja": " ピラー型。", - "fr": " Pilier.", - "de": " Säulenart.", - "it": " Soprasuolo." + "en": "Pillar type.", + "ja": "ピラー型。", + "fr": "Pilier.", + "de": "Säulenart.", + "it": "Soprasuolo." + }, + "icon": { + "path": "./assets/themes/hailhydrant/hydrant_pillar.svg", + "class": "small" } }, { @@ -171,11 +175,15 @@ ] }, "then": { - "en": " Pipe type.", - "ja": " パイプ型。", - "fr": " Tuyau.", - "de": " Rohrtyp.", - "it": " Tubo." + "en": "Pipe type.", + "ja": "パイプ型。", + "fr": "Tuyau.", + "de": "Rohrtyp.", + "it": "Tubo." + }, + "icon": { + "path": "./assets/themes/hailhydrant/hydrant_unknown.svg", + "class": "small" } }, { @@ -185,13 +193,17 @@ ] }, "then": { - "en": " Wall type.", - "id": " Jenis dinding.", - "ru": " Тип стены.", - "ja": " 壁型。", - "fr": " Mural.", - "de": " Wandtyp.", - "it": " A muro." + "en": "Wall type.", + "id": "Jenis dinding.", + "ru": "Тип стены.", + "ja": "壁型。", + "fr": "Mural.", + "de": "Wandtyp.", + "it": "A muro." + }, + "icon": { + "path": "./assets/themes/hailhydrant/hydrant_unknown.svg", + "class": "small" } }, { @@ -201,11 +213,15 @@ ] }, "then": { - "en": " Underground type.", - "ja": "地下式。", - "fr": " Enterré.", - "de": " Untergrundtyp.", - "it": " Sottosuolo." + "en": "Underground type.", + "ja": "地下式。", + "fr": "Enterré.", + "de": "Untergrundtyp.", + "it": "Sottosuolo." + }, + "icon": { + "path": "./assets/themes/hailhydrant/hydrant_underground.svg", + "class": "small" } } ] diff --git a/langs/layers/de.json b/langs/layers/de.json index 3a27f2dd9..38e3accf2 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -2124,16 +2124,16 @@ "then": "Der Typ des Hydranten ist unbekannt." }, "1": { - "then": " Säulenart." + "then": "Säulenart." }, "2": { - "then": " Rohrtyp." + "then": "Rohrtyp." }, "3": { - "then": " Wandtyp." + "then": "Wandtyp." }, "4": { - "then": " Untergrundtyp." + "then": "Untergrundtyp." } }, "question": "Um welche Art von Hydrant handelt es sich?", diff --git a/langs/layers/en.json b/langs/layers/en.json index b4d6b78b5..1fbb0a54e 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -3486,16 +3486,16 @@ "then": "The hydrant type is unknown." }, "1": { - "then": " Pillar type." + "then": "Pillar type." }, "2": { - "then": " Pipe type." + "then": "Pipe type." }, "3": { - "then": " Wall type." + "then": "Wall type." }, "4": { - "then": " Underground type." + "then": "Underground type." } }, "question": "What type of hydrant is it?", diff --git a/langs/layers/fr.json b/langs/layers/fr.json index 79c03d20c..b4abbdfb9 100644 --- a/langs/layers/fr.json +++ b/langs/layers/fr.json @@ -1438,16 +1438,16 @@ "then": "La borne est de type inconnu." }, "1": { - "then": " Pilier." + "then": "Pilier." }, "2": { - "then": " Tuyau." + "then": "Tuyau." }, "3": { - "then": " Mural." + "then": "Mural." }, "4": { - "then": " Enterré." + "then": "Enterré." } }, "question": "De quel type de borne s’agit-il ?", diff --git a/langs/layers/id.json b/langs/layers/id.json index 408033c98..5c3035690 100644 --- a/langs/layers/id.json +++ b/langs/layers/id.json @@ -304,7 +304,7 @@ "hydrant-type": { "mappings": { "3": { - "then": " Jenis dinding." + "then": "Jenis dinding." } } } diff --git a/langs/layers/it.json b/langs/layers/it.json index 814431ad8..b17dc4871 100644 --- a/langs/layers/it.json +++ b/langs/layers/it.json @@ -1126,16 +1126,16 @@ "then": "Il tipo di idrante è sconosciuto." }, "1": { - "then": " Soprasuolo." + "then": "Soprasuolo." }, "2": { - "then": " Tubo." + "then": "Tubo." }, "3": { - "then": " A muro." + "then": "A muro." }, "4": { - "then": " Sottosuolo." + "then": "Sottosuolo." } }, "question": "Di che tipo è questo idrante?", diff --git a/langs/layers/ja.json b/langs/layers/ja.json index 743f4b2c8..a81b39656 100644 --- a/langs/layers/ja.json +++ b/langs/layers/ja.json @@ -276,16 +276,16 @@ "then": "消火栓の種類は不明です。" }, "1": { - "then": " ピラー型。" + "then": "ピラー型。" }, "2": { - "then": " パイプ型。" + "then": "パイプ型。" }, "3": { - "then": " 壁型。" + "then": "壁型。" }, "4": { - "then": "地下式。" + "then": "地下式。" } }, "question": "どんな消火栓なんですか?", diff --git a/langs/layers/ru.json b/langs/layers/ru.json index 90e13fc43..610d19480 100644 --- a/langs/layers/ru.json +++ b/langs/layers/ru.json @@ -957,7 +957,7 @@ "then": "Тип гидранта не определён." }, "3": { - "then": " Тип стены." + "then": "Тип стены." } }, "question": "К какому типу относится этот гидрант?", From 682b68a094c3d729472e86707f7412ca89939822 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 23:10:27 +0100 Subject: [PATCH 12/24] Regenerate schemas, more fixes to images and licenses --- Docs/Schemas/LayerConfigJson.schema.json | 33 +- Docs/Schemas/LayerConfigJsonJSC.ts | 33 +- Docs/Schemas/LayoutConfigJson.schema.json | 33 +- Docs/Schemas/LayoutConfigJsonJSC.ts | 33 +- .../LineRenderingConfigJson.schema.json | 23 +- Docs/Schemas/LineRenderingConfigJsonJSC.ts | 23 +- .../PointRenderingConfigJson.schema.json | 23 +- Docs/Schemas/PointRenderingConfigJsonJSC.ts | 23 +- .../TagRenderingConfigJson.schema.json | 23 +- Docs/Schemas/TagRenderingConfigJsonJSC.ts | 23 +- Docs/Schemas/TilesourceConfigJson.schema.json | 23 +- Docs/Schemas/TilesourceConfigJsonJSC.ts | 23 +- Models/ThemeConfig/Conversion/FixImages.ts | 24 +- Models/ThemeConfig/Conversion/PrepareLayer.ts | 16 +- Models/ThemeConfig/Conversion/PrepareTheme.ts | 4 + Models/ThemeConfig/Conversion/Validation.ts | 24 +- Models/ThemeConfig/LayoutConfig.ts | 2 +- Utils.ts | 16 +- .../bike_repair_station/license_info.json | 14 + .../charging_station/charging_station.json | 34 +- .../charging_station.protojson | 2 +- assets/layers/charging_station/csvToJson.ts | 2 +- assets/layoutconfigmeta.json | 749 ++++++++++++++++++ assets/tagrenderingconfigmeta.json | 38 + assets/themes/buurtnatuur/buurtnatuur.json | 9 +- assets/themes/campersite/campersite.json | 2 +- assets/themes/campersite/license_info.json | 20 +- ...ohnmobilstellplatz.jpg => social_image.jpg} | Bin assets/themes/cyclofix/cyclofix.json | 2 +- assets/themes/grb_import/grb.json | 8 +- langs/themes/icon.json | 21 + langs/themes/nl.json | 6 +- scripts/generateLayerOverview.ts | 7 +- test/LegacyThemeLoader.spec.ts | 100 ++- 34 files changed, 1298 insertions(+), 118 deletions(-) rename assets/themes/campersite/{Barßel_Wohnmobilstellplatz.jpg => social_image.jpg} (100%) create mode 100644 langs/themes/icon.json diff --git a/Docs/Schemas/LayerConfigJson.schema.json b/Docs/Schemas/LayerConfigJson.schema.json index 52f9f1e69..9e72ff1a3 100644 --- a/Docs/Schemas/LayerConfigJson.schema.json +++ b/Docs/Schemas/LayerConfigJson.schema.json @@ -426,6 +426,16 @@ "items": { "$ref": "#/definitions/default_2" } + }, + "syncSelection": { + "description": "If set, synchronizes wether or not this layer is selected.\n\nno: Do not sync at all, always revert to default\nlocal: keep selection on local storage\ntheme-only: sync via OSM, but this layer will only be toggled in this theme\nglobal: all layers with this ID will be synced accross all themes", + "enum": [ + "global", + "local", + "no", + "theme-only" + ], + "type": "string" } }, "required": [ @@ -606,7 +616,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/LayerConfigJsonJSC.ts b/Docs/Schemas/LayerConfigJsonJSC.ts index 35dc011ac..0348fcb91 100644 --- a/Docs/Schemas/LayerConfigJsonJSC.ts +++ b/Docs/Schemas/LayerConfigJsonJSC.ts @@ -426,6 +426,16 @@ export default { "items": { "$ref": "#/definitions/default_2" } + }, + "syncSelection": { + "description": "If set, synchronizes wether or not this layer is selected.\n\nno: Do not sync at all, always revert to default\nlocal: keep selection on local storage\ntheme-only: sync via OSM, but this layer will only be toggled in this theme\nglobal: all layers with this ID will be synced accross all themes", + "enum": [ + "global", + "local", + "no", + "theme-only" + ], + "type": "string" } }, "required": [ @@ -604,7 +614,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/LayoutConfigJson.schema.json b/Docs/Schemas/LayoutConfigJson.schema.json index dcfda9918..3321c1eed 100644 --- a/Docs/Schemas/LayoutConfigJson.schema.json +++ b/Docs/Schemas/LayoutConfigJson.schema.json @@ -460,7 +460,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", @@ -1314,6 +1335,16 @@ "items": { "$ref": "#/definitions/default_2" } + }, + "syncSelection": { + "description": "If set, synchronizes wether or not this layer is selected.\n\nno: Do not sync at all, always revert to default\nlocal: keep selection on local storage\ntheme-only: sync via OSM, but this layer will only be toggled in this theme\nglobal: all layers with this ID will be synced accross all themes", + "enum": [ + "global", + "local", + "no", + "theme-only" + ], + "type": "string" } }, "required": [ diff --git a/Docs/Schemas/LayoutConfigJsonJSC.ts b/Docs/Schemas/LayoutConfigJsonJSC.ts index 14f441f16..49ca6c05e 100644 --- a/Docs/Schemas/LayoutConfigJsonJSC.ts +++ b/Docs/Schemas/LayoutConfigJsonJSC.ts @@ -458,7 +458,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", @@ -1304,6 +1325,16 @@ export default { "items": { "$ref": "#/definitions/default_2" } + }, + "syncSelection": { + "description": "If set, synchronizes wether or not this layer is selected.\n\nno: Do not sync at all, always revert to default\nlocal: keep selection on local storage\ntheme-only: sync via OSM, but this layer will only be toggled in this theme\nglobal: all layers with this ID will be synced accross all themes", + "enum": [ + "global", + "local", + "no", + "theme-only" + ], + "type": "string" } }, "required": [ diff --git a/Docs/Schemas/LineRenderingConfigJson.schema.json b/Docs/Schemas/LineRenderingConfigJson.schema.json index a410d218d..278e857e4 100644 --- a/Docs/Schemas/LineRenderingConfigJson.schema.json +++ b/Docs/Schemas/LineRenderingConfigJson.schema.json @@ -260,7 +260,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/LineRenderingConfigJsonJSC.ts b/Docs/Schemas/LineRenderingConfigJsonJSC.ts index 918f1b4c8..f4a2e76d3 100644 --- a/Docs/Schemas/LineRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/LineRenderingConfigJsonJSC.ts @@ -258,7 +258,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/PointRenderingConfigJson.schema.json b/Docs/Schemas/PointRenderingConfigJson.schema.json index 5f14ee615..715988459 100644 --- a/Docs/Schemas/PointRenderingConfigJson.schema.json +++ b/Docs/Schemas/PointRenderingConfigJson.schema.json @@ -264,7 +264,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/PointRenderingConfigJsonJSC.ts b/Docs/Schemas/PointRenderingConfigJsonJSC.ts index 30827308f..1f37ef54a 100644 --- a/Docs/Schemas/PointRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/PointRenderingConfigJsonJSC.ts @@ -262,7 +262,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/TagRenderingConfigJson.schema.json b/Docs/Schemas/TagRenderingConfigJson.schema.json index 9b74df032..1c595208d 100644 --- a/Docs/Schemas/TagRenderingConfigJson.schema.json +++ b/Docs/Schemas/TagRenderingConfigJson.schema.json @@ -100,7 +100,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/TagRenderingConfigJsonJSC.ts b/Docs/Schemas/TagRenderingConfigJsonJSC.ts index 2bc849c6e..172740e9c 100644 --- a/Docs/Schemas/TagRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/TagRenderingConfigJsonJSC.ts @@ -100,7 +100,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/TilesourceConfigJson.schema.json b/Docs/Schemas/TilesourceConfigJson.schema.json index cef3d5386..a7ae626b5 100644 --- a/Docs/Schemas/TilesourceConfigJson.schema.json +++ b/Docs/Schemas/TilesourceConfigJson.schema.json @@ -208,7 +208,28 @@ }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Docs/Schemas/TilesourceConfigJsonJSC.ts b/Docs/Schemas/TilesourceConfigJsonJSC.ts index 15178b758..21d48703c 100644 --- a/Docs/Schemas/TilesourceConfigJsonJSC.ts +++ b/Docs/Schemas/TilesourceConfigJsonJSC.ts @@ -206,7 +206,28 @@ export default { }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", - "type": "string" + "anyOf": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] }, "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}", diff --git a/Models/ThemeConfig/Conversion/FixImages.ts b/Models/ThemeConfig/Conversion/FixImages.ts index ef315fd95..ebeb0223d 100644 --- a/Models/ThemeConfig/Conversion/FixImages.ts +++ b/Models/ThemeConfig/Conversion/FixImages.ts @@ -6,9 +6,11 @@ import * as tagrenderingmetapaths from "../../../assets/tagrenderingconfigmeta.j export class ExtractImages extends Conversion { private _isOfficial: boolean; - constructor(isOfficial: boolean) { + private _sharedTagRenderings: Map; + constructor(isOfficial: boolean, sharedTagRenderings: Map) { super("Extract all images from a layoutConfig using the meta paths",[],"ExctractImages"); this._isOfficial = isOfficial; + this._sharedTagRenderings = sharedTagRenderings; } convert(json: LayoutConfigJson, context: string): { result: string[], errors: string[], warnings: string[] } { @@ -29,8 +31,19 @@ export class ExtractImages extends Conversion { const found = Utils.CollectPath(metapath.path, json) if (mightBeTr) { // We might have tagRenderingConfigs containing icons here - for (const foundImage of found) { + for (const {path, leaf} of found) { + const foundImage = leaf; if (typeof foundImage === "string") { + + if(foundImage == ""){ + errors.push(context+"."+path.join(".")+" Found an empty image") + } + + if(this._sharedTagRenderings?.has(foundImage)){ + // This is not an image, but a shared tag rendering + continue + } + allFoundImages.push(foundImage) } else{ // This is a tagRendering where every rendered value might be an icon! @@ -45,6 +58,11 @@ export class ExtractImages extends Conversion { } } allFoundImages.push(...fromPath.filter(i => typeof i === "string")) + for (const pathAndImg of fromPath) { + if(pathAndImg.leaf === "" || pathAndImg.leaf["path"] == ""){ + errors.push(context+[...path,...pathAndImg.path].join(".")+": Found an empty image at ") + } + } } } @@ -108,7 +126,7 @@ export class FixImages extends DesugaringStep { continue } const mightBeTr = Array.isArray(metapath.type) && metapath.type.some(t => t["$ref"] == "#/definitions/TagRenderingConfigJson") - Utils.WalkPath(metapath.path, json, leaf => { + Utils.WalkPath(metapath.path, json, (leaf, path) => { if (typeof leaf === "string") { return replaceString(leaf) } diff --git a/Models/ThemeConfig/Conversion/PrepareLayer.ts b/Models/ThemeConfig/Conversion/PrepareLayer.ts index 70b9815d7..88fc0276e 100644 --- a/Models/ThemeConfig/Conversion/PrepareLayer.ts +++ b/Models/ThemeConfig/Conversion/PrepareLayer.ts @@ -75,14 +75,14 @@ class ExpandTagRendering extends Conversion { new PreparePersonalTheme(state), new OnEveryConcat("layers", new SubstituteLayer(state)), new SetDefault("socialImage", "assets/SocialImage.png", true), + // We expand all tagrenderings first... new OnEvery("layers", new PrepareLayer(state)), + // Then we apply the override all new ApplyOverrideAll(), + // And then we prepare all the layers _again_ in case that an override all contained unexpanded tagrenderings! + new OnEvery("layers", new PrepareLayer(state)), new AddDefaultLayers(state), new AddDependencyLayersToTheme(state), new AddImportLayers(), diff --git a/Models/ThemeConfig/Conversion/Validation.ts b/Models/ThemeConfig/Conversion/Validation.ts index 2e87d706c..571cc7d3a 100644 --- a/Models/ThemeConfig/Conversion/Validation.ts +++ b/Models/ThemeConfig/Conversion/Validation.ts @@ -12,6 +12,7 @@ import {ExtractImages} from "./FixImages"; import ScriptUtils from "../../../scripts/ScriptUtils"; import {And} from "../../../Logic/Tags/And"; import Translations from "../../../UI/i18n/Translations"; +import Svg from "../../../Svg"; class ValidateLanguageCompleteness extends DesugaringStep { @@ -50,12 +51,14 @@ class ValidateTheme extends DesugaringStep { private readonly _path?: string; private readonly knownImagePaths: Set; private readonly _isBuiltin: boolean; + private _sharedTagRenderings: Map; - constructor(knownImagePaths: Set, path: string, isBuiltin: boolean) { + constructor(knownImagePaths: Set, path: string, isBuiltin: boolean, sharedTagRenderings: Map) { super("Doesn't change anything, but emits warnings and errors", [], "ValidateTheme"); this.knownImagePaths = knownImagePaths; this._path = path; this._isBuiltin = isBuiltin; + this._sharedTagRenderings = sharedTagRenderings; } convert(json: LayoutConfigJson, context: string): { result: LayoutConfigJson; errors: string[], warnings: string[], information: string[] } { @@ -78,7 +81,7 @@ class ValidateTheme extends DesugaringStep { } { // Check images: are they local, are the licenses there, is the theme icon square, ... - const images = new ExtractImages(this._isBuiltin).convertStrict(json, "validation") + const images = new ExtractImages(this._isBuiltin, this._sharedTagRenderings).convertStrict(json, "validation") const remoteImages = images.filter(img => img.indexOf("http") == 0) for (const remoteImage of remoteImages) { errors.push("Found a remote image: " + remoteImage + " in theme " + json.id + ", please download it.") @@ -93,8 +96,11 @@ class ValidateTheme extends DesugaringStep { continue } if (image.match(/[a-z]*/)) { - // This is a builtin img, e.g. 'checkmark' or 'crosshair' - continue; + + if(Svg.All[image + ".svg"] !== undefined){ + // This is a builtin img, e.g. 'checkmark' or 'crosshair' + continue; + } } if (this.knownImagePaths !== undefined && !this.knownImagePaths.has(image)) { @@ -163,10 +169,10 @@ class ValidateTheme extends DesugaringStep { } export class ValidateThemeAndLayers extends Fuse { - constructor(knownImagePaths: Set, path: string, isBuiltin: boolean) { + constructor(knownImagePaths: Set, path: string, isBuiltin: boolean, sharedTagRenderings: Map) { super("Validates a theme and the contained layers", - new ValidateTheme(knownImagePaths, path, isBuiltin), - new OnEvery("layers", new ValidateLayer(knownImagePaths, undefined, false)) + new ValidateTheme(knownImagePaths, path, isBuiltin, sharedTagRenderings), + new OnEvery("layers", new ValidateLayer(undefined, false)) ); } } @@ -302,12 +308,10 @@ export class ValidateLayer extends DesugaringStep { * @private */ private readonly _path?: string; - private readonly knownImagePaths?: Set; private readonly _isBuiltin: boolean; - constructor(knownImagePaths: Set, path: string, isBuiltin: boolean) { + constructor(path: string, isBuiltin: boolean) { super("Doesn't change anything, but emits warnings and errors", [], "ValidateLayer"); - this.knownImagePaths = knownImagePaths; this._path = path; this._isBuiltin = isBuiltin; } diff --git a/Models/ThemeConfig/LayoutConfig.ts b/Models/ThemeConfig/LayoutConfig.ts index 1875b8d99..eb22b8443 100644 --- a/Models/ThemeConfig/LayoutConfig.ts +++ b/Models/ThemeConfig/LayoutConfig.ts @@ -71,7 +71,7 @@ export default class LayoutConfig { this.credits = json.credits; this.version = json.version; this.language = json.mustHaveLanguage ?? Array.from(Object.keys(json.title)); - this.usedImages = Array.from(new ExtractImages(official).convertStrict(json, "while extracting the images of " + json.id + " " + context ?? "")).sort() + this.usedImages = Array.from(new ExtractImages(official, undefined).convertStrict(json, "while extracting the images of " + json.id + " " + context ?? "")).sort() { if (typeof json.title === "string") { throw `The title of a theme should always be a translation, as it sets the corresponding languages (${context}.title). The themenID is ${this.id}; the offending object is ${JSON.stringify(json.title)} which is a ${typeof json.title})` diff --git a/Utils.ts b/Utils.ts index cdf0cb26b..9132347f4 100644 --- a/Utils.ts +++ b/Utils.ts @@ -358,16 +358,16 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be * * The leaf objects are replaced by the function */ - public static WalkPath(path: string[], object: any, replaceLeaf: ((leaf: any) => any)) { + public static WalkPath(path: string[], object: any, replaceLeaf: ((leaf: any, travelledPath: string[]) => any), travelledPath: string[] = []) { const head = path[0] if (path.length === 1) { // We have reached the leaf const leaf = object[head]; if (leaf !== undefined) { if(Array.isArray(leaf)){ - object[head] = leaf.map(replaceLeaf) + object[head] = leaf.map(o => replaceLeaf(o, travelledPath)) }else{ - object[head] = replaceLeaf(leaf) + object[head] = replaceLeaf(leaf, travelledPath) } } return @@ -381,10 +381,10 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be return; } if (Array.isArray(sub)) { - sub.forEach(el => Utils.WalkPath(path.slice(1), el, replaceLeaf)) + sub.forEach((el, i) => Utils.WalkPath(path.slice(1), el, replaceLeaf, [...travelledPath, head, ""+i])) return; } - Utils.WalkPath(path.slice(1), sub, replaceLeaf) + Utils.WalkPath(path.slice(1), sub, replaceLeaf, [...travelledPath,head]) } /** @@ -393,7 +393,7 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be * * The leaf objects are collected in the list */ - public static CollectPath(path: string[], object: any, collectedList = []): any[] { + public static CollectPath(path: string[], object: any, collectedList: {leaf: any, path: string[]}[] = [], travelledPath: string[] = []): {leaf: any, path: string[]}[] { if (object === undefined || object === null) { return collectedList; } @@ -417,13 +417,13 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be } if (Array.isArray(sub)) { - sub.forEach(el => Utils.CollectPath(path.slice(1), el, collectedList)) + sub.forEach((el, i) => Utils.CollectPath(path.slice(1), el, collectedList, [...travelledPath,head,""+i])) return collectedList; } if (typeof sub !== "object") { return collectedList; } - return Utils.CollectPath(path.slice(1), sub, collectedList) + return Utils.CollectPath(path.slice(1), sub, collectedList,[...travelledPath, head]) } /** diff --git a/assets/layers/bike_repair_station/license_info.json b/assets/layers/bike_repair_station/license_info.json index 4ad68baaf..fb56c0978 100644 --- a/assets/layers/bike_repair_station/license_info.json +++ b/assets/layers/bike_repair_station/license_info.json @@ -84,6 +84,20 @@ "https://osoc.be/editions/2020/cyclofix" ] }, + { + "path": "repair_station_broken_pump.svg", + "license": "CC-BY-SA", + "authors": [ + "Pieter Fiers", + "Thibault Declercq", + "Pierre Barban", + "Joost Schouppe", + "Pieter Vander Vennet" + ], + "sources": [ + "https://osoc.be/editions/2020/cyclofix" + ] + }, { "path": "repair_station_example.jpg", "license": "CC-BY-SA 4.0", diff --git a/assets/layers/charging_station/charging_station.json b/assets/layers/charging_station/charging_station.json index 38926d2d9..e7c89c5d2 100644 --- a/assets/layers/charging_station/charging_station.json +++ b/assets/layers/charging_station/charging_station.json @@ -241,7 +241,7 @@ }, "hideInAnswer": true, "icon": { - "path": "CEE7_4F.svg", + "path": "./assets/layers/charging_station/CEE7_4F.svg", "class": "medium" } }, @@ -270,7 +270,7 @@ }, "hideInAnswer": true, "icon": { - "path": "TypeE.svg", + "path": "./assets/layers/charging_station/TypeE.svg", "class": "medium" } }, @@ -325,7 +325,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Chademo_type4.svg", + "path": "./assets/layers/charging_station/Chademo_type4.svg", "class": "medium" } }, @@ -380,7 +380,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type1_J1772.svg", + "path": "./assets/layers/charging_station/Type1_J1772.svg", "class": "medium" } }, @@ -435,7 +435,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type1_J1772.svg", + "path": "./assets/layers/charging_station/Type1_J1772.svg", "class": "medium" } }, @@ -490,7 +490,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type1-ccs.svg", + "path": "./assets/layers/charging_station/Type1-ccs.svg", "class": "medium" } }, @@ -545,7 +545,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Tesla-hpwc-model-s.svg", + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", "class": "medium" } }, @@ -600,7 +600,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type2_socket.svg", + "path": "./assets/layers/charging_station/Type2_socket.svg", "class": "medium" } }, @@ -655,7 +655,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type2_CCS.svg", + "path": "./assets/layers/charging_station/Type2_CCS.svg", "class": "medium" } }, @@ -710,7 +710,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type2_tethered.svg", + "path": "./assets/layers/charging_station/Type2_tethered.svg", "class": "medium" } }, @@ -765,7 +765,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type2_CCS.svg", + "path": "./assets/layers/charging_station/Type2_CCS.svg", "class": "medium" } }, @@ -826,7 +826,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Tesla-hpwc-model-s.svg", + "path": "./assets/layers/charging_station/Tesla-hpwc-model-s.svg", "class": "medium" } }, @@ -887,7 +887,7 @@ }, "hideInAnswer": true, "icon": { - "path": "Type2_tethered.svg", + "path": "./assets/layers/charging_station/Type2_tethered.svg", "class": "medium" } }, @@ -916,7 +916,7 @@ }, "hideInAnswer": true, "icon": { - "path": "usb_port.svg", + "path": "./assets/layers/charging_station/usb_port.svg", "class": "medium" } }, @@ -967,7 +967,7 @@ }, "hideInAnswer": true, "icon": { - "path": "bosch-3pin.svg", + "path": "./assets/layers/charging_station/bosch-3pin.svg", "class": "medium" } }, @@ -1018,7 +1018,7 @@ }, "hideInAnswer": true, "icon": { - "path": "bosch-5pin.svg", + "path": "./assets/layers/charging_station/bosch-5pin.svg", "class": "medium" } } @@ -3953,7 +3953,7 @@ "operational_status=broken" ] }, - "then": "cross:#c22;" + "then": "close:#c22;" }, { "if": { diff --git a/assets/layers/charging_station/charging_station.protojson b/assets/layers/charging_station/charging_station.protojson index 72fb64d1d..35a2fc40a 100644 --- a/assets/layers/charging_station/charging_station.protojson +++ b/assets/layers/charging_station/charging_station.protojson @@ -764,7 +764,7 @@ "operational_status=broken" ] }, - "then": "cross:#c22;" + "then": "close:#c22;" }, { "if": { diff --git a/assets/layers/charging_station/csvToJson.ts b/assets/layers/charging_station/csvToJson.ts index e138243f7..ea1d55ac9 100644 --- a/assets/layers/charging_station/csvToJson.ts +++ b/assets/layers/charging_station/csvToJson.ts @@ -131,7 +131,7 @@ function run(file, protojson) { then: txt, hideInAnswer: true, icon:{ - path: e.image, + path: `./assets/layers/charging_station/${e.image}`, class:"medium" } } diff --git a/assets/layoutconfigmeta.json b/assets/layoutconfigmeta.json index 40abedbc8..c596f78b9 100644 --- a/assets/layoutconfigmeta.json +++ b/assets/layoutconfigmeta.json @@ -485,6 +485,48 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "isShown", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "isShown", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -753,6 +795,48 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "title", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "title", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -1014,6 +1098,48 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "titleIcons", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "titleIcons", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -1291,6 +1417,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "icon", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "icon", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -1585,6 +1755,52 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "iconBadges", + "then", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "iconBadges", + "then", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -1852,6 +2068,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "iconSize", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "iconSize", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -2116,6 +2376,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "rotation", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "rotation", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -2380,6 +2684,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "label", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "label", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -2651,6 +2999,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "color", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "color", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -2918,6 +3310,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "width", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "width", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -3182,6 +3618,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "dashArray", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "dashArray", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -3446,6 +3926,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "lineCap", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "lineCap", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -3714,6 +4238,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "fill", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "fill", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -3978,6 +4546,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "fillColor", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "fillColor", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -4242,6 +4854,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "mapRendering", + "offset", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "mapRendering", + "offset", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -4625,6 +5281,48 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "tagRenderings", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "tagRenderings", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -4871,6 +5569,50 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "layers", + "tagRenderings", + "renderings", + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "layers", + "tagRenderings", + "renderings", + "mappings", + "icon", + "class" + ], "type": "string" }, { @@ -5160,6 +5902,13 @@ ], "type": "boolean" }, + { + "path": [ + "layers", + "syncSelection" + ], + "type": "string" + }, { "path": [ "layers", diff --git a/assets/tagrenderingconfigmeta.json b/assets/tagrenderingconfigmeta.json index fd9483b82..6f7b349c1 100644 --- a/assets/tagrenderingconfigmeta.json +++ b/assets/tagrenderingconfigmeta.json @@ -138,6 +138,44 @@ "icon" ], "typeHint": "icon", + "type": [ + { + "type": "object", + "properties": { + "path": { + "description": "The path to the icon\nType: icon", + "type": "string" + }, + "class": { + "description": "A hint to mapcomplete on how to render this icon within the mapping.\nThis is translated to 'mapping-icon-', so defining your own in combination with a custom CSS is possible (but discouraged)", + "type": "string" + } + }, + "required": [ + "class", + "path" + ] + }, + { + "type": "string" + } + ] + }, + { + "path": [ + "mappings", + "icon", + "path" + ], + "typeHint": "icon", + "type": "string" + }, + { + "path": [ + "mappings", + "icon", + "class" + ], "type": "string" }, { diff --git a/assets/themes/buurtnatuur/buurtnatuur.json b/assets/themes/buurtnatuur/buurtnatuur.json index 1ef2e4f1d..991654c46 100644 --- a/assets/themes/buurtnatuur/buurtnatuur.json +++ b/assets/themes/buurtnatuur/buurtnatuur.json @@ -504,7 +504,8 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door Natuurpunt" + "nl": "Dit gebied wordt beheerd door Natuurpunt", + "icon": "./assets/themes/buurtnatuur/Natuurpunt.jpg" } }, { @@ -514,7 +515,8 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door {operator}" + "nl": "Dit gebied wordt beheerd door {operator}", + "icon": "./assets/themes/buurtnatuur/Natuurpunt.jpg" }, "hideInAnswer": true }, @@ -525,7 +527,8 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door het Agentschap Natuur en Bos" + "nl": "Dit gebied wordt beheerd door het Agentschap Natuur en Bos", + "icon": "./assets/themes/buurtnatuur/ANB.jpg" } }, { diff --git a/assets/themes/campersite/campersite.json b/assets/themes/campersite/campersite.json index 59acbe7c6..bc792011e 100644 --- a/assets/themes/campersite/campersite.json +++ b/assets/themes/campersite/campersite.json @@ -42,7 +42,7 @@ "startLon": 3.14, "startZoom": 14, "widenFactor": 1.5, - "socialImage": "./assets/themes/campersite/Bar%C3%9Fel_Wohnmobilstellplatz.jpg", + "socialImage": "./assets/themes/campersite/social_image.jpg", "layers": [ { "id": "caravansites", diff --git a/assets/themes/campersite/license_info.json b/assets/themes/campersite/license_info.json index 6e12c74c2..d1b076033 100644 --- a/assets/themes/campersite/license_info.json +++ b/assets/themes/campersite/license_info.json @@ -1,14 +1,4 @@ [ - { - "path": "Barßel_Wohnmobilstellplatz.jpg", - "license": "CC-BY-SA 3.0", - "authors": [ - "ES01" - ], - "sources": [ - "https://commons.wikimedia.org/wiki/File:Bar%C3%9Fel_Wohnmobilstellplatz.jpg" - ] - }, { "path": "caravan.svg", "license": "CC0", @@ -41,5 +31,15 @@ "https://github.com/osmandapp/Osmand/blob/master/LICENSE", "https://github.com/osmandapp/OsmAnd-resources/blob/16892d8b2fc00dd422abfb2fef967d5ccd05eeac/icons/svg/poi/sanitary_dump_station.svg" ] + }, + { + "path": "social_image.jpg", + "license": "CC-BY-SA 3.0", + "authors": [ + "ES01" + ], + "sources": [ + "https://commons.wikimedia.org/wiki/File:Bar%C3%9Fel_Wohnmobilstellplatz.jpg" + ] } ] \ No newline at end of file diff --git a/assets/themes/campersite/Barßel_Wohnmobilstellplatz.jpg b/assets/themes/campersite/social_image.jpg similarity index 100% rename from assets/themes/campersite/Barßel_Wohnmobilstellplatz.jpg rename to assets/themes/campersite/social_image.jpg diff --git a/assets/themes/cyclofix/cyclofix.json b/assets/themes/cyclofix/cyclofix.json index 99ec5635b..82a94047f 100644 --- a/assets/themes/cyclofix/cyclofix.json +++ b/assets/themes/cyclofix/cyclofix.json @@ -33,7 +33,7 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "assets/themes/cyclofix/logo.svg", + "socialImage": "./assets/themes/cyclofix/logo.svg", "layers": [ "bike_cafe", "bike_shop", diff --git a/assets/themes/grb_import/grb.json b/assets/themes/grb_import/grb.json index c184f8594..28b9c62a4 100644 --- a/assets/themes/grb_import/grb.json +++ b/assets/themes/grb_import/grb.json @@ -11,14 +11,13 @@ "en": "This theme is an attempt to help automating the GRB import.", "hu": "Ez a sablon a flandriai GRB épületimportálás automatizlását kívánja megkönnyíteni." }, - "maintainer": "", + "maintainer": "Pieter Vander Vennet", "icon": "./assets/themes/grb_import/logo.svg", "version": "0", "startLat": 51.0249, "startLon": 4.026489, "startZoom": 9, "widenFactor": 2, - "socialImage": "", "clustering": { "maxZoom": 15 }, @@ -605,15 +604,14 @@ }, "iconSize": "50,50,center", "icon": { - "render": "./assets/themes/grb_import/housenumber_blank.svg", "mappings": [ { "if": "_intersects_with_other_features~*", "then": "./assets/themes/grb_import/warning.svg" }, { - "if": "addr:housenumber=", - "then": "" + "if": "addr:housenumber~*", + "then": "./assets/themes/grb_import/housenumber_blank.svg" } ] }, diff --git a/langs/themes/icon.json b/langs/themes/icon.json new file mode 100644 index 000000000..9544aaac9 --- /dev/null +++ b/langs/themes/icon.json @@ -0,0 +1,21 @@ +{ + "buurtnatuur": { + "overrideAll": { + "tagRenderings+": { + "1": { + "mappings": { + "1": { + "then": "./assets/themes/buurtnatuur/Natuurpunt.jpg" + }, + "2": { + "then": "./assets/themes/buurtnatuur/Natuurpunt.jpg" + }, + "3": { + "then": "./assets/themes/buurtnatuur/ANB.jpg" + } + } + } + } + } + } +} \ No newline at end of file diff --git a/langs/themes/nl.json b/langs/themes/nl.json index 4e77e8d09..660702e1a 100644 --- a/langs/themes/nl.json +++ b/langs/themes/nl.json @@ -134,13 +134,13 @@ "1": { "mappings": { "1": { - "then": "Dit gebied wordt beheerd door Natuurpunt" + "then": "Dit gebied wordt beheerd door Natuurpunt" }, "2": { - "then": "Dit gebied wordt beheerd door {operator}" + "then": "Dit gebied wordt beheerd door {operator}" }, "3": { - "then": "Dit gebied wordt beheerd door het Agentschap Natuur en Bos" + "then": "Dit gebied wordt beheerd door het Agentschap Natuur en Bos" } }, "question": "Wie beheert dit gebied?", diff --git a/scripts/generateLayerOverview.ts b/scripts/generateLayerOverview.ts index 4ee9aa129..a14a88623 100644 --- a/scripts/generateLayerOverview.ts +++ b/scripts/generateLayerOverview.ts @@ -169,7 +169,7 @@ class LayerOverviewUtils { for (const sharedLayerJson of layerFiles) { const context = "While building builtin layer " + sharedLayerJson.path const fixed = prepLayer.convertStrict(sharedLayerJson.parsed, context) - const validator = new ValidateLayer(knownImagePaths, sharedLayerJson.path, true); + const validator = new ValidateLayer(sharedLayerJson.path, true); validator.convertStrict(fixed, context) if (sharedLayers.has(fixed.id)) { @@ -200,7 +200,10 @@ class LayerOverviewUtils { new PrevalidateTheme().convertStrict(themeFile, themePath) themeFile = new PrepareTheme(convertState).convertStrict(themeFile, themePath) - new ValidateThemeAndLayers(knownImagePaths, themePath, true) + if(knownImagePaths === undefined){ + throw "Could not load known images/licenses" + } + new ValidateThemeAndLayers(knownImagePaths, themePath, true, convertState.tagRenderings) .convertStrict(themeFile, themePath) this.writeTheme(themeFile) diff --git a/test/LegacyThemeLoader.spec.ts b/test/LegacyThemeLoader.spec.ts index 83284c5be..85a3d5b17 100644 --- a/test/LegacyThemeLoader.spec.ts +++ b/test/LegacyThemeLoader.spec.ts @@ -5,7 +5,7 @@ import {TagRenderingConfigJson} from "../Models/ThemeConfig/Json/TagRenderingCon import {AddMiniMap} from "../Models/ThemeConfig/Conversion/PrepareTheme"; import {DetectMappingsWithImages, DetectShadowedMappings} from "../Models/ThemeConfig/Conversion/Validation"; import * as Assert from "assert"; -import {FixImages} from "../Models/ThemeConfig/Conversion/FixImages"; +import {ExtractImages, FixImages} from "../Models/ThemeConfig/Conversion/FixImages"; export default class LegacyThemeLoaderSpec extends T { @@ -144,7 +144,7 @@ export default class LegacyThemeLoaderSpec extends T { ] } - private static readonly verkeerde_borden ={ + private static readonly verkeerde_borden = { "id": "https://raw.githubusercontent.com/seppesantens/MapComplete-Themes/main/VerkeerdeBordenDatabank/VerkeerdeBordenDatabank.json", "title": { "nl": "VerkeerdeBordenDatabank", @@ -242,7 +242,7 @@ export default class LegacyThemeLoaderSpec extends T { "icon": "./TS_bolt.svg", iconBadges: [{ if: "id=yes", - then:{ + then: { mappings: [ { if: "id=yes", @@ -351,7 +351,6 @@ export default class LegacyThemeLoaderSpec extends T { } - constructor() { super([ ["Walking_node_theme", () => { @@ -423,9 +422,9 @@ export default class LegacyThemeLoaderSpec extends T { } ] }, "test"); - T.isTrue(r.errors.length > 0, "Failing case 0 is not detected") + T.isTrue(r.errors.length > 0, "Failing case 0 is not detected") - const r0 = new DetectShadowedMappings().convert( { + const r0 = new DetectShadowedMappings().convert({ mappings: [ { if: {or: ["key=value", "x=y"]}, @@ -440,34 +439,71 @@ export default class LegacyThemeLoaderSpec extends T { T.isTrue(r0.errors.length > 0, "Failing case 1 is not detected") } ], - ["Images are rewritten", () => { - const fixed = new FixImages(new Set()).convertStrict(LegacyThemeLoaderSpec.verkeerde_borden, "test") - const fixedValue = fixed.layers[0]["mapRendering"][0].icon - Assert.equal("https://raw.githubusercontent.com/seppesantens/MapComplete-Themes/main/VerkeerdeBordenDatabank/TS_bolt.svg", - fixedValue) + ["Images are rewritten", () => { + const fixed = new FixImages(new Set()).convertStrict(LegacyThemeLoaderSpec.verkeerde_borden, "test") + const fixedValue = fixed.layers[0]["mapRendering"][0].icon + Assert.equal("https://raw.githubusercontent.com/seppesantens/MapComplete-Themes/main/VerkeerdeBordenDatabank/TS_bolt.svg", + fixedValue) - const fixedMapping = fixed.layers[0]["mapRendering"][0].iconBadges[0].then.mappings[0].then - Assert.equal("https://raw.githubusercontent.com/seppesantens/MapComplete-Themes/main/VerkeerdeBordenDatabank/Something.svg", - fixedMapping) - } ], - ["Images in 'thens' are detected", () => { - const r = new DetectMappingsWithImages().convert({ + const fixedMapping = fixed.layers[0]["mapRendering"][0].iconBadges[0].then.mappings[0].then + Assert.equal("https://raw.githubusercontent.com/seppesantens/MapComplete-Themes/main/VerkeerdeBordenDatabank/Something.svg", + fixedMapping) + }], + ["Images in 'thens' are detected", () => { + const r = new DetectMappingsWithImages().convert({ "mappings": [ - { - "if": "bicycle_parking=stands", - "then": { - "en": "Staple racks ", - "nl": "Nietjes ", - "fr": "Arceaux ", - "gl": "De roda (Stands) ", - "de": "Fahrradbügel ", - "hu": "Korlát ", - "it": "Archetti ", - "zh_Hant": "單車架 " - } - }]}, "test"); - T.isTrue(r.warnings.length > 0, "No images found"); - }] + { + "if": "bicycle_parking=stands", + "then": { + "en": "Staple racks ", + "nl": "Nietjes ", + "fr": "Arceaux ", + "gl": "De roda (Stands) ", + "de": "Fahrradbügel ", + "hu": "Korlát ", + "it": "Archetti ", + "zh_Hant": "單車架 " + } + }] + }, "test"); + T.isTrue(r.warnings.length > 0, "No images found"); + T.isTrue(r.warnings.some(msg => msg.indexOf("./assets/layers/bike_parking/staple.svg") >= 0), "staple.svg not mentioned"); + }], + ["Images in 'thens' icons are detected", () => { + const r = new ExtractImages(true).convert({ + "layers": [ + { + tagRenderings: [ + { + "mappings": [ + { + "if": "bicycle_parking=stands", + "then": { + "en": "Staple racks", + }, + "icon": { + path: "./assets/layers/bike_parking/staple.svg", + class: "small" + } + }, + { + "if": "bicycle_parking=stands", + "then": { + "en": "Bollard", + }, + "icon": "./assets/layers/bike_parking/bollard.svg", + } + ] + } + ] + } + ] + }, "test"); + const images = r.result + T.isTrue(images.length > 0, "No images found"); + T.isTrue(images.findIndex(img => img =="./assets/layers/bike_parking/staple.svg") >= 0, "staple.svg not mentioned"); + T.isTrue(images.findIndex(img => img == "./assets/layers/bike_parking/bollard.svg") >= 0, "bollard.svg not mentioned"); + }] ] ); } From d9d6e96fed90026aa40eef61c008226c6ffc1eed Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 18 Feb 2022 23:12:46 +0100 Subject: [PATCH 13/24] Extract images from crossings.json --- assets/layers/crossings/crossings.json | 24 ++++++++++++++++-------- langs/layers/de.json | 4 ++-- langs/layers/en.json | 4 ++-- langs/layers/nl.json | 4 ++-- 4 files changed, 22 insertions(+), 14 deletions(-) diff --git a/assets/layers/crossings/crossings.json b/assets/layers/crossings/crossings.json index 2c1fb4b6a..dd6a4f7b5 100644 --- a/assets/layers/crossings/crossings.json +++ b/assets/layers/crossings/crossings.json @@ -306,11 +306,15 @@ { "if": "red_turn:right:bicycle=yes", "then": { - "en": "A cyclist can turn right if the light is red ", - "nl": "Een fietser mag wel rechtsaf slaan als het licht rood is ", - "de": "Ein Radfahrer kann bei roter Ampel rechts abbiegen " + "en": "A cyclist can turn right if the light is red", + "nl": "Een fietser mag wel rechtsaf slaan als het licht rood is", + "de": "Ein Radfahrer kann bei roter Ampel rechts abbiegen" }, - "hideInAnswer": "_country!=be" + "hideInAnswer": "_country!=be", + "icon": { + "path": "./assets/layers/crossings/Belgian_road_sign_B22.svg", + "class": "medium" + } }, { "if": "red_turn:right:bicycle=yes", @@ -343,11 +347,15 @@ { "if": "red_turn:straight:bicycle=yes", "then": { - "en": "A cyclist can go straight on if the light is red ", - "nl": "Een fietser mag wel rechtdoor gaan als het licht rood is ", - "de": "Ein Radfahrer kann bei roter Ampel geradeaus fahren " + "en": "A cyclist can go straight on if the light is red", + "nl": "Een fietser mag wel rechtdoor gaan als het licht rood is", + "de": "Ein Radfahrer kann bei roter Ampel geradeaus fahren" }, - "hideInAnswer": "_country!=be" + "hideInAnswer": "_country!=be", + "icon": { + "path": "./assets/layers/crossings/Belgian_road_sign_B23.svg", + "class": "medium" + } }, { "if": "red_turn:straight:bicycle=yes", diff --git a/langs/layers/de.json b/langs/layers/de.json index 38e3accf2..e3182578f 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -1242,7 +1242,7 @@ "crossing-continue-through-red": { "mappings": { "0": { - "then": "Ein Radfahrer kann bei roter Ampel geradeaus fahren " + "then": "Ein Radfahrer kann bei roter Ampel geradeaus fahren" }, "1": { "then": "Ein Radfahrer kann bei roter Ampel geradeaus fahren" @@ -1278,7 +1278,7 @@ "crossing-right-turn-through-red": { "mappings": { "0": { - "then": "Ein Radfahrer kann bei roter Ampel rechts abbiegen " + "then": "Ein Radfahrer kann bei roter Ampel rechts abbiegen" }, "1": { "then": "Ein Radfahrer kann bei roter Ampel rechts abbiegen" diff --git a/langs/layers/en.json b/langs/layers/en.json index 1fbb0a54e..e7b8d1d14 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -2305,7 +2305,7 @@ "crossing-continue-through-red": { "mappings": { "0": { - "then": "A cyclist can go straight on if the light is red " + "then": "A cyclist can go straight on if the light is red" }, "1": { "then": "A cyclist can go straight on if the light is red" @@ -2341,7 +2341,7 @@ "crossing-right-turn-through-red": { "mappings": { "0": { - "then": "A cyclist can turn right if the light is red " + "then": "A cyclist can turn right if the light is red" }, "1": { "then": "A cyclist can turn right if the light is red" diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 4ec425d43..7c2c17a36 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -2321,7 +2321,7 @@ "crossing-continue-through-red": { "mappings": { "0": { - "then": "Een fietser mag wel rechtdoor gaan als het licht rood is " + "then": "Een fietser mag wel rechtdoor gaan als het licht rood is" }, "1": { "then": "Een fietser mag wel rechtdoor gaan als het licht rood is" @@ -2357,7 +2357,7 @@ "crossing-right-turn-through-red": { "mappings": { "0": { - "then": "Een fietser mag wel rechtsaf slaan als het licht rood is " + "then": "Een fietser mag wel rechtsaf slaan als het licht rood is" }, "1": { "then": "Een fietser mag wel rechtsaf slaan als het licht rood is" From 04a2cc9bc796b99cda2c9ec8b1a90f5429c0ed58 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 02:45:15 +0100 Subject: [PATCH 14/24] Fix tests --- Docs/Schemas/LayerConfigJson.schema.json | 2 +- Docs/Schemas/LayerConfigJsonJSC.ts | 2 +- Docs/Schemas/LayoutConfigJson.schema.json | 2 +- Docs/Schemas/LayoutConfigJsonJSC.ts | 2 +- .../LineRenderingConfigJson.schema.json | 2 +- Docs/Schemas/LineRenderingConfigJsonJSC.ts | 2 +- .../PointRenderingConfigJson.schema.json | 2 +- Docs/Schemas/PointRenderingConfigJsonJSC.ts | 2 +- .../TagRenderingConfigJson.schema.json | 2 +- Docs/Schemas/TagRenderingConfigJsonJSC.ts | 2 +- Docs/Schemas/TilesourceConfigJson.schema.json | 2 +- Docs/Schemas/TilesourceConfigJsonJSC.ts | 2 +- Models/ThemeConfig/Conversion/FixImages.ts | 36 ++++----- .../Json/TagRenderingConfigJson.ts | 2 +- Utils.ts | 74 ++++++++++--------- test/ImageAttribution.spec.ts | 2 +- test/LegacyThemeLoader.spec.ts | 2 +- test/TestAll.ts | 3 +- 18 files changed, 71 insertions(+), 72 deletions(-) diff --git a/Docs/Schemas/LayerConfigJson.schema.json b/Docs/Schemas/LayerConfigJson.schema.json index 9e72ff1a3..72a8a69e0 100644 --- a/Docs/Schemas/LayerConfigJson.schema.json +++ b/Docs/Schemas/LayerConfigJson.schema.json @@ -612,7 +612,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/LayerConfigJsonJSC.ts b/Docs/Schemas/LayerConfigJsonJSC.ts index 0348fcb91..481e12736 100644 --- a/Docs/Schemas/LayerConfigJsonJSC.ts +++ b/Docs/Schemas/LayerConfigJsonJSC.ts @@ -610,7 +610,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/LayoutConfigJson.schema.json b/Docs/Schemas/LayoutConfigJson.schema.json index 3321c1eed..362a59e45 100644 --- a/Docs/Schemas/LayoutConfigJson.schema.json +++ b/Docs/Schemas/LayoutConfigJson.schema.json @@ -456,7 +456,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/LayoutConfigJsonJSC.ts b/Docs/Schemas/LayoutConfigJsonJSC.ts index 49ca6c05e..92e8e24fb 100644 --- a/Docs/Schemas/LayoutConfigJsonJSC.ts +++ b/Docs/Schemas/LayoutConfigJsonJSC.ts @@ -454,7 +454,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/LineRenderingConfigJson.schema.json b/Docs/Schemas/LineRenderingConfigJson.schema.json index 278e857e4..2b8cac100 100644 --- a/Docs/Schemas/LineRenderingConfigJson.schema.json +++ b/Docs/Schemas/LineRenderingConfigJson.schema.json @@ -256,7 +256,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/LineRenderingConfigJsonJSC.ts b/Docs/Schemas/LineRenderingConfigJsonJSC.ts index f4a2e76d3..b0037110a 100644 --- a/Docs/Schemas/LineRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/LineRenderingConfigJsonJSC.ts @@ -254,7 +254,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/PointRenderingConfigJson.schema.json b/Docs/Schemas/PointRenderingConfigJson.schema.json index 715988459..89d2c3c41 100644 --- a/Docs/Schemas/PointRenderingConfigJson.schema.json +++ b/Docs/Schemas/PointRenderingConfigJson.schema.json @@ -260,7 +260,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/PointRenderingConfigJsonJSC.ts b/Docs/Schemas/PointRenderingConfigJsonJSC.ts index 1f37ef54a..599e6c5c1 100644 --- a/Docs/Schemas/PointRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/PointRenderingConfigJsonJSC.ts @@ -258,7 +258,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/TagRenderingConfigJson.schema.json b/Docs/Schemas/TagRenderingConfigJson.schema.json index 1c595208d..21ee45e1e 100644 --- a/Docs/Schemas/TagRenderingConfigJson.schema.json +++ b/Docs/Schemas/TagRenderingConfigJson.schema.json @@ -96,7 +96,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/TagRenderingConfigJsonJSC.ts b/Docs/Schemas/TagRenderingConfigJsonJSC.ts index 172740e9c..cf2358570 100644 --- a/Docs/Schemas/TagRenderingConfigJsonJSC.ts +++ b/Docs/Schemas/TagRenderingConfigJsonJSC.ts @@ -96,7 +96,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/TilesourceConfigJson.schema.json b/Docs/Schemas/TilesourceConfigJson.schema.json index a7ae626b5..ebac53292 100644 --- a/Docs/Schemas/TilesourceConfigJson.schema.json +++ b/Docs/Schemas/TilesourceConfigJson.schema.json @@ -204,7 +204,7 @@ ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Docs/Schemas/TilesourceConfigJsonJSC.ts b/Docs/Schemas/TilesourceConfigJsonJSC.ts index 21d48703c..bc487ece2 100644 --- a/Docs/Schemas/TilesourceConfigJsonJSC.ts +++ b/Docs/Schemas/TilesourceConfigJsonJSC.ts @@ -202,7 +202,7 @@ export default { ] }, "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\ntype: rendered" + "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\nType: rendered" }, "icon": { "description": "An icon supporting this mapping; typically shown pretty small\nType: icon", diff --git a/Models/ThemeConfig/Conversion/FixImages.ts b/Models/ThemeConfig/Conversion/FixImages.ts index ebeb0223d..08318b4bc 100644 --- a/Models/ThemeConfig/Conversion/FixImages.ts +++ b/Models/ThemeConfig/Conversion/FixImages.ts @@ -7,6 +7,11 @@ import * as tagrenderingmetapaths from "../../../assets/tagrenderingconfigmeta.j export class ExtractImages extends Conversion { private _isOfficial: boolean; private _sharedTagRenderings: Map; + + private static readonly layoutMetaPaths = (metapaths["default"] ?? metapaths).filter(mp => mp.typeHint !== undefined && (mp.typeHint === "image" || mp.typeHint === "icon")) + private static readonly tagRenderingMetaPaths = (tagrenderingmetapaths["default"] ?? tagrenderingmetapaths).filter(trpath => trpath.typeHint !== "rendered") + + constructor(isOfficial: boolean, sharedTagRenderings: Map) { super("Extract all images from a layoutConfig using the meta paths",[],"ExctractImages"); this._isOfficial = isOfficial; @@ -14,25 +19,17 @@ export class ExtractImages extends Conversion { } convert(json: LayoutConfigJson, context: string): { result: string[], errors: string[], warnings: string[] } { - const paths = metapaths["default"] ?? metapaths - const trpaths = tagrenderingmetapaths["default"] ?? tagrenderingmetapaths - const allFoundImages = [] + const allFoundImages = [] const errors = [] const warnings = [] - for (const metapath of paths) { - if (metapath.typeHint === undefined) { - continue - } - if (metapath.typeHint !== "image" && metapath.typeHint !== "icon") { - continue - } - + for (const metapath of ExtractImages.layoutMetaPaths) { const mightBeTr = Array.isArray(metapath.type) && metapath.type.some(t => t["$ref"] == "#/definitions/TagRenderingConfigJson") const found = Utils.CollectPath(metapath.path, json) if (mightBeTr) { // We might have tagRenderingConfigs containing icons here - for (const {path, leaf} of found) { - const foundImage = leaf; + for (const el of found) { + const path = el.path + const foundImage = el.leaf; if (typeof foundImage === "string") { if(foundImage == ""){ @@ -47,17 +44,14 @@ export class ExtractImages extends Conversion { allFoundImages.push(foundImage) } else{ // This is a tagRendering where every rendered value might be an icon! - for (const trpath of trpaths) { - if (trpath.typeHint !== "rendered") { - continue - } + for (const trpath of ExtractImages.tagRenderingMetaPaths) { const fromPath = Utils.CollectPath(trpath.path, foundImage) for (const img of fromPath) { - if (typeof img !== "string") { - (this._isOfficial ? errors: warnings).push(context+": found an image path that is not a path at " + context + "." + metapath.path.join(".") + ": " + JSON.stringify(img)) + if (typeof img.leaf !== "string") { + (this._isOfficial ? errors: warnings).push(context+": found an image path that is not a path at " + context + "." + img.path.join(".") + ": " + JSON.stringify(img)) } } - allFoundImages.push(...fromPath.filter(i => typeof i === "string")) + allFoundImages.push(...fromPath.map(i => i.leaf).filter(i => typeof i=== "string")) for (const pathAndImg of fromPath) { if(pathAndImg.leaf === "" || pathAndImg.leaf["path"] == ""){ errors.push(context+[...path,...pathAndImg.path].join(".")+": Found an empty image at ") @@ -68,7 +62,7 @@ export class ExtractImages extends Conversion { } } } else { - allFoundImages.push(...found) + allFoundImages.push(...found.map(i => i.leaf)) } } diff --git a/Models/ThemeConfig/Json/TagRenderingConfigJson.ts b/Models/ThemeConfig/Json/TagRenderingConfigJson.ts index 36ccbf3cc..0b08218b5 100644 --- a/Models/ThemeConfig/Json/TagRenderingConfigJson.ts +++ b/Models/ThemeConfig/Json/TagRenderingConfigJson.ts @@ -115,7 +115,7 @@ export interface TagRenderingConfigJson { /** * If the condition `if` is met, the text `then` will be rendered. * If not known yet, the user will be presented with `then` as an option - * type: rendered + * Type: rendered */ then: string | any, /** diff --git a/Utils.ts b/Utils.ts index 9132347f4..41e4d141e 100644 --- a/Utils.ts +++ b/Utils.ts @@ -304,7 +304,7 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be if (target === null) { return source } - + for (const key in source) { if (!source.hasOwnProperty(key)) { continue @@ -364,9 +364,9 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be // We have reached the leaf const leaf = object[head]; if (leaf !== undefined) { - if(Array.isArray(leaf)){ + if (Array.isArray(leaf)) { object[head] = leaf.map(o => replaceLeaf(o, travelledPath)) - }else{ + } else { object[head] = replaceLeaf(leaf, travelledPath) } } @@ -381,10 +381,10 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be return; } if (Array.isArray(sub)) { - sub.forEach((el, i) => Utils.WalkPath(path.slice(1), el, replaceLeaf, [...travelledPath, head, ""+i])) + sub.forEach((el, i) => Utils.WalkPath(path.slice(1), el, replaceLeaf, [...travelledPath, head, "" + i])) return; } - Utils.WalkPath(path.slice(1), sub, replaceLeaf, [...travelledPath,head]) + Utils.WalkPath(path.slice(1), sub, replaceLeaf, [...travelledPath, head]) } /** @@ -393,22 +393,26 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be * * The leaf objects are collected in the list */ - public static CollectPath(path: string[], object: any, collectedList: {leaf: any, path: string[]}[] = [], travelledPath: string[] = []): {leaf: any, path: string[]}[] { + public static CollectPath(path: string[], object: any, collectedList: { leaf: any, path: string[] }[] = [], travelledPath: string[] = []): { leaf: any, path: string[] }[] { if (object === undefined || object === null) { return collectedList; } const head = path[0] + travelledPath = [...travelledPath, head] if (path.length === 1) { // We have reached the leaf const leaf = object[head]; if (leaf === undefined || leaf === null) { return collectedList - } - if (Array.isArray(leaf)) { - collectedList.push(...leaf) - } else { - collectedList.push(leaf) + } + if (Array.isArray(leaf)) { + for (let i = 0; i < (leaf).length; i++){ + const l = (leaf)[i]; + collectedList.push({leaf: l, path: [...travelledPath, ""+i]}) } + } else { + collectedList.push({leaf, path: travelledPath}) + } return collectedList } const sub = object[head] @@ -417,13 +421,13 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be } if (Array.isArray(sub)) { - sub.forEach((el, i) => Utils.CollectPath(path.slice(1), el, collectedList, [...travelledPath,head,""+i])) + sub.forEach((el, i) => Utils.CollectPath(path.slice(1), el, collectedList, [...travelledPath, "" + i])) return collectedList; } if (typeof sub !== "object") { return collectedList; } - return Utils.CollectPath(path.slice(1), sub, collectedList,[...travelledPath, head]) + return Utils.CollectPath(path.slice(1), sub, collectedList, travelledPath) } /** @@ -725,6 +729,28 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be return new Date(str) } + public static levenshteinDistance(str1: string, str2: string) { + const track = Array(str2.length + 1).fill(null).map(() => + Array(str1.length + 1).fill(null)); + for (let i = 0; i <= str1.length; i += 1) { + track[0][i] = i; + } + for (let j = 0; j <= str2.length; j += 1) { + track[j][0] = j; + } + for (let j = 1; j <= str2.length; j += 1) { + for (let i = 1; i <= str1.length; i += 1) { + const indicator = str1[i - 1] === str2[j - 1] ? 0 : 1; + track[j][i] = Math.min( + track[j][i - 1] + 1, // deletion + track[j - 1][i] + 1, // insertion + track[j - 1][i - 1] + indicator, // substitution + ); + } + } + return track[str2.length][str1.length]; + } + private static colorDiff(c0: { r: number, g: number, b: number }, c1: { r: number, g: number, b: number }) { return Math.abs(c0.r - c1.r) + Math.abs(c0.g - c1.g) + Math.abs(c0.b - c1.b); } @@ -751,27 +777,5 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be b: parseInt(hex.substr(5, 2), 16), } } - - public static levenshteinDistance (str1: string, str2: string) { - const track = Array(str2.length + 1).fill(null).map(() => - Array(str1.length + 1).fill(null)); - for (let i = 0; i <= str1.length; i += 1) { - track[0][i] = i; - } - for (let j = 0; j <= str2.length; j += 1) { - track[j][0] = j; - } - for (let j = 1; j <= str2.length; j += 1) { - for (let i = 1; i <= str1.length; i += 1) { - const indicator = str1[i - 1] === str2[j - 1] ? 0 : 1; - track[j][i] = Math.min( - track[j][i - 1] + 1, // deletion - track[j - 1][i] + 1, // insertion - track[j - 1][i - 1] + indicator, // substitution - ); - } - } - return track[str2.length][str1.length]; - } } diff --git a/test/ImageAttribution.spec.ts b/test/ImageAttribution.spec.ts index 10883105a..86b394a79 100644 --- a/test/ImageAttribution.spec.ts +++ b/test/ImageAttribution.spec.ts @@ -10,7 +10,7 @@ export default class ImageAttributionSpec extends T { [ "Should find all the images", () => { - const images = new Set(new ExtractImages(true).convertStrict( cyclofix, "test")) + const images = new Set(new ExtractImages(true, new Map()).convertStrict( cyclofix, "test")) const expectedValues = [ './assets/layers/bike_repair_station/repair_station.svg', './assets/layers/bike_repair_station/repair_station_pump.svg', diff --git a/test/LegacyThemeLoader.spec.ts b/test/LegacyThemeLoader.spec.ts index 85a3d5b17..d310887f7 100644 --- a/test/LegacyThemeLoader.spec.ts +++ b/test/LegacyThemeLoader.spec.ts @@ -470,7 +470,7 @@ export default class LegacyThemeLoaderSpec extends T { T.isTrue(r.warnings.some(msg => msg.indexOf("./assets/layers/bike_parking/staple.svg") >= 0), "staple.svg not mentioned"); }], ["Images in 'thens' icons are detected", () => { - const r = new ExtractImages(true).convert({ + const r = new ExtractImages(true, new Map()).convert({ "layers": [ { tagRenderings: [ diff --git a/test/TestAll.ts b/test/TestAll.ts index de9211864..5d43853cc 100644 --- a/test/TestAll.ts +++ b/test/TestAll.ts @@ -59,7 +59,7 @@ async function main() { let args = [...process.argv] args.splice(0, 2) - args = args.map(a => a.toLowerCase()) + args = args.map(a => a.toLowerCase().replace(/"/g, "")) const allFailures: { testsuite: string, name: string, msg: string } [] = [] let testsToRun = allTests @@ -72,6 +72,7 @@ async function main() { } }) testsToRun = allTests.filter(t => args.indexOf(t.name.toLowerCase()) >= 0) + console.log("Only running test "+testsToRun.join(", ")) } if (testsToRun.length == 0) { From dcfac434e2a150d38a46e53ebc8f0d738a9aebb4 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 02:50:54 +0100 Subject: [PATCH 15/24] Fix filter --- Models/ThemeConfig/Conversion/FixImages.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Models/ThemeConfig/Conversion/FixImages.ts b/Models/ThemeConfig/Conversion/FixImages.ts index 08318b4bc..9558e2f6e 100644 --- a/Models/ThemeConfig/Conversion/FixImages.ts +++ b/Models/ThemeConfig/Conversion/FixImages.ts @@ -9,7 +9,7 @@ export class ExtractImages extends Conversion { private _sharedTagRenderings: Map; private static readonly layoutMetaPaths = (metapaths["default"] ?? metapaths).filter(mp => mp.typeHint !== undefined && (mp.typeHint === "image" || mp.typeHint === "icon")) - private static readonly tagRenderingMetaPaths = (tagrenderingmetapaths["default"] ?? tagrenderingmetapaths).filter(trpath => trpath.typeHint !== "rendered") + private static readonly tagRenderingMetaPaths = (tagrenderingmetapaths["default"] ?? tagrenderingmetapaths).filter(trpath => trpath.typeHint === "rendered") constructor(isOfficial: boolean, sharedTagRenderings: Map) { @@ -48,7 +48,7 @@ export class ExtractImages extends Conversion { const fromPath = Utils.CollectPath(trpath.path, foundImage) for (const img of fromPath) { if (typeof img.leaf !== "string") { - (this._isOfficial ? errors: warnings).push(context+": found an image path that is not a path at " + context + "." + img.path.join(".") + ": " + JSON.stringify(img)) + (this._isOfficial ? errors: warnings).push(context+"."+img.path.join(".")+": found an image path that is not a string: " + JSON.stringify(img.leaf)) } } allFoundImages.push(...fromPath.map(i => i.leaf).filter(i => typeof i=== "string")) From f39bbff08c5b53d1e2c70f519ab5290f2b298ad7 Mon Sep 17 00:00:00 2001 From: Robin van der Linde Date: Fri, 18 Feb 2022 14:50:27 +0000 Subject: [PATCH 16/24] Translated using Weblate (Dutch) Currently translated at 93.6% (1492 of 1593 strings) Translation: MapComplete/Layer translations Translate-URL: https://hosted.weblate.org/projects/mapcomplete/layer-translations/nl/ --- langs/layers/nl.json | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 4ec425d43..951570e51 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -1343,7 +1343,7 @@ "question": "Heeft een
Tesla Supercharger (destination)
" }, "13": { - "question": "Heeft een
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" + "question": "Heeft een
Tesla supercharger (destination) (Een Type 2 met kabel en Tesla-logo)
" }, "14": { "question": "Heeft een
USB om GSMs en kleine electronica op te laden
" @@ -1499,7 +1499,7 @@ "then": "Bosch Active Connect met 5 pinnen aan een kabel" } }, - "question": "Welke aansluitingen zijn hier beschikbaar?" + "question": "Welke laadaansluitingen zijn hier beschikbaar?" }, "Network": { "mappings": { @@ -1658,8 +1658,8 @@ "then": "Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo) levert een stroom van maximaal 32 A" } }, - "question": "Welke stroom levert de stekker van type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
?", - "render": "
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal {socket:tesla_destination:current}A" + "question": "Welke stroom levert de stekker van type
Tesla supercharger (destination) (Een Type 2 met kabel en Tesla-logo)
?", + "render": "
Tesla supercharger (destination) (Een Type 2 met kabel en Tesla-logo)
levert een stroom van maximaal {socket:tesla_destination:current}A" }, "current-13": { "mappings": { @@ -1822,7 +1822,7 @@ "render": "Hier zijn {socket:tesla_destination} stekkers van het type
Tesla Supercharger (destination)
" }, "plugs-12": { - "question": "Hoeveel stekkers van type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
heeft dit oplaadpunt?", + "question": "Hoeveel stekkers van type
Tesla supercharger (destination) (Een Type 2 met kabel en Tesla-logo)
heeft dit oplaadpunt?", "render": "Hier zijn {socket:tesla_destination} stekkers van het type
Tesla supercharger (destination (Een Type 2 met kabel en Tesla-logo)
" }, "plugs-13": { @@ -3882,7 +3882,7 @@ "then": "Dit boekenruilkastje heeft geen naam" } }, - "question": "Wat is de naam van dit boekenuilkastje?", + "question": "Wat is de naam van dit boekenruilkastje?", "render": "De naam van dit boekenruilkastje is {name}" }, "public_bookcase-operator": { @@ -4841,10 +4841,10 @@ "then": "Deze vuilnisbak heeft een verdeler voor hondenpoepzakjes" }, "1": { - "then": "Deze vuilnisbak heeft geenverdeler voor hondenpoepzakjes" + "then": "Deze vuilnisbak heeft geen verdeler voor hondenpoepzakjes" }, "2": { - "then": "Deze vuilnisbaak heeft waarschijnlijk geen verdeler voor hondenpoepzakjes" + "then": "Deze vuilnisbak heeft waarschijnlijk geen verdeler voor hondenpoepzakjes" } }, "question": "Heeft deze vuilnisbak een verdeler voor hondenpoepzakjes?" @@ -4930,4 +4930,4 @@ "render": "Watermolens" } } -} \ No newline at end of file +} From 55f9ee605f78b788680e207ab8c02b3b035ce918 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:39:16 +0100 Subject: [PATCH 17/24] More checks --- Models/ThemeConfig/Conversion/FixImages.ts | 16 ++++++++++++---- Models/ThemeConfig/Conversion/Validation.ts | 20 +++++++++++++++++++- 2 files changed, 31 insertions(+), 5 deletions(-) diff --git a/Models/ThemeConfig/Conversion/FixImages.ts b/Models/ThemeConfig/Conversion/FixImages.ts index 9558e2f6e..0b8bb1de0 100644 --- a/Models/ThemeConfig/Conversion/FixImages.ts +++ b/Models/ThemeConfig/Conversion/FixImages.ts @@ -19,7 +19,7 @@ export class ExtractImages extends Conversion { } convert(json: LayoutConfigJson, context: string): { result: string[], errors: string[], warnings: string[] } { - const allFoundImages = [] + const allFoundImages : string[] = [] const errors = [] const warnings = [] for (const metapath of ExtractImages.layoutMetaPaths) { @@ -33,7 +33,7 @@ export class ExtractImages extends Conversion { if (typeof foundImage === "string") { if(foundImage == ""){ - errors.push(context+"."+path.join(".")+" Found an empty image") + warnings.push(context+"."+path.join(".")+" Found an empty image") } if(this._sharedTagRenderings?.has(foundImage)){ @@ -54,7 +54,7 @@ export class ExtractImages extends Conversion { allFoundImages.push(...fromPath.map(i => i.leaf).filter(i => typeof i=== "string")) for (const pathAndImg of fromPath) { if(pathAndImg.leaf === "" || pathAndImg.leaf["path"] == ""){ - errors.push(context+[...path,...pathAndImg.path].join(".")+": Found an empty image at ") + warnings.push(context+[...path,...pathAndImg.path].join(".")+": Found an empty image at ") } } } @@ -62,7 +62,14 @@ export class ExtractImages extends Conversion { } } } else { - allFoundImages.push(...found.map(i => i.leaf)) + for (const foundElement of found) { + if(foundElement.leaf === ""){ + warnings.push(context+"."+foundElement.path.join(".")+" Found an empty image") + continue + } + allFoundImages.push(foundElement.leaf) + } + } } @@ -70,6 +77,7 @@ export class ExtractImages extends Conversion { .map(img => img["path"] ?? img) .map(img => img.split(";"))) .map(img => img.split(":")[0]) + .filter(img => img !== "") return {result: Utils.Dedup(splitParts), errors, warnings}; } diff --git a/Models/ThemeConfig/Conversion/Validation.ts b/Models/ThemeConfig/Conversion/Validation.ts index 571cc7d3a..bcdb3902d 100644 --- a/Models/ThemeConfig/Conversion/Validation.ts +++ b/Models/ThemeConfig/Conversion/Validation.ts @@ -208,11 +208,29 @@ class OverrideShadowingCheck extends DesugaringStep { } +class MiscThemeChecks extends DesugaringStep{ + constructor() { + super("Miscelleanous checks on the theme", [],"MiscThemesChecks"); + } + + convert(json: LayoutConfigJson, context: string): { result: LayoutConfigJson; errors?: string[]; warnings?: string[]; information?: string[] } { + const warnings = [] + if(json.socialImage === ""){ + warnings.push("Social image for theme "+json.id+" is the emtpy string") + } + return { + result :json, + warnings + }; + } +} + export class PrevalidateTheme extends Fuse { constructor() { super("Various consistency checks on the raw JSON", - new OverrideShadowingCheck() + new OverrideShadowingCheck(), + new MiscThemeChecks() ); } From 2e586cedc4a8ab32da0753160625233cd13430c7 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:40:51 +0100 Subject: [PATCH 18/24] Remove empty social images --- Models/ThemeConfig/Conversion/LegacyJsonConvert.ts | 5 +++++ assets/themes/benches/benches.json | 1 - assets/themes/bicycle_rental/bicycle_rental.json | 1 - assets/themes/binoculars/binoculars.json | 1 - assets/themes/cafes_and_pubs/cafes_and_pubs.json | 1 - assets/themes/charging_stations/charging_stations.json | 1 - assets/themes/climbing/climbing.json | 1 - assets/themes/etymology.json | 1 - assets/themes/facadegardens/facadegardens.json | 1 - assets/themes/food/food.json | 1 - assets/themes/fritures/fritures.json | 1 - assets/themes/fruit_trees/fruit_trees.json | 1 - assets/themes/grb_import/grb_fixme.json | 1 - assets/themes/grb_import/missing_streets.json | 1 - assets/themes/hackerspaces/hackerspaces.json | 1 - assets/themes/hailhydrant/hailhydrant.json | 1 - assets/themes/maps/maps.json | 1 - assets/themes/nature/nature.json | 1 - assets/themes/natuurpunt/natuurpunt.json | 1 - assets/themes/observation_towers/observation_towers.json | 1 - assets/themes/play_forests/play_forests.json | 1 - assets/themes/playgrounds/playgrounds.json | 1 - assets/themes/postal_codes/postal_codes.json | 1 - assets/themes/shops/shops.json | 1 - assets/themes/sidewalks/sidewalks.json | 1 - assets/themes/sport_pitches/sport_pitches.json | 1 - assets/themes/surveillance/surveillance.json | 1 - assets/themes/uk_addresses/uk_addresses.json | 1 - assets/themes/waste_basket/waste_basket.json | 1 - 29 files changed, 5 insertions(+), 28 deletions(-) diff --git a/Models/ThemeConfig/Conversion/LegacyJsonConvert.ts b/Models/ThemeConfig/Conversion/LegacyJsonConvert.ts index f5a5294fb..c1bbcec37 100644 --- a/Models/ThemeConfig/Conversion/LegacyJsonConvert.ts +++ b/Models/ThemeConfig/Conversion/LegacyJsonConvert.ts @@ -126,6 +126,11 @@ class UpdateLegacyTheme extends DesugaringStep { convert(json: LayoutConfigJson, context: string): { result: LayoutConfigJson; errors: string[]; warnings: string[] } { const oldThemeConfig = {...json} + + if(oldThemeConfig.socialImage === ""){ + delete oldThemeConfig.socialImage + } + if (oldThemeConfig["roamingRenderings"] !== undefined) { if (oldThemeConfig["roamingRenderings"].length == 0) { diff --git a/assets/themes/benches/benches.json b/assets/themes/benches/benches.json index 193b38d40..7ed0d305e 100644 --- a/assets/themes/benches/benches.json +++ b/assets/themes/benches/benches.json @@ -45,7 +45,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 1.5, - "socialImage": "", "layers": [ "bench", "bench_at_pt", diff --git a/assets/themes/bicycle_rental/bicycle_rental.json b/assets/themes/bicycle_rental/bicycle_rental.json index 9f30efca3..b26d1bf16 100644 --- a/assets/themes/bicycle_rental/bicycle_rental.json +++ b/assets/themes/bicycle_rental/bicycle_rental.json @@ -19,7 +19,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 0.05, - "socialImage": "", "layers": [ "bicycle_rental" ] diff --git a/assets/themes/binoculars/binoculars.json b/assets/themes/binoculars/binoculars.json index 1e77b49c6..fed6bcb98 100644 --- a/assets/themes/binoculars/binoculars.json +++ b/assets/themes/binoculars/binoculars.json @@ -33,7 +33,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 1.5, - "socialImage": "", "layers": [ "binocular" ] diff --git a/assets/themes/cafes_and_pubs/cafes_and_pubs.json b/assets/themes/cafes_and_pubs/cafes_and_pubs.json index 9ab64a6c9..92256e06a 100644 --- a/assets/themes/cafes_and_pubs/cafes_and_pubs.json +++ b/assets/themes/cafes_and_pubs/cafes_and_pubs.json @@ -22,7 +22,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 1.5, - "socialImage": "", "layers": [ "cafe_pub" ] diff --git a/assets/themes/charging_stations/charging_stations.json b/assets/themes/charging_stations/charging_stations.json index 2b6fc04d2..6c0dbdc86 100644 --- a/assets/themes/charging_stations/charging_stations.json +++ b/assets/themes/charging_stations/charging_stations.json @@ -39,7 +39,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 1.5, - "socialImage": "", "defaultBackgroundId": "CartoDB.Voyager", "layers": [ "charging_station" diff --git a/assets/themes/climbing/climbing.json b/assets/themes/climbing/climbing.json index fc948705d..e93273ebf 100644 --- a/assets/themes/climbing/climbing.json +++ b/assets/themes/climbing/climbing.json @@ -41,7 +41,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 1.5, - "socialImage": "", "layers": [ { "id": "climbing_club", diff --git a/assets/themes/etymology.json b/assets/themes/etymology.json index bd76bf8a3..1ed79cf96 100644 --- a/assets/themes/etymology.json +++ b/assets/themes/etymology.json @@ -32,7 +32,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "", "clustering": { "maxZoom": 14, "minNeededElements": 250 diff --git a/assets/themes/facadegardens/facadegardens.json b/assets/themes/facadegardens/facadegardens.json index a9d50b9c6..923346ff3 100644 --- a/assets/themes/facadegardens/facadegardens.json +++ b/assets/themes/facadegardens/facadegardens.json @@ -36,7 +36,6 @@ "startLon": 4.480705, "startZoom": 15, "widenFactor": 1.5, - "socialImage": "", "layers": [ { "id": "facadegardens", diff --git a/assets/themes/food/food.json b/assets/themes/food/food.json index 796aeefd4..05b4516ce 100644 --- a/assets/themes/food/food.json +++ b/assets/themes/food/food.json @@ -20,7 +20,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 3, - "socialImage": "", "layers": [ "food" ] diff --git a/assets/themes/fritures/fritures.json b/assets/themes/fritures/fritures.json index 22677da03..46d5a4e8e 100644 --- a/assets/themes/fritures/fritures.json +++ b/assets/themes/fritures/fritures.json @@ -16,7 +16,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 3, - "socialImage": "", "layers": [ { "builtin": "food", diff --git a/assets/themes/fruit_trees/fruit_trees.json b/assets/themes/fruit_trees/fruit_trees.json index 3b687bd89..7fe8c9323 100644 --- a/assets/themes/fruit_trees/fruit_trees.json +++ b/assets/themes/fruit_trees/fruit_trees.json @@ -16,7 +16,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "", "hideFromOverview": true, "layers": [ { diff --git a/assets/themes/grb_import/grb_fixme.json b/assets/themes/grb_import/grb_fixme.json index 313b5efb6..2ae057dfd 100644 --- a/assets/themes/grb_import/grb_fixme.json +++ b/assets/themes/grb_import/grb_fixme.json @@ -16,7 +16,6 @@ "startLon": 3.231, "startZoom": 14, "widenFactor": 2, - "socialImage": "", "clustering": { "maxZoom": 15 }, diff --git a/assets/themes/grb_import/missing_streets.json b/assets/themes/grb_import/missing_streets.json index 4bcd22c2a..d30e0a2cc 100644 --- a/assets/themes/grb_import/missing_streets.json +++ b/assets/themes/grb_import/missing_streets.json @@ -16,7 +16,6 @@ "startLon": 4.026489, "startZoom": 9, "widenFactor": 2, - "socialImage": "", "clustering": { "maxZoom": 15 }, diff --git a/assets/themes/hackerspaces/hackerspaces.json b/assets/themes/hackerspaces/hackerspaces.json index 4deafa356..c5728cb7e 100644 --- a/assets/themes/hackerspaces/hackerspaces.json +++ b/assets/themes/hackerspaces/hackerspaces.json @@ -29,7 +29,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 5, - "socialImage": "", "layers": [ { "id": "hackerspaces", diff --git a/assets/themes/hailhydrant/hailhydrant.json b/assets/themes/hailhydrant/hailhydrant.json index a135d0f4e..0d4007b45 100644 --- a/assets/themes/hailhydrant/hailhydrant.json +++ b/assets/themes/hailhydrant/hailhydrant.json @@ -37,7 +37,6 @@ "startLon": 121.6625, "startZoom": 6, "widenFactor": 3, - "socialImage": "", "layers": [ "hydrant", "extinguisher", diff --git a/assets/themes/maps/maps.json b/assets/themes/maps/maps.json index 305eb4a17..b18aecf4f 100644 --- a/assets/themes/maps/maps.json +++ b/assets/themes/maps/maps.json @@ -37,7 +37,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 5, - "socialImage": "", "layers": [ "map" ] diff --git a/assets/themes/nature/nature.json b/assets/themes/nature/nature.json index 8dc62a6df..294d6be52 100644 --- a/assets/themes/nature/nature.json +++ b/assets/themes/nature/nature.json @@ -19,7 +19,6 @@ "startLon": 3.22435, "startZoom": 12, "widenFactor": 2, - "socialImage": "", "layers": [ "drinking_water", "birdhide", diff --git a/assets/themes/natuurpunt/natuurpunt.json b/assets/themes/natuurpunt/natuurpunt.json index c66a67d92..3231ecbab 100644 --- a/assets/themes/natuurpunt/natuurpunt.json +++ b/assets/themes/natuurpunt/natuurpunt.json @@ -41,7 +41,6 @@ ] ], "widenFactor": 2, - "socialImage": "", "defaultBackgroundId": "CartoDB.Positron", "enablePdfDownload": true, "enableDownload": false, diff --git a/assets/themes/observation_towers/observation_towers.json b/assets/themes/observation_towers/observation_towers.json index 5a76cb753..f6bf823f9 100644 --- a/assets/themes/observation_towers/observation_towers.json +++ b/assets/themes/observation_towers/observation_towers.json @@ -32,7 +32,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 5, - "socialImage": "", "layers": [ "observation_tower" ] diff --git a/assets/themes/play_forests/play_forests.json b/assets/themes/play_forests/play_forests.json index 7c6950912..1a003edff 100644 --- a/assets/themes/play_forests/play_forests.json +++ b/assets/themes/play_forests/play_forests.json @@ -17,7 +17,6 @@ "startZoom": 1, "hideFromOverview": true, "widenFactor": 3, - "socialImage": "", "layers": [ "play_forest" ] diff --git a/assets/themes/playgrounds/playgrounds.json b/assets/themes/playgrounds/playgrounds.json index 696b7ff1b..8ab906ae8 100644 --- a/assets/themes/playgrounds/playgrounds.json +++ b/assets/themes/playgrounds/playgrounds.json @@ -45,7 +45,6 @@ "startLon": 4.399, "startZoom": 13, "widenFactor": 5, - "socialImage": "", "layers": [ "playground" ] diff --git a/assets/themes/postal_codes/postal_codes.json b/assets/themes/postal_codes/postal_codes.json index 6e14f97ec..247b4de33 100644 --- a/assets/themes/postal_codes/postal_codes.json +++ b/assets/themes/postal_codes/postal_codes.json @@ -22,7 +22,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 0.05, - "socialImage": "", "hideFromOverview": true, "clustering": false, "overpassTimeout": 180, diff --git a/assets/themes/shops/shops.json b/assets/themes/shops/shops.json index 6f07ffdf2..0c058075e 100644 --- a/assets/themes/shops/shops.json +++ b/assets/themes/shops/shops.json @@ -35,7 +35,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 3, - "socialImage": "", "layers": [ "shops" ] diff --git a/assets/themes/sidewalks/sidewalks.json b/assets/themes/sidewalks/sidewalks.json index 72ef76042..28cbe8ae8 100644 --- a/assets/themes/sidewalks/sidewalks.json +++ b/assets/themes/sidewalks/sidewalks.json @@ -18,7 +18,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 0.05, - "socialImage": "", "hideFromOverview": true, "layers": [ { diff --git a/assets/themes/sport_pitches/sport_pitches.json b/assets/themes/sport_pitches/sport_pitches.json index d2a88cd00..b0237a414 100644 --- a/assets/themes/sport_pitches/sport_pitches.json +++ b/assets/themes/sport_pitches/sport_pitches.json @@ -39,7 +39,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "", "layers": [ "sport_pitch" ] diff --git a/assets/themes/surveillance/surveillance.json b/assets/themes/surveillance/surveillance.json index fefeb406c..197362a86 100644 --- a/assets/themes/surveillance/surveillance.json +++ b/assets/themes/surveillance/surveillance.json @@ -39,7 +39,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "", "defaultBackgroundId": "osm", "layers": [ "direction", diff --git a/assets/themes/uk_addresses/uk_addresses.json b/assets/themes/uk_addresses/uk_addresses.json index febb712fe..6efb7ccdb 100644 --- a/assets/themes/uk_addresses/uk_addresses.json +++ b/assets/themes/uk_addresses/uk_addresses.json @@ -24,7 +24,6 @@ "startLon": 51.52224, "startZoom": 17, "widenFactor": 1.01, - "socialImage": "", "hideFromOverview": true, "clustering": { "minNeededFeatures": 25, diff --git a/assets/themes/waste_basket/waste_basket.json b/assets/themes/waste_basket/waste_basket.json index b0bca66e1..d312125a8 100644 --- a/assets/themes/waste_basket/waste_basket.json +++ b/assets/themes/waste_basket/waste_basket.json @@ -32,7 +32,6 @@ "startLon": 0, "startZoom": 1, "widenFactor": 2, - "socialImage": "", "layers": [ { "builtin": "waste_basket", From 812626456dbb85353e2a46662fbd8799e5b68bfc Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:44:25 +0100 Subject: [PATCH 19/24] Fix dead image --- assets/layers/direction/direction.json | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/assets/layers/direction/direction.json b/assets/layers/direction/direction.json index c60322d11..4fa7f7ce6 100644 --- a/assets/layers/direction/direction.json +++ b/assets/layers/direction/direction.json @@ -32,16 +32,7 @@ "presets": [], "mapRendering": [ { - "icon": { - "render": "direction_gradient:var(--catch-detail-color)", - "#": "For some weird reason, showing the icon in the layer control panel breaks the svg-gradient (because the svg gradient has a global color or smthng) - so we use a different icon without gradient", - "mappings": [ - { - "if": "id=node/-1", - "then": "direction:var(--catch-detail-color)" - } - ] - }, + "icon": "direction_gradient:var(--catch-detail-color)", "iconSize": "200,200,center", "location": [ "point", From c06f8820a847b7dfc54993b67083b48c770110e7 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:47:12 +0100 Subject: [PATCH 20/24] Extract images from slow_roads.json --- assets/layers/slow_roads/slow_roads.json | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/assets/layers/slow_roads/slow_roads.json b/assets/layers/slow_roads/slow_roads.json index 2964b7808..9984d916f 100644 --- a/assets/layers/slow_roads/slow_roads.json +++ b/assets/layers/slow_roads/slow_roads.json @@ -71,7 +71,11 @@ { "if": "highway=living_street", "then": { - "nl:": "
Dit is een woonerf:
  • Voetgangers mogen hier de volledige breedte van de straat gebruiken
  • Gemotoriseerd verkeer mag maximaal 20km/h rijden
" + "nl:": "
Dit is een woonerf:
  • Voetgangers mogen hier de volledige breedte van de straat gebruiken
  • Gemotoriseerd verkeer mag maximaal 20km/h rijden
" + }, + "icon": { + "path": "./assets/layers/slow_roads/woonerf.svg", + "class": "medium" } }, { From 798556f6d381fe6bbbca39d636403edf3511e08f Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:50:06 +0100 Subject: [PATCH 21/24] Extract images from watermill.json and trail.json --- assets/layers/trail/trail.json | 14 +++++++++++--- assets/layers/watermill/watermill.json | 14 +++++++++++--- langs/layers/nl.json | 8 ++++---- 3 files changed, 26 insertions(+), 10 deletions(-) diff --git a/assets/layers/trail/trail.json b/assets/layers/trail/trail.json index 84416e15f..0ec5f307b 100644 --- a/assets/layers/trail/trail.json +++ b/assets/layers/trail/trail.json @@ -77,7 +77,11 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door Natuurpunt" + "nl": "Dit gebied wordt beheerd door Natuurpunt" + }, + "icon": { + "path": "./assets/themes/buurtnatuur/Natuurpunt.jpg", + "class": "small" } }, { @@ -87,9 +91,13 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door {operator}" + "nl": "Dit gebied wordt beheerd door {operator}" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "./assets/themes/buurtnatuur/Natuurpunt.jpg", + "class": "small" + } } ], "id": "Operator tag" diff --git a/assets/layers/watermill/watermill.json b/assets/layers/watermill/watermill.json index 1e885ee8e..b69a4d4de 100644 --- a/assets/layers/watermill/watermill.json +++ b/assets/layers/watermill/watermill.json @@ -146,7 +146,11 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door Natuurpunt" + "nl": "Dit gebied wordt beheerd door Natuurpunt" + }, + "icon": { + "path": "./assets/themes/buurtnatuur/Natuurpunt.jpg", + "class": "small" } }, { @@ -156,9 +160,13 @@ ] }, "then": { - "nl": "Dit gebied wordt beheerd door {operator}" + "nl": "Dit gebied wordt beheerd door {operator}" }, - "hideInAnswer": true + "hideInAnswer": true, + "icon": { + "path": "./assets/themes/buurtnatuur/Natuurpunt.jpg", + "class": "small" + } } ], "id": "Operator tag" diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 7c2c17a36..d11d5942b 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -4612,10 +4612,10 @@ "Operator tag": { "mappings": { "0": { - "then": "Dit gebied wordt beheerd door Natuurpunt" + "then": "Dit gebied wordt beheerd door Natuurpunt" }, "1": { - "then": "Dit gebied wordt beheerd door {operator}" + "then": "Dit gebied wordt beheerd door {operator}" } }, "question": "Wie beheert deze wandeltocht?", @@ -4908,10 +4908,10 @@ "Operator tag": { "mappings": { "0": { - "then": "Dit gebied wordt beheerd door Natuurpunt" + "then": "Dit gebied wordt beheerd door Natuurpunt" }, "1": { - "then": "Dit gebied wordt beheerd door {operator}" + "then": "Dit gebied wordt beheerd door {operator}" } }, "question": "Wie beheert dit pad?", From 4580ba0ce0812be17278233f98799282b3548bc3 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sat, 19 Feb 2022 17:57:34 +0100 Subject: [PATCH 22/24] Add error suppression --- Models/ThemeConfig/Conversion/Validation.ts | 17 ++++++++++++++--- assets/themes/uk_addresses/uk_addresses.json | 1 + 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/Models/ThemeConfig/Conversion/Validation.ts b/Models/ThemeConfig/Conversion/Validation.ts index bcdb3902d..e7624b0dc 100644 --- a/Models/ThemeConfig/Conversion/Validation.ts +++ b/Models/ThemeConfig/Conversion/Validation.ts @@ -289,22 +289,33 @@ export class DetectMappingsWithImages extends DesugaringStep=0 const images = Utils.Dedup(Translations.T(mapping.then).ExtractImages()) + const ctx = `${context}.mappings[${i}]` if (images.length > 0) { - warnings.push(context + ".mappings[" + i + "]: A mapping has an image in the 'then'-clause. Remove the image there and use `\"icon\": ` instead. The images found are "+images.join(", ")) + if(!ignore){ + errors.push(`${ctx}: A mapping has an image in the 'then'-clause. Remove the image there and use \`"icon": \` instead. The images found are ${images.join(", ")}. (Ignore this warning by adding "#": "${ignoreToken}" to the mapping`) + }else{ + information.push(`${ctx}: Ignored images in then`) + } + }else if (ignore){ + warnings.push(`${ctx}: unused '${ignoreToken}' - please remove this`) } } return { - warnings, + errors,warnings,information, result: json }; } diff --git a/assets/themes/uk_addresses/uk_addresses.json b/assets/themes/uk_addresses/uk_addresses.json index 6efb7ccdb..4a46793bf 100644 --- a/assets/themes/uk_addresses/uk_addresses.json +++ b/assets/themes/uk_addresses/uk_addresses.json @@ -239,6 +239,7 @@ }, "mappings": [ { + "#": "ignore-image-in-then", "if": "addr:substreet~*", "then": "
The envelope below shows the address that we have recorded. You can change this by answering any remaining questions above, or by clicking the pencil icons below. We do not need you to provide a recipient's name or any of the parts shown in [blue].
{addr:unit} {addr:housename}
{addr:housenumber} {addr:substreet}
{addr:street}
{addr:parentstreet}
[Suburb]
[Town]
[Postal code]
" } From 6a76865312e5e92cb368dd5c00cf2b1750312383 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sun, 20 Feb 2022 00:30:28 +0100 Subject: [PATCH 23/24] Fix title() element --- UI/SpecialVisualizations.ts | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/UI/SpecialVisualizations.ts b/UI/SpecialVisualizations.ts index 8a4d6a2cb..97b594375 100644 --- a/UI/SpecialVisualizations.ts +++ b/UI/SpecialVisualizations.ts @@ -45,6 +45,7 @@ import ImgurUploader from "../Logic/ImageProviders/ImgurUploader"; import FileSelectorButton from "./Input/FileSelectorButton"; import {LoginToggle} from "./Popup/LoginButton"; import {start} from "repl"; +import {SubstitutedTranslation} from "./SubstitutedTranslation"; export interface SpecialVisualization { funcName: string, @@ -865,13 +866,14 @@ export default class SpecialVisualizations { args: [], docs:"Shows the title of the popup. Useful for some cases, e.g. 'What is phone number of {title()}?'", example:"`What is the phone number of {title()}`, which might automatically become `What is the phone number of XYZ`.", - constr: (state, tags, args, guistate) => - new VariableUiElement(tags.map(tags => { + constr: (state, tagsSource, args, guistate) => + new VariableUiElement(tagsSource.map(tags => { const layer = state.layoutToUse.getMatchingLayer(tags) - console.log("Layer for tags", tags,"is", layer.id) const title = layer?.title?.GetRenderValue(tags) - console.log("Title became: ", title) - return title + if(title === undefined){ + return undefined + } + return new SubstitutedTranslation(title, tagsSource, state) })) } ] From 89c5cd3565ba0e51a175ed5374652444da8a8d40 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Sun, 20 Feb 2022 00:44:38 +0100 Subject: [PATCH 24/24] Fix tests --- test/LegacyThemeLoader.spec.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/LegacyThemeLoader.spec.ts b/test/LegacyThemeLoader.spec.ts index d310887f7..e3b66ff65 100644 --- a/test/LegacyThemeLoader.spec.ts +++ b/test/LegacyThemeLoader.spec.ts @@ -466,8 +466,9 @@ export default class LegacyThemeLoaderSpec extends T { } }] }, "test"); - T.isTrue(r.warnings.length > 0, "No images found"); - T.isTrue(r.warnings.some(msg => msg.indexOf("./assets/layers/bike_parking/staple.svg") >= 0), "staple.svg not mentioned"); + const errors = r.errors; + T.isTrue(errors.length > 0, "No images found"); + T.isTrue(errors.some(msg => msg.indexOf("./assets/layers/bike_parking/staple.svg") >= 0), "staple.svg not mentioned"); }], ["Images in 'thens' icons are detected", () => { const r = new ExtractImages(true, new Map()).convert({