Skip to content

Commit

Permalink
[RNMobile] Improve text read by screen readers for BottomSheetSelectC…
Browse files Browse the repository at this point in the history
…ontrol (#41036)

Improves the text that's read by screen readers by the BottomSheetSelectControl component, adding extra context and making its purpose clearer.
  • Loading branch information
Siobhan Bamber committed May 13, 2022
1 parent 239a7ce commit b83ce72
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,16 @@ const BottomSheetSelectControl = ( {
value={ selectedOption.label }
onPress={ openSubSheet }
accessibilityRole={ 'button' }
accessibilityLabel={ selectedOption.label }
accessibilityLabel={ sprintf(
// translators: %1$s: Select control button label e.g. "Button width". %2$s: Select control option value e.g: "Auto, 25%".
__( '%1$s. Currently selected: %2$s' ),
label,
selectedOption.label
) }
accessibilityHint={ sprintf(
// translators: %s: Select control button label e.g. "Button width"
__( 'Navigates to select %s' ),
selectedOption.label
label
) }
>
<Icon icon={ chevronRight }></Icon>
Expand Down
1 change: 1 addition & 0 deletions packages/react-native-editor/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ For each user feature we should also add a importance categorization label to i

## Unreleased

- [*] [a11y] Improve text read by screen readers for BottomSheetSelectControl [#41036]

## 1.76.0

Expand Down

0 comments on commit b83ce72

Please sign in to comment.