|
14 | 14 | #import <React/RCTAssert.h>
|
15 | 15 | #import <React/RCTBorderDrawing.h>
|
16 | 16 | #import <React/RCTConversions.h>
|
| 17 | +#import <React/RCTLocalizedString.h> |
17 | 18 | #import <react/renderer/components/view/ViewComponentDescriptor.h>
|
18 | 19 | #import <react/renderer/components/view/ViewEventEmitter.h>
|
19 | 20 | #import <react/renderer/components/view/ViewProps.h>
|
@@ -731,28 +732,38 @@ - (NSString *)accessibilityValue
|
731 | 732 | // these to screenreader users. (They should already be familiar with them
|
732 | 733 | // from using web).
|
733 | 734 | if ([roleString isEqualToString:@"checkbox"]) {
|
734 |
| - [valueComponents addObject:@"checkbox"]; |
| 735 | + [valueComponents addObject:RCTLocalizedString("checkbox", "checkable interactive control")]; |
735 | 736 | }
|
736 | 737 |
|
737 | 738 | if ([roleString isEqualToString:@"radio"]) {
|
738 |
| - [valueComponents addObject:@"radio button"]; |
| 739 | + [valueComponents |
| 740 | + addObject: |
| 741 | + RCTLocalizedString( |
| 742 | + "radio button", |
| 743 | + "a checkable input that when associated with other radio buttons, only one of which can be checked at a time")]; |
739 | 744 | }
|
740 | 745 |
|
741 | 746 | // Handle states which haven't already been handled.
|
742 | 747 | if (props.accessibilityState.checked == AccessibilityState::Checked) {
|
743 |
| - [valueComponents addObject:@"checked"]; |
| 748 | + [valueComponents |
| 749 | + addObject:RCTLocalizedString("checked", "a checkbox, radio button, or other widget which is checked")]; |
744 | 750 | }
|
745 | 751 | if (props.accessibilityState.checked == AccessibilityState::Unchecked) {
|
746 |
| - [valueComponents addObject:@"unchecked"]; |
| 752 | + [valueComponents |
| 753 | + addObject:RCTLocalizedString("unchecked", "a checkbox, radio button, or other widget which is unchecked")]; |
747 | 754 | }
|
748 | 755 | if (props.accessibilityState.checked == AccessibilityState::Mixed) {
|
749 |
| - [valueComponents addObject:@"mixed"]; |
| 756 | + [valueComponents |
| 757 | + addObject:RCTLocalizedString( |
| 758 | + "mixed", "a checkbox, radio button, or other widget which is both checked and unchecked")]; |
750 | 759 | }
|
751 | 760 | if (props.accessibilityState.expanded) {
|
752 |
| - [valueComponents addObject:@"expanded"]; |
| 761 | + [valueComponents |
| 762 | + addObject:RCTLocalizedString("expanded", "a menu, dialog, accordian panel, or other widget which is expanded")]; |
753 | 763 | }
|
| 764 | + |
754 | 765 | if (props.accessibilityState.busy) {
|
755 |
| - [valueComponents addObject:@"busy"]; |
| 766 | + [valueComponents addObject:RCTLocalizedString("busy", "an element currently being updated or modified")]; |
756 | 767 | }
|
757 | 768 |
|
758 | 769 | if (valueComponents.count > 0) {
|
|
0 commit comments