Fix group reactions and tag filtering

This commit is contained in:
Isaac
2024-02-07 23:08:10 +04:00
parent 714bcf7af3
commit 3fe8232c6e
14 changed files with 41 additions and 25 deletions

View File

@@ -59,7 +59,7 @@ public class ChatMessageContactBubbleContentNode: ChatMessageBubbleContentNode {
guard let strongSelf = self, let item = strongSelf.item else {
return
}
item.controllerInteraction.updateMessageReaction(item.message, .reaction(value), false, sourceView)
item.controllerInteraction.updateMessageReaction(item.topMessage, .reaction(value), false, sourceView)
}
self.dateAndStatusNode.openReactionPreview = { [weak self] gesture, sourceView, value in
@@ -290,11 +290,11 @@ public class ChatMessageContactBubbleContentNode: ChatMessageBubbleContentNode {
reactions: dateReactionsAndPeers.reactions,
reactionPeers: dateReactionsAndPeers.peers,
displayAllReactionPeers: item.message.id.peerId.namespace == Namespaces.Peer.CloudUser,
areReactionsTags: item.message.areReactionsTags(accountPeerId: item.context.account.peerId),
areReactionsTags: item.topMessage.areReactionsTags(accountPeerId: item.context.account.peerId),
replyCount: dateReplies,
isPinned: item.message.tags.contains(.pinned) && !item.associatedData.isInPinnedListMode && isReplyThread,
hasAutoremove: item.message.isSelfExpiring,
canViewReactionList: canViewMessageReactionList(message: item.message, isInline: item.associatedData.isInline),
canViewReactionList: canViewMessageReactionList(message: item.topMessage, isInline: item.associatedData.isInline),
animationCache: item.controllerInteraction.presentationContext.animationCache,
animationRenderer: item.controllerInteraction.presentationContext.animationRenderer
))