Fix up tag reference transition

This commit is contained in:
John Firebaugh
2013-03-26 11:50:00 -07:00
parent ad49e884ab
commit 29eddc15eb

View File

@@ -150,24 +150,23 @@ iD.ui.preset = function(context, entity, preset) {
.each(function(field) {
if (field.showingReference) {
d3.select(this)
.call(iD.ui.TagReference(entity, {key: field.key}))
.style('max-height', '0px')
.style('padding-top', '0px')
.style('opacity', '0')
.transition()
.duration(200)
.style('padding-top', '20px')
.style('max-height', '200px')
.style('opacity', '1');
} else {
d3.select(this)
.call(iD.ui.TagReference(entity, {key: field.key}))
.transition()
.duration(200)
.style('max-height', '0px')
.style('padding-top', '0px')
.style('opacity', '0');
}
.call(iD.ui.TagReference(entity, {key: field.key}))
.style('max-height', '0px')
.style('padding-top', '0px')
.style('opacity', '0')
.transition()
.duration(200)
.style('padding-top', '20px')
.style('max-height', '200px')
.style('opacity', '1');
} else {
d3.select(this)
.transition()
.duration(200)
.style('max-height', '0px')
.style('padding-top', '0px')
.style('opacity', '0');
}
});
selection.exit()