Jump to content
Search Community

Iphone Low power mode animation flicker issue on single hold scroll.

codechirag test
Moderator Tag

Recommended Posts

Namaste Guys, I have worked with quite many projects using gsap and recently found a very annoying issue in an old project. It is flickering a lot only while on low power mode in Iphone. I am attaching the video here. Please if you guys have any clue help me out.

 

Here is the link of video https://www.loom.com/share/3d5d2721c3ab4c2a801dde2ee702d8ff

and here is the url of website : https://ovecare.com/

Link to comment
Share on other sites

Just to be clear, GSAP doesn't change ANYTHING when a device is in low-power mode; the problem here is that iOS devices suddenly slow down JS execution (the frame rate in particular, like requestAnimationFrame()) significantly when in low-power mode. The device is doing that, and GSAP has no way of forcing it back to normal performance levels. It's not a limitation of GSAP; it's a browser-forced issue.

  • Like 1
Link to comment
Share on other sites

7 hours ago, Rodrigo said:

I tested on my iPad and yeah it doesn't look good at all. Maybe you're using normalizeScroll? Try disabling it and use ignoreMobileResize instead:

Hey @Rodrigo Thanks. I have tried this but still the same. I doubt on what the @GreenSock is saying because, I have used gsap in many websites not all those are causing issue in the same scenario. i.e. https://solusent.com/

Link to comment
Share on other sites

Sorry but I don't really know what to tell you. I checked  the other link you shared and it works fine on battery saving mode, same as these links from our site:

https://gsap.com/

 

https://gsap.com/scroll/

 

There is something in this other site that is causing that but I'm afraid that without a minimal demo that clearly reproduces the problem there is not a lot we can do to help debugging this 😞

Link to comment
Share on other sites

Sorry but we don't have the time resources to comb through an entire codebase trying to find potential issues and problems, and then start testing in order to see what/how can they be resolved, is beyond the scope of what we do in these free forums.

Link to comment
Share on other sites

On 9/16/2024 at 8:21 PM, Rodrigo said:

Hi,

 

I tested on my iPad and yeah it doesn't look good at all. Maybe you're using normalizeScroll? Try disabling it and use ignoreMobileResize instead:

https://gsap.com/docs/v3/Plugins/ScrollTrigger/static.config()#details

ScrollTrigger.config({ ignoreMobileResize: true });

Hopefully this helps.

Happy Tweening!

where do I put this in a react app?
can I stick it directly after registering plugins after importing it, like so?

gsap.registerPlugin(useGSAP, ScrollTrigger, ScrollToPlugin);
ScrollTrigger.config({ ignoreMobileResize: true });

?

Link to comment
Share on other sites

hey @Rodrigo, Finally I found the issue. It is happening due to use of

if (ScrollTrigger.isTouch === 1) {
   ScrollTrigger.normalizeScroll(true);
}

And I have used this for some other section and also I took this solution from the thread and solution by you only 

So, I found this recent issue solution but if I remove the normalize scroll then the jerk issue starts comming.

Link to comment
Share on other sites

To be clear, if you remove normalizeScroll the flicker goes away but a new issue appears, right?

 

Sorry but I really don't know what to tell you, this really sucks and sounds like no fun at all. Unfortunately iOS is really painful when it comes to scroll and there are issues that have been open for years now without any response from apple. Normalize Scroll is our best attempt to make things work as good as possible across all devices and browsers but unfortunately is not a silver bullet for every issue out there.

 

What I could recommend is to do some checking for low battery mode on iOS and create a different version of your code and animations in order to prevent UX issues:

https://stackoverflow.com/questions/46670150/low-power-mode-detection-in-javascript-for-ios11

 

Beyond suggesting that, honestly IDK what else can be done 😞

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...