From 535efc1403e53bde190ce5ddb7ecf97918c5e5fd Mon Sep 17 00:00:00 2001 From: Riccardo Cipolleschi Date: Fri, 17 Oct 2025 09:47:58 -0700 Subject: [PATCH] Fixed tint color for action sheets (#54180) Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/54180 in iOS 26, the tintColor prop is not applied by default to the action sheets buttons. This change fixes it by restoring the same behavior we had before iOS 26. ## Changelog: [iOS][Fixed] - Apply tint color to Actions sheets buttons Reviewed By: cortinico Differential Revision: D84844319 fbshipit-source-id: e211d0a735ea2da35f825c3568d66ba83e4ad832 --- .../React/CoreModules/RCTActionSheetManager.mm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/react-native/React/CoreModules/RCTActionSheetManager.mm b/packages/react-native/React/CoreModules/RCTActionSheetManager.mm index 07d52c5c32c..2d630032f2e 100644 --- a/packages/react-native/React/CoreModules/RCTActionSheetManager.mm +++ b/packages/react-native/React/CoreModules/RCTActionSheetManager.mm @@ -168,8 +168,15 @@ RCT_EXPORT_METHOD(showActionSheetWithOptions callback(@[ @(localIndex) ]); } }]; - if (isCancelButtonIndex) { + if (isCancelButtonIndex && cancelButtonTintColor != NULL) { [actionButton setValue:cancelButtonTintColor forKey:@"titleTextColor"]; + } else if (style != UIAlertActionStyleDestructive) { + // iOS 26 does not apply the tint color automatically to all the buttons. + // So we ca forcibly apply the tint color to all the buttons that are not + // destructive (which usually have a different tint color) nor they are + // cancel buttons (which might have a different tint color). + // This makes the Action Sheet behave as in iOS < 26. + [actionButton setValue:tintColor forKey:@"titleTextColor"]; } [alertController addAction:actionButton];