From f13d0218d8d328398b5631a605609ab5048403e9 Mon Sep 17 00:00:00 2001 From: Alexander Zinchuk Date: Wed, 26 Apr 2023 21:15:22 +0400 Subject: [PATCH] Manage Topic: Fix default icon (#3083) --- src/components/common/StickerSet.tsx | 2 +- src/components/common/TopicIcon.tsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/common/StickerSet.tsx b/src/components/common/StickerSet.tsx index cd7f1e077..34ca285b7 100644 --- a/src/components/common/StickerSet.tsx +++ b/src/components/common/StickerSet.tsx @@ -291,7 +291,7 @@ const StickerSet: FC = ({ onClick={handleDefaultTopicIconClick} key="default-topic-icon" > - Reset + Reset )} {withDefaultStatusIcon && ( diff --git a/src/components/common/TopicIcon.tsx b/src/components/common/TopicIcon.tsx index 4c967512d..8ff0faefd 100644 --- a/src/components/common/TopicIcon.tsx +++ b/src/components/common/TopicIcon.tsx @@ -18,6 +18,7 @@ type OwnProps = { }; const LOOP_LIMIT = 2; +const DEFAULT_ICON_ID = '0'; const TopicIcon: FC = ({ topic, @@ -28,7 +29,7 @@ const TopicIcon: FC = ({ observeIntersection, onClick, }) => { - if (topic.iconEmojiId) { + if (topic.iconEmojiId && topic.iconEmojiId !== DEFAULT_ICON_ID) { return (