refactoring of legacy js events

This commit is contained in:
zadam
2019-11-09 17:45:22 +01:00
parent 31bcc037f1
commit 3a1c80c189
22 changed files with 34 additions and 31 deletions

View File

@@ -44,7 +44,7 @@ $dialog.on('shown.bs.modal', () => {
shownCb({ $dialog, $question, $answer, $form });
}
$answer.focus().select();
$answer.trigger('focus').select();
});
$dialog.on("hidden.bs.modal", () => {
@@ -53,7 +53,7 @@ $dialog.on("hidden.bs.modal", () => {
}
});
$form.submit(() => {
$form.on('submit', () => {
resolve($answer.val());
$dialog.modal('hide');