Merge pull request #71 from Simple2B/kostia/fix/fix_quicksearch

fixed
This commit is contained in:
Костя Столярский 2023-05-25 17:58:20 +03:00 committed by GitHub
commit 4736cb5ee9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 4 deletions

File diff suppressed because one or more lines are too long

View File

@ -8,6 +8,7 @@ const searchDiv: HTMLElement = document.querySelector('#quickSearchModal');
const modalOptions: ModalOptions = {
closable: true,
backdrop: 'static',
onHide: () => {},
onShow: () => {},
onToggle: () => {},
@ -18,9 +19,6 @@ const quickSearchModal: ModalInterface = new Modal(searchDiv, modalOptions);
export function quickSearch() {
if (currentSearchInput && searchDiv) {
currentSearchInput.addEventListener('input', debounce(onInputChange, 500));
currentSearchInput.addEventListener('blur', () => {
quickSearchModal.hide();
});
currentSearchInput.addEventListener('keypress', async e => {
if (e.key === 'Enter') {
const urlParams = new URLSearchParams({