From 25e6a8f72fb32373ef8144ab05bc604bb07873b4 Mon Sep 17 00:00:00 2001 From: Alexander Zinchuk Date: Mon, 4 Sep 2023 04:05:47 +0200 Subject: [PATCH] Message / Custom Emoji: Fix ignoring heavy animation --- src/components/mediaViewer/MediaViewer.tsx | 2 +- src/components/middle/message/AnimatedCustomEmoji.tsx | 2 +- src/components/story/StoryViewer.tsx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/mediaViewer/MediaViewer.tsx b/src/components/mediaViewer/MediaViewer.tsx index f65a48cde..7896d32ce 100644 --- a/src/components/mediaViewer/MediaViewer.tsx +++ b/src/components/mediaViewer/MediaViewer.tsx @@ -73,7 +73,7 @@ type StateProps = { shouldSkipHistoryAnimations?: boolean; }; -const ANIMATION_DURATION = 350; +const ANIMATION_DURATION = 250; const MediaViewer: FC = ({ chatId, diff --git a/src/components/middle/message/AnimatedCustomEmoji.tsx b/src/components/middle/message/AnimatedCustomEmoji.tsx index 506662657..4e33f5537 100644 --- a/src/components/middle/message/AnimatedCustomEmoji.tsx +++ b/src/components/middle/message/AnimatedCustomEmoji.tsx @@ -69,7 +69,7 @@ const AnimatedCustomEmoji: FC = ({ isBig noPlay={noPlay} withSharedAnimation - forceOnHeavyAnimation + forceOnHeavyAnimation={Boolean(effect && activeEmojiInteractions?.length)} observeIntersectionForLoading={observeIntersection} onClick={handleClick} /> diff --git a/src/components/story/StoryViewer.tsx b/src/components/story/StoryViewer.tsx index aa9244368..4cd5959e9 100644 --- a/src/components/story/StoryViewer.tsx +++ b/src/components/story/StoryViewer.tsx @@ -37,7 +37,7 @@ import StorySettings from './StorySettings'; import styles from './StoryViewer.module.scss'; -const ANIMATION_DURATION = 350; +const ANIMATION_DURATION = 250; interface StateProps { isOpen: boolean;