fix: add missing accessibilityLabel to interactable components#1811
fix: add missing accessibilityLabel to interactable components#1811
Conversation
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1811 +/- ##
=======================================
Coverage 59.15% 59.16%
=======================================
Files 322 322
Lines 11261 11264 +3
Branches 3124 3111 -13
=======================================
+ Hits 6662 6664 +2
- Misses 4552 4571 +19
+ Partials 47 29 -18 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Add accessibilityLabel (and accessibilityRole, hitSlop, testID where
missing) to 15 interactable components across screens, components, and
modules so that Android Voice Access and iOS Voice Control can assign
command numbers to them.
- Mark non-semantic overlays (ActionSlider dismiss, ScanCamera tap)
as accessible={false}
- Use prop values for labels where applicable (SingleSelectBlock,
CredentialCard11ActionFooter, BaseToast, Banner)
- Add new i18n keys for PINEnter, PasteUrl, ProofChangeCredential,
Settings, VerifierCredentialCard, OpenIDProofChangeCredential
- Extract shared cardTitleKeys map in HistoryListItem
Closes: #1809
Signed-off-by: Jason C. Leach <jason.leach@fullboar.ca>
Signed-off-by: Jason C. Leach <jason.leach@fullboar.ca>
Suppress console.debug during tests (override with TEST_VERBOSE=1) so expected resolver failures in helpers.ts don't clutter test output. Mark @bifold/core jest.mock as virtual so logger.comprehensive.test.ts no longer requires a built @bifold/core to resolve. Signed-off-by: Jason C. Leach <jason.leach@fullboar.ca>
2576124 to
b366632
Compare
|
|
@jleach similar work was done in BC Wallet, |
|
this PR is missing a changeset |



Summary
Adds missing
accessibilityLabel(and where absent,accessibilityRole,hitSlop,testID) to 15 interactable components across 14 files in@bifold/coreso Android Voice Access and iOS Voice Control can assign numbered commands to every tappable element.Non-semantic overlays — marked
accessible={false}ActionSliderdismiss overlay (TouchableOpacity) — tap-outside-to-close, no meaningful labelScanCameratap-to-focus area (Pressable) — camera overlay, no meaningful labelCloses #1809
Labels derived from existing props
SingleSelectBlock—accessibilityLabel={item.value}, addsaccessibilityRole="radio"andaccessibilityState={{ selected }}CredentialCard11ActionFooter—accessibilityLabel={text}, addsaccessibilityRole="button"andhitSlopBaseToastouter touchable —accessibilityLabel={title},accessibilityRole="alert",testIDBaseToastclose button — newGlobal.CloseNotificationkey,accessibilityRole="button",hitSlop,testIDBanner—accessibilityLabel={title},accessibilityRole="button"HistoryListItem— composite label from card-type title + correspondence name; extracts a sharedcardTitleKeysmap for DRY translation key resolutionLabels from new i18n keys
PINEnterdeveloper menu triggerPINEnter.DeveloperMenuTriggerPasteUrlURL text inputPasteUrl.PasteUrlInputPasteUrldisabled submit buttonPasteUrl.ScanDisabledProofChangeCredentialselect buttonProofRequest.SelectCredentialOpenIDProofChangeCredentialselect buttonProofRequest.SelectCredential(shared)VerifierCredentialCardpredicate inputProofRequest.PredicateInput(interpolated with field label)Settingsversion info triggerSettings.VersionInfoNew keys added to
en.json,fr.json, andpt-br.json(FR and PT-BR entries marked with language suffix pending translation).Test plan
SingleSelectBlockannounces selected state correctly with TalkBack / VoiceOverBaseToastclose button is reachable and announced as "Close notification"HistoryListItemrows announce card type + correspondence nameVerifierCredentialCardpredicate inputs announce the field labelaccessible={false}overlays remain invisible to sighted users