iOS: Respect Auto-Play Animated Images setting#2182
iOS: Respect Auto-Play Animated Images setting#2182ganidande905 wants to merge 2 commits intozulip:mainfrom
Conversation
|
@chrisbobbe Could you please review this when convenient? The PR follows the contribution guidelines and all CI checks are passing. Thanks |
|
Please remove the unrelated code formatting changes. |
f41e6d8 to
722df08
Compare
|
@chrisbobbe I’ve removed the unrelated formatting changes and kept the diff limited to the intended logic change. Please let me know if this looks good now. |
|
Please update your commit message to match our style (it's missing a properly-formatted issue reference) and add a test for this new logic; see the project README. It looks like the feature is new in iOS 17. What behavior do we offer users on older iOS versions? The earliest we support is 15.0 (from ios/Podfile). Probably falling back to that reduce-motion setting would be a reasonable behavior. We should also include test coverage for that case. |
|
I’ll update the commit message and add tests for the new logic.
|
4d17e56 to
e796816
Compare
Fixes zulip#1924. Update ImageAnimationMode.shouldAnimate to respect the iOS "auto-play animated images" accessibility setting and reduce motion when determining whether images should animate.
Add widget tests covering ImageAnimationMode.shouldAnimate behavior when animations are disabled via MediaQuery and iOS accessibility settings.
e796816 to
bc8d9a6
Compare
|
Hi! I've pushed the latest changes addressing the feedback and updated the tests as well. Could you please take a look at the updated commits when you have time? Thanks! |
|
Thanks. Before we can fully review this PR, you'll need to revise it to have clear and coherent commits. See the resources linked from our README. Pay attention also to making the code look and work similarly to existing code in the codebase. For example, note what our README says about |
Overview - Fixes #1924
This PR updates ImageAnimationMode.shouldAnimate to respect the iOS 17+ accessibility setting Auto-Play Animated Images, using Flutter’s
AccessibilityFeatures.autoPlayAnimatedImages.What changed
autoPlayAnimatedImages(the setting intended for animated images/GIFs).Testing
Edge case / follow-up
ImageAnimationMode(or equivalent gating) into the inline image/link-preview renderer, which seems out of scope for this issue.Screen Recording
The screen recording demonstrates the behaviour of animated images with the iOS Auto-Play Animated Images accessibility setting:
Inline GIFs from pasted URLs are included in the recording to show current behaviour; however, that rendering path does not consult ImageAnimationMode, so it does not yet respect the setting (as noted in the edge-case section above).
Screen.Recording.Feb.26.2026.1.1.mov