diff --git a/assets/layers/chandler/chandler.json b/assets/layers/chandler/chandler.json
new file mode 100644
index 0000000000..880204b335
--- /dev/null
+++ b/assets/layers/chandler/chandler.json
@@ -0,0 +1,55 @@
+{
+ "minzoom": 13,
+ "pointRendering": [
+ {
+ "location": [
+ "point",
+ "centroid"
+ ],
+ "marker": [
+ {
+ "icon": "circle",
+ "color": "white"
+ },
+ {
+ "icon": "./assets/layers/chandler/chandler.svg"
+ }
+ ],
+ "iconSize": "80,80"
+ }
+ ],
+ "tagRenderings": [
+ "shop.*"
+ ],
+ "lineRendering": [
+ {
+ "width": 1,
+ "color": "blue"
+ }
+ ],
+ "id": "chandler",
+ "name": {
+ "en": "Chandlers"
+ },
+ "description": {
+ "en": "Boating supplies and equipment."
+ },
+ "source": {
+ "osmTags": {
+ "or": [
+ "shop=chandler",
+ "shop=ship_chandler",
+ "seamark:small_craft_facility:category=chandler",
+ "shop=chandlery"
+ ]
+ }
+ },
+ "title": {
+ "render": {
+ "en": "Chandler {name}"
+ }
+ },
+ "allowMove": true,
+ "credits": "Pieter Vander Vennet",
+ "credits:uid": 3818858
+}
\ No newline at end of file
diff --git a/assets/layers/chandler/chandler.svg b/assets/layers/chandler/chandler.svg
new file mode 100644
index 0000000000..d423bd0674
--- /dev/null
+++ b/assets/layers/chandler/chandler.svg
@@ -0,0 +1,5 @@
+
diff --git a/assets/layers/chandler/chandler.svg.license b/assets/layers/chandler/chandler.svg.license
new file mode 100644
index 0000000000..1642050816
--- /dev/null
+++ b/assets/layers/chandler/chandler.svg.license
@@ -0,0 +1,2 @@
+SPDX-FileCopyrightText: OsmAnd
+SPDX-License-Identifier: GPLv3
\ No newline at end of file
diff --git a/assets/layers/chandler/license_info.json b/assets/layers/chandler/license_info.json
new file mode 100644
index 0000000000..10c8b4a093
--- /dev/null
+++ b/assets/layers/chandler/license_info.json
@@ -0,0 +1,12 @@
+[
+ {
+ "path": "chandler.svg",
+ "license": "GPLv3",
+ "authors": [
+ "OsmAnd"
+ ],
+ "sources": [
+ "https://github.com/osmandapp/OsmAnd-resources/tree/master"
+ ]
+ }
+]
\ No newline at end of file
diff --git a/assets/layers/lock_outline/lock_outline.json b/assets/layers/lock_outline/lock_outline.json
index 4488f6800f..91a9065344 100644
--- a/assets/layers/lock_outline/lock_outline.json
+++ b/assets/layers/lock_outline/lock_outline.json
@@ -34,4 +34,4 @@
"allowMove": false,
"credits": "Pieter Vander Vennet",
"credits:uid": 3818858
-}
+}
\ No newline at end of file
diff --git a/assets/layers/marinas/Marina_in_Seething_Wells.jpg b/assets/layers/marinas/Marina_in_Seething_Wells.jpg
new file mode 100644
index 0000000000..22567c79b3
Binary files /dev/null and b/assets/layers/marinas/Marina_in_Seething_Wells.jpg differ
diff --git a/assets/layers/marinas/Marina_in_Seething_Wells.jpg.license b/assets/layers/marinas/Marina_in_Seething_Wells.jpg.license
new file mode 100644
index 0000000000..254f083e3a
--- /dev/null
+++ b/assets/layers/marinas/Marina_in_Seething_Wells.jpg.license
@@ -0,0 +1,2 @@
+SPDX-FileCopyrightText: JogGrapher
+SPDX-License-Identifier: CC0-1.0
\ No newline at end of file
diff --git a/assets/layers/marinas/license_info.json b/assets/layers/marinas/license_info.json
new file mode 100644
index 0000000000..a63fc076a0
--- /dev/null
+++ b/assets/layers/marinas/license_info.json
@@ -0,0 +1,22 @@
+[
+ {
+ "path": "Marina_in_Seething_Wells.jpg",
+ "license": "CC0-1.0",
+ "authors": [
+ "JogGrapher"
+ ],
+ "sources": [
+ "https://commons.wikimedia.org/wiki/File:Marina_in_Seething_Wells.jpg"
+ ]
+ },
+ {
+ "path": "marina.svg",
+ "license": "CC0-1.0",
+ "authors": [
+ "DePiep"
+ ],
+ "sources": [
+ "https://commons.wikimedia.org/wiki/File:BSicon_ANCHOR.svg"
+ ]
+ }
+]
\ No newline at end of file
diff --git a/assets/layers/marinas/marina.svg b/assets/layers/marinas/marina.svg
new file mode 100644
index 0000000000..4bf33c3299
--- /dev/null
+++ b/assets/layers/marinas/marina.svg
@@ -0,0 +1,12 @@
+
+
\ No newline at end of file
diff --git a/assets/layers/marinas/marina.svg.license b/assets/layers/marinas/marina.svg.license
new file mode 100644
index 0000000000..66d129eb73
--- /dev/null
+++ b/assets/layers/marinas/marina.svg.license
@@ -0,0 +1,2 @@
+SPDX-FileCopyrightText: DePiep
+SPDX-License-Identifier: CC0-1.0
\ No newline at end of file
diff --git a/assets/layers/marinas/marinas.json b/assets/layers/marinas/marinas.json
new file mode 100644
index 0000000000..10b814b026
--- /dev/null
+++ b/assets/layers/marinas/marinas.json
@@ -0,0 +1,167 @@
+{
+ "credits": "Pieter Vander Vennet",
+ "minzoom": 10,
+ "pointRendering": [
+ {
+ "location": [
+ "point",
+ "centroid"
+ ],
+ "marker": [
+ {
+ "icon": "circle",
+ "color": "white"
+ },
+ {
+ "icon": "./assets/layers/marina/marina.svg"
+ }
+ ]
+ }
+ ],
+ "tagRenderings": [
+ "phone",
+ "images",
+ {
+ "question": {
+ "en": "What is the name of this marina?"
+ },
+ "id": "marina-name",
+ "freeform": {
+ "key": "name"
+ },
+ "render": {
+ "en": "The name of this marina is: {name}"
+ }
+ },
+ "website",
+ "opening_hours_24_7",
+ "internet-all",
+ "wikipedia",
+ {
+ "question": {
+ "en": "Does this marina have a sanitary dump station?"
+ },
+ "id": "marina-sewage-station",
+ "questionHint": {
+ "en": "Does this marina provide facilities for pump out or other black water disposal."
+ },
+ "mappings": [
+ {
+ "if": "sanitary_dump_station=yes",
+ "then": {
+ "en": "This marina does provide facilities to dispose of sewage."
+ }
+ },
+ {
+ "if": "sanitary_dump_station=no",
+ "then": {
+ "en": "This marina does not provide facilities to dispose of sewage."
+ }
+ },
+ {
+ "if": "sanitary_dump_station=customers",
+ "then": {
+ "en": "Only customers are allowed to use the facilities here to dispose of sewage."
+ }
+ }
+ ]
+ },
+ {
+ "question": {
+ "en": "Do the wastewater facilities here provide a means of pumping out a sewage tank?"
+ },
+ "id": "marina_dump_station",
+ "condition": {
+ "or": [
+ "sanitary_dump_station=yes",
+ "sanitary_dump_station=customers"
+ ]
+ },
+ "mappings": [
+ {
+ "if": "sanitary_dump_station:pump-out=yes",
+ "then": {
+ "en": "This marina offers toilet pump-out services"
+ }
+ },
+ {
+ "if": "sanitary_dump_station:pump-out=no",
+ "then": {
+ "en": "There is no toilet pump-out service at this marina"
+ }
+ }
+ ]
+ },
+ {
+ "condition": {
+ "or": [
+ "sanitary_dump_station=yes",
+ "sanitary_dump_station=customers"
+ ]
+ },
+ "id": "marina_basin",
+ "question": {
+ "en": "Does this sanitary dump station provide the means to empty a toilet cassette or other container into a basin?"
+ },
+ "mappings": [
+ {
+ "if": "sanitary_dump_station:basin=yes",
+ "then": {
+ "en": "You can empty toilet cassettes into a basin here."
+ }
+ },
+ {
+ "if": "sanitary_dump_station:basin=no",
+ "then": {
+ "en": "There is no basin to empty a toilet cassettes here."
+ }
+ }
+ ]
+ }
+ ],
+ "lineRendering": [
+ {
+ "width": 1,
+ "color": "blue"
+ }
+ ],
+ "id": "marinas",
+ "name": {
+ "en": "Marinas"
+ },
+ "description": {
+ "en": "Marinas and yacht havens for small craft."
+ },
+ "source": {
+ "osmTags": {
+ "or": [
+ "leisure=marina",
+ "seamark:harbour:category=marina",
+ "seamark:harbour:category=marina_no_facilities"
+ ]
+ }
+ },
+ "title": {
+ "render": {
+ "en": "Marina {name}"
+ },
+ "icon": "./assets/layers/marina/marina.svg"
+ },
+ "presets": [
+ {
+ "title": {
+ "en": "a marina"
+ },
+ "tags": [
+ "leisure=marina",
+ "seamark:harbour:category=marina",
+ "seamark:type=harbour"
+ ],
+ "exampleImages": [
+ "./assets/layers/marina/Marina_in_Seething_Wells.jpg"
+ ]
+ }
+ ],
+ "allowMove": true,
+ "credits:uid": 3818858
+}
diff --git a/assets/layers/piers_and_quays/piers_and_quays.json b/assets/layers/piers_and_quays/piers_and_quays.json
new file mode 100644
index 0000000000..3908adc354
--- /dev/null
+++ b/assets/layers/piers_and_quays/piers_and_quays.json
@@ -0,0 +1,86 @@
+{
+ "credits": "Pieter Vander Vennet",
+ "minzoom": 15,
+ "pointRendering": [
+ {
+ "location": [
+ "point",
+ "centroid"
+ ],
+ "marker": [
+ {
+ "icon": "circle",
+ "color": "white"
+ }
+ ]
+ }
+ ],
+ "tagRenderings": [
+ "images",
+ {
+ "question": {
+ "en": "Which boats are allowed to moor here?"
+ },
+ "id": "allowed_boats",
+ "multiAnswer": true,
+ "mappings": [
+ {
+ "if": "motorboat=yes",
+ "ifnot": "motorboat=no",
+ "then": {
+ "en": "Small motorboats (<20m) are allowed here"
+ }
+ },
+ {
+ "if": "sailboat=yes",
+ "ifnot": "sailboat=no",
+ "then": {
+ "en": "Small sailboats (<20m) are allowed here"
+ }
+ },
+ {
+ "if": "canoe=yes",
+ "ifnot": "canoe=no",
+ "then": {
+ "en": "Canoes and kayaks are allowed here"
+ }
+ }
+ ]
+ }
+ ],
+ "lineRendering": [
+ {
+ "width": 1,
+ "color": "blue"
+ }
+ ],
+ "id": "piers_and_quays",
+ "name": {
+ "en": "Piers and quays"
+ },
+ "description": {
+ "en": "Piers and quays are structures next to or on the water where people might walk on and where boats might be moored"
+ },
+ "source": {
+ "osmTags": {
+ "or": [
+ "man_made=pier",
+ "man_made=quay"
+ ]
+ }
+ },
+ "title": {
+ "render": {
+ "en": "{name}"
+ },
+ "mappings": [
+ {
+ "if": "man_made=pier",
+ "then": {
+ "en": "Pier {name}"
+ }
+ }
+ ]
+ },
+ "allowMove": false
+}
diff --git a/assets/layers/police/checkpoint.svg.license b/assets/layers/police/checkpoint.svg.license
index 2452bee1e8..ed02883002 100644
--- a/assets/layers/police/checkpoint.svg.license
+++ b/assets/layers/police/checkpoint.svg.license
@@ -1,2 +1,2 @@
SPDX-FileCopyrightText: Pieter Vander Vennet
-SPDX-License-Identifier: CC0
\ No newline at end of file
+SPDX-License-Identifier: CC0-1.0
\ No newline at end of file
diff --git a/assets/layers/waterway/waterway.json b/assets/layers/waterway/waterway.json
index f23a5c2e89..e3e3ab94eb 100644
--- a/assets/layers/waterway/waterway.json
+++ b/assets/layers/waterway/waterway.json
@@ -26,7 +26,6 @@
"pointRendering": null,
"lineRendering": [
{
- "color": "blue",
"width": {
"mappings": [
{
@@ -42,6 +41,23 @@
"then": "6"
}
]
+ },
+ "color": {
+ "render": "blue",
+ "mappings": [
+ {
+ "if": "boat=no",
+ "then": "red"
+ },
+ {
+ "if": "motorboat=yes",
+ "then": "#00ff00"
+ },
+ {
+ "if": "boat=yes",
+ "then": "#00cc00"
+ }
+ ]
}
}
],
@@ -73,7 +89,56 @@
}
}
]
+ },
+ {
+ "question": {
+ "en": "Are boats allowed on this waterway?"
+ },
+ "id": "3_vyksl7ofya7m97l",
+ "questionHint": {
+ "en": "A boat is a floating craft of which the hull is less then 20 meter long (without rudder or bowsprit)"
+ },
+ "mappings": [
+ {
+ "if": "boat=yes",
+ "then": {
+ "en": "Boats (<20m) are allowed on this waterway"
+ },
+ "alsoShowIf": "motorboat=yes"
+ },
+ {
+ "if": "boat=no",
+ "then": {
+ "en": "Boats (<20m) are not allowed on this waterway"
+ },
+ "addExtraTags": [
+ "motorboat="
+ ]
+ }
+ ]
+ },
+ {
+ "question": {
+ "en": "Are motorboats allowed on this waterway?"
+ },
+ "id": "4_yuodfwdyocflwg8",
+ "mappings": [
+ {
+ "if": "motorboat=yes",
+ "then": {
+ "en": "Motorized boats are allowed"
+ }
+ },
+ {
+ "if": "motorboat=no",
+ "then": {
+ "en": "Motorized boats are not allowed"
+ }
+ }
+ ]
}
],
- "allowMove": false
-}
+ "allowMove": false,
+ "credits": "Pieter Vander Vennet",
+ "credits:uid": 3818858
+}
\ No newline at end of file
diff --git a/assets/layers/waterway_lock/waterway_lock.json b/assets/layers/waterway_lock/waterway_lock.json
index 67315bed6c..567dbce24a 100644
--- a/assets/layers/waterway_lock/waterway_lock.json
+++ b/assets/layers/waterway_lock/waterway_lock.json
@@ -128,17 +128,21 @@
"then": {
"en": "This lock is automated (operated from control panel or control room)"
},
- "ifnot": "automated="
+ "addExtraTags": [
+ "manual=no"
+ ]
},
{
"if": "manual=yes",
"then": {
"en": "This lock is manually operated (with muscle power)"
},
- "ifnot": "manual="
+ "addExtraTags": [
+ "automated=no"
+ ]
}
],
- "multiAnswer": true,
+ "multiAnswer": false,
"condition": "waterway!=derelict_canal"
},
{
@@ -189,7 +193,7 @@
},
{
"question": {
- "en": "What VHF channel should be used to communicate with this lock?"
+ "en": "What VHF channel should be used to communicate with the control room of this lock?"
},
"id": "vhf",
"render": {
@@ -197,6 +201,12 @@
},
"freeform": {
"key": "vhf"
+ },
+ "condition": {
+ "or": [
+ "automated=yes",
+ "automated="
+ ]
}
},
"opening_hours_24_7",
diff --git a/assets/themes/narrowboat/boat.svg b/assets/themes/narrowboat/boat.svg
new file mode 100644
index 0000000000..763f1c91ef
--- /dev/null
+++ b/assets/themes/narrowboat/boat.svg
@@ -0,0 +1,64 @@
+
+
diff --git a/assets/themes/narrowboat/boat.svg.license b/assets/themes/narrowboat/boat.svg.license
new file mode 100644
index 0000000000..7e60f23475
--- /dev/null
+++ b/assets/themes/narrowboat/boat.svg.license
@@ -0,0 +1,2 @@
+SPDX-FileCopyrightText: Officialworks
+SPDX-License-Identifier: CC-BY-SA 4.0 Intl
\ No newline at end of file
diff --git a/assets/themes/narrowboat/license_info.json b/assets/themes/narrowboat/license_info.json
new file mode 100644
index 0000000000..19fcd14e8c
--- /dev/null
+++ b/assets/themes/narrowboat/license_info.json
@@ -0,0 +1,12 @@
+[
+ {
+ "path": "boat.svg",
+ "license": "CC-BY-SA 4.0 Intl",
+ "authors": [
+ "Officialworks"
+ ],
+ "sources": [
+ "https://commons.wikimedia.org/wiki/File:SL_Boat_Symbol.svg"
+ ]
+ }
+]
\ No newline at end of file
diff --git a/assets/themes/narrowboat/narrowboat.json b/assets/themes/narrowboat/narrowboat.json
index 97d477c5c8..06622911cb 100644
--- a/assets/themes/narrowboat/narrowboat.json
+++ b/assets/themes/narrowboat/narrowboat.json
@@ -6,7 +6,7 @@
"description": {
"en": "Features of interest to narrowboats and similar cruisers on inland waterways. "
},
- "icon": "./assets/layers/waterway_lock/waterway_lock.svg",
+ "icon": "./assets/themes/narrowboat/boat.svg",
"startZoom": 5,
"startLat": 54.44,
"startLon": -5.23,
@@ -14,6 +14,9 @@
"waterway_lock",
"waterway",
"lock_outline",
+ "marinas",
+ "chandler",
+ "piers_and_quays",
{
"builtin": [
"drinking_water",
@@ -26,12 +29,9 @@
}
],
"#layers": [
- "https://studio.mapcomplete.org/89098/layers/waterway_locks/waterway_locks.json",
"https://studio.mapcomplete.org/89098/layers/waterway_sanitary_dump_station/waterway_sanitary_dump_station.json",
"https://studio.mapcomplete.org/89098/layers/fuel_dock/fuel_dock.json",
"https://studio.mapcomplete.org/89098/layers/water_point/water_point.json",
- "https://studio.mapcomplete.org/89098/layers/winding_holes/winding_holes.json",
- "https://studio.mapcomplete.org/89098/layers/marinas/marinas.json",
- "https://studio.mapcomplete.org/89098/layers/chandler/chandler.json"
+ "https://studio.mapcomplete.org/89098/layers/winding_holes/winding_holes.json"
]
}
diff --git a/src/Logic/DetermineLayout.ts b/src/Logic/DetermineLayout.ts
index 0225b16b92..1fc9dbdbc9 100644
--- a/src/Logic/DetermineLayout.ts
+++ b/src/Logic/DetermineLayout.ts
@@ -181,7 +181,7 @@ export default class DetermineLayout {
// We got fed a layer instead of a theme
const layerConfig = json
let icon = Utils.NoNull(
- layerConfig.pointRendering
+ (layerConfig.pointRendering ?? [])
.flatMap((pr) => pr.marker)
.map((iconSpec) => {
if (!iconSpec) {