From 6e9db779cd1b9881e6038df8924a9161d8f707eb Mon Sep 17 00:00:00 2001 From: Alexander Skvortsov <38059171+askvortsov1@users.noreply.github.com> Date: Wed, 23 Sep 2020 23:04:56 -0400 Subject: [PATCH] Fix double fadein for post stream (#2300) --- js/src/forum/components/PostStream.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/js/src/forum/components/PostStream.js b/js/src/forum/components/PostStream.js index 99172efe9..afb6a2756 100644 --- a/js/src/forum/components/PostStream.js +++ b/js/src/forum/components/PostStream.js @@ -368,6 +368,10 @@ export default class PostStream extends Component { * @param {jQuery} $item */ flashItem($item) { - $item.addClass('flash').one('animationend webkitAnimationEnd', () => $item.removeClass('flash')); + $item.addClass('flash').on('animationend webkitAnimationEnd', (e) => { + if (e.animationName === 'fadeIn') { + $item.removeClass('flash'); + } + }); } }