Comboboxes now clear search text when selecting an option
This commit is contained in:
@@ -5,8 +5,9 @@
|
|||||||
:error-messages="errors"
|
:error-messages="errors"
|
||||||
:value="safeValue"
|
:value="safeValue"
|
||||||
:menu-props="{auto: true, lazy: true}"
|
:menu-props="{auto: true, lazy: true}"
|
||||||
|
:search-input.sync="searchInput"
|
||||||
box
|
box
|
||||||
@change="change"
|
@change="customChange"
|
||||||
@focus="focused = true"
|
@focus="focused = true"
|
||||||
@blur="focused = false"
|
@blur="focused = false"
|
||||||
>
|
>
|
||||||
@@ -22,5 +23,14 @@
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [SmartInput],
|
mixins: [SmartInput],
|
||||||
|
data(){ return {
|
||||||
|
searchInput: '',
|
||||||
|
}},
|
||||||
|
methods: {
|
||||||
|
customChange(val){
|
||||||
|
this.change(val);
|
||||||
|
this.searchInput = '';
|
||||||
|
},
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user