Carousel Delay Not Updating Dynamically Based on Page Change in FlutterFlow

Widgets & Design

I am using a carousel in FlutterFlow to display images fetched from a Supabase table. Each image in the table has an associated delay value (in milliseconds), which I want to apply dynamically as the carousel transitions between images.

To achieve this, I:

  • Created a Component State Variable named delay to store the delay value for the current image.

  • Used the onPageChange event of the carousel to update the delay variable with the delay value of the currently displayed image.

However, even though the delay variable updates correctly with each page change, the carousel continues to use the delay value of the first image for all subsequent transitions. This results in inconsistent behavior when different images should have varying delays.

What have you tried so far?
  • I verified that the delay variable is updating correctly on each page change by printing its value.

  • Ensured that the delay property of the carousel is bound to the delay variable.

  • Experimented with re-rendering the component, but the carousel still uses the initial delay value.

  • Checked for potential workarounds, like forcing the carousel to refresh or reinitialize, but I couldn't find a straightforward solution.

Did you check FlutterFlow's Documentation for this topic?
Yes
4
1 reply