feat(CountDown): time can be string type

This commit is contained in:
陈嘉涵
2020-01-29 10:09:18 +08:00
parent ef70384cdb
commit 36ba412f70
3 changed files with 4 additions and 4 deletions

View File

@@ -8,7 +8,7 @@ export default createComponent({
props: {
millisecond: Boolean,
time: {
type: Number,
type: [Number, String],
default: 0,
},
format: {
@@ -84,7 +84,7 @@ export default createComponent({
// @exposed-api
reset() {
this.pause();
this.remain = this.time;
this.remain = +this.time;
if (this.autoStart) {
this.start();