diff --git a/data/presets.yaml b/data/presets.yaml index 7db3bd310..cd0897488 100644 --- a/data/presets.yaml +++ b/data/presets.yaml @@ -2625,6 +2625,9 @@ en: name: Camp Pitch # 'terms: tent,rv' terms: '' + circular: + # junction=circular + name: Traffic Circle club: # club=* name: Club diff --git a/data/presets/presets.json b/data/presets/presets.json index f1f502404..dcebda370 100644 --- a/data/presets/presets.json +++ b/data/presets/presets.json @@ -52,6 +52,20 @@ "searchable": false, "name": "Amenity" }, + "circular": { + "geometry": [ + "vertex", + "line" + ], + "fields": [ + "name" + ], + "tags": { + "junction": "circular" + }, + "name": "Traffic Circle", + "searchable": false + }, "highway": { "fields": [ "name", diff --git a/data/presets/presets/_circular.json b/data/presets/presets/_circular.json new file mode 100644 index 000000000..19c6d911c --- /dev/null +++ b/data/presets/presets/_circular.json @@ -0,0 +1,14 @@ +{ + "geometry": [ + "vertex", + "line" + ], + "fields": [ + "name" + ], + "tags": { + "junction": "circular" + }, + "name": "Traffic Circle", + "searchable": false +} diff --git a/data/taginfo.json b/data/taginfo.json index 1553e1fc5..9d34fec62 100644 --- a/data/taginfo.json +++ b/data/taginfo.json @@ -21,6 +21,10 @@ { "key": "amenity" }, + { + "key": "junction", + "value": "circular" + }, { "key": "highway" }, diff --git a/dist/locales/en.json b/dist/locales/en.json index 0ad8b8474..cc3227962 100644 --- a/dist/locales/en.json +++ b/dist/locales/en.json @@ -2638,6 +2638,10 @@ "name": "Amenity", "terms": "" }, + "circular": { + "name": "Traffic Circle", + "terms": "" + }, "highway": { "name": "Highway", "terms": "" diff --git a/modules/osm/tags.js b/modules/osm/tags.js index 77905a201..1a66bdbd6 100644 --- a/modules/osm/tags.js +++ b/modules/osm/tags.js @@ -24,6 +24,7 @@ export var osmOneWayTags = { 'motorway_link': true }, 'junction': { + 'circular': true, 'roundabout': true }, 'man_made': { diff --git a/test/spec/osm/way.js b/test/spec/osm/way.js index 3881358e9..2460f5fc8 100644 --- a/test/spec/osm/way.js +++ b/test/spec/osm/way.js @@ -299,6 +299,7 @@ describe('iD.osmWay', function() { expect(iD.Way({tags: { highway: 'motorway' }}).isOneWay(), 'motorway').to.be.true; expect(iD.Way({tags: { highway: 'motorway_link' }}).isOneWay(), 'motorway_link').to.be.true; expect(iD.Way({tags: { junction: 'roundabout' }}).isOneWay(), 'roundabout').to.be.true; + expect(iD.Way({tags: { junction: 'circular' }}).isOneWay(), 'circular').to.be.true; }); it('returns false when the way does not have implied oneway tag', function() { @@ -320,6 +321,7 @@ describe('iD.osmWay', function() { it('returns false when oneway=no overrides implied oneway tag', function() { expect(iD.Way({tags: { junction: 'roundabout', oneway: 'no' }}).isOneWay(), 'roundabout').to.be.false; + expect(iD.Way({tags: { junction: 'circular', oneway: 'no' }}).isOneWay(), 'circular').to.be.false; expect(iD.Way({tags: { highway: 'motorway', oneway: 'no' }}).isOneWay(), 'motorway').to.be.false; }); });