Commit 7f2510f0 authored by hetech's avatar hetech Committed by GitHub

Select: debounce query (#12181)

parent c5347b80
......@@ -62,8 +62,7 @@
@compositionupdate="handleComposition"
@compositionend="handleComposition"
v-model="query"
@input="e => handleQueryChange(e.target.value)"
:debounce="remote ? 300 : 0"
@input="debouncedQueryChange"
v-if="filterable"
:style="{ width: inputLength + 'px', 'max-width': inputWidth - 42 + 'px' }"
ref="input">
......@@ -849,6 +848,10 @@
this.onInputChange();
});
this.debouncedQueryChange = debounce(this.debounce, (e) => {
this.handleQueryChange(e.target.value);
});
this.$on('handleOptionClick', this.handleOptionSelect);
this.$on('setSelected', this.setSelected);
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment