Improve entry search with a debouncer
Signed-off-by: Yohann D'ANELLO <ynerant@crans.org>
This commit is contained in:
parent
df3bb71357
commit
9628560d64
2 changed files with 10 additions and 5 deletions
|
|
@ -63,7 +63,12 @@ SPDX-License-Identifier: GPL-3.0-or-later
|
|||
refreshBalance();
|
||||
}
|
||||
|
||||
alias_obj.keyup(reloadTable);
|
||||
alias_obj.keyup(function(event) {
|
||||
let code = event.originalEvent.keyCode
|
||||
if (65 <= code <= 122 || code === 13) {
|
||||
debounce(reloadTable)()
|
||||
}
|
||||
});
|
||||
|
||||
$(document).ready(init);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue