Regularize comments for localized strings so the Localizable.xcstrings file doesn't change just because we switched targets.

This commit is contained in:
Brent Simmons committed 2026-06-06 14:43:31 -07:00
1 parent 38e7b53803
commit fb05b944cf
30 files changed
+159 -159

No files matched your search

+4 -4
View File
@@ -974,7 +974,7 @@ extension AppDelegate {
alert.accessoryView = textView
alert.addButton(withTitle: NSLocalizedString("Install Theme", comment: "Install Theme"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel Install Theme"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
func importTheme() {
do {
@@ -996,7 +996,7 @@ extension AppDelegate {
alert.messageText = NSString.localizedStringWithFormat(localizedMessageText as NSString, theme.name) as String
alert.addButton(withTitle: NSLocalizedString("Overwrite", comment: "Overwrite"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel Install Theme"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
alert.beginSheetModal(for: window) { result in
if result == NSApplication.ModalResponse.alertFirstButtonReturn {
@@ -1023,7 +1023,7 @@ extension AppDelegate {
let localizedInformativeText = NSLocalizedString("The theme “%@” has been installed.", comment: "Theme installed")
alert.informativeText = NSString.localizedStringWithFormat(localizedInformativeText as NSString, themeName) as String
alert.addButton(withTitle: NSLocalizedString("OK", comment: "OK"))
alert.addButton(withTitle: NSLocalizedString("OK", comment: "OK button"))
alert.beginSheetModal(for: window)
}
@@ -1068,7 +1068,7 @@ extension AppDelegate {
alert.messageText = NSLocalizedString("Theme Error", comment: "Theme download error")
alert.informativeText = informativeText
alert.addButton(withTitle: NSLocalizedString("Open Theme Folder", comment: "Open Theme Folder"))
alert.addButton(withTitle: NSLocalizedString("OK", comment: "OK"))
alert.addButton(withTitle: NSLocalizedString("OK", comment: "OK button"))
let button = alert.buttons.first
button?.target = self
@@ -24,14 +24,14 @@ final class CloudKitStatsToolbarView: NSView {
shareButton = NSButton()
shareButton.bezelStyle = .rounded
shareButton.image = NSImage(systemSymbolName: "square.and.arrow.up", accessibilityDescription: NSLocalizedString("Share", comment: "Share button accessibility description"))
shareButton.image = NSImage(systemSymbolName: "square.and.arrow.up", accessibilityDescription: NSLocalizedString("Share", comment: "Share button"))
shareButton.translatesAutoresizingMaskIntoConstraints = false
shareButton.target = nil
shareButton.action = #selector(CloudKitStatsViewController.shareStats(_:))
cleanUpButton = NSButton()
cleanUpButton.bezelStyle = .rounded
cleanUpButton.title = NSLocalizedString("Clean Up", comment: "Clean Up button title")
cleanUpButton.title = NSLocalizedString("Clean Up", comment: "Clean Up button")
cleanUpButton.translatesAutoresizingMaskIntoConstraints = false
cleanUpButton.target = nil
cleanUpButton.action = #selector(CloudKitStatsViewController.cleanUp(_:))
@@ -103,7 +103,7 @@ extension CloudKitStatsViewController {
alert.alertStyle = .warning
alert.messageText = NSLocalizedString("Clean Up iCloud Records", comment: "Clean up alert title")
alert.informativeText = model.cleanUpPlanIsStale ? staleCleanUpConfirmationText() : cleanUpConfirmationText(plan)
alert.addButton(withTitle: NSLocalizedString("Clean Up", comment: "Clean up alert button"))
alert.addButton(withTitle: NSLocalizedString("Clean Up", comment: "Clean Up button"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
guard let window = view.window else {
@@ -38,16 +38,16 @@ final class CloudKitStatsScanContentView: NSView {
buildSectionRows(statusSectionView, rows: [
.header(NSLocalizedString("Status Records", comment: "Status records section header")),
.data(labelView: NSTextField(labelWithString: NSLocalizedString("Total", comment: "Total row label")), valueLabel: statusRecordCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Starred", comment: "Starred row label"), symbolName: "star.fill", color: CloudKitStatsLayout.starColor), valueLabel: starredCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Unread", comment: "Unread row label"), symbolName: "circle.fill", color: .controlAccentColor, iconOffset: 0.5), valueLabel: unreadCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Starred", comment: "Starred label"), symbolName: "star.fill", color: CloudKitStatsLayout.starColor), valueLabel: starredCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Unread", comment: "Unread label"), symbolName: "circle.fill", color: .controlAccentColor, iconOffset: 0.5), valueLabel: unreadCountLabel),
.data(labelView: NSTextField(labelWithString: NSLocalizedString("Read", comment: "Read row label")), valueLabel: readCountLabel)
])
buildSectionRows(articleSectionView, rows: [
.header(NSLocalizedString("Article Content Records", comment: "Article content records section header")),
.header(NSLocalizedString("Article Content Records", comment: "Article content records header")),
.data(labelView: NSTextField(labelWithString: NSLocalizedString("Total", comment: "Total row label")), valueLabel: totalContentCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Starred", comment: "Starred row label"), symbolName: "star.fill", color: CloudKitStatsLayout.starColor), valueLabel: starredContentCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Unread", comment: "Unread row label"), symbolName: "circle.fill", color: .controlAccentColor, iconOffset: 0.5), valueLabel: unreadContentCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Starred", comment: "Starred label"), symbolName: "star.fill", color: CloudKitStatsLayout.starColor), valueLabel: starredContentCountLabel),
.data(labelView: CloudKitStatsLayout.makeLabelWithIcon(NSLocalizedString("Unread", comment: "Unread label"), symbolName: "circle.fill", color: .controlAccentColor, iconOffset: 0.5), valueLabel: unreadContentCountLabel),
.data(labelView: NSTextField(labelWithString: NSLocalizedString("Read", comment: "Read row label")), valueLabel: readContentCountLabel)
])
@@ -111,11 +111,11 @@ final class DinosaursWindowController: NSWindowController {
let alert = NSAlert()
alert.alertStyle = .warning
if rows.count == 1, let only = rows.first {
alert.messageText = NSLocalizedString("Delete Feed", comment: "Delete feed alert title")
alert.messageText = NSLocalizedString("Delete Feed", comment: "Delete Feed")
let format = NSLocalizedString("Are you sure you want to delete the feed “%@”?", comment: "Delete feed alert message")
alert.informativeText = String(format: format, only.feedName)
} else {
alert.messageText = NSLocalizedString("Delete Feeds", comment: "Delete feeds alert title")
alert.messageText = NSLocalizedString("Delete Feeds", comment: "Delete Feeds")
let format = NSLocalizedString("Are you sure you want to delete %d feeds?", comment: "Delete feeds alert message")
alert.informativeText = String(format: format, rows.count)
}
@@ -299,8 +299,8 @@ private extension DinosaursWindowController {
controller.refreshModel()
}
let actionName = deletions.count == 1
? NSLocalizedString("Delete Feed", comment: "Undo action name")
: NSLocalizedString("Delete Feeds", comment: "Undo action name")
? NSLocalizedString("Delete Feed", comment: "Delete Feed")
: NSLocalizedString("Delete Feeds", comment: "Delete Feeds")
undoManager.setActionName(actionName)
}
+5 -5
View File
@@ -821,7 +821,7 @@ extension MainWindowController: NSToolbarDelegate {
return toolbarItem
case .markAllAsRead:
let title = NSLocalizedString("Mark All as Read", comment: "Mark All as Read")
let title = NSLocalizedString("Mark All as Read", comment: "Command")
return buildToolbarButton(.markAllAsRead, title, Assets.Images.markAllAsRead, "markAllAsRead:")
case .toggleReadArticlesFilter:
@@ -832,7 +832,7 @@ extension MainWindowController: NSToolbarDelegate {
return NSTrackingSeparatorToolbarItem(identifier: .timelineTrackingSeparator, splitView: splitViewController!.splitView, dividerIndex: 1)
case .markRead:
let title = NSLocalizedString("Mark Read", comment: "Mark Read")
let title = NSLocalizedString("Mark Read", comment: "command")
return buildToolbarButton(.markRead, title, Assets.Images.readClosed, "toggleRead:")
case .markStar:
@@ -855,11 +855,11 @@ extension MainWindowController: NSToolbarDelegate {
return toolbarItem
case .share:
let title = NSLocalizedString("Share", comment: "Share")
let title = NSLocalizedString("Share", comment: "Share button")
return buildToolbarButton(.share, title, Assets.Images.share, "toolbarShowShareMenu:")
case .openInBrowser:
let title = NSLocalizedString("Open in Browser", comment: "Open in Browser")
let title = NSLocalizedString("Open in Browser", comment: "Command")
return buildToolbarButton(.openInBrowser, title, Assets.Images.openInBrowser, "openArticleInBrowser:")
case .articleThemeMenu:
@@ -877,7 +877,7 @@ extension MainWindowController: NSToolbarDelegate {
return toolbarItem
case .cleanUp:
let title = NSLocalizedString("Clean Up", comment: "Clean Up")
let title = NSLocalizedString("Clean Up", comment: "Clean Up button")
return buildToolbarButton(.cleanUp, title, Assets.Images.cleanUp, "cleanUp:")
default:
@@ -19,7 +19,7 @@ enum SidebarDeleteItemsAlert {
if nodes.count == 1 {
if let folder = nodes.first?.representedObject as? Folder {
alert.messageText = NSLocalizedString("Delete Folder", comment: "Delete Folder")
alert.messageText = NSLocalizedString("Delete Folder", comment: "Command")
let localizedInformativeText = NSLocalizedString("Are you sure you want to delete the “%@” folder?", comment: "Folder delete text")
alert.informativeText = NSString.localizedStringWithFormat(localizedInformativeText as NSString, folder.nameForDisplay) as String
} else if let sidebarItem = nodes.first?.representedObject as? SidebarItem {
@@ -33,8 +33,8 @@ enum SidebarDeleteItemsAlert {
alert.informativeText = NSString.localizedStringWithFormat(localizedInformativeText as NSString, nodes.count) as String
}
alert.addButton(withTitle: NSLocalizedString("Delete", comment: "Delete Account"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel Delete Account"))
alert.addButton(withTitle: NSLocalizedString("Delete", comment: "Delete button"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
return alert
}
@@ -295,7 +295,7 @@ private extension SidebarViewController {
func deleteMenuItem(_ objects: [Any]) -> NSMenuItem {
return menuItem(NSLocalizedString("Delete", comment: "Command"), #selector(deleteFromContextualMenu(_:)), objects, image: Assets.Images.delete)
return menuItem(NSLocalizedString("Delete", comment: "Delete button"), #selector(deleteFromContextualMenu(_:)), objects, image: Assets.Images.delete)
}
func renameMenuItem(_ object: Any) -> NSMenuItem {
@@ -68,12 +68,12 @@ final class AccountsPreferencesViewController: NSViewController {
let alert = NSAlert()
alert.alertStyle = .warning
let deletePrompt = NSLocalizedString("Delete", comment: "Delete")
let deletePrompt = NSLocalizedString("Delete", comment: "Delete button")
alert.messageText = "\(deletePrompt) “\(accountName)”?"
alert.informativeText = NSLocalizedString("Are you sure you want to delete the account “\(accountName)”? This cannot be undone.", comment: "Delete text")
alert.addButton(withTitle: NSLocalizedString("Delete", comment: "Delete Account"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel Delete Account"))
alert.addButton(withTitle: NSLocalizedString("Delete", comment: "Delete button"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
guard let window = view.window else {
return
@@ -208,7 +208,7 @@ extension AccountsPreferencesViewController: AccountsPreferencesAddAccountDelega
alert.informativeText = NSLocalizedString("A web browser will open the Feedly login for you to authorize access.",
comment: "Alert informative text when adding a Feedly account and waiting for authorization from the user.")
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel"))
alert.addButton(withTitle: NSLocalizedString("Cancel", comment: "Cancel button"))
let attachedWindow = self.view.window!
@@ -66,13 +66,13 @@ nonisolated public enum AccountType: Int, Codable, Sendable {
case .newsBlur:
return NSLocalizedString("NewsBlur", comment: "NewsBlur")
case .freshRSS:
return NSLocalizedString("FreshRSS", comment: "FreshRSS")
return NSLocalizedString("FreshRSS", comment: "Account name")
case .inoreader:
return NSLocalizedString("Inoreader", comment: "Inoreader")
return NSLocalizedString("Inoreader", comment: "Account name")
case .bazQux:
return NSLocalizedString("BazQux", comment: "BazQux")
return NSLocalizedString("BazQux", comment: "Account name")
case .theOldReader:
return NSLocalizedString("The Old Reader", comment: "The Old Reader")
return NSLocalizedString("The Old Reader", comment: "Account name")
}
}
}
@@ -16,7 +16,7 @@ extension UIViewController {
public func presentError(title: String, message: String, dismiss: (() -> Void)? = nil) {
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let dismissTitle = NSLocalizedString("OK", comment: "OK")
let dismissTitle = NSLocalizedString("OK", comment: "OK button")
let dismissAction = UIAlertAction(title: dismissTitle, style: .default) { _ in
dismiss?()
}
+3 -3
View File
@@ -244,9 +244,9 @@ final class DeleteCommand: UndoableCommand {
private struct DeleteActionName {
private static let deleteFeed = NSLocalizedString("Delete Feed", comment: "command")
private static let deleteFeeds = NSLocalizedString("Delete Feeds", comment: "command")
private static let deleteFolder = NSLocalizedString("Delete Folder", comment: "command")
private static let deleteFeed = NSLocalizedString("Delete Feed", comment: "Delete Feed")
private static let deleteFeeds = NSLocalizedString("Delete Feeds", comment: "Delete Feeds")
private static let deleteFolder = NSLocalizedString("Delete Folder", comment: "Command")
private static let deleteFolders = NSLocalizedString("Delete Folders", comment: "command")
private static let deleteFeedsAndFolders = NSLocalizedString("Delete Feeds and Folders", comment: "command")
+40 -40
View File
@@ -130,7 +130,7 @@
"comment" : "Automatic"
},
"BazQux" : {
"comment" : "Account name\nBazQux"
"comment" : "Account name"
},
"Can’t add a feed because no feed was found." : {
"comment" : "Feed finder"
@@ -145,10 +145,10 @@
"comment" : "Feed finder"
},
"Cancel" : {
"comment" : "Cancel\nCancel button"
"comment" : "Cancel button"
},
"Canceled." : {
"comment" : "Scan canceled text"
"comment" : "Scan status text when canceled"
},
"Choose a location for the exported OPML file." : {
"comment" : "Export OPML"
@@ -166,7 +166,7 @@
"comment" : "Export Account"
},
"Clean Up" : {
"comment" : "Clean Up\nClean up alert button"
"comment" : "Clean Up button"
},
"Clean Up iCloud Records" : {
"comment" : "Clean up alert title"
@@ -202,19 +202,19 @@
},
"Copy Article URL" : {
"comment" : "Copy Article URL"
"comment" : "Command"
},
"Copy Contents" : {
"comment" : "Copy Contents button"
},
"Copy External URL" : {
"comment" : "Copy External URL"
"comment" : "Command"
},
"Copy Feed URL" : {
"comment" : "Copy Feed URL"
"comment" : "Command"
},
"Copy Home Page URL" : {
"comment" : "Copy Home Page URL"
"comment" : "Command"
},
"Couldn’t complete the iCloud scan because of an error:" : {
"comment" : "Scan error alert title"
@@ -238,19 +238,19 @@
"comment" : "Default"
},
"Delete" : {
"comment" : "Delete"
"comment" : "Delete button"
},
"Delete Feed" : {
"comment" : "Delete feed\ncommand"
"comment" : "Delete Feed"
},
"Delete Feeds" : {
"comment" : "command"
"comment" : "Delete Feeds"
},
"Delete Feeds and Folders" : {
"comment" : "command"
},
"Delete Folder" : {
"comment" : "Delete folder\ncommand"
"comment" : "Command"
},
"Delete Folders" : {
"comment" : "command"
@@ -415,7 +415,7 @@
"comment" : "Folder Inspector window title"
},
"FreshRSS" : {
"comment" : "Account name\nFreshRSS"
"comment" : "Account name"
},
"General" : {
"comment" : "Preferences"
@@ -469,7 +469,7 @@
"comment" : "Cleanup phase text when completed"
},
"iCloud Storage Stats" : {
"comment" : "Navigation title for iCloud stats view"
"comment" : "iCloud Storage Stats window title"
},
"Icon Preview" : {
"comment" : "Icon Preview"
@@ -484,7 +484,7 @@
"comment" : "Import Theme"
},
"Inoreader" : {
"comment" : "Account name\nInoreader"
"comment" : "Account name"
},
"Inspector" : {
"comment" : "Inspector window title"
@@ -543,34 +543,34 @@
"comment" : "Manually"
},
"Mark Above as Read" : {
"comment" : "Mark Above as Read"
"comment" : "Command"
},
"Mark All as Read" : {
"comment" : "Mark All as Read"
"comment" : "Command"
},
"Mark All as Read in “%@”" : {
"comment" : "Command\nMark All as Read in Feed"
"comment" : "Command"
},
"Mark Article Unread" : {
"comment" : "Mark Article Unread"
},
"Mark as Read" : {
"comment" : "Mark as Read"
"comment" : "Command"
},
"Mark As Read" : {
"comment" : "Mark As Read"
},
"Mark as Starred" : {
"comment" : "Mark as Starred"
"comment" : "Command"
},
"Mark as Unread" : {
"comment" : "Mark as Unread"
"comment" : "Command"
},
"Mark as Unstarred" : {
"comment" : "Mark as Unstarred"
"comment" : "Command"
},
"Mark Below as Read" : {
"comment" : "Mark Below as Read"
"comment" : "Command"
},
"Mark Read" : {
"comment" : "command"
@@ -622,13 +622,13 @@
"comment" : "New Article Notifications"
},
"New Feed" : {
"comment" : "New Feed"
"comment" : "Command"
},
"New Feed…" : {
"comment" : "New Feed"
},
"New Folder" : {
"comment" : "New Folder"
"comment" : "Command"
},
"New Folder…" : {
"comment" : "New Folder"
@@ -672,16 +672,16 @@
"comment" : "Number of Lines"
},
"OK" : {
"comment" : "OK"
"comment" : "OK button"
},
"Open" : {
"comment" : "Open"
},
"Open Home Page" : {
"comment" : "Open Home Page"
"comment" : "Command"
},
"Open in Browser" : {
"comment" : "Open in Browser"
"comment" : "Command"
},
"Open In Browser" : {
"comment" : "Open In Browser"
@@ -720,13 +720,13 @@
"comment" : "Processing - Reader View"
},
"Read" : {
"comment" : "Read label"
"comment" : "Read row label"
},
"Read Articles Filter" : {
"comment" : "Read Articles Filter"
},
"Read Content Deleted" : {
"comment" : "Read content deleted label"
"comment" : "Cleanup stat row label"
},
"read content record" : {
"comment" : "Singular label for read content records"
@@ -753,7 +753,7 @@
"comment" : "Remove Account"
},
"Rename" : {
"comment" : "Rename"
"comment" : "Command"
},
"Rename “%@”" : {
"comment" : "Rename feed"
@@ -762,10 +762,10 @@
"comment" : "Rename sheet"
},
"Return to Previous Scan Results" : {
"comment" : "Return to scan results button"
"comment" : "Return to previous scan results button"
},
"Scan completed." : {
"comment" : "Scan completed text"
"comment" : "Scan status text when completed"
},
"Scan failed." : {
"comment" : "Scan failed text"
@@ -777,7 +777,7 @@
"comment" : "Spinner accessibility label"
},
"Scanning iCloud storage" : {
"comment" : "Scan status text"
"comment" : "Scan status text while fetching"
},
"Search" : {
"comment" : "Search"
@@ -828,7 +828,7 @@
"comment" : "Self hosted Account"
},
"Share" : {
"comment" : "Share"
"comment" : "Share button"
},
"Share Stats" : {
"comment" : "Share stats menu item"
@@ -909,10 +909,10 @@
"comment" : "Star Article"
},
"Starred" : {
"comment" : "Accessibility announcement\nStarred article for accessibility\nStarred label\nStarred pseudo-feed title"
"comment" : "Starred label"
},
"Status Records" : {
"comment" : "Status records header"
"comment" : "Status records section header"
},
"Sync content of unread articles" : {
@@ -931,7 +931,7 @@
},
"The Old Reader" : {
"comment" : "Account name\nThe Old Reader"
"comment" : "Account name"
},
"The theme “%@” already exists. Overwrite it?" : {
"comment" : "Overwrite theme"
@@ -1036,10 +1036,10 @@
"comment" : "Unread label for accessibility"
},
"Unread" : {
"comment" : "Unread\nUnread label"
"comment" : "Unread label"
},
"Unread Content Deleted" : {
"comment" : "Unread content deleted label"
"comment" : "Cleanup stat row label"
},
"unread content record" : {
"comment" : "Singular label for unread content records"
+1 -1
View File
@@ -19,7 +19,7 @@ import Images
return SidebarItemIdentifier.smartFeed(String(describing: StarredFeedDelegate.self))
}
let nameForDisplay = NSLocalizedString("Starred", comment: "Starred pseudo-feed title")
let nameForDisplay = NSLocalizedString("Starred", comment: "Starred label")
let fetchType: FetchType = .starred(nil)
var smallIcon: IconImage? {
Assets.Images.starredFeed
@@ -104,8 +104,8 @@ private extension UserNotificationManager {
}
func registerCategoriesAndActions() {
let readAction = UNNotificationAction(identifier: ActionIdentifier.markAsRead, title: NSLocalizedString("Mark as Read", comment: "Mark as Read"), options: [])
let starredAction = UNNotificationAction(identifier: ActionIdentifier.markAsStarred, title: NSLocalizedString("Mark as Starred", comment: "Mark as Starred"), options: [])
let readAction = UNNotificationAction(identifier: ActionIdentifier.markAsRead, title: NSLocalizedString("Mark as Read", comment: "Command"), options: [])
let starredAction = UNNotificationAction(identifier: ActionIdentifier.markAsStarred, title: NSLocalizedString("Mark as Starred", comment: "Command"), options: [])
let openAction = UNNotificationAction(identifier: ActionIdentifier.openArticle, title: NSLocalizedString("Open", comment: "Open"), options: [.foreground])
let newArticleCategory = UNNotificationCategory(identifier: Self.notificationCategory,
@@ -49,14 +49,14 @@ final class ReaderAPIAccountViewController: UITableViewController {
if let unwrappedAccountType = accountType {
switch unwrappedAccountType {
case .freshRSS:
title = NSLocalizedString("FreshRSS", comment: "FreshRSS")
title = NSLocalizedString("FreshRSS", comment: "Account name")
apiURLTextField.placeholder = NSLocalizedString("API URL: https://fresh.rss.net/api/greader.php", comment: "FreshRSS API Helper")
case .inoreader:
title = NSLocalizedString("Inoreader", comment: "Inoreader")
title = NSLocalizedString("Inoreader", comment: "Account name")
case .bazQux:
title = NSLocalizedString("BazQux", comment: "BazQux")
title = NSLocalizedString("BazQux", comment: "Account name")
case .theOldReader:
title = NSLocalizedString("The Old Reader", comment: "The Old Reader")
title = NSLocalizedString("The Old Reader", comment: "Account name")
default:
title = ""
}
+1 -1
View File
@@ -13,7 +13,7 @@ final class OpenInBrowserActivity: UIActivity {
private var activityItems: [Any]?
override var activityTitle: String? {
return NSLocalizedString("Open in Browser", comment: "Open in Browser")
return NSLocalizedString("Open in Browser", comment: "Command")
}
override var activityImage: UIImage? {
+3 -3
View File
@@ -826,7 +826,7 @@ private extension WebViewController {
func toggleReadAction() -> UIAction? {
guard let article = article, !article.status.read || article.isAvailableToMarkUnread else { return nil }
let title = article.status.read ? NSLocalizedString("Mark as Unread", comment: "Mark as Unread") : NSLocalizedString("Mark as Read", comment: "Mark as Read")
let title = article.status.read ? NSLocalizedString("Mark as Unread", comment: "Command") : NSLocalizedString("Mark as Read", comment: "Command")
let readImage = article.status.read ? Assets.Images.circleClosed : Assets.Images.circleOpen
return UIAction(title: title, image: readImage) { [weak self] _ in
self?.coordinator.toggleReadForCurrentArticle()
@@ -835,7 +835,7 @@ private extension WebViewController {
func toggleStarredAction() -> UIAction {
let starred = article?.status.starred ?? false
let title = starred ? NSLocalizedString("Mark as Unstarred", comment: "Mark as Unstarred") : NSLocalizedString("Mark as Starred", comment: "Mark as Starred")
let title = starred ? NSLocalizedString("Mark as Unstarred", comment: "Command") : NSLocalizedString("Mark as Starred", comment: "Command")
let starredImage = starred ? Assets.Images.starOpen : Assets.Images.starClosed
return UIAction(title: title, image: starredImage) { [weak self] _ in
self?.coordinator.toggleStarredForCurrentArticle()
@@ -860,7 +860,7 @@ private extension WebViewController {
}
func shareAction() -> UIAction {
let title = NSLocalizedString("Share", comment: "Share")
let title = NSLocalizedString("Share", comment: "Share button")
return UIAction(title: title, image: Assets.Images.share) { [weak self] _ in
self?.showActivityDialog()
}
@@ -108,7 +108,7 @@ final class AccountInspectorViewController: UITableViewController {
}
}()
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
let cancelAction = UIAlertAction(title: cancelTitle, style: .cancel)
alertController.addAction(cancelAction)
@@ -213,7 +213,7 @@ extension FeedInspectorViewController {
func notificationUpdateErrorAlert() -> UIAlertController {
let alert = UIAlertController(title: NSLocalizedString("Enable Notifications", comment: "Notifications"),
message: NSLocalizedString("Notifications need to be enabled in the Settings app.", comment: "Notifications need to be enabled in the Settings app."), preferredStyle: .alert)
let openSettings = UIAlertAction(title: NSLocalizedString("Open Settings", comment: "Open Settings"), style: .default) { _ in
let openSettings = UIAlertAction(title: NSLocalizedString("Open Settings", comment: "Open Settings button"), style: .default) { _ in
UIApplication.shared.open(URL(string: UIApplication.openSettingsURLString)!, options: [UIApplication.OpenExternalURLOptionsKey.universalLinksOnly: false], completionHandler: nil)
}
let dismiss = UIAlertAction(title: NSLocalizedString("Dismiss", comment: "Dismiss"), style: .cancel, handler: nil)
+6 -6
View File
@@ -129,10 +129,10 @@ private extension KeyboardManager {
static func globalAuxilaryKeyCommands() -> [UIKeyCommand] {
var keys = [UIKeyCommand]()
let addNewFeedTitle = NSLocalizedString("New Feed", comment: "New Feed")
let addNewFeedTitle = NSLocalizedString("New Feed", comment: "Command")
keys.append(KeyboardManager.createKeyCommand(title: addNewFeedTitle, action: "addNewFeed:", input: "n", modifiers: [.command]))
let addNewFolderTitle = NSLocalizedString("New Folder", comment: "New Folder")
let addNewFolderTitle = NSLocalizedString("New Folder", comment: "Command")
keys.append(KeyboardManager.createKeyCommand(title: addNewFolderTitle, action: "addNewFolder:", input: "n", modifiers: [.command, .shift]))
let refreshTitle = NSLocalizedString("Refresh", comment: "Refresh")
@@ -156,10 +156,10 @@ private extension KeyboardManager {
let articleSearchTitle = NSLocalizedString("Article Search", comment: "Article Search")
keys.append(KeyboardManager.createKeyCommand(title: articleSearchTitle, action: "articleSearch:", input: "f", modifiers: [.command, .alternate]))
let markAllAsReadTitle = NSLocalizedString("Mark All as Read", comment: "Mark All as Read")
let markAllAsReadTitle = NSLocalizedString("Mark All as Read", comment: "Command")
keys.append(KeyboardManager.createKeyCommand(title: markAllAsReadTitle, action: "markAllAsRead:", input: "k", modifiers: [.command]))
let cleanUp = NSLocalizedString("Clean Up", comment: "Clean Up")
let cleanUp = NSLocalizedString("Clean Up", comment: "Clean Up button")
keys.append(KeyboardManager.createKeyCommand(title: cleanUp, action: "cleanUp:", input: "'", modifiers: [.command]))
let toggleReadFeedsFilter = NSLocalizedString("Toggle Read Feeds Filter", comment: "Toggle Read Feeds Filter")
@@ -195,10 +195,10 @@ private extension KeyboardManager {
let toggleReadTitle = NSLocalizedString("Toggle Read Status", comment: "Toggle Read Status")
keys.append(KeyboardManager.createKeyCommand(title: toggleReadTitle, action: "toggleRead:", input: "u", modifiers: [.command, .shift]))
let markAboveAsReadTitle = NSLocalizedString("Mark Above as Read", comment: "Mark Above as Read")
let markAboveAsReadTitle = NSLocalizedString("Mark Above as Read", comment: "Command")
keys.append(KeyboardManager.createKeyCommand(title: markAboveAsReadTitle, action: "markAboveAsRead:", input: "k", modifiers: [.command, .control]))
let markBelowAsReadTitle = NSLocalizedString("Mark Below as Read", comment: "Mark Below as Read")
let markBelowAsReadTitle = NSLocalizedString("Mark Below as Read", comment: "Command")
keys.append(KeyboardManager.createKeyCommand(title: markBelowAsReadTitle, action: "markBelowAsRead:", input: "k", modifiers: [.command, .shift]))
let toggleStarredTitle = NSLocalizedString("Toggle Starred Status", comment: "Toggle Starred Status")
@@ -168,7 +168,7 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
var actions = [UIContextualAction]()
// Set up the delete action
let deleteTitle = NSLocalizedString("Delete", comment: "Delete")
let deleteTitle = NSLocalizedString("Delete", comment: "Delete button")
let deleteAction = UIContextualAction(style: .destructive, title: nil) { [weak self] _, _, completion in
self?.delete(indexPath: indexPath)
completion(true)
@@ -179,7 +179,7 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
actions.append(deleteAction)
// Set up the rename action
let renameTitle = NSLocalizedString("Rename", comment: "Rename")
let renameTitle = NSLocalizedString("Rename", comment: "Command")
let renameAction = UIContextualAction(style: .normal, title: nil) { [weak self] _, _, completion in
self?.rename(indexPath: indexPath)
completion(true)
@@ -221,7 +221,7 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
alert.addAction(action)
}
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alert.addAction(UIAlertAction(title: cancelTitle, style: .cancel) { _ in
completion(true)
})
@@ -452,7 +452,7 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
return
}
let title = NSLocalizedString("Mark All as Read", comment: "Mark All as Read")
let title = NSLocalizedString("Mark All as Read", comment: "Command")
MarkAsReadAlertController.confirm(self, coordinator: coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
self?.coordinator.markAllAsReadInTimeline()
}
@@ -789,7 +789,7 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
@IBAction func add(_ sender: UIBarButtonItem) {
let alertController = UIAlertController(title: nil, message: nil, preferredStyle: .actionSheet)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
let cancelAction = UIAlertAction(title: cancelTitle, style: .cancel)
let addFeedActionTitle = NSLocalizedString("Add Feed", comment: "Add Feed")
@@ -1013,7 +1013,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Open Home Page", comment: "Open Home Page")
let title = NSLocalizedString("Open Home Page", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.safari) { _ in
UIApplication.shared.open(url, options: [:])
}
@@ -1027,7 +1027,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Open Home Page", comment: "Open Home Page")
let title = NSLocalizedString("Open Home Page", comment: "Command")
let action = UIAlertAction(title: title, style: .default) { _ in
UIApplication.shared.open(url, options: [:])
completion(true)
@@ -1041,7 +1041,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Copy Feed URL", comment: "Copy Feed URL")
let title = NSLocalizedString("Copy Feed URL", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.copy) { _ in
UIPasteboard.general.url = url
}
@@ -1054,7 +1054,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Copy Feed URL", comment: "Copy Feed URL")
let title = NSLocalizedString("Copy Feed URL", comment: "Command")
let action = UIAlertAction(title: title, style: .default) { _ in
UIPasteboard.general.url = url
completion(true)
@@ -1069,7 +1069,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Copy Home Page URL", comment: "Copy Home Page URL")
let title = NSLocalizedString("Copy Home Page URL", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.copy) { _ in
UIPasteboard.general.url = url
}
@@ -1083,7 +1083,7 @@ extension MainFeedCollectionViewController {
return nil
}
let title = NSLocalizedString("Copy Home Page URL", comment: "Copy Home Page URL")
let title = NSLocalizedString("Copy Home Page URL", comment: "Command")
let action = UIAlertAction(title: title, style: .default) { _ in
UIPasteboard.general.url = url
completion(true)
@@ -1114,7 +1114,7 @@ extension MainFeedCollectionViewController {
}
func deleteAction(indexPath: IndexPath) -> UIAction {
let title = NSLocalizedString("Delete", comment: "Delete")
let title = NSLocalizedString("Delete", comment: "Delete button")
let action = UIAction(title: title, image: Assets.Images.trash, attributes: .destructive) { [weak self] _ in
self?.delete(indexPath: indexPath)
@@ -1123,7 +1123,7 @@ extension MainFeedCollectionViewController {
}
func renameAction(indexPath: IndexPath) -> UIAction {
let title = NSLocalizedString("Rename", comment: "Rename")
let title = NSLocalizedString("Rename", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.edit) { [weak self] _ in
self?.rename(indexPath: indexPath)
}
@@ -1230,10 +1230,10 @@ extension MainFeedCollectionViewController {
let alertController = UIAlertController(title: title, message: nil, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alertController.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
let renameTitle = NSLocalizedString("Rename", comment: "Rename")
let renameTitle = NSLocalizedString("Rename", comment: "Command")
let renameAction = UIAlertAction(title: renameTitle, style: .default) { [weak self] _ in
guard let name = alertController.textFields?[0].text, !name.isEmpty else {
@@ -1285,21 +1285,21 @@ extension MainFeedCollectionViewController {
let title: String
let message: String
if sidebarItem is Folder {
title = NSLocalizedString("Delete Folder", comment: "Delete folder")
title = NSLocalizedString("Delete Folder", comment: "Command")
let localizedInformativeText = NSLocalizedString("Are you sure you want to delete the “%@” folder?", comment: "Folder delete text")
message = NSString.localizedStringWithFormat(localizedInformativeText as NSString, sidebarItem.nameForDisplay) as String
} else {
title = NSLocalizedString("Delete Feed", comment: "Delete feed")
title = NSLocalizedString("Delete Feed", comment: "Delete Feed")
let localizedInformativeText = NSLocalizedString("Are you sure you want to delete the “%@” feed?", comment: "Feed delete text")
message = NSString.localizedStringWithFormat(localizedInformativeText as NSString, sidebarItem.nameForDisplay) as String
}
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alertController.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
let deleteTitle = NSLocalizedString("Delete", comment: "Delete")
let deleteTitle = NSLocalizedString("Delete", comment: "Delete button")
let deleteAction = UIAlertAction(title: deleteTitle, style: .destructive) { [weak self] _ in
self?.performDelete(indexPath: indexPath)
}
@@ -119,8 +119,8 @@ class MainTimelineCollectionViewCell: UICollectionViewCell {
}
private func updateAccessibilityLabel() {
let starredStatus = cellData.starred ? "\(NSLocalizedString("Starred", comment: "Starred article for accessibility")), " : ""
let unreadStatus = cellData.read ? "" : "\(NSLocalizedString("Unread", comment: "Unread")), "
let starredStatus = cellData.starred ? "\(NSLocalizedString("Starred", comment: "Starred label")), " : ""
let unreadStatus = cellData.read ? "" : "\(NSLocalizedString("Unread", comment: "Unread label")), "
let label = starredStatus + unreadStatus + "\(cellData.feedName), \(cellData.title), \(cellData.summary), \(cellData.dateString)"
accessibilityLabel = label
}
@@ -464,7 +464,7 @@ final class MainTimelineModernViewController: UIViewController, UndoableCommandR
}
@IBAction func markAllAsRead(_ sender: Any?) {
let title = NSLocalizedString("Mark All as Read", comment: "Mark All as Read")
let title = NSLocalizedString("Mark All as Read", comment: "Command")
if let source = sender as? UIBarButtonItem {
MarkAsReadAlertController.confirm(self, coordinator: coordinator, confirmTitle: title, sourceType: source) { [weak self] in
@@ -700,7 +700,7 @@ private extension MainTimelineModernViewController {
// doesn't lag behind user actions.
let announcement = article.status.starred ?
NSLocalizedString("Unstarred", comment: "Accessibility announcement") :
NSLocalizedString("Starred", comment: "Accessibility announcement")
NSLocalizedString("Starred", comment: "Starred label")
UIAccessibility.post(notification: .announcement, argument: announcement)
/// The call to `toggleStar` is delayed in order to allow
@@ -753,7 +753,7 @@ private extension MainTimelineModernViewController {
alert.addAction(action)
}
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alert.addAction(UIAlertAction(title: cancelTitle, style: .cancel) { _ in
completion(true)
})
@@ -785,8 +785,8 @@ private extension MainTimelineModernViewController {
// Set up the read action
let readTitle = article.status.read ?
NSLocalizedString("Mark as Unread", comment: "Mark as Unread") :
NSLocalizedString("Mark as Read", comment: "Mark as Read")
NSLocalizedString("Mark as Unread", comment: "Command") :
NSLocalizedString("Mark as Read", comment: "Command")
let readAction = UIContextualAction(style: .normal, title: readTitle) { [weak self] _, _, completion in
@@ -1124,8 +1124,8 @@ extension MainTimelineModernViewController {
guard !article.status.read || article.isAvailableToMarkUnread else { return nil }
let title = article.status.read ?
NSLocalizedString("Mark as Unread", comment: "Mark as Unread") :
NSLocalizedString("Mark as Read", comment: "Mark as Read")
NSLocalizedString("Mark as Unread", comment: "Command") :
NSLocalizedString("Mark as Read", comment: "Command")
let image = article.status.read ? Assets.Images.circleClosed : Assets.Images.circleOpen
let action = UIAction(title: title, image: image) { [weak self] _ in
@@ -1152,8 +1152,8 @@ extension MainTimelineModernViewController {
func toggleArticleStarStatusAction(_ article: Article) -> UIAction {
let title = article.status.starred ?
NSLocalizedString("Mark as Unstarred", comment: "Mark as Unstarred") :
NSLocalizedString("Mark as Starred", comment: "Mark as Starred")
NSLocalizedString("Mark as Unstarred", comment: "Command") :
NSLocalizedString("Mark as Starred", comment: "Command")
let image = article.status.starred ? Assets.Images.starOpen : Assets.Images.starClosed
let action = UIAction(title: title, image: image) { [weak self] _ in
@@ -1161,7 +1161,7 @@ extension MainTimelineModernViewController {
// doesn't lag behind user actions.
let announcement = article.status.starred ?
NSLocalizedString("Unstarred", comment: "Accessibility announcement") :
NSLocalizedString("Starred", comment: "Accessibility announcement")
NSLocalizedString("Starred", comment: "Starred label")
UIAccessibility.post(notification: .announcement, argument: announcement)
DispatchQueue.main.asyncAfter(wallDeadline: .now() + 1.0) {
@@ -1187,7 +1187,7 @@ extension MainTimelineModernViewController {
return nil
}
let title = NSLocalizedString("Mark Above as Read", comment: "Mark Above as Read")
let title = NSLocalizedString("Mark Above as Read", comment: "Command")
let image = Assets.Images.markAboveAsRead
let action = UIAction(title: title, image: image) { [weak self] _ in
MarkAsReadAlertController.confirm(self, coordinator: self?.coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
@@ -1212,7 +1212,7 @@ extension MainTimelineModernViewController {
return nil
}
let title = NSLocalizedString("Mark Below as Read", comment: "Mark Below as Read")
let title = NSLocalizedString("Mark Below as Read", comment: "Command")
let image = Assets.Images.markBelowAsRead
let action = UIAction(title: title, image: image) { [weak self] _ in
MarkAsReadAlertController.confirm(self, coordinator: self?.coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
@@ -1227,7 +1227,7 @@ extension MainTimelineModernViewController {
return nil
}
let title = NSLocalizedString("Mark Above as Read", comment: "Mark Above as Read")
let title = NSLocalizedString("Mark Above as Read", comment: "Command")
let cancel = {
completion(true)
}
@@ -1246,7 +1246,7 @@ extension MainTimelineModernViewController {
return nil
}
let title = NSLocalizedString("Mark Below as Read", comment: "Mark Below as Read")
let title = NSLocalizedString("Mark Below as Read", comment: "Command")
let cancel = {
completion(true)
}
@@ -1331,7 +1331,7 @@ extension MainTimelineModernViewController {
return nil
}
let localizedMenuText = NSLocalizedString("Mark All as Read in “%@”", comment: "Mark All as Read in Feed")
let localizedMenuText = NSLocalizedString("Mark All as Read in “%@”", comment: "Command")
let title = NSString.localizedStringWithFormat(localizedMenuText as NSString, feed.nameForDisplay) as String
let cancel = {
completion(true)
@@ -1348,7 +1348,7 @@ extension MainTimelineModernViewController {
func copyArticleURLAction(_ article: Article) -> UIAction? {
guard let url = article.preferredURL else { return nil }
let title = NSLocalizedString("Copy Article URL", comment: "Copy Article URL")
let title = NSLocalizedString("Copy Article URL", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.copy) { _ in
UIPasteboard.general.url = url
}
@@ -1357,7 +1357,7 @@ extension MainTimelineModernViewController {
func copyExternalURLAction(_ article: Article) -> UIAction? {
guard let externalLink = article.externalLink, externalLink != article.preferredLink, let url = URL(string: externalLink) else { return nil }
let title = NSLocalizedString("Copy External URL", comment: "Copy External URL")
let title = NSLocalizedString("Copy External URL", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.copy) { _ in
UIPasteboard.general.url = url
}
@@ -1373,7 +1373,7 @@ extension MainTimelineModernViewController {
guard article.preferredURL != nil else {
return nil
}
let title = NSLocalizedString("Open in Browser", comment: "Open in Browser")
let title = NSLocalizedString("Open in Browser", comment: "Command")
let action = UIAction(title: title, image: Assets.Images.safari) { [weak self] _ in
self?.showBrowserForArticle(article)
}
@@ -1385,7 +1385,7 @@ extension MainTimelineModernViewController {
return nil
}
let title = NSLocalizedString("Open in Browser", comment: "Open in Browser")
let title = NSLocalizedString("Open in Browser", comment: "Command")
let action = UIAlertAction(title: title, style: .default) { [weak self] _ in
self?.showBrowserForArticle(article)
completion(true)
@@ -1408,7 +1408,7 @@ extension MainTimelineModernViewController {
func shareAction(_ article: Article, indexPath: IndexPath) -> UIAction? {
guard let url = article.preferredURL else { return nil }
let title = NSLocalizedString("Share", comment: "Share")
let title = NSLocalizedString("Share", comment: "Share button")
let action = UIAction(title: title, image: Assets.Images.share) { [weak self] _ in
self?.shareDialogForTableCell(indexPath: indexPath, url: url, title: article.title)
}
@@ -1417,7 +1417,7 @@ extension MainTimelineModernViewController {
func shareAlertAction(_ article: Article, indexPath: IndexPath, completion: @escaping (Bool) -> Void) -> UIAlertAction? {
guard let url = article.preferredURL else { return nil }
let title = NSLocalizedString("Share", comment: "Share")
let title = NSLocalizedString("Share", comment: "Share button")
let action = UIAlertAction(title: title, style: .default) { [weak self] _ in
completion(true)
self?.shareDialogForTableCell(indexPath: indexPath, url: url, title: article.title)
@@ -47,8 +47,8 @@ extension UIBarButtonItem: MarkAsReadAlertControllerSourceType {}
let title = NSLocalizedString("Mark As Read", comment: "Mark As Read")
let message = NSLocalizedString("You can turn this confirmation off in Settings.",
comment: "You can turn this confirmation off in Settings.")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let settingsTitle = NSLocalizedString("Open Settings", comment: "Open Settings")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
let settingsTitle = NSLocalizedString("Open Settings", comment: "Open Settings button")
let alertController = UIAlertController(title: title, message: message, preferredStyle: .actionSheet)
let cancelAction = UIAlertAction(title: cancelTitle, style: .cancel) { _ in
+2 -2
View File
@@ -21,7 +21,7 @@ import UIKit
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alertController.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
if let websiteURL = URL(string: theme.creatorHomePage) {
@@ -58,7 +58,7 @@ import UIKit
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alertController.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
let overwriteAction = UIAlertAction(title: NSLocalizedString("Overwrite", comment: "Overwrite"), style: .default) { _ in
@@ -79,7 +79,7 @@ final class ArticleThemesTableViewController: UITableViewController {
let theme = ArticleThemesManager.shared.articleThemeWithThemeName(themeName),
!theme.isAppTheme else { return nil }
let deleteTitle = NSLocalizedString("Delete", comment: "Delete")
let deleteTitle = NSLocalizedString("Delete", comment: "Delete button")
let deleteAction = UIContextualAction(style: .normal, title: deleteTitle) { [weak self] (_, _, completion) in
let title = NSLocalizedString("Delete Theme?", comment: "Delete Theme")
@@ -88,13 +88,13 @@ final class ArticleThemesTableViewController: UITableViewController {
let alertController = UIAlertController(title: title, message: message, preferredStyle: .alert)
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
let cancelAction = UIAlertAction(title: cancelTitle, style: .cancel) { _ in
completion(true)
}
alertController.addAction(cancelAction)
let deleteTitle = NSLocalizedString("Delete", comment: "Delete")
let deleteTitle = NSLocalizedString("Delete", comment: "Delete button")
let deleteAction = UIAlertAction(title: deleteTitle, style: .destructive) { _ in
ArticleThemesManager.shared.deleteTheme(themeName: themeName)
completion(true)
+11 -11
View File
@@ -51,7 +51,7 @@ struct CloudKitStatsView: View {
}
}
}
.navigationTitle(NSLocalizedString("iCloud Storage Stats", comment: "Navigation title for iCloud stats view"))
.navigationTitle(NSLocalizedString("iCloud Storage Stats", comment: "iCloud Storage Stats window title"))
.toolbar {
ToolbarItem(placement: .topBarTrailing) {
if model.fetchStatus.isFetching {
@@ -78,7 +78,7 @@ struct CloudKitStatsView: View {
}
}
.alert(NSLocalizedString("Clean Up iCloud Records", comment: "Clean up alert title"), isPresented: $showCleanUpConfirmation) {
Button(NSLocalizedString("Clean Up", comment: "Clean up alert button"), role: .destructive) {
Button(NSLocalizedString("Clean Up", comment: "Clean Up button"), role: .destructive) {
model.cleanUp()
}
Button(NSLocalizedString("Cancel", comment: "Cancel button"), role: .cancel) {
@@ -115,7 +115,7 @@ struct CloudKitStatsView: View {
HStack(spacing: 6) {
ProgressView()
.controlSize(.small)
Text(NSLocalizedString("Scanning iCloud storage", comment: "Scan status text"))
Text(NSLocalizedString("Scanning iCloud storage", comment: "Scan status text while fetching"))
.foregroundStyle(.secondary)
}
.id("fetching")
@@ -123,7 +123,7 @@ struct CloudKitStatsView: View {
HStack(spacing: 4) {
Image(systemName: "checkmark.circle.fill")
.foregroundStyle(.green)
Text(NSLocalizedString("Scan completed.", comment: "Scan completed text"))
Text(NSLocalizedString("Scan completed.", comment: "Scan status text when completed"))
.foregroundStyle(.secondary)
Spacer()
Button(NSLocalizedString("Refresh", comment: "Refresh button")) {
@@ -131,7 +131,7 @@ struct CloudKitStatsView: View {
}
}
case .canceled:
statusRow(NSLocalizedString("Canceled.", comment: "Scan canceled text"))
statusRow(NSLocalizedString("Canceled.", comment: "Scan status text when canceled"))
case .error:
statusRow(NSLocalizedString("Scan failed.", comment: "Scan failed text"))
}
@@ -140,10 +140,10 @@ struct CloudKitStatsView: View {
private var statusRecordsSection: some View {
Section {
statsRow(NSLocalizedString("Status Records", comment: "Status records header"), model.stats.statusCount, isHeader: true)
statsRow(NSLocalizedString("Status Records", comment: "Status records section header"), model.stats.statusCount, isHeader: true)
iconStatsRow(NSLocalizedString("Starred", comment: "Starred label"), systemImage: "star.fill", iconColor: .yellow, model.stats.starredStatusCount, iconBaselineOffset: 1)
iconStatsRow(NSLocalizedString("Unread", comment: "Unread label"), systemImage: "circle.fill", iconColor: .accentColor, model.stats.unreadStatusCount)
statsRow(NSLocalizedString("Read", comment: "Read label"), model.stats.readStatusCount)
statsRow(NSLocalizedString("Read", comment: "Read row label"), model.stats.readStatusCount)
}
}
@@ -161,7 +161,7 @@ struct CloudKitStatsView: View {
statsRow(NSLocalizedString("Article Content Records", comment: "Article content records header"), model.stats.articleCount, isHeader: true)
iconStatsRow(NSLocalizedString("Starred", comment: "Starred label"), systemImage: "star.fill", iconColor: .yellow, model.stats.starredArticleCount, iconBaselineOffset: 1)
iconStatsRow(NSLocalizedString("Unread", comment: "Unread label"), systemImage: "circle.fill", iconColor: .accentColor, model.stats.unreadArticleCount, isWarning: !syncUnreadContent)
statsRow(NSLocalizedString("Read", comment: "Read label"), model.stats.readArticleCount, isWarning: true)
statsRow(NSLocalizedString("Read", comment: "Read row label"), model.stats.readArticleCount, isWarning: true)
}
}
@@ -197,10 +197,10 @@ struct CloudKitStatsView: View {
if let progress = model.cleanUpStatus.progress {
Section {
if progress.readContentDeleted > 0 || progress.phase == .deletingReadContent {
statsRow(NSLocalizedString("Read Content Deleted", comment: "Read content deleted label"), progress.readContentDeleted)
statsRow(NSLocalizedString("Read Content Deleted", comment: "Cleanup stat row label"), progress.readContentDeleted)
}
if progress.unreadContentDeleted > 0 || progress.phase == .deletingUnreadContent {
statsRow(NSLocalizedString("Unread Content Deleted", comment: "Unread content deleted label"), progress.unreadContentDeleted)
statsRow(NSLocalizedString("Unread Content Deleted", comment: "Cleanup stat row label"), progress.unreadContentDeleted)
}
}
}
@@ -209,7 +209,7 @@ struct CloudKitStatsView: View {
@ViewBuilder private var cleanUpNavigationSection: some View {
if model.cleanUpStatus.isCompleted || model.cleanUpStatus.isCanceled {
Section {
Button(NSLocalizedString("Return to Previous Scan Results", comment: "Return to scan results button")) {
Button(NSLocalizedString("Return to Previous Scan Results", comment: "Return to previous scan results button")) {
withAnimation(.easeInOut(duration: 0.25)) {
model.cleanUpStatus = .idle
}
+2 -2
View File
@@ -475,7 +475,7 @@ private extension SettingsViewController {
alert.addAction(action)
}
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alert.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
self.present(alert, animated: true)
@@ -531,7 +531,7 @@ private extension SettingsViewController {
alert.addAction(action)
}
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel")
let cancelTitle = NSLocalizedString("Cancel", comment: "Cancel button")
alert.addAction(UIAlertAction(title: cancelTitle, style: .cancel))
self.present(alert, animated: true)
@@ -85,7 +85,7 @@ private extension UIViewController {
}
let dismissTitle = NSLocalizedString("OK", comment: "OK")
let dismissTitle = NSLocalizedString("OK", comment: "OK button")
let dismissAction = UIAlertAction(title: dismissTitle, style: .default) { _ in
dismiss?()
}