feat: add tests && fix bugs

This commit is contained in:
jiangruowei
2017-04-06 15:11:29 +08:00
parent a85c3c2695
commit a32142c723
9 changed files with 216 additions and 46 deletions

View File

@@ -53,7 +53,7 @@ export default {
type: {
type: String,
default: 'text',
validate(value) {
validator(value) {
return VALID_TYPES.indexOf(value) > -1;
}
},
@@ -71,7 +71,7 @@ export default {
autosize: {
type: Boolean,
default: false,
validate(value) {
validator(value) {
if (value && this.type !== 'textarea') return false;
}
}