feat: exposure on-focus and on-blur event in <AutoComplete>

This commit is contained in:
blackcater 2018-05-07 15:47:17 +08:00
parent 17d9922b08
commit 11ab651993
2 changed files with 50 additions and 14 deletions

View file

@ -150,11 +150,13 @@
this.$refs.input.blur();
this.$emit('on-select', val);
},
handleFocus () {
handleFocus (event) {
this.$refs.select.visible = true;
this.$emit('on-focus', event);
},
handleBlur () {
handleBlur (event) {
this.$refs.select.visible = false;
this.$emit('on-blur', event);
},
handleClear () {
if (!this.clearable) return;