Skip to content

Commit

Permalink
Make the localization keys clear strings
Browse files Browse the repository at this point in the history
  • Loading branch information
Havhingstor committed May 13, 2024
1 parent 643ad75 commit 7de6a0f
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 71 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ struct TranslationSettingsView: View {
!apiKey.isEmpty
{
Section {
Text("settings.translation.api-key-still-stored")
Text("The DeepL API Key is still stored!")
if preferences.preferredTranslationType == .useServerIfPossible {
Text("It can however still be used as a fallback for your instance's translation service.")
}
Expand Down
117 changes: 50 additions & 67 deletions IceCubesApp/Resources/Localization/Localizable.xcstrings
Original file line number Diff line number Diff line change
Expand Up @@ -20424,40 +20424,6 @@
}
}
},
"alert.translation-error.deepl" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "DeepL konnte nicht erreicht werden!\nIst der API-Schlüssel korrekt?"
}
},
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "DeepL couldn't be reached!\nIs the API Key correct?"
}
}
}
},
"alert.translation-error.instance" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "Der Übersetzung-Service deiner Instanz konnte nicht erreicht werden!"
}
},
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "The Translation Service of your Instance couldn't be reached!"
}
}
}
},
"An error occured while posting to Mastodon, please try again." : {
"localizations" : {
"de" : {
Expand Down Expand Up @@ -22178,6 +22144,23 @@
}
}
},
"DeepL couldn't be reached!\nIs the API Key correct?" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "DeepL konnte nicht erreicht werden! Ist der API-Schlüssel korrekt?"
}
},
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "DeepL couldn't be reached!\nIs the API Key correct?"
}
}
}
},
"design.tag.n-posts-from-n-participants %lld %lld" : {
"comment" : "MARK: Package: DesignSystem",
"extractionState" : "manual",
Expand Down Expand Up @@ -26314,23 +26297,6 @@
}
}
},
"enum.translation-type.use-server-if-possible" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "needs_review",
"value" : "Instanz"
}
},
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Instance"
}
}
}
},
"env.poll-vote-frequency.multiple" : {
"extractionState" : "manual",
"localizations" : {
Expand Down Expand Up @@ -30978,6 +30944,17 @@
}
}
},
"Instance" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "Instanz"
}
}
}
},
"instance.info.domains" : {
"comment" : "MARK: Instances",
"localizations" : {
Expand Down Expand Up @@ -60051,22 +60028,6 @@
}
}
},
"settings.translation.api-key-still-stored" : {
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "needs_review",
"value" : "Der DeepL-API-Schlüssel ist noch gespeichert!"
}
},
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "The DeepL API Key is still stored!"
}
}
}
},
"settings.translation.api-key-type" : {
"localizations" : {
"be" : {
Expand Down Expand Up @@ -76925,6 +76886,28 @@
}
}
},
"The DeepL API Key is still stored!" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "Der DeepL-API-Schlüssel ist noch gespeichert!"
}
}
}
},
"The Translation Service of your Instance couldn't be reached!" : {
"extractionState" : "manual",
"localizations" : {
"de" : {
"stringUnit" : {
"state" : "translated",
"value" : "Der Übersetzung-Service deiner Instanz konnte nicht erreicht werden!"
}
}
}
},
"timeline-new-posts %lld" : {
"comment" : "Turkish does not have \"-ler\" on words in the sentence, so it follows the singular word.",
"extractionState" : "manual",
Expand Down
2 changes: 1 addition & 1 deletion Packages/Env/Sources/Env/TranslationType.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public enum TranslationType: String, CaseIterable {
public var description: LocalizedStringKey {
switch self {
case .useServerIfPossible:
"enum.translation-type.use-server-if-possible"
"Instance"
case .useDeepl:
"DeepL"
case .useApple:
Expand Down
4 changes: 2 additions & 2 deletions Packages/StatusKit/Sources/StatusKit/Row/StatusRowView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -233,14 +233,14 @@ public struct StatusRowView: View {
StatusDataControllerProvider.shared.dataController(for: viewModel.finalStatus,
client: viewModel.client)
)
.alert("alert.translation-error.deepl", isPresented: $viewModel.deeplTranslationError) {
.alert("DeepL couldn't be reached!\nIs the API Key correct?", isPresented: $viewModel.deeplTranslationError) {
Button("alert.button.ok", role: .cancel) {}
Button("settings.general.translate") {
RouterPath.settingsStartingPoint = .translation
routerPath.presentedSheet = .settings
}
}
.alert("alert.translation-error.instance", isPresented: $viewModel.instanceTranslationError) {
.alert("The Translation Service of your Instance couldn't be reached!", isPresented: $viewModel.instanceTranslationError) {
Button("alert.button.ok", role: .cancel) {}
Button("settings.general.translate") {
RouterPath.settingsStartingPoint = .translation
Expand Down

0 comments on commit 7de6a0f

Please sign in to comment.