mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-19 14:31:47 +01:00
feat(InputMenu/SelectMenu): allow lazy search (#1705)
Co-authored-by: chenying <chenying@addcn.com> Co-authored-by: Benjamin Canac <canacb1@gmail.com>
This commit is contained in:
@@ -249,6 +249,10 @@ export default defineComponent({
|
||||
type: Array,
|
||||
default: null
|
||||
},
|
||||
searchLazy: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
debounce: {
|
||||
type: Number,
|
||||
default: 200
|
||||
@@ -407,6 +411,8 @@ export default defineComponent({
|
||||
return child !== null && child !== undefined && String(child).search(new RegExp(query.value, 'i')) !== -1
|
||||
})
|
||||
})
|
||||
}, [], {
|
||||
lazy: props.searchLazy
|
||||
})
|
||||
|
||||
watch(container, (value) => {
|
||||
|
||||
Reference in New Issue
Block a user