If combobox is open, clicking on carat should close it

This commit is contained in:
Bryan Housel
2014-07-21 14:32:10 -04:00
parent 82c09ab454
commit f8a99d03e2

View File

@@ -44,8 +44,12 @@ d3.combobox = function() {
// on mousedown
d3.event.stopPropagation();
d3.event.preventDefault();
input.node().focus();
fetch('', render);
if (!shown) {
input.node().focus();
fetch('', render);
} else {
hide();
}
});
});