We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
https://www.naiveui.com/zh-CN/os-theme/components/countdown
在倒计时中可以先暂停一段时间再开始
The text was updated successfully, but these errors were encountered:
RFC: 接口的实现方式
组件:statistic, countdown
statistic
countdown
<template> <a-statistic ref="statisticRef" title="User Growth Rate" :value="50.52" :precision="2" :value-from="0" :start="start" animation > <template #prefix> <icon-arrow-rise /> </template> <template #suffix>%</template> </a-statistic> <a-button @click="start=true">Start</a-button> <a-button @click="handleToggleStop">Toggle Stop</a-button> </template> <script> import { ref } from 'vue'; export default { setup() { const statisticRef = ref(null); const start = ref(false); const handleToggleStop = (stoped) => { if (!statisticRef.value) return statisticRef.value?.stop(!stoped) } return { statisticRef, start, handleToggleStop } }, } </script>
两个组件实现类似
💬 不使用 stop 属性的原因,stop 和 start 属性名称语义上的问题,使用时功能有些不清晰 ❗️ 切换 start 属性的值,目前并不会影响已经执行的动画(即使结束也不会重新开始)
Sorry, something went wrong.
hehehai
Successfully merging a pull request may close this issue.
Basic Info
What are the similar cases of this feature
https://www.naiveui.com/zh-CN/os-theme/components/countdown
What problem does this feature solve?
在倒计时中可以先暂停一段时间再开始
The text was updated successfully, but these errors were encountered: