-
Notifications
You must be signed in to change notification settings - Fork 127
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal to add support for "Prefer Cross-Fade Transitions" into AccessibilityInfo #452
Comments
I believe this would be especially helpful for solving facebook/react-native#31484 |
This would help improve react-navigation for users who have motion sensitivity and prefer cross-fade transitions |
1 task
1 task
facebook-github-bot
pushed a commit
to facebook/react-native
that referenced
this issue
Aug 25, 2022
…ityInfo (#34406) Summary: This PR adds `prefersCrossFadeTransitions()` to AccessibilityInfo in order to add support for "Prefer Cross-Fade Transitions", exposing the iOS settings option as proposed here react-native-community/discussions-and-proposals#452. I believe this would be especially helpful for solving #31484 #### TODO - [ ] Submit react-native-web PR updating AccessibilityInfo documentation. ## Changelog [iOS] [Added] - Add support for "Prefer Cross-Fade Transitions" into AccessibilityInfo Pull Request resolved: #34406 Test Plan: **On iOS 14+** 1. Access Settings > "General" > "Accessibility" > "Reduce Motion", enable "Reduce Motion" then enable "Prefer Cross-Fade Transitions". 2. Open the RNTester app and navigate to the Accessibility page https://user-images.githubusercontent.com/11707729/154588402-7d050858-3c2d-4d86-9585-928b8c66941b.mov Reviewed By: cipolleschi Differential Revision: D38711316 Pulled By: makovkastar fbshipit-source-id: b9965cd4285f1aa0f1fa927080370a22329c2f62
I'm closing this as the support for "Prefer Cross-Fade Transitions" into AccessibilityInfo was added through facebook/react-native@be7c50f |
kelset
pushed a commit
to facebook/react-native
that referenced
this issue
Oct 3, 2022
…ityInfo (#34406) Summary: This PR adds `prefersCrossFadeTransitions()` to AccessibilityInfo in order to add support for "Prefer Cross-Fade Transitions", exposing the iOS settings option as proposed here react-native-community/discussions-and-proposals#452. I believe this would be especially helpful for solving #31484 #### TODO - [ ] Submit react-native-web PR updating AccessibilityInfo documentation. ## Changelog [iOS] [Added] - Add support for "Prefer Cross-Fade Transitions" into AccessibilityInfo Pull Request resolved: #34406 Test Plan: **On iOS 14+** 1. Access Settings > "General" > "Accessibility" > "Reduce Motion", enable "Reduce Motion" then enable "Prefer Cross-Fade Transitions". 2. Open the RNTester app and navigate to the Accessibility page https://user-images.githubusercontent.com/11707729/154588402-7d050858-3c2d-4d86-9585-928b8c66941b.mov Reviewed By: cipolleschi Differential Revision: D38711316 Pulled By: makovkastar fbshipit-source-id: b9965cd4285f1aa0f1fa927080370a22329c2f62
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Introduction
I would like to propose adding support for "Prefer Cross-Fade Transitions" into AccessibilityInfo by exposing the iOS
UIAccessibilityPrefersCrossFadeTransitions()
function.Details
UIAccessibilityPrefersCrossFadeTransitions
was added to UIKit on iOS 14.0 indicating whether the Reduce Motion and the Prefer Cross-Fade Transitions settings are in an enabled state. It would be great to have a method for that embedded into AccessibilityInfo. As this is an iOS-only feature I suggest we just always return false on Android.There's a caveat though, we would not be able to add support for a
prefersCrossFadeTransitionsChanged
event intoAccessibilityInfo.addEventListener
because from my testing (iOS 14.4 and 15.2)UIAccessibilityPrefersCrossFadeTransitionsStatusDidChangeNotification
does not get triggered when changing the "Prefer Cross-Fade Transitions" option in the accessibility settings, due to this factor we would need to callUIAccessibilityPrefersCrossFadeTransitions()
every time to get the most updated value instead of storing it into a private variable insideRCTAccessibilityManager
My idea is to add a
prefersCrossFadeTransitions
function toAccessibilityInfo
which would probably look something like this:Note: I already have a draft for this implementation if anyone is interested in taking a look gabrieldonadel/react-native#2
Discussion points
prefersCrossFadeTransitions
function to AccessibilityInfo?The text was updated successfully, but these errors were encountered: