Changing colour of a group on creating a new thing

I am trying to implement a feature where on saving a new thing, e.g like a block of text in a repeating group, the latest entry acquires a different colour briefly and then fades back to normal. Like how Bubble forum posts are purple on saving and fades to white over the next second. Any suggestions on how to implement this in Bubble?

This could be very useful in mobile UI as well. Thanks in advance.

There are several ways you might do this, depending on how you want it to look. You could have a shape at the back of your RG’s cell and do an Animate fade out on it (that’s an action, find it in Workflows under Element).

You might also as last step in workflow set some custom state on the text element representing your thing (like a Boolean “Just Been Saved” - set it to yes). Then in its Conditions tab, have a condition like:

When This Text’s Just Been Saved

… change its color or background or size or whatever.

Then have a pause in your workflow (a short one). Then set Just Been Saved back to no.

(This would cause the formatting to go back to default, right?)

This will make a sudden transition. To fade it over time, look at the Transitions tab on that same text element we’ve been discussing.

Thanks Keith - I will have a go at those suggestions.

Your second suggestion worked. With the first, I could not find a way to animate an element placed inside a repeating group cell. Not sure if this is a new bug - I thought we could animate all elements.

With the suggestion that worked, the tricky bit was working out the best durations. Also the shape/ group needs to be made visible based on index, if not the elements appears in all cells :slight_smile:

1 Like

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