Files
mes-ui-d2/docs/zh/components/count-up.md
liyang 58ec52afac no message
Former-commit-id: de9fc7ee6ce7d2874bedb5d51fd2997f52870126
Former-commit-id: 70cb9e2b35ef7a76a62dc085aeb77eb914bc42ab
Former-commit-id: 47e9746d0a0fd6d32e798a0f6fbd684c8b555f09
2018-06-10 08:43:27 +08:00

827 B

数字动画

参数

参数名 介绍 必选 值类型 可选值 默认值
start 起始值 Number 0
end 结束值 Number 0
decimals 小数位数 Number 0
duration 持续时间 Number 2
options 设置项 Object 空对象
callback 回调函数 Function 空函数

示例

// 基本使用方法
<d2-count-up :end="100"></d2-count-up>

// 设置始末值
<d2-count-up :start="14" :end="100"></d2-count-up>

// 设置动画时间
<d2-count-up :end="100" :decimals="2"></d2-count-up>

组件会在页面上渲染 <span> 标签

组件根据 countUp.js 封装,options 参数详见原始插件文档