How to make a Flashing Item?


I was wondering, how do you make a flashing type of item? Meaning, flash white and black, or red and blue, and so on. I was trying to figure this out, and try this on my bubble app.

Hi Xavier,
welcome to bubble,

what you can do to to make a shape, group or anything flash different colours:

  1. On the item of choice, click i to add a custom state. Make this type number . I called it flashing state. Have the default value as 0.
  2. In the workflow tab, add a new event using: Do every 5 seconds.
  3. Use the workflow action, set state of the shape, to that shapes state + 1.
  4. Add another action, set state of the shape, back to 0, only if the state reaches e.g. 3 to go between flashing between 3 colours
  5. On the shape, go to conditional and depending on the states number, have the shape show a different background colour. You could also hide it using “element is visible” if the state is a certain number.
  6. If you want, in the “do every 2 seconds” workflow, you can use the workflow action “animate” if the state of the element has a certain number.

Hope this helps.
Feel free to pm me or add me @narathiel on discord if you have further questions

happy bubbling,

Free tips and step by step lists for bubble & more @



This topic was automatically closed after 70 days. New replies are no longer allowed.