more work on tag reference.

This commit is contained in:
saman bb
2013-03-25 19:16:58 -04:00
parent 22463ea785
commit f6d1abf2bf
4 changed files with 8 additions and 5 deletions

View File

@@ -2222,10 +2222,8 @@ a.success-action.twitter:before {
}
::-webkit-scrollbar-track:hover {
background-color: rgba(0,0,0,.05);
box-shadow: inset 1px 0 0 rgba(0,0,0,.1);
}
::-webkit-scrollbar-track:horizontal:hover {
box-shadow: inset 0 1px 0 rgba(0,0,0,.1)
}
::-webkit-scrollbar-track:active {
background-color: rgba(0,0,0,.05);

View File

@@ -89,7 +89,7 @@ iD.ui.preset = function(context, entity) {
});
label.append('button')
.attr('class', 'fr icon inspect')
.attr('class', 'tag-reference-button')
.attr('tabindex', -1)
.on('click', function(field) {
selection.selectAll('div.tag-help')
@@ -99,7 +99,9 @@ iD.ui.preset = function(context, entity) {
.select('div.tag-help')
.style('display', 'block')
.call(iD.ui.TagReference(entity, {key: field.key}));
});
})
.append('span')
.attr('class', 'icon inspect');
sections.transition()
.style('max-height', '0px')

View File

@@ -50,7 +50,7 @@ iD.ui.TagEditor = function(context, entity) {
.attr('class', 'tag-wrap inspector-body fillL2 inspector-body-' + geometry);
editorwrap.append('div')
.attr('class', 'col12 inspector-inner fillL2 preset-icon-wrap')
.attr('class', 'col12 inspector-inner preset-icon-wrap')
.append('div')
.attr('class','fillL')
.append('span')

View File

@@ -29,6 +29,8 @@ iD.ui.TagReference = function(entity, tag) {
return function(selection) {
selection.html('');
selection.attr('class','cf');
taginfo.docs(tag, function(err, docs) {
if (!err && docs) {
docs = findLocal(docs);
@@ -57,6 +59,7 @@ iD.ui.TagReference = function(entity, tag) {
.attr('target', '_blank')
.attr('href', 'http://wiki.openstreetmap.org/wiki/' + docs.title)
.text(t('inspector.reference'));
});
}
};