From ee1176c17ad9e19afe53663387d50b44e657d9bc Mon Sep 17 00:00:00 2001 From: rachelmcr Date: Mon, 5 Oct 2020 21:39:13 +0100 Subject: [PATCH 1/3] Don't localize text field accessibility identifiers --- .../Reusable Views/TextFieldTableViewCell.swift | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift b/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift index 1cbda6d4f..af05d52da 100644 --- a/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift +++ b/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift @@ -89,13 +89,13 @@ private extension TextFieldTableViewCell { textField.returnKeyType = .continue registerTextFieldAction() textField.accessibilityLabel = Constants.siteAddress - textField.accessibilityIdentifier = Constants.siteAddress + textField.accessibilityIdentifier = Constants.siteAddressID case .username: textField.keyboardType = .default textField.returnKeyType = .next setupOnePasswordButtonIfNeeded() textField.accessibilityLabel = Constants.username - textField.accessibilityIdentifier = Constants.username + textField.accessibilityIdentifier = Constants.usernameID case .password: textField.keyboardType = .default textField.returnKeyType = .continue @@ -103,19 +103,19 @@ private extension TextFieldTableViewCell { showSecureTextEntryToggle = true configureSecureTextEntryToggle() textField.accessibilityLabel = Constants.password - textField.accessibilityIdentifier = Constants.password + textField.accessibilityIdentifier = Constants.passwordID case .numericCode: textField.keyboardType = .numberPad textField.returnKeyType = .continue textField.accessibilityLabel = Constants.otp - textField.accessibilityIdentifier = Constants.otp + textField.accessibilityIdentifier = Constants.otpID case .email: textField.keyboardType = .emailAddress textField.returnKeyType = .continue textField.textContentType = .username // So the password autofill appears on the keyboard setupOnePasswordButtonIfNeeded() textField.accessibilityLabel = Constants.email - textField.accessibilityIdentifier = Constants.email + textField.accessibilityIdentifier = Constants.emailID } } @@ -236,11 +236,17 @@ extension TextFieldTableViewCell { comment: "Accessibility label of the site address field shown when adding a self-hosted site.") static let username = NSLocalizedString("Username", comment: "Accessibility label for the username text field in the self-hosted login page.") + static let password = NSLocalizedString("Password", comment: "Accessibility label for the password text field in the self-hosted login page.") static let otp = NSLocalizedString("Authentication code", comment: "Accessibility label for the 2FA text field.") static let email = NSLocalizedString("Email address", comment: "Accessibility label for the email address text field.") + static let siteAddressID = "Site address" + static let usernameID = "Username" + static let passwordID = "Password" + static let otpID = "Authentication code" + static let emailID = "Email address" } } From 753b7643948cfde00425779eba86c36c689025fb Mon Sep 17 00:00:00 2001 From: rachelmcr Date: Tue, 6 Oct 2020 10:26:09 +0100 Subject: [PATCH 2/3] Bump pod version --- WordPressAuthenticator.podspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/WordPressAuthenticator.podspec b/WordPressAuthenticator.podspec index 5bdf0af6f..c7c3a1e42 100644 --- a/WordPressAuthenticator.podspec +++ b/WordPressAuthenticator.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "WordPressAuthenticator" - s.version = "1.26.0" + s.version = "1.27.0-beta.1" s.summary = "WordPressAuthenticator implements an easy and elegant way to authenticate your WordPress Apps." s.description = <<-DESC From 20f709620d777e72bd42342e4bdf86f25d7a7cbc Mon Sep 17 00:00:00 2001 From: rachelmcr Date: Tue, 6 Oct 2020 10:31:48 +0100 Subject: [PATCH 3/3] Clean up extra line break --- .../View Related/Reusable Views/TextFieldTableViewCell.swift | 1 - 1 file changed, 1 deletion(-) diff --git a/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift b/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift index af05d52da..b6e8e78d4 100644 --- a/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift +++ b/WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift @@ -236,7 +236,6 @@ extension TextFieldTableViewCell { comment: "Accessibility label of the site address field shown when adding a self-hosted site.") static let username = NSLocalizedString("Username", comment: "Accessibility label for the username text field in the self-hosted login page.") - static let password = NSLocalizedString("Password", comment: "Accessibility label for the password text field in the self-hosted login page.") static let otp = NSLocalizedString("Authentication code",