Do not show combobox if input has lost focus

This commit is contained in:
Yohan Boniface
2013-02-19 21:35:04 +01:00
parent 2b4cfe87d0
commit 6d1fa6b258

View File

@@ -187,7 +187,8 @@ d3.combobox = function() {
function render(data) {
if (data.length) show();
if (data.length &&
document.activeElement === input.node()) show();
else hide();
autocomplete(e, data);