react-native-circular-progress icon indicating copy to clipboard operation
react-native-circular-progress copied to clipboard

Timer as "fill" value

Open dr-star opened this issue 5 years ago • 1 comments

Hello all, My issue is that, the progress seems finish before the actual time. There is a way to access the remaining time?

How I have configured the increase time: setInterval(() => { if (!this.state.stopTimer) { this.setState({ currentTime: subSeconds(this.state.currentTime, 1), }); } }, 1000); How I have configured the progress: <AnimatedCircularProgress size={250} width={12} fill={100} duration={0} style={styles.progress} tintColor="#b09838" onAnimationComplete={() => this.animationComplete()} backgroundColor="#3d5875" ref={ref => (this._circularProgressRef = ref)}> {fill => ( <Text style={styles.remainingTime}> {format(this.state.currentTime, 'mm:ss')} </Text> )} </AnimatedCircularProgress>

Thanks in advance for your time 😄

dr-star avatar Mar 24 '20 21:03 dr-star

I'm also having the same issue, if I run interval for 1 minutes, the progress fills completely around 5 seconds before timeout. circularProgress.current.animate(100, (60 * 1000), Easing.linear); Any solution? Thanks

AMBTech avatar Dec 04 '21 14:12 AMBTech