diff --git a/damus/Components/SupporterBadge.swift b/damus/Components/SupporterBadge.swift index f6241bec..1af67eee 100644 --- a/damus/Components/SupporterBadge.swift +++ b/damus/Components/SupporterBadge.swift @@ -46,7 +46,7 @@ struct SupporterBadge_Previews: PreviewProvider { HStack(alignment: .center) { SupporterBadge(percent: p) .frame(width: 50) - Text("\(p)") + Text(verbatim: p.formatted()) .frame(width: 50) } } diff --git a/damus/Views/Relays/RelayDetailView.swift b/damus/Views/Relays/RelayDetailView.swift index 5814a539..6a7b6c91 100644 --- a/damus/Views/Relays/RelayDetailView.swift +++ b/damus/Views/Relays/RelayDetailView.swift @@ -24,7 +24,11 @@ struct RelayDetailView: View { } func FieldText(_ str: String?) -> some View { - Text(str ?? "No data available") + if let s = str { + return Text(verbatim: s) + } else { + return Text("No data available", comment: "Text indicating that there is no data available to show for specific metadata about a relay server.") + } } var body: some View { diff --git a/damus/Views/Wallet/ConnectWalletView.swift b/damus/Views/Wallet/ConnectWalletView.swift index de16540c..a926935b 100644 --- a/damus/Views/Wallet/ConnectWalletView.swift +++ b/damus/Views/Wallet/ConnectWalletView.swift @@ -17,7 +17,7 @@ struct ConnectWalletView: View { var body: some View { MainContent - .navigationTitle("Attach a Wallet") + .navigationTitle(NSLocalizedString("Attach a Wallet", comment: "Navigation title for attaching Nostr Wallet Connect lightning wallet.")) .navigationBarTitleDisplayMode(.large) .padding() .onChange(of: wallet_scan_result) { res in @@ -39,7 +39,7 @@ struct ConnectWalletView: View { func AreYouSure(nwc: WalletConnectURL) -> some View { VStack { - Text("Are you sure you want to attach this wallet?") + Text("Are you sure you want to attach this wallet?", comment: "Prompt to ask user if they want to attach their Nostr Wallet Connect lightning wallet.") .font(.title) Text(nwc.relay.id) @@ -52,11 +52,11 @@ struct ConnectWalletView: View { .foregroundColor(.gray) } - BigButton("Attach") { + BigButton(NSLocalizedString("Attach", comment: "Text for button to attach Nostr Wallet Connect lightning wallet.")) { model.connect(nwc) } - BigButton("Cancel") { + BigButton(NSLocalizedString("Cancel", comment: "Text for button to cancel out of connecting Nostr Wallet Connect lightning ewallet.")) { model.cancel() } } @@ -72,7 +72,7 @@ struct ConnectWalletView: View { openURL(URL(string:"https://nwc.getalby.com/apps/new?c=Damus")!) } - BigButton("Attach Wallet") { + BigButton(NSLocalizedString("Attach Wallet", comment: "Text for button to attach Nostr Wallet Connect lightning wallet.")) { scanning = true } @@ -89,7 +89,7 @@ struct ConnectWalletView: View { case .new(let nwc): AreYouSure(nwc: nwc) case .existing: - Text("Shouldn't happen") + Text(verbatim: "Shouldn't happen") case .none: ConnectWallet } diff --git a/damus/Views/Wallet/WalletView.swift b/damus/Views/Wallet/WalletView.swift index f5bc9eab..21fd6b47 100644 --- a/damus/Views/Wallet/WalletView.swift +++ b/damus/Views/Wallet/WalletView.swift @@ -24,18 +24,18 @@ struct WalletView: View { Spacer() - Text("\(nwc.relay.id)") + Text(verbatim: nwc.relay.id) if let lud16 = nwc.lud16 { - Text("\(lud16)") + Text(verbatim: lud16) } - BigButton("Disconnect Wallet") { + BigButton(NSLocalizedString("Disconnect Wallet", comment: "Text for button to disconnect from Nostr Wallet Connect lightning wallet.")) { self.model.disconnect() } } - .navigationTitle("Wallet") + .navigationTitle(NSLocalizedString("Wallet", comment: "Navigation title for Wallet view")) .navigationBarTitleDisplayMode(.large) .padding() } @@ -83,16 +83,16 @@ struct WalletView: View { Image("logo-nobg") .resizable() .frame(width: 50, height: 50) - Text("Support Damus") + Text("Support Damus", comment: "Text calling for the user to support Damus through zaps") .font(.title.bold()) .foregroundColor(.white) } - Text("Help build the future of decentralized communication on the web.") + Text("Help build the future of decentralized communication on the web.", comment: "Text indicating the goal of developing Damus which the user can help with.") .fixedSize(horizontal: false, vertical: true) .foregroundColor(.white) - Text("An additional percentage of each zap will be sent to support Damus development ") + Text("An additional percentage of each zap will be sent to support Damus development", comment: "Text indicating that they can contribute zaps to support Damus development.") .fixedSize(horizontal: false, vertical: true) .foregroundColor(.white) @@ -102,7 +102,7 @@ struct WalletView: View { Slider(value: binding, in: WalletView.min_donation...WalletView.max_donation, label: { }) - Text("\(Int(binding.wrappedValue))%") + Text("\(Int(binding.wrappedValue))%", comment: "Percentage of additional zap that should be sent to support Damus development.") .font(.title.bold()) .foregroundColor(.white) .frame(width: 80) @@ -119,12 +119,12 @@ struct WalletView: View { .frame(width: 120) } - Text("Zap") + Text("Zap", comment: "Text underneath the number of sats indicating that it's the amount used for zaps.") .foregroundColor(.white) } Spacer() - Text("+") + Text(verbatim: "+") .font(.title) .foregroundColor(.white) Spacer() @@ -137,23 +137,13 @@ struct WalletView: View { .frame(width: 120) } - Text(percent == 0 ? "🩶" : "💜") + Text(verbatim: percent == 0 ? "🩶" : "💜") .foregroundColor(.white) } Spacer() } EventProfile(damus_state: damus_state, pubkey: damus_state.pubkey, profile: damus_state.profiles.lookup(id: damus_state.pubkey), size: .small) - - /* - Slider(value: donation_binding(), - in: WalletView.min...WalletView.max, - step: 1, - minimumValueLabel: { Text("\(WalletView.min)") }, - maximumValueLabel: { Text("\(WalletView.max)") }, - label: { Text("label") } - ) - */ } .padding(25) } diff --git a/damus/Views/Zaps/CustomizeZapView.swift b/damus/Views/Zaps/CustomizeZapView.swift index e06a667f..543465ae 100644 --- a/damus/Views/Zaps/CustomizeZapView.swift +++ b/damus/Views/Zaps/CustomizeZapView.swift @@ -136,7 +136,7 @@ struct CustomizeZapView: View { VStack(alignment: .center, spacing: 0) { TextField("", text: $custom_amount) .placeholder(when: custom_amount.isEmpty, alignment: .center) { - Text(String("0")) + Text(verbatim: 0.formatted()) } .accentColor(.clear) .font(.system(size: 72, weight: .heavy)) diff --git a/damus/cs.lproj/Localizable.strings b/damus/cs.lproj/Localizable.strings index 56327364..6d5ca1b0 100644 Binary files a/damus/cs.lproj/Localizable.strings and b/damus/cs.lproj/Localizable.strings differ diff --git a/damus/de.lproj/Localizable.strings b/damus/de.lproj/Localizable.strings index fac44eb6..9beeb069 100644 Binary files a/damus/de.lproj/Localizable.strings and b/damus/de.lproj/Localizable.strings differ diff --git a/damus/el-GR.lproj/Localizable.strings b/damus/el-GR.lproj/Localizable.strings index 749448b9..ccd6d465 100644 Binary files a/damus/el-GR.lproj/Localizable.strings and b/damus/el-GR.lproj/Localizable.strings differ diff --git a/damus/en-US.xcloc/Localized Contents/en-US.xliff b/damus/en-US.xcloc/Localized Contents/en-US.xliff index 1fe7bc9b..1222dc7e 100644 --- a/damus/en-US.xcloc/Localized Contents/en-US.xliff +++ b/damus/en-US.xcloc/Localized Contents/en-US.xliff @@ -42,11 +42,6 @@ - - %@ - %@ - No comment provided by engineer. - %@ %@ %@ %@ @@ -83,6 +78,11 @@ Sentence composed of 2 variables to describe how many people are following a use %@. Tip your friend's posts and stack sats with Bitcoin⚡️, the native currency of the internet. Explanation of what can be done by users to earn money. There is a heading that precedes this explanation which is a variable to this string. + + %lld%% + %lld%% + Percentage of additional zap that should be sent to support Damus development. + %lld/%lld %lld/%lld @@ -174,6 +174,11 @@ Sentence composed of 2 variables to describe how many people are following a use Always show images Setting to always show and never blur images + + An additional percentage of each zap will be sent to support Damus development + An additional percentage of each zap will be sent to support Damus development + Text indicating that they can contribute zaps to support Damus development. + Animations Animations @@ -201,6 +206,11 @@ Sentence composed of 2 variables to describe how many people are following a use Are you lost? Text asking the user if they are lost in the app. + + Are you sure you want to attach this wallet? + Are you sure you want to attach this wallet? + Prompt to ask user if they want to attach their Nostr Wallet Connect lightning wallet. + Are you sure you want to delete all of your bookmarks? Are you sure you want to delete all of your bookmarks? @@ -216,6 +226,26 @@ Sentence composed of 2 variables to describe how many people are following a use Are you sure you want to upload this media? Alert message asking if the user wants to upload media. + + Attach + Attach + Text for button to attach Nostr Wallet Connect lightning wallet. + + + Attach Alby Wallet + Attach Alby Wallet + Button to attach an Alby Wallet, a service that provides a Lightning wallet for zapping sats. Alby is the name of the service and should not be translated. + + + Attach Wallet + Attach Wallet + Text for button to attach Nostr Wallet Connect lightning wallet. + + + Attach a Wallet + Attach a Wallet + Navigation title for attaching Nostr Wallet Connect lightning wallet. + Automatically translate notes Automatically translate notes @@ -264,7 +294,8 @@ Sentence composed of 2 variables to describe how many people are following a use Button to cancel the upload. Cancel deleting bookmarks. Cancel deleting the user. - Cancel out of logging out the user. + Cancel out of logging out the user. + Text for button to cancel out of connecting Nostr Wallet Connect lightning ewallet. Choose from Library @@ -291,11 +322,6 @@ Sentence composed of 2 variables to describe how many people are following a use Connect To Relay Label for section for adding a relay server. - - Connect to Alby - Connect to Alby - Button to connect to Alby, a service that provides a Lightning wallet for zapping sats. Alby is the name of the service and should not be translated. - Connected Relays Connected Relays @@ -476,6 +502,11 @@ Sentence composed of 2 variables to describe how many people are following a use Disconnect From Relay Button to disconnect from the relay. + + Disconnect Wallet + Disconnect Wallet + Text for button to disconnect from Nostr Wallet Connect lightning wallet. + Display Name Display Name @@ -581,6 +612,11 @@ Sentence composed of 2 variables to describe how many people are following a use Get API Key with BTC/Lightning Button to navigate to nokyctranslate website to get a translation API key. + + Help build the future of decentralized communication on the web. + Help build the future of decentralized communication on the web. + Text indicating the goal of developing Damus which the user can help with. + Hide Hide @@ -777,6 +813,11 @@ Sentence composed of 2 variables to describe how many people are following a use No Button to cancel out of posting a note after being alerted that it looks like they might be posting a private key. + + No data available + No data available + Text indicating that there is no data available to show for specific metadata about a relay server. + No mute list found, create a new one? This will overwrite any previous mute lists. No mute list found, create a new one? This will overwrite any previous mute lists. @@ -1226,6 +1267,11 @@ Button text to indicate that the zap type is a private zap. Software Label to display relay software. + + Support Damus + Support Damus + Text calling for the user to support Damus through zaps + Supported NIPs Supported NIPs @@ -1414,7 +1460,8 @@ YOU WILL NO LONGER BE ABLE TO LOG INTO DAMUS USING THIS ACCOUNT KEY. Wallet Wallet - Sidebar menu label for Wallet view. + Navigation title for Wallet view + Sidebar menu label for Wallet view. Title for section in zap settings that controls the Lightning wallet selection. diff --git a/damus/en-US.xcloc/Source Contents/damus/en-US.lproj/Localizable.strings b/damus/en-US.xcloc/Source Contents/damus/en-US.lproj/Localizable.strings index 67202776..9b975054 100644 Binary files a/damus/en-US.xcloc/Source Contents/damus/en-US.lproj/Localizable.strings and b/damus/en-US.xcloc/Source Contents/damus/en-US.lproj/Localizable.strings differ diff --git a/damus/es-419.lproj/Localizable.strings b/damus/es-419.lproj/Localizable.strings index 0f682fb3..24629091 100644 Binary files a/damus/es-419.lproj/Localizable.strings and b/damus/es-419.lproj/Localizable.strings differ diff --git a/damus/es-ES.lproj/Localizable.strings b/damus/es-ES.lproj/Localizable.strings index b3c2cf7f..3819d1ee 100644 Binary files a/damus/es-ES.lproj/Localizable.strings and b/damus/es-ES.lproj/Localizable.strings differ diff --git a/damus/es-ES.lproj/Localizable.stringsdict b/damus/es-ES.lproj/Localizable.stringsdict index 770e63ae..146fe434 100644 --- a/damus/es-ES.lproj/Localizable.stringsdict +++ b/damus/es-ES.lproj/Localizable.stringsdict @@ -236,6 +236,24 @@ Republicaciones + sats + + NSStringLocalizedFormatKey + %#@SATS@ + SATS + + NSStringFormatSpecTypeKey + NSStringPluralRuleType + NSStringFormatValueTypeKey + d + one + sat + many + sats + other + sats + + sats_count NSStringLocalizedFormatKey diff --git a/damus/fa.lproj/Localizable.strings b/damus/fa.lproj/Localizable.strings index b2d0e91e..60e6ee97 100644 Binary files a/damus/fa.lproj/Localizable.strings and b/damus/fa.lproj/Localizable.strings differ diff --git a/damus/fa.lproj/Localizable.stringsdict b/damus/fa.lproj/Localizable.stringsdict index 17dc0417..ca3d594f 100644 --- a/damus/fa.lproj/Localizable.stringsdict +++ b/damus/fa.lproj/Localizable.stringsdict @@ -15,7 +15,7 @@ one ... %d یادداشت دیگر ... other - ... %d نوت های دیگر ... + ... %d یادداشت های دیگر ... followers_count @@ -63,7 +63,7 @@ one %2$@ و %1$d نفر دیگر به یک مطلب که شما در آن تگ شده‌اید بازخورد داده‌اند other - %2$@ و %1$d نفر دیگر به یک نوت که شما در آن تگ شده‌اید بازخورد داده‌اند + %2$@ و %1$d نفر دیگر به یک یادداشت که شما در آن تگ شده‌اید واکنش داده‌اند reacted_your_post_3 @@ -79,7 +79,7 @@ one %2$@ و %1$d نفر دیگر به مطلب شما بازخورد داده‌اند other - %2$@ و %1$d نفر دیگر به نوت شما بازخورد داده‌اند + %2$@ و %1$d نفر دیگر به یادداشت شما واکنش داده‌اند reacted_your_profile_3 @@ -95,7 +95,7 @@ one %2$@ و %1$d نفر دیگر به نمایه‌ی شما بازخورد داده‌اند other - %2$@ و %1$d نفر دیگر به پروفایل شما بازخورد داده‌اند + %2$@ و %1$d نفر دیگر به نمایه شما واکنش داده‌اند reactions_count @@ -111,7 +111,7 @@ one بازخورد other - بازخوردها + واکنش ها relays_count @@ -159,7 +159,7 @@ one %2$@ و %1$d نفر دیگر یک مطلب که شما در آن تگ شده‌اید را بازنشر کرده‌اند other - %2$@ و %1$d نفر دیگر یک مطلب که شما در آن تگ شده‌اید را بازنشر کرده‌اند + %2$@ و %1$d نفر دیگر یک یادداشت که شما در آن تگ شده‌اید را بازنشر کرده‌اند reposted_your_post_3 @@ -175,7 +175,7 @@ one %2$@ و %1$d نفر دیگر مطلب شما را بازنشر کرده‌اند other - %2$@ و %1$d نفر دیگر مطلب شما را بازنشر کرده‌اند + %2$@ و %1$d نفر دیگر یادداشت شما را بازنشر کرده‌اند reposted_your_profile_3 @@ -287,7 +287,7 @@ one %2$@ و %1$d نفر دیگر یک مطلب که شما در آن تگ شده‌اید را زپ کرده‌اند other - %2$@ و %1$d نفر دیگر یک مطلب که شما در آن تگ شده‌اید را زپ کرده‌اند + %2$@ و %1$d نفر دیگر یک یادداشت که شما در آن تگ شده‌اید را زپ کرده‌اند zapped_your_post_3 @@ -303,7 +303,7 @@ one %2$@ و %1$d نفر دیگر مطلب شما را زپ کرده‌اند other - %2$@ و %1$d نفر دیگر مطلب شما را زپ کرده‌اند + %2$@ و %1$d نفر دیگر یادداشت شما را زپ کرده‌اند zapped_your_profile_3 diff --git a/damus/fr.lproj/Localizable.stringsdict b/damus/fr.lproj/Localizable.stringsdict index ba36c7c7..d512c525 100644 --- a/damus/fr.lproj/Localizable.stringsdict +++ b/damus/fr.lproj/Localizable.stringsdict @@ -236,6 +236,24 @@ Republications + sats + + NSStringLocalizedFormatKey + %#@SATS@ + SATS + + NSStringFormatSpecTypeKey + NSStringPluralRuleType + NSStringFormatValueTypeKey + d + one + sat + many + sats + other + sats + + sats_count NSStringLocalizedFormatKey diff --git a/damus/hu-HU.lproj/Localizable.strings b/damus/hu-HU.lproj/Localizable.strings index 051632ae..9806e9c8 100644 Binary files a/damus/hu-HU.lproj/Localizable.strings and b/damus/hu-HU.lproj/Localizable.strings differ diff --git a/damus/ja.lproj/Localizable.strings b/damus/ja.lproj/Localizable.strings index d0b98af1..ba6d59bf 100644 Binary files a/damus/ja.lproj/Localizable.strings and b/damus/ja.lproj/Localizable.strings differ diff --git a/damus/nl.lproj/Localizable.strings b/damus/nl.lproj/Localizable.strings index ef91a2ec..d8e9366c 100644 Binary files a/damus/nl.lproj/Localizable.strings and b/damus/nl.lproj/Localizable.strings differ diff --git a/damus/pl-PL.lproj/Localizable.strings b/damus/pl-PL.lproj/Localizable.strings index e331917b..e9666bea 100644 Binary files a/damus/pl-PL.lproj/Localizable.strings and b/damus/pl-PL.lproj/Localizable.strings differ diff --git a/damus/sv-SE.lproj/Localizable.strings b/damus/sv-SE.lproj/Localizable.strings index 59a50800..294d8239 100644 Binary files a/damus/sv-SE.lproj/Localizable.strings and b/damus/sv-SE.lproj/Localizable.strings differ diff --git a/damus/zh-CN.lproj/Localizable.strings b/damus/zh-CN.lproj/Localizable.strings index bfce553b..4c5f0f1c 100644 Binary files a/damus/zh-CN.lproj/Localizable.strings and b/damus/zh-CN.lproj/Localizable.strings differ diff --git a/damus/zh-HK.lproj/Localizable.strings b/damus/zh-HK.lproj/Localizable.strings index ffae7208..fddd8b88 100644 Binary files a/damus/zh-HK.lproj/Localizable.strings and b/damus/zh-HK.lproj/Localizable.strings differ diff --git a/damus/zh-TW.lproj/Localizable.strings b/damus/zh-TW.lproj/Localizable.strings index fe2b7039..9ef5d142 100644 Binary files a/damus/zh-TW.lproj/Localizable.strings and b/damus/zh-TW.lproj/Localizable.strings differ