add localized strings

This commit is contained in:
JanNiklas Grabowski
2023-09-15 13:46:16 +02:00
parent fbcd6dcd8c
commit 6fed37b635
4 changed files with 14 additions and 2 deletions
+2
View File
@@ -550,6 +550,8 @@
"poll_timeline_show_participants_button" = "Stimmen ansehen";
"poll_participant_details_show_more" = "Alle ansehen (%lu weitere)";
"poll_participant_details_title" = "Umfragedetails";
"poll_participant_details_clock_string" = " Uhr";
"poll_participant_details_date_string_today" = "Heute, ";
// MARK: - Welcome Experience
"welcome_experience_title1" = "Willkommen beim BundesMessenger";
+2
View File
@@ -455,6 +455,8 @@
"poll_timeline_show_participants_button" = "Show votes";
"poll_participant_details_show_more" = "Show all (%lu more)";
"poll_participant_details_title" = "Poll details";
"poll_participant_details_clock_string" = "";
"poll_participant_details_date_string_today" = "Today, ";
// MARK: - Welcome Experience
"welcome_experience_title1" = "Welcome to BundesMessenger";
+8
View File
@@ -1023,6 +1023,14 @@ public class BWIL10n: NSObject {
public static var pollEditFormPollTypeOpen: String {
return BWIL10n.tr("Bwi", "poll_edit_form_poll_type_open")
}
/// Uhr
public static var pollParticipantDetailsClockString: String {
return BWIL10n.tr("Bwi", "poll_participant_details_clock_string")
}
/// Heute,
public static var pollParticipantDetailsDateStringToday: String {
return BWIL10n.tr("Bwi", "poll_participant_details_date_string_today")
}
/// Alle ansehen (%lu weitere)
public static func pollParticipantDetailsShowMore(_ p1: Int) -> String {
return BWIL10n.tr("Bwi", "poll_participant_details_show_more", p1)
@@ -52,12 +52,12 @@ struct PollParticipantVoter: Identifiable, BindableState {
var strDate = ""
if Calendar.current.isDateInToday(votingTime) {
dateFormatter.dateFormat = "HH:mm"
strDate = "Heute, ".appending(dateFormatter.string(from: votingTime))
strDate = BWIL10n.pollParticipantDetailsDateStringToday.appending(dateFormatter.string(from: votingTime))
} else {
dateFormatter.dateFormat = "E, d. MMM yyyy, HH:mm"
strDate = dateFormatter.string(from: votingTime)
}
strDate.append(contentsOf: " Uhr")
strDate.append(contentsOf: BWIL10n.pollParticipantDetailsClockString)
return PollParticipantVoter(displayName: user.displayname, userAvatarData: avatarData, formattedVotingTime: strDate)
} else {