vydimitrov / react-countdown-circle-timer

Lightweight React/React Native countdown timer component with color and progress animation based on SVG
MIT License
692 stars 87 forks source link

How can i start timer from 0 to end time. #177

Closed berkaygurbuz closed 3 years ago

berkaygurbuz commented 3 years ago

Is there any feature about to start timer from 0 to end time.

vydimitrov commented 3 years ago

Hey @berkaygurbuz, what is your use-case? I guess you can achieve it with the current API.

berkaygurbuz commented 3 years ago

I want to use like a timer not a countdown timer. It starts 0 to specific end time.

quicksilverr commented 3 years ago

?Any updates on this @vydimitrov @berkaygurbuz

quicksilverr commented 3 years ago

Basically, want there shouldn't be a progress bar initially, once we start the progress should be visible from zero

vydimitrov commented 3 years ago

Hey, there is no API for this but you can make it yourself with the current one. The children prop receives the elapsedTime in seconds, which you can use to display it in the middle of the circle. The progress bar - you will need to make the trailColor to be your active color and set the colors prop to your inactive color so this way it will appear like counting up.

berkaygurbuz commented 3 years ago

I solved the problem as following :

vydimitrov commented 3 years ago

Perfect, thank you for sharing your solution :)

rgavinc commented 2 years ago

Would it be possible to add this as a feature that can be turned on/off with a Boolean?

Geczy commented 1 year ago

any update on adding this as a boolfeature?

vydimitrov commented 1 year ago

Is this one going to help? https://github.com/vydimitrov/react-countdown-circle-timer/pull/214