diff --git a/data/presets/presets.json b/data/presets/presets.json index 13e4dc6e5..407d0418b 100644 --- a/data/presets/presets.json +++ b/data/presets/presets.json @@ -4245,9 +4245,6 @@ "tags": { "highway": "traffic_signals" }, - "fields": [ - "restrictions" - ], "terms": [ "light", "stoplight", diff --git a/data/presets/presets/highway/traffic_signals.json b/data/presets/presets/highway/traffic_signals.json index 7f3fd4157..62e5d60e8 100644 --- a/data/presets/presets/highway/traffic_signals.json +++ b/data/presets/presets/highway/traffic_signals.json @@ -5,9 +5,6 @@ "tags": { "highway": "traffic_signals" }, - "fields": [ - "restrictions" - ], "terms": [ "light", "stoplight", diff --git a/js/id/ui/inspector.js b/js/id/ui/inspector.js index 0f53ef62c..5c4bff46a 100644 --- a/js/id/ui/inspector.js +++ b/js/id/ui/inspector.js @@ -31,7 +31,12 @@ iD.ui.Inspector = function(context) { var $presetPane = $wrap.select('.preset-list-pane'); var $editorPane = $wrap.select('.entity-editor-pane'); - var showEditor = state === 'hover' || context.entity(entityID).isUsed(context.graph()); + var graph = context.graph(), + entity = context.entity(entityID), + showEditor = state === 'hover' || + entity.isUsed(graph) || + entity.isIntersection(graph); + if (showEditor) { $wrap.style('right', '0%'); $editorPane.call(entityEditor); diff --git a/js/id/ui/preset.js b/js/id/ui/preset.js index 99ae2ff54..de3f550b3 100644 --- a/js/id/ui/preset.js +++ b/js/id/ui/preset.js @@ -72,6 +72,10 @@ iD.ui.preset = function(context) { } }); + if (geometry === 'vertex' && entity.isIntersection(context.graph())) { + fields.push(UIField(context.presets().field('restrictions'), entity, true)); + } + context.presets().universal().forEach(function(field) { if (preset.fields.indexOf(field) < 0) { fields.push(UIField(field, entity)); @@ -177,7 +181,7 @@ iD.ui.preset = function(context) { function show(field) { field.show = true; - presets(selection); + context.presets()(selection); field.input.focus(); }