Various improvements

This commit is contained in:
Ilya Laktyushin 2026-04-22 23:03:51 +02:00
parent 1dd23f6641
commit dbd40fe7d3
76 changed files with 5186 additions and 2625 deletions

View file

@ -2189,6 +2189,30 @@ func contextMenuForChatPresentationInterfaceState(chatPresentationInterfaceState
c?.dismiss(completion: {
controllerInteraction.openPeer(peer, .default, MessageReference(message), hasReaction ? .reaction : .default)
})
},
deleteReaction: { [weak c] peer, _ in
c?.dismiss(completion: {
guard let chatController = interfaceInteraction.chatController() as? ChatControllerImpl, chatController.chatLocation.peerId?.namespace == Namespaces.Peer.CloudChannel else {
return
}
let _ = (context.sharedContext.chatAvailableMessageActions(
engine: context.engine,
accountPeerId: context.account.peerId,
messageIds: Set([message.id]),
keepUpdated: false
)
|> deliverOnMainQueue).startStandalone(next: { actions in
guard !actions.options.isEmpty else {
return
}
chatController.presentBanMessageOptions(
accountPeerId: context.account.peerId,
author: peer._asPeer(),
messageIds: Set([message.id]),
options: actions.options
)
})
})
}
)), tip: tip)))
} else {