Skip to content

Commit

Permalink
#485 | Update localized strings
Browse files Browse the repository at this point in the history
  • Loading branch information
moyerr committed Mar 30, 2022
1 parent 9a74e08 commit 3f83519
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,18 @@ final class EditCategoryDetailViewController: VocableCollectionViewController {

switch item {
case .renameCategory:
config = .disclosureCellConfiguration(withTitle: "Rename Category") { [weak self] in
config = .disclosureCellConfiguration(
withTitle: NSLocalizedString(
"category_editor.detail.button.rename_category.title",
comment: "Rename Category button label within the category detail screen")
) { [weak self] in
self?.handleRenameCategory()
}
case .editPhrases:
config = .disclosureCellConfiguration(
withTitle: NSLocalizedString("Edit Phrases", comment: "Edit Phrases")
withTitle: NSLocalizedString(
"category_editor.detail.button.edit_phrases.title",
comment: "Edit Phrases button label within the category detail screen")
) { [weak self] in
self?.displayEditPhrasesViewController()
}
Expand All @@ -105,8 +111,7 @@ final class EditCategoryDetailViewController: VocableCollectionViewController {
config = .toggleCellConfiguration(
withTitle: NSLocalizedString(
"category_editor.detail.button.show_category.title",
comment: "Show category button label within the category detail screen."
),
comment: "Show category button label within the category detail screen."),
toggleIsOn: !category.isHidden
) { [weak self] in
self?.handleToggle(at: indexPath)
Expand Down
2 changes: 1 addition & 1 deletion Vocable/Features/Settings/SettingsViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ final class SettingsViewController: VocableCollectionViewController, MFMailCompo
private func presentResetFailureAlert() {
let alertString = NSLocalizedString("settings.alert.reset_app_settings_failure.body",
comment: "body of alert presented when Vocable's application settings failed to reset")
let dismissTitle = NSLocalizedString("settings.alert.reset_app_settings_success.button.ok",
let dismissTitle = NSLocalizedString("settings.alert.reset_app_settings_failure.button.ok",
comment: "Button dismissing the alert informing the user that Vocable's application settings failed to reset")

let alertViewController = GazeableAlertViewController(alertTitle: alertString)
Expand Down
6 changes: 5 additions & 1 deletion Vocable/Supporting Files/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,12 @@
/* Settings screen header title */
"settings.header.title" = "Settings";

"category_editor.detail.button.rename_category.title" = "Rename Category";

"category_editor.detail.button.show_category.title" = "Show Category";

"category_editor.detail.button.edit_phrases.title" = "Edit Phrases";

"category_editor.detail.button.remove_category.title" = "Remove Category";

"category_editor.toast.successfully_saved.title" = "Changes Saved";
Expand Down Expand Up @@ -161,4 +165,4 @@

"settings.alert.reset_app_settings_failure.body" = "Vocable failed to reset. Please try again or reinstall Vocable if the issue persists.";

"settings.alert.reset_app_settings_success.button.ok" = "OK";
"settings.alert.reset_app_settings_failure.button.ok" = "OK";

0 comments on commit 3f83519

Please sign in to comment.