Updated textView to have label text for accessibility behavior
This commit is contained in:
parent
85e967c492
commit
d65df06934
@ -281,6 +281,11 @@ class TextViewEntryField: EntryField, UITextViewDelegate, ObservingTextFieldDele
|
||||
if model.hideBorders {
|
||||
adjustMarginConstraints(constant: 0)
|
||||
}
|
||||
|
||||
setAccessibilityString(model.title)
|
||||
}
|
||||
|
||||
override func setAccessibilityString(_ accessibilityString: String?) {
|
||||
let accessibilityString = accessibilityString ?? ""
|
||||
textView.accessibilityLabel = "\(String(describing: accessibilityString)) \(self.textView.isEnabled ? "" : MVMCoreUIUtility.hardcodedString(withKey: "textfield_disabled_state") ?? "")"
|
||||
}
|
||||
}
|
||||
|
||||
@ -98,7 +98,6 @@ import UIKit
|
||||
smartInsertDeleteType = .no
|
||||
inputAccessoryView = nil
|
||||
isAccessibilityElement = true
|
||||
accessibilityTraits = .staticText
|
||||
font = fontStyle.getFont()
|
||||
keyboardType = .default
|
||||
isEditable = true
|
||||
|
||||
@ -27,6 +27,7 @@
|
||||
// MARK: Textfield
|
||||
"textfield_today_string" = "Today";
|
||||
"textfield_error_message" = "%@.\n The error message.\n %@";
|
||||
"textView_error_message" = "%@.\n The error message.\n %@";
|
||||
"textfield_picker_item" = " picker item";
|
||||
"textfield_regular" = " regular";
|
||||
"textfield_disabled_state" = "disabled";
|
||||
|
||||
@ -23,6 +23,7 @@
|
||||
// Textfield
|
||||
"textfield_today_string" = "Hoy";
|
||||
"textfield_error_message" = "%@.\n El mensaje de error.\n %@";
|
||||
"textView_error_message" = "%@.\n El mensaje de error.\n %@";
|
||||
"textfield_picker_item" = " artículo de selector";
|
||||
"textfield_regular" = " regular";
|
||||
"textfield_disabled_state" = "inactivo";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user