Various improvements [skip ci]

This commit is contained in:
Ilya Laktyushin
2025-02-12 22:15:02 +04:00
parent 8c523ec741
commit 2f2a27f0d2
130 changed files with 5126 additions and 1700 deletions

View File

@@ -99,7 +99,17 @@ func inputPanelForChatPresentationIntefaceState(_ chatPresentationInterfaceState
}
}
if chatPresentationInterfaceState.isPremiumRequiredForMessaging {
if let _ = chatPresentationInterfaceState.sendPaidMessageStars, !chatPresentationInterfaceState.acknowledgedPaidMessage {
if let currentPanel = (currentPanel as? ChatStarsRequiredInputPanelNode) ?? (currentSecondaryPanel as? ChatStarsRequiredInputPanelNode) {
currentPanel.interfaceInteraction = interfaceInteraction
return (currentPanel, nil)
} else {
let panel = ChatStarsRequiredInputPanelNode(theme: chatPresentationInterfaceState.theme)
panel.context = context
panel.interfaceInteraction = interfaceInteraction
return (panel, nil)
}
} else if chatPresentationInterfaceState.isPremiumRequiredForMessaging {
if let currentPanel = (currentPanel as? ChatPremiumRequiredInputPanelNode) ?? (currentSecondaryPanel as? ChatPremiumRequiredInputPanelNode) {
currentPanel.interfaceInteraction = interfaceInteraction
return (currentPanel, nil)