Skip to content
This repository was archived by the owner on Feb 5, 2025. It is now read-only.

Commit 6ab9cdd

Browse files
Merge pull request #493 from wordpress-mobile/fix/accessibility-ids
Remove localization from accessibility IDs
2 parents c90f02e + 20f7096 commit 6ab9cdd

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

WordPressAuthenticator.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = "WordPressAuthenticator"
3-
s.version = "1.26.0"
3+
s.version = "1.27.0-beta.1"
44
s.summary = "WordPressAuthenticator implements an easy and elegant way to authenticate your WordPress Apps."
55

66
s.description = <<-DESC

WordPressAuthenticator/Unified Auth/View Related/Reusable Views/TextFieldTableViewCell.swift

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -89,33 +89,33 @@ private extension TextFieldTableViewCell {
8989
textField.returnKeyType = .continue
9090
registerTextFieldAction()
9191
textField.accessibilityLabel = Constants.siteAddress
92-
textField.accessibilityIdentifier = Constants.siteAddress
92+
textField.accessibilityIdentifier = Constants.siteAddressID
9393
case .username:
9494
textField.keyboardType = .default
9595
textField.returnKeyType = .next
9696
setupOnePasswordButtonIfNeeded()
9797
textField.accessibilityLabel = Constants.username
98-
textField.accessibilityIdentifier = Constants.username
98+
textField.accessibilityIdentifier = Constants.usernameID
9999
case .password:
100100
textField.keyboardType = .default
101101
textField.returnKeyType = .continue
102102
setSecureTextEntry(true)
103103
showSecureTextEntryToggle = true
104104
configureSecureTextEntryToggle()
105105
textField.accessibilityLabel = Constants.password
106-
textField.accessibilityIdentifier = Constants.password
106+
textField.accessibilityIdentifier = Constants.passwordID
107107
case .numericCode:
108108
textField.keyboardType = .numberPad
109109
textField.returnKeyType = .continue
110110
textField.accessibilityLabel = Constants.otp
111-
textField.accessibilityIdentifier = Constants.otp
111+
textField.accessibilityIdentifier = Constants.otpID
112112
case .email:
113113
textField.keyboardType = .emailAddress
114114
textField.returnKeyType = .continue
115115
textField.textContentType = .username // So the password autofill appears on the keyboard
116116
setupOnePasswordButtonIfNeeded()
117117
textField.accessibilityLabel = Constants.email
118-
textField.accessibilityIdentifier = Constants.email
118+
textField.accessibilityIdentifier = Constants.emailID
119119
}
120120
}
121121

@@ -242,5 +242,10 @@ extension TextFieldTableViewCell {
242242
comment: "Accessibility label for the 2FA text field.")
243243
static let email = NSLocalizedString("Email address",
244244
comment: "Accessibility label for the email address text field.")
245+
static let siteAddressID = "Site address"
246+
static let usernameID = "Username"
247+
static let passwordID = "Password"
248+
static let otpID = "Authentication code"
249+
static let emailID = "Email address"
245250
}
246251
}

0 commit comments

Comments
 (0)