Skip to content

fix: a11y actionable items fixes#3628

Merged
isekovanic merged 7 commits into
developfrom
fix/a11y-actionable-items-fixes
Jun 1, 2026
Merged

fix: a11y actionable items fixes#3628
isekovanic merged 7 commits into
developfrom
fix/a11y-actionable-items-fixes

Conversation

@isekovanic
Copy link
Copy Markdown
Contributor

🎯 Goal

This PR should fix some outstanding a11y issues for screen readers. The prior foundation work (a11y context, useA11yLabel, useAccessibilityAnnouncer, useResolvedModalAccessibilityProps, translation namespace, etc.) shipped the primitives. This PR uses those primitives to fix the surfaces flagged by an audit - polls, message context menus, and bottom sheets.

🛠 Implementation details

Five focused changes, each scoped to one surface:

Poll - actionable rotor (Poll.tsx, new usePollAccessibilityActions/usePollAccessibilityLabel/PollUIStateContext)

  • Voting, ending the vote, and "show all options" are now exposed as standard accessibility actions. Screen reader users reach each interaction via the rotor/actions menu instead of having to hunt for the right subelement
  • PollUIStateContext carries state across the poll's modals (vote / see results / end vote confirm) so the available action set stays correct as the user navigates (we do this so that we have one source of truth for firing these actions)

Poll & Message - context menu hint

  • accessibilityHint='a11y/Double tap and hold to activate contextual menu' on both MessageContent and Poll, so screen reader users know a long-press menu is available before triggering it

Message overlay - open announcement (MessageOverlayHostLayer.tsx)

  • One shot announceForAccessibility('Swipe right to go through different actions') when the overlay activates. useRef dedupes so it speaks once per open and resets on close

BottomSheetModal - modal trait + accessible dismiss (BottomSheetModal.tsx)

  • Drag handle is now a focusable element labeled "Close" with accessibilityRole='button'
  • iOS VoiceOver double tap goes into onAccessibilityTap which goes into onClose
  • Android TalkBack double tap goes into accessibilityActions=[{name:'activate'}] + onAccessibilityAction which then goes into onClose as well
  • iOS two-finger Z scrub triggers onAccessibilityEscape={onClose}. Android hardware back was already wired through Modal.onRequestClose.
  • One shot open announcement, deferred 800ms so VoiceOver's auto focus shift speech ("Close, button") doesn't preempt the announce mid sentence.
  • Lifts to every consumer automatically: Reactions detail, "More reactions" emoji picker, Attachment type picker, Image gallery grid view.

Translations

  • Five new a11y/* keys (Bottom sheet opened…, Close, Double tap and hold to activate contextual menu, Swipe right to go through different actions, plus the poll action labels) added to all 13 locales.

🎨 UI Changes

iOS
Before After
Android
Before After

🧪 Testing

☑️ Checklist

  • I have signed the Stream CLA (required)
  • PR targets the develop branch
  • Documentation is updated
  • New code is tested in main example apps, including all possible scenarios
    • SampleApp iOS and Android
    • Expo iOS and Android

@isekovanic isekovanic requested review from oliverlaz and szuperaz June 1, 2026 15:45
@Stream-SDK-Bot
Copy link
Copy Markdown
Contributor

SDK Size

title develop branch diff status
js_bundle_size 1802 KB 1814 KB +12569 B 🔴

@isekovanic isekovanic merged commit 439776a into develop Jun 1, 2026
4 of 5 checks passed
@isekovanic isekovanic deleted the fix/a11y-actionable-items-fixes branch June 1, 2026 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants