forked from MapComplete/MapComplete
commit
fb311b9d56
14 changed files with 1210 additions and 6 deletions
12
assets/layers/shelter/license_info.json
Normal file
12
assets/layers/shelter/license_info.json
Normal file
|
@ -0,0 +1,12 @@
|
|||
[
|
||||
{
|
||||
"path": "shelter.svg",
|
||||
"license": "MIT",
|
||||
"authors": [
|
||||
"Diemen Design"
|
||||
],
|
||||
"sources": [
|
||||
"https://icon-icons.com/icon/map-shelter/158301"
|
||||
]
|
||||
}
|
||||
]
|
88
assets/layers/shelter/shelter.json
Normal file
88
assets/layers/shelter/shelter.json
Normal file
|
@ -0,0 +1,88 @@
|
|||
{
|
||||
"id": "shelter",
|
||||
"name": {
|
||||
"en": "Shelter"
|
||||
},
|
||||
"description": {
|
||||
"en": "Layer showing shelter structures"
|
||||
},
|
||||
"source": {
|
||||
"osmTags": {
|
||||
"and": [
|
||||
"amenity=shelter"
|
||||
]
|
||||
}
|
||||
},
|
||||
"minzoom": 13,
|
||||
"title": {
|
||||
"render": {
|
||||
"en": "Shelter"
|
||||
}
|
||||
},
|
||||
"mapRendering": [
|
||||
{
|
||||
"location": [
|
||||
"point",
|
||||
"centroid"
|
||||
],
|
||||
"icon": "./assets/layers/shelter/shelter.svg"
|
||||
}
|
||||
],
|
||||
"tagRenderings": [
|
||||
{
|
||||
"id": "shelter-type",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "shelter_type=public_transport",
|
||||
"then": {
|
||||
"en": "This is a shelter at a public transport stop."
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=picnic_shelter",
|
||||
"then": {
|
||||
"en": "This is a shelter protecting from rain at a picnic site."
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=gazebo",
|
||||
"then": {
|
||||
"en": "This is a gazebo."
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=weather_shelter",
|
||||
"then": {
|
||||
"en": "This is a small shelter, primarily intended for short breaks. Usually found in the mountains or alongside roads."
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=lean_to",
|
||||
"then": {
|
||||
"en": "This is a shed with 3 walls, primarily intended for camping."
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=pavilion",
|
||||
"then": {
|
||||
"en": "This is a pavilion"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter_type=basic_hut",
|
||||
"then": "This is a basic hut, providing basic shelter and sleeping facilities."
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "What kind of shelter is this?"
|
||||
},
|
||||
"render": {
|
||||
"en": "Shelter type: {shelter_type}"
|
||||
},
|
||||
"freeform": {
|
||||
"key": "shelter_type",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
1
assets/layers/shelter/shelter.svg
Normal file
1
assets/layers/shelter/shelter.svg
Normal file
|
@ -0,0 +1 @@
|
|||
<svg role="img" focusable="false" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 14 14"><path d="M 4.4352679,0.99999571 3.578125,2.7143027 l 0.4017857,0 0.8973214,-1.71430699 -0.4419642,0 z m 3.4285714,0 -0.8571429,1.71430699 0.4017857,0 0.8973215,-1.71430699 -0.4419643,0 z m 3.4285707,0 -0.857143,1.71430699 0.401786,0 0.897322,-1.71430699 -0.441965,0 z M 1.8571429,2.7143027 1,4.4286098 l 0.4017857,0 0.8989955,-1.7143071 -0.4436383,0 z m 3.4352678,0 -0.8571428,1.7143071 0.4017857,0 0.8973214,-1.7143071 -0.4419643,0 z m 3.4285714,0 -0.8571428,1.7143071 0.4017857,0 0.8973214,-1.7143071 -0.4419643,0 z m 3.4285709,0 -0.857143,1.7143071 0.401786,0 0.897322,-1.7143071 -0.441965,0 z m -9.0066959,1.7143071 -0.8571428,1.714307 0.4017857,0 0.8989955,-1.714307 -0.4436384,0 z m 6.842076,0 -0.8571429,1.714307 0.4017857,0 0.8989951,-1.714307 -0.4436379,0 z M 7,5.2857633 l -6,3.428614 1.7142857,0 0.8571429,-0.3431962 0,4.1853199 0,0.01507 a 0.42857143,0.42857675 0 0 0 0.2059152,0.366634 0.42857143,0.42857675 0 0 0 0.4319196,0.0067 0.42857143,0.42857675 0 0 0 0.219308,-0.373322 l 0,-4.5435832 L 7,7.0000703 l 2.5714286,1.0279145 0,4.5435832 a 0.42857143,0.42857675 0 0 0 0.2059148,0.366634 0.42857143,0.42857675 0 0 0 0.4319206,0.0067 0.42857143,0.42857675 0 0 0 0.219307,-0.37332 l 0,-4.2003869 0.857143,0.3431962 1.714286,0 -6,-3.428614 z"/></svg>
|
After Width: | Height: | Size: 1.3 KiB |
141
assets/layers/transit_routes/transit_routes.json
Normal file
141
assets/layers/transit_routes/transit_routes.json
Normal file
|
@ -0,0 +1,141 @@
|
|||
{
|
||||
"id": "transit_routes",
|
||||
"name": {
|
||||
"en": "Bus lines"
|
||||
},
|
||||
"description": {
|
||||
"en": "Layer showing bus lines"
|
||||
},
|
||||
"source": {
|
||||
"osmTags": {
|
||||
"and": [
|
||||
"type=route",
|
||||
"route=bus"
|
||||
]
|
||||
}
|
||||
},
|
||||
"minzoom": 15,
|
||||
"title": {
|
||||
"render": {
|
||||
"en": "Bus line"
|
||||
},
|
||||
"mappings": [
|
||||
{
|
||||
"if": "name~*",
|
||||
"then": {
|
||||
"en": "{name}"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"mapRendering": [
|
||||
{
|
||||
"color": {
|
||||
"render": {
|
||||
"en": "#ff0000"
|
||||
},
|
||||
"mappings": [
|
||||
{
|
||||
"if": "colour~*",
|
||||
"then": "{colour}"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"tagRenderings": [
|
||||
{
|
||||
"id": "name",
|
||||
"freeform": {
|
||||
"key": "name",
|
||||
"type": "string",
|
||||
"placeholder": "Bus XX: From => Via => To"
|
||||
},
|
||||
"render": "{name}",
|
||||
"question": {
|
||||
"en": "What is the name for this bus line? (i.e. Bus XX: From => Via => To)"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "from",
|
||||
"freeform": {
|
||||
"key": "from",
|
||||
"type": "string",
|
||||
"placeholder": "City, Stop Name"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line begins at {from}"
|
||||
},
|
||||
"question": {
|
||||
"en": "What is the starting point for this bus line?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "via",
|
||||
"freeform": {
|
||||
"key": "via",
|
||||
"type": "string",
|
||||
"placeholder": "City, Stop Name"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line goes via {via}"
|
||||
},
|
||||
"question": {
|
||||
"en": "What is the via point for this bus line?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "to",
|
||||
"freeform": {
|
||||
"key": "to",
|
||||
"type": "string",
|
||||
"placeholder": "City, Stop Name"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line ends at {to}"
|
||||
},
|
||||
"question": {
|
||||
"en": "What is the ending point for this bus line?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "colour",
|
||||
"freeform": {
|
||||
"key": "colour",
|
||||
"type": "color"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line has the color {colour}"
|
||||
},
|
||||
"question": {
|
||||
"en": "What is the colour for this bus line?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "network",
|
||||
"freeform": {
|
||||
"key": "network",
|
||||
"type": "string"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line is part of the {network} network"
|
||||
},
|
||||
"question": {
|
||||
"en": "What network does this bus line belong to?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "operator",
|
||||
"freeform": {
|
||||
"key": "operator",
|
||||
"type": "string"
|
||||
},
|
||||
"render": {
|
||||
"en": "This bus line is operated by {operator}"
|
||||
},
|
||||
"question": {
|
||||
"en": "What company operates this bus line?"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
55
assets/layers/transit_stops/bus_stop.svg
Normal file
55
assets/layers/transit_stops/bus_stop.svg
Normal file
|
@ -0,0 +1,55 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="500"
|
||||
height="500"
|
||||
viewBox="0 0 500 500"
|
||||
version="1.1"
|
||||
id="svg4"
|
||||
sodipodi:docname="bus_stop.svg"
|
||||
inkscape:version="1.0.1 (3bc2e813f5, 2020-09-07)">
|
||||
<metadata
|
||||
id="metadata10">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<defs
|
||||
id="defs8" />
|
||||
<sodipodi:namedview
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1"
|
||||
objecttolerance="10"
|
||||
gridtolerance="10"
|
||||
guidetolerance="10"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1017"
|
||||
id="namedview6"
|
||||
showgrid="false"
|
||||
inkscape:zoom="25.986174"
|
||||
inkscape:cx="-2.629287"
|
||||
inkscape:cy="10.208516"
|
||||
inkscape:window-x="-8"
|
||||
inkscape:window-y="-8"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg4" />
|
||||
<path
|
||||
d="M 100,0 50,50 v 400 h 32.8125 c 0,0 5.057445,50 40.6375,50 34.45648,0 39.05,-50 39.05,-50 h 175 c 0,0 5.7171,50 39.05,50 40.82343,0 40.6375,-50 40.6375,-50 H 450 V 50 L 400,0 Z m 50,50 h 200 v 50 H 150 Z M 100,150 H 400 V 300 H 100 Z m 0,200 h 50 v 50 h -50 z m 250,0 h 50 v 50 h -50 z"
|
||||
id="path2"
|
||||
style="stroke-width:50" />
|
||||
</svg>
|
After Width: | Height: | Size: 1.8 KiB |
15
assets/layers/transit_stops/license_info.json
Normal file
15
assets/layers/transit_stops/license_info.json
Normal file
|
@ -0,0 +1,15 @@
|
|||
[
|
||||
{
|
||||
"path": "bus_stop.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Andy Allan",
|
||||
"Michael Glanznig",
|
||||
"Paul Norman",
|
||||
"Paul Dicker"
|
||||
],
|
||||
"sources": [
|
||||
"https://github.com/gravitystorm/openstreetmap-carto/blob/master/symbols/highway/bus_stop.svg"
|
||||
]
|
||||
}
|
||||
]
|
260
assets/layers/transit_stops/transit_stops.json
Normal file
260
assets/layers/transit_stops/transit_stops.json
Normal file
|
@ -0,0 +1,260 @@
|
|||
{
|
||||
"id": "transit_stops",
|
||||
"name": {
|
||||
"en": "Transit Stops"
|
||||
},
|
||||
"description": {
|
||||
"en": "Layer showing different types of transit stops."
|
||||
},
|
||||
"source": {
|
||||
"osmTags": {
|
||||
"or": [
|
||||
"highway=bus_stop"
|
||||
]
|
||||
}
|
||||
},
|
||||
"minzoom": 15,
|
||||
"title": {
|
||||
"render": {
|
||||
"en": "Transit Stop"
|
||||
},
|
||||
"mappings": [
|
||||
{
|
||||
"if": "name~*",
|
||||
"then": {
|
||||
"en": "Stop {name}"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"mapRendering": [
|
||||
{
|
||||
"location": [
|
||||
"point",
|
||||
"centroid"
|
||||
],
|
||||
"icon": {
|
||||
"render": "./assets/layers/transit_stops/bus_stop.svg",
|
||||
"mappings": []
|
||||
},
|
||||
"label": "<div style=\"background: white; display: block\">{name}</div>"
|
||||
}
|
||||
],
|
||||
"calculatedTags": [
|
||||
"_routes=feat.memberships()",
|
||||
"_contained_routes_properties=feat.memberships().map(p => {return {id: p.relation.id, name: p.relation.properties.name} }).filter((v,i,a)=>a.findIndex(t=>(JSON.stringify(t) === JSON.stringify(v)))===i)",
|
||||
"_contained_route_ids=JSON.parse(feat.properties._contained_routes_properties ?? '[]').map(p => p.id)",
|
||||
"_contained_routes=JSON.parse(feat.properties._contained_routes_properties ?? '[]').map(p => `<li><a href='#relation/${p.id}'>${p.name ?? 'bus route'}</a></li>`).join('')",
|
||||
"_contained_routes_count=JSON.parse(feat.properties._contained_routes_properties ?? '[]').length"
|
||||
],
|
||||
"tagRenderings": [
|
||||
{
|
||||
"id": "stop_name",
|
||||
"render": {
|
||||
"en": "This stop is called <b>{name}</b>"
|
||||
},
|
||||
"freeform": {
|
||||
"key": "name",
|
||||
"type": "string",
|
||||
"addExtraTags": [
|
||||
"noname="
|
||||
],
|
||||
"placeholder": {
|
||||
"en": "Name of the stop"
|
||||
}
|
||||
},
|
||||
"mappings": [
|
||||
{
|
||||
"if": {
|
||||
"and": [
|
||||
"noname=yes",
|
||||
"name="
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"en": "This stop has no name"
|
||||
}
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "What is the name of this stop?"
|
||||
},
|
||||
"placeholder": "Name of the stop"
|
||||
},
|
||||
"images",
|
||||
{
|
||||
"id": "shelter",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "shelter=yes",
|
||||
"then": {
|
||||
"en": "This stop has a shelter"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter=no",
|
||||
"then": {
|
||||
"en": "This stop does not have a shelter"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "shelter=separate",
|
||||
"then": {
|
||||
"en": "This stop has a shelter, that's separately mapped"
|
||||
},
|
||||
"hideInAnswer": true
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "Does this stop have a shelter?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "bench",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "bench=yes",
|
||||
"then": {
|
||||
"en": "This stop has a bench"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "bench=no",
|
||||
"then": {
|
||||
"en": "This stop does not have a bench"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "bench=separate",
|
||||
"then": {
|
||||
"en": "This stop has a bench, that's separately mapped"
|
||||
},
|
||||
"hideInAnswer": true
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "Does this stop have a bench?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "bin",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "bin=yes",
|
||||
"then": {
|
||||
"en": "This stop has a bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "bin=no",
|
||||
"then": {
|
||||
"en": "This stop does not have a bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "bin=separate",
|
||||
"then": {
|
||||
"en": "This stop has a bin, that's separately mapped"
|
||||
},
|
||||
"hideInAnswer": true
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "Does this stop have a bin?"
|
||||
}
|
||||
},
|
||||
"wheelchair-access",
|
||||
{
|
||||
"id": "tactile_paving",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "tactile_paving=yes",
|
||||
"then": {
|
||||
"en": "This stop has tactile paving"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "tactile_paving=no",
|
||||
"then": {
|
||||
"en": "This stop does not have tactile paving"
|
||||
}
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "Does this stop have tactile paving?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "lit",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "lit=yes",
|
||||
"then": {
|
||||
"en": "This stop is lit"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "lit=no",
|
||||
"then": {
|
||||
"en": "This stop is not lit"
|
||||
}
|
||||
}
|
||||
],
|
||||
"question": {
|
||||
"en": "Is this stop lit?"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "departures_board",
|
||||
"mappings": [
|
||||
{
|
||||
"if": "departures_board=yes",
|
||||
"then": {
|
||||
"en": "This stop has a departures board of unknown type"
|
||||
},
|
||||
"hideInAnswer": true
|
||||
},
|
||||
{
|
||||
"if": "departures_board=realtime",
|
||||
"then": {
|
||||
"en": "This stop has a board showing realtime departure information"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "passenger_information_display=yes",
|
||||
"then": {
|
||||
"en": "This stop has a board showing realtime departure information"
|
||||
},
|
||||
"hideInAnswer": true
|
||||
},
|
||||
{
|
||||
"if": "departures_board=timetable",
|
||||
"then": {
|
||||
"en": "This stop has a timetable showing regular departures"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "departures_board=interval",
|
||||
"then": {
|
||||
"en": "This stop has a timetable containing just the interval between departures"
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": "departures_board=no",
|
||||
"then": {
|
||||
"en": "This stop does not have a departures board"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"render": {
|
||||
"en": "<h3>{_contained_routes_count} routes stop at this stop</h3> <ul>{_contained_routes}</ul>"
|
||||
},
|
||||
"condition": "_contained_routes~*",
|
||||
"id": "contained_routes"
|
||||
}
|
||||
],
|
||||
"filter": [],
|
||||
"allowMove": false
|
||||
}
|
|
@ -311,6 +311,10 @@
|
|||
"if": "theme=toilets",
|
||||
"then": "./assets/themes/toilets/toilets.svg"
|
||||
},
|
||||
{
|
||||
"if": "theme=transit",
|
||||
"then": "./assets/layers/transit_stops/bus_stop.svg"
|
||||
},
|
||||
{
|
||||
"if": "theme=trees",
|
||||
"then": "./assets/themes/trees/logo.svg"
|
||||
|
|
51
assets/themes/transit/transit.json
Normal file
51
assets/themes/transit/transit.json
Normal file
|
@ -0,0 +1,51 @@
|
|||
{
|
||||
"id": "transit",
|
||||
"maintainer": "Robin van der Linde",
|
||||
"version": "20220406",
|
||||
"title": {
|
||||
"en": "Bus routes"
|
||||
},
|
||||
"description": {
|
||||
"en": "Plan your trip with the help of the public transport system."
|
||||
},
|
||||
"icon": "./assets/layers/transit_stops/bus_stop.svg",
|
||||
"startZoom": 20,
|
||||
"startLat": 53.21333,
|
||||
"startLon": 6.56963,
|
||||
"layers": [
|
||||
"transit_stops",
|
||||
"transit_routes",
|
||||
{
|
||||
"builtin": "bike_parking",
|
||||
"override": {
|
||||
"minzoom": 19,
|
||||
"minzoomVisible": 19
|
||||
}
|
||||
},
|
||||
{
|
||||
"builtin": "parking",
|
||||
"override": {
|
||||
"minzoom": 19,
|
||||
"minzoomVisible": 19
|
||||
}
|
||||
},
|
||||
{
|
||||
"builtin": "shelter",
|
||||
"override": {
|
||||
"minzoom": 19,
|
||||
"minzoomVisible": 19,
|
||||
"source": {
|
||||
"osmTags": {
|
||||
"and": [
|
||||
"amenity=shelter",
|
||||
"shelter_type=public_transport"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"hideTagRenderingsWithLabels": [
|
||||
"shelter-type"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue