diff --git a/js/id/ui/raw_membership_editor.js b/js/id/ui/raw_membership_editor.js index 2ca442552e..84881980e8 100644 --- a/js/id/ui/raw_membership_editor.js +++ b/js/id/ui/raw_membership_editor.js @@ -1,9 +1,22 @@ iD.ui.RawMembershipEditor = function(context) { - var id, showBlank; + var id, showBlank, MemElement; function selectRelation(d) { d3.event.preventDefault(); context.enter(iD.modes.Select(context, [d.relation.id])); + + d.relation.members.forEach(function(member) { + if (member.type === 'way') { + MemElement = document.getElementsByClassName(member.id + ' ' + member.type + ' shadow'); + } + else if (member.type === 'node') { + MemElement = document.getElementsByClassName(member.id + ' ' + member.type); + } + else { + return; + } + MemElement[0].classList.add('selected'); + }); } function changeRole(d) {