Hello Flutter community,
I'm working on a feature in my app where I need to toggle the visibility of a RichText
widget with an embedded countdown timer. Here’s what I’m trying to achieve:
I have a
RichText
widget that includes a clickable text portion, say "Resend OTP".When "Resend OTP" is clicked, the
RichText
widget should be hidden.Simultaneously, a countdown timer (for 1 minute) should appear.
Once the countdown ends, the timer should disappear, and the
RichText
widget should reappear.
I am unsure how to properly toggle the visibility between the RichText
and the timer. Could anyone guide me on the best way to implement this or point me toward any relevant examples or resources?
Thanks for your help!