From 3f73d4cc4ea8b5980c85749c5b6c5d5c4fffe701 Mon Sep 17 00:00:00 2001 From: Ilya Laktyushin Date: Thu, 5 Sep 2024 19:12:45 +0400 Subject: [PATCH] Fix localization --- Telegram/Telegram-iOS/en.lproj/Localizable.strings | 5 +++++ .../Sources/ChatMessageGiftBubbleContentNode.swift | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Telegram/Telegram-iOS/en.lproj/Localizable.strings b/Telegram/Telegram-iOS/en.lproj/Localizable.strings index f73882df76..2eb8b2e591 100644 --- a/Telegram/Telegram-iOS/en.lproj/Localizable.strings +++ b/Telegram/Telegram-iOS/en.lproj/Localizable.strings @@ -12934,3 +12934,8 @@ Sorry for the inconvenience."; "Notification.StarsGiveawayResultsNoWinners" = "Due to the giveaway terms, no winners could be selected by Telegram, all stars were credited to channel administrators."; "Notification.StarsGiveawayResultsNoWinners.Group" = "Due to the giveaway terms, no winners could be selected by Telegram, all stars were credited to group administrators."; + +"Notification.StarsGiveaway.Title" = "Congratulations!"; +"Notification.StarsGiveaway.Subtitle" = "You won a prize in a giveaway organized by **%1$@**.\n\nYour prize is **%2$@**."; +"Notification.StarsGiveaway.Subtitle.Stars_1" = "%@ Star"; +"Notification.StarsGiveaway.Subtitle.Stars_any" = "%@ Stars"; diff --git a/submodules/TelegramUI/Components/Chat/ChatMessageGiftBubbleContentNode/Sources/ChatMessageGiftBubbleContentNode.swift b/submodules/TelegramUI/Components/Chat/ChatMessageGiftBubbleContentNode/Sources/ChatMessageGiftBubbleContentNode.swift index c3fbf5d309..69497821c0 100644 --- a/submodules/TelegramUI/Components/Chat/ChatMessageGiftBubbleContentNode/Sources/ChatMessageGiftBubbleContentNode.swift +++ b/submodules/TelegramUI/Components/Chat/ChatMessageGiftBubbleContentNode/Sources/ChatMessageGiftBubbleContentNode.swift @@ -280,8 +280,8 @@ public class ChatMessageGiftBubbleContentNode: ChatMessageBubbleContentNode { if let channelId, let channel = item.message.peers[channelId] { peerName = EnginePeer(channel).compactDisplayTitle } - title = "Congratulations!" //""item.presentationData.strings.Notification_StarsGift_Title(Int32(count)) - text = "You won a prize in a giveaway organized by **\(peerName)**.\n\nYour prize is **\(count) Stars**." //item.presentationData.strings.Notification_StarsGift_Subtitle + title = item.presentationData.strings.Notification_StarsGiveaway_Title + text = item.presentationData.strings.Notification_StarsGiveaway_Subtitle(peerName, item.presentationData.strings.Notification_StarsGiveaway_Subtitle_Stars(Int32(count))).string case let .giftCode(_, fromGiveaway, unclaimed, channelId, monthsValue, _, _, _, _): if channelId == nil { months = monthsValue