Commit fcf85fd0 authored by Tim Zallmann's avatar Tim Zallmann

Replaced last fadeTo in Commit history

parent 397f75b8
...@@ -31,7 +31,7 @@ export default class CommitsList { ...@@ -31,7 +31,7 @@ export default class CommitsList {
const search = this.searchField.val(); const search = this.searchField.val();
if (search === this.lastSearch) return Promise.resolve(); if (search === this.lastSearch) return Promise.resolve();
const commitsUrl = `${form.attr('action')}?${form.serialize()}`; const commitsUrl = `${form.attr('action')}?${form.serialize()}`;
this.content.fadeTo('fast', 0.5); this.content.addClass('gl-opacity-5');
const params = form.serializeArray().reduce( const params = form.serializeArray().reduce(
(acc, obj) => (acc, obj) =>
Object.assign(acc, { Object.assign(acc, {
...@@ -47,7 +47,7 @@ export default class CommitsList { ...@@ -47,7 +47,7 @@ export default class CommitsList {
.then(({ data }) => { .then(({ data }) => {
this.lastSearch = search; this.lastSearch = search;
this.content.html(data.html); this.content.html(data.html);
this.content.fadeTo('fast', 1.0); this.content.removeClass('gl-opacity-5');
// Change url so if user reload a page - search results are saved // Change url so if user reload a page - search results are saved
window.history.replaceState( window.history.replaceState(
...@@ -59,7 +59,7 @@ export default class CommitsList { ...@@ -59,7 +59,7 @@ export default class CommitsList {
); );
}) })
.catch(() => { .catch(() => {
this.content.fadeTo('fast', 1.0); this.content.removeClass('gl-opacity-5');
this.lastSearch = null; this.lastSearch = null;
}); });
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment