We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8948aeb commit 3d5263fCopy full SHA for 3d5263f
1 file changed
src/components/MessageActions/defaults.tsx
@@ -316,7 +316,10 @@ const DefaultMessageActionComponents = {
316
const { client } = useChatContext();
317
const { message } = useMessageContext();
318
const { t } = useTranslationContext();
319
- const isBlocked = false; // !!client.blockedUsers[targetId]
+ const isBlocked =
320
+ !message.user?.id ||
321
+ new Set(client.blockedUsers.getLatestValue().userIds).has(message.user?.id);
322
+
323
return (
324
<ContextMenuButton
325
aria-label={isBlocked ? t('aria/Unblock User') : t('aria/Block User')}
0 commit comments