拥有动画效果的倒计时组件.
组件会根据传入的endDate属性自动计算应该显示哪些时间节点. 比如: 截止日期距今是 1 年以内的. 则只会从月开始显示, 同理,截止日期距今是 1 月以内的, 则只会从日开始显示, 以此类推. 最多显示到年.
variant属性支持: labelInline和box
| 属性名 | 类型 | 是否必须 | 默认值 | 说明 |
|---|---|---|---|---|
| endDate | Date | yes | ||
| labelPosition | "right" | "bottom" | undefined | no | ||
| labels | { years: string; months: string; days: string; hours: string; minutes: string; seconds: string; } | undefined | no | '{years:"years", months:"months", days:"days", hours:"hours", minutes:"minutes", seconds:"seconds"}' | 显示文本, 可以本地化 |
| variant | "box" | "labelInline" | "labelUnder" | undefined | no |