[DE PE embed] Fix bug 58292

This commit is contained in:
JuliaSvinareva 2022-09-12 14:26:27 +03:00 committed by Ilya Kirillov
parent 05889fe8f2
commit 33a05836db
4 changed files with 14 additions and 2 deletions

View file

@ -117,7 +117,11 @@
if ((new Date()) - _lastInputChange < 400) return;
_state.searchText = _state.newSearchText;
(_state.newSearchText !== '') && onQuerySearch();
if (_state.newSearchText !== '') {
onQuerySearch();
} else {
api.asc_endFindText();
}
clearInterval(_searchTimer);
_searchTimer = undefined;
}, 10);

View file

@ -154,6 +154,8 @@ define([
me._state.searchText = me._state.newSearchText;
if (!(me._state.newSearchText !== '' && me.onQuerySearch()) && me._state.newSearchText === '') {
me.api.asc_endFindText();
me.hideResults();
me.view.updateResultsNumber('no-results');
me.view.disableNavButtons();
me.view.disableReplaceButtons(true);

View file

@ -115,7 +115,11 @@
if ((new Date()) - _lastInputChange < 400) return;
_state.searchText = _state.newSearchText;
(_state.newSearchText !== '') && onQuerySearch();
if (_state.newSearchText !== '') {
onQuerySearch();
} else {
api.asc_endFindText();
}
clearInterval(_searchTimer);
_searchTimer = undefined;
}, 10);

View file

@ -151,6 +151,8 @@ define([
me._state.searchText = me._state.newSearchText;
if (!(me._state.newSearchText !== '' && me.onQuerySearch()) && me._state.newSearchText === '') {
me.api.asc_endFindText();
me.hideResults();
me.view.updateResultsNumber('no-results');
me.view.disableNavButtons();
me.view.disableReplaceButtons(true);