Skip to main content
L
6mo ago

Flutter: scrolling not working as expected on mobile

In a flutter app, I have a Rive animation in a scrollable view that takes up the majority of the screen. The entire animation is clickable. On web and desktop targets, scrolling works as expected, but on mobile any clickable area seems to prevent scrolling from happening. This is also evident when there are smaller targets; then scrolling happens as expected around the targets but does not occur when the swipe gesture starts on a target area. I know there is a solution for this on some web runtimes - is there something similar for the Flutter runtime?

Edit:

This behaviour seems to only occur for iOS devices.

I've created an issue on the github repo: https://github.com/rive-app/rive-flutter/issues/436

9 replies
L
6mo ago

Hi, does this still happen when you toggle the isTouchScrollEnabled parameter when you initialize the Rive instance?

L
6mo ago

As far as I'm aware, isTouchScrollEnabled isn't an available parameter for the Flutter runtime? If it is, would you be able to point me in the right direction?

6mo ago

You're right, this is a JS-only feature. My mistake. :)

Let me ping someone to see if there's a Flutter workaround or an upcoming feature.

6mo ago

We're looking into the best way to support this without breaking current functionality. We'll keep you updated but it may take some time

L
6mo ago

Thanks! Looking forward to hearing from you.

6mo ago

Okay we have a fix that is in review. This should be available in the next release

L
(edited) 6mo ago

Great news! This may mean that we can go ahead with a Rive animation as planned for our app :D

(edited) 5mo ago

That PR has been merged: https://github.com/rive-app/rive/pull/8651.

You should be able to use isTouchScrollEnabled in the latest version of the Rive Flutter runtime. Thanks Gordon!

L
5mo ago

Can confirm that it's operational on our side. Much appreciated!