Merge branch '2.0' of https://github.com/iview/iview into iview-2.0

This commit is contained in:
Lawrence Lee 2017-06-08 10:25:51 +08:00
commit 0b8442ed26
7 changed files with 20283 additions and 35 deletions

View file

@ -362,7 +362,7 @@
handleIconClick () {
if (this.showClose) {
this.handleClear();
} else {
} else if (!this.disabled) {
this.handleFocus();
}
},

View file

@ -198,12 +198,14 @@
}
// if trigger and children is input or textarea,listen focus & blur event
if (this.trigger === 'focus') {
const $children = this.getInputChildren();
if ($children) {
$children.addEventListener('focus', this.handleFocus, false);
$children.addEventListener('blur', this.handleBlur, false);
this.isInput = true;
}
this.isInput = true;
this.$nextTick(() => {
const $children = this.getInputChildren();
if ($children) {
$children.addEventListener('focus', this.handleFocus, false);
$children.addEventListener('blur', this.handleBlur, false);
}
});
}
},
beforeDestroy () {