From 28878a2df1e264ea342ceeed4a41e606a830ed10 Mon Sep 17 00:00:00 2001 From: Dmitry Zhigulin <104712148+faciledictu@users.noreply.github.com> Date: Thu, 22 Oct 2026 22:56:28 +0000 Subject: [PATCH] fix(iOS): apply accessibility props to the indicator in ActivityIndicator The accessibility props of ActivityIndicator went to the host view, which is not an accessibility element, so VoiceOver read the inner UIActivityIndicatorView with its default label. Return the indicator from accessibilityElement, as RCTSwitchComponentView does for UISwitch. --- .../RCTActivityIndicatorViewComponentView.mm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages/react-native/React/Fabric/Mounting/ComponentViews/ActivityIndicator/RCTActivityIndicatorViewComponentView.mm b/packages/react-native/React/Fabric/Mounting/ComponentViews/ActivityIndicator/RCTActivityIndicatorViewComponentView.mm index 0797faa47e15..91b2d3c867ac 100644 --- a/packages/react-native/React/Fabric/Mounting/ComponentViews/ActivityIndicator/RCTActivityIndicatorViewComponentView.mm +++ b/packages/react-native/React/Fabric/Mounting/ComponentViews/ActivityIndicator/RCTActivityIndicatorViewComponentView.mm @@ -91,6 +91,18 @@ - (void)updateProps:(const Props::Shared &)props oldProps:(const Props::Shared & [super updateProps:props oldProps:oldProps]; } +// UIActivityIndicatorView is the accessibility element, not this view, so the +// accessibility props go to it. +- (BOOL)isAccessibilityElement +{ + return NO; +} + +- (NSObject *)accessibilityElement +{ + return _activityIndicatorView; +} + @end Class RCTActivityIndicatorViewCls(void)