Add a fade in out animation when the server process

This commit is contained in:
Kerollmops 2020-07-12 11:34:48 +02:00
parent 92c2b1dd2d
commit 54afec58a3
No known key found for this signature in database
GPG key ID: 92ADA4E935E71FA4
2 changed files with 12 additions and 0 deletions

View file

@ -16,6 +16,7 @@ $('#search').on('input', function () {
let numberOfDocuments = httpResults.data.length;
count.innerHTML = `${numberOfDocuments}`;
time.innerHTML = `${timeSpent}ms`;
time.classList.remove('fade-in-out');
for (element of httpResults.data) {
const elem = document.createElement('li');
@ -49,6 +50,7 @@ $('#search').on('input', function () {
beforeSend: function () {
if (request !== null) {
request.abort();
time.classList.add('fade-in-out');
}
},
});