diff options
Diffstat (limited to 'modules/luci-base/htdocs')
-rw-r--r-- | modules/luci-base/htdocs/luci-static/resources/cbi.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/luci-base/htdocs/luci-static/resources/cbi.js b/modules/luci-base/htdocs/luci-static/resources/cbi.js index fcfc506942..e5acdbcd79 100644 --- a/modules/luci-base/htdocs/luci-static/resources/cbi.js +++ b/modules/luci-base/htdocs/luci-static/resources/cbi.js @@ -2062,8 +2062,12 @@ function cbi_dropdown_init(sb) { create.addEventListener('keydown', function(ev) { switch (ev.keyCode) { case 13: - sbox.createItems(sb, this.value); ev.preventDefault(); + + if (this.classList.contains('cbi-input-invalid')) + return; + + sbox.createItems(sb, this.value); this.value = ''; this.blur(); break; |