Skip to content

Commit

Permalink
Merge pull request #5410 from castriganoj/AddToAndFromFieldsToRoutePr…
Browse files Browse the repository at this point in the history
…esets#5408

Add fields for To and From and add fields to all route presets.
  • Loading branch information
bhousel authored Oct 24, 2018
2 parents 2721a26 + 10dbbbe commit 8de0c8f
Show file tree
Hide file tree
Showing 23 changed files with 104 additions and 32 deletions.
6 changes: 6 additions & 0 deletions data/presets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -633,6 +633,9 @@ en:
frequency:
# frequency=*
label: Operating Frequency
from:
# from=*
label: From
fuel:
# fuel=*
label: Fuel
Expand Down Expand Up @@ -1800,6 +1803,9 @@ en:
'yes': 'Yes'
# takeaway field placeholder
placeholder: 'Yes, No, Takeaway Only...'
to:
# to =*
label: To
toilets/disposal:
# 'toilets:disposal=*'
label: Disposal
Expand Down
2 changes: 2 additions & 0 deletions data/presets/fields.json
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@
"flag/type": {"key": "flag:type", "type": "combo", "label": "Flag Type"},
"ford": {"key": "ford", "type": "typeCombo", "label": "Type", "placeholder": "Default"},
"frequency": {"key": "frequency", "type": "combo", "label": "Operating Frequency"},
"from": {"key": "from", "type": "text", "label": "From"},
"fuel_multi": {"key": "fuel:", "type": "multiCombo", "label": "Fuel Types"},
"fuel": {"key": "fuel", "type": "combo", "label": "Fuel"},
"gauge": {"key": "gauge", "type": "combo", "label": "Gauge"},
Expand Down Expand Up @@ -303,6 +304,7 @@
"switch": {"key": "switch", "type": "combo", "label": "Type", "strings": {"options": {"mechanical": "Mechanical", "circuit_breaker": "Circuit Breaker", "disconnector": "Disconnector", "earthing": "Earthing"}}},
"tactile_paving": {"key": "tactile_paving", "type": "check", "label": "Tactile Paving"},
"takeaway": {"key": "takeaway", "type": "combo", "label": "Takeaway", "placeholder": "Yes, No, Takeaway Only...", "strings": {"options": {"yes": "Yes", "no": "No", "only": "Takeaway Only"}}},
"to": {"key": "to ", "type": "text", "label": "To"},
"toilets/disposal": {"key": "toilets:disposal", "type": "combo", "label": "Disposal", "strings": {"options": {"flush": "Flush", "pitlatrine": "Pit/Latrine", "chemical": "Chemical", "bucket": "Bucket"}}},
"toll": {"key": "toll", "type": "check", "label": "Toll"},
"tomb": {"key": "tomb", "type": "typeCombo", "label": "Type"},
Expand Down
5 changes: 5 additions & 0 deletions data/presets/fields/from.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"key": "from",
"type": "text",
"label": "From"
}
5 changes: 5 additions & 0 deletions data/presets/fields/to.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"key": "to",
"type": "text",
"label": "To"
}
32 changes: 16 additions & 16 deletions data/presets/presets.json
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,7 @@
"railway/train_wash": {"icon": "maki-rail", "geometry": ["point", "vertex", "area"], "fields": ["operator", "building_area"], "tags": {"railway": "wash"}, "terms": ["wash", "clean"], "name": "Train Wash"},
"railway/tram": {"icon": "iD-railway-light-rail", "fields": ["name", "structure", "gauge", "electrified", "service_rail", "usage_rail", "voltage", "frequency"], "geometry": ["line"], "tags": {"railway": "tram"}, "terms": ["light rail", "streetcar", "tram", "trolley"], "name": "Tram"},
"relation": {"icon": "iD-relation", "fields": ["name", "relation"], "geometry": ["relation"], "tags": {}, "name": "Relation"},
"route/ferry": {"icon": "iD-ferry-line", "geometry": ["line"], "fields": ["name", "operator", "duration", "access"], "tags": {"route": "ferry"}, "name": "Ferry Route"},
"route/ferry": {"icon": "iD-ferry-line", "geometry": ["line"], "fields": ["name", "operator", "duration", "access", "to", "from"], "tags": {"route": "ferry"}, "name": "Ferry Route"},
"seamark/beacon_isolated_danger": {"fields": ["ref", "operator", "seamark/beacon_isolated_danger/shape"], "geometry": ["point", "vertex"], "terms": ["beacon isolated danger", "isolated danger beacon", "iala"], "tags": {"seamark:type": "beacon_isolated_danger"}, "name": "Danger Beacon"},
"seamark/beacon_lateral": {"fields": ["ref", "operator", "seamark/beacon_lateral/colour", "seamark/beacon_lateral/category", "seamark/beacon_lateral/shape", "seamark/beacon_lateral/system"], "geometry": ["point", "vertex"], "terms": ["lateral beacon", "beacon lateral", "cevni", "channel marker", "iala", "lateral mark"], "tags": {"seamark:type": "beacon_lateral"}, "name": "Channel Beacon"},
"seamark/buoy_lateral": {"fields": ["ref", "operator", "seamark/buoy_lateral/colour", "seamark/buoy_lateral/category", "seamark/buoy_lateral/shape", "seamark/buoy_lateral/system"], "geometry": ["point", "vertex"], "terms": ["lateral buoy", "buoy lateral", "cevni", "channel marker", "iala", "lateral mark"], "tags": {"seamark:type": "buoy_lateral"}, "name": "Channel Buoy"},
Expand Down Expand Up @@ -971,21 +971,21 @@
"type/restriction/only_u_turn": {"icon": "iD-restriction-only-u-turn", "fields": ["except"], "geometry": ["relation"], "tags": {"type": "restriction", "restriction": "only_u_turn"}, "name": "Only U-turn"},
"type/route_master": {"icon": "iD-route-master", "fields": ["name", "route_master", "ref", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route_master"}, "name": "Route Master"},
"type/route": {"icon": "iD-route", "fields": ["name", "route", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route"}, "name": "Route"},
"type/route/bicycle": {"icon": "iD-route-bicycle", "fields": ["name", "ref_route", "network_bicycle", "cycle_network"], "geometry": ["relation"], "tags": {"type": "route", "route": "bicycle"}, "name": "Cycle Route"},
"type/route/bus": {"icon": "iD-route-bus", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "bus"}, "name": "Bus Route"},
"type/route/detour": {"icon": "iD-route-detour", "fields": ["name", "ref_route"], "geometry": ["relation"], "tags": {"type": "route", "route": "detour"}, "name": "Detour Route"},
"type/route/ferry": {"icon": "iD-route-ferry", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "ferry"}, "name": "Ferry Route"},
"type/route/foot": {"icon": "iD-route-foot", "fields": ["name", "ref_route", "operator", "network_foot"], "geometry": ["relation"], "tags": {"type": "route", "route": "foot"}, "name": "Foot Route"},
"type/route/hiking": {"icon": "iD-route-foot", "fields": ["name", "ref_route", "operator", "network_foot", "description", "distance"], "geometry": ["relation"], "tags": {"type": "route", "route": "hiking"}, "name": "Hiking Route"},
"type/route/horse": {"icon": "iD-route-horse", "fields": ["name", "ref_route", "operator", "network_horse", "description", "distance"], "geometry": ["relation"], "tags": {"type": "route", "route": "horse"}, "name": "Riding Route"},
"type/route/light_rail": {"icon": "iD-route-light-rail", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "light_rail"}, "name": "Light Rail Route"},
"type/route/pipeline": {"icon": "iD-route-pipeline", "fields": ["name", "ref_route", "operator"], "geometry": ["relation"], "tags": {"type": "route", "route": "pipeline"}, "name": "Pipeline Route"},
"type/route/piste": {"icon": "iD-route-piste", "fields": ["name", "piste/type", "colour", "ref_route", "operator"], "geometry": ["relation"], "tags": {"type": "route", "route": "piste"}, "name": "Piste/Ski Route"},
"type/route/power": {"icon": "iD-route-power", "fields": ["name", "ref_route", "operator"], "geometry": ["relation"], "tags": {"type": "route", "route": "power"}, "name": "Power Route"},
"type/route/road": {"icon": "iD-route-road", "fields": ["name", "ref_route", "network_road"], "geometry": ["relation"], "tags": {"type": "route", "route": "road"}, "name": "Road Route"},
"type/route/subway": {"icon": "iD-route-subway", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "subway"}, "name": "Subway Route"},
"type/route/train": {"icon": "iD-route-train", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "train"}, "name": "Train Route"},
"type/route/tram": {"icon": "iD-route-tram", "fields": ["name", "ref_route", "operator", "network"], "geometry": ["relation"], "tags": {"type": "route", "route": "tram"}, "name": "Tram Route"},
"type/route/bicycle": {"icon": "iD-route-bicycle", "fields": ["name", "ref_route", "network_bicycle", "cycle_network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "bicycle"}, "name": "Cycle Route"},
"type/route/bus": {"icon": "iD-route-bus", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "bus"}, "name": "Bus Route"},
"type/route/detour": {"icon": "iD-route-detour", "fields": ["name", "ref_route", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "detour"}, "name": "Detour Route"},
"type/route/ferry": {"icon": "iD-route-ferry", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "ferry"}, "name": "Ferry Route"},
"type/route/foot": {"icon": "iD-route-foot", "fields": ["name", "ref_route", "operator", "network_foot", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "foot"}, "name": "Foot Route"},
"type/route/hiking": {"icon": "iD-route-foot", "fields": ["name", "ref_route", "operator", "network_foot", "description", "distance", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "hiking"}, "name": "Hiking Route"},
"type/route/horse": {"icon": "iD-route-horse", "fields": ["name", "ref_route", "operator", "network_horse", "description", "distance", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "horse"}, "name": "Riding Route"},
"type/route/light_rail": {"icon": "iD-route-light-rail", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "light_rail"}, "name": "Light Rail Route"},
"type/route/pipeline": {"icon": "iD-route-pipeline", "fields": ["name", "ref_route", "operator", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "pipeline"}, "name": "Pipeline Route"},
"type/route/piste": {"icon": "iD-route-piste", "fields": ["name", "piste/type", "colour", "ref_route", "operator", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "piste"}, "name": "Piste/Ski Route"},
"type/route/power": {"icon": "iD-route-power", "fields": ["name", "ref_route", "operator", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "power"}, "name": "Power Route"},
"type/route/road": {"icon": "iD-route-road", "fields": ["name", "ref_route", "network_road", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "road"}, "name": "Road Route"},
"type/route/subway": {"icon": "iD-route-subway", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "subway"}, "name": "Subway Route"},
"type/route/train": {"icon": "iD-route-train", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "train"}, "name": "Train Route"},
"type/route/tram": {"icon": "iD-route-tram", "fields": ["name", "ref_route", "operator", "network", "to", "from"], "geometry": ["relation"], "tags": {"type": "route", "route": "tram"}, "name": "Tram Route"},
"type/site": {"icon": "iD-relation", "fields": ["name", "site"], "geometry": ["relation"], "tags": {"type": "site"}, "name": "Site"},
"type/waterway": {"icon": "iD-route-water", "fields": ["name", "waterway", "ref"], "geometry": ["relation"], "tags": {"type": "waterway"}, "name": "Waterway"},
"vertex": {"fields": ["name"], "geometry": ["vertex"], "tags": {}, "name": "Other", "matchScore": 0.1},
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/route/ferry.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
"name",
"operator",
"duration",
"access"
"access",
"to",
"from"
],
"tags": {
"route": "ferry"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/bicycle.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"network_bicycle",
"cycle_network"
"cycle_network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/bus.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/detour.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
"icon": "iD-route-detour",
"fields": [
"name",
"ref_route"
"ref_route",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/ferry.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/foot.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network_foot"
"network_foot",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/hiking.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
"operator",
"network_foot",
"description",
"distance"
"distance",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/horse.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
"operator",
"network_horse",
"description",
"distance"
"distance",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/light_rail.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/pipeline.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
"fields": [
"name",
"ref_route",
"operator"
"operator",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/piste.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
"piste/type",
"colour",
"ref_route",
"operator"
"operator",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/power.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
"fields": [
"name",
"ref_route",
"operator"
"operator",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/road.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
"fields": [
"name",
"ref_route",
"network_road"
"network_road",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/subway.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/train.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
4 changes: 3 additions & 1 deletion data/presets/presets/type/route/tram.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"name",
"ref_route",
"operator",
"network"
"network",
"to",
"from"
],
"geometry": [
"relation"
Expand Down
2 changes: 2 additions & 0 deletions data/taginfo.json
Original file line number Diff line number Diff line change
Expand Up @@ -6860,6 +6860,7 @@
{"key": "flag:type", "description": "Flag Type"},
{"key": "ford", "description": "Type"},
{"key": "frequency", "description": "Operating Frequency"},
{"key": "from", "description": "From"},
{"key": "fuel:", "description": "Fuel Types"},
{"key": "fuel", "description": "Fuel"},
{"key": "gauge", "description": "Gauge"},
Expand Down Expand Up @@ -7493,6 +7494,7 @@
{"key": "takeaway", "value": "yes", "description": "Takeaway"},
{"key": "takeaway", "value": "no", "description": "Takeaway"},
{"key": "takeaway", "value": "only", "description": "Takeaway"},
{"key": "to ", "description": "To"},
{"key": "toilets:disposal", "value": "flush", "description": "Disposal"},
{
"key": "toilets:disposal",
Expand Down
20 changes: 20 additions & 0 deletions dist/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -2004,6 +2004,9 @@
"frequency": {
"label": "Operating Frequency"
},
"from": {
"label": "From"
},
"fuel_multi": {
"label": "Fuel Types"
},
Expand Down Expand Up @@ -2954,6 +2957,9 @@
"only": "Takeaway Only"
}
},
"to": {
"label": "To"
},
"toilets/disposal": {
"label": "Disposal",
"options": {
Expand Down Expand Up @@ -7412,6 +7418,13 @@
"description": "Japan GSI Standard Map. Widely covered.",
"name": "Japan GSI Standard Map"
},
"helsingborg-orto": {
"attribution": {
"text": "© Helsingborg municipality"
},
"description": "Orthophotos from the municipality of Helsingborg 2016, public domain",
"name": "Helsingborg Orthophoto"
},
"hike_n_bike": {
"attribution": {
"text": "© OpenStreetMap contributors"
Expand Down Expand Up @@ -7503,6 +7516,13 @@
},
"name": "Stamen Terrain"
},
"stockholm-orto": {
"attribution": {
"text": "© Stockholm municipality, CC0"
},
"description": "Orthophotos from the municipality of Stockholm 2015, CC0 license",
"name": "Stockholm Orthophoto"
},
"tf-cycle": {
"attribution": {
"text": "Maps © Thunderforest, Data © OpenStreetMap contributors"
Expand Down

0 comments on commit 8de0c8f

Please sign in to comment.