Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

统计数值里的倒计时组件是否应该从初始值开始算,例如5秒倒计时,应该是5-4-3-2-1-结束,而不是4-3-2-1-0-结束。 #6798

Closed
1 task
createlinux opened this issue Jul 29, 2023 · 3 comments
Labels

Comments

@createlinux
Copy link

  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

4.0.0-rc.6

Environment

browser version

Reproduction link

https://antdv.com/components/statistic-cn#components-statistic-demo-countdown

Steps to reproduce

不需要重现,目前倒计时就是4-3-2-1-0-结束,比如初始值是5s,页面开始显示的是剩余4s。

What is expected?

希望能从初始值开始倒计时,并且能秒数在变为0的时候就立即结束,而不是0到结束之间相隔1秒后结束。

What is actually happening?

如标题所描述,生活中倒计时的时候,例如5秒倒计时就是从5开始算,目前组件是从4s开始算,0秒到结束之间还间隔了1秒。虽然加起来一共都是5秒钟,但是实际生活中使用的时候是从5开始,而不是4开始。

@webvs2
Copy link
Contributor

webvs2 commented Aug 1, 2023

倒计时的思想是剩余时间,在停留1的时候,事件尚未归零

@github-actions
Copy link

github-actions bot commented Oct 1, 2023

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days

@github-actions github-actions bot added the Stale label Oct 1, 2023
@github-actions github-actions bot closed this as completed Oct 9, 2023
@createlinux
Copy link
Author

倒计时的思想是剩余时间,在停留1的时候,事件尚未归零

你说的没错,但是不应该反应到UI上。看看手机自带的计时器,到0就是结束了,而不是到0了还停留1s后结束。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants