diff --git a/www/form/inner.js b/www/form/inner.js index 5b6e7eb14..7c2b220f9 100644 --- a/www/form/inner.js +++ b/www/form/inner.js @@ -365,7 +365,7 @@ define([ }); if (!v.type || v.type === "text") { - $input.keyup(function (e) { + $input.keydown(function (e) { try { if (e.which === 13) { var $line = $input.closest('.cp-form-edit-block-input'); @@ -572,7 +572,8 @@ define([ } // "Add option" button handler - $add = $(add).click(function () { + $add = $(add); + Util.onClickEnter($add, function () { var txt = v.type ? '' : Messages.form_newOption; var el = getOption(txt, true, false, Util.uid()); $add.before(el);