diff --git a/docs/en-US/component/autocomplete.md b/docs/en-US/component/autocomplete.md index dc9650bc60..afb4abf74f 100644 --- a/docs/en-US/component/autocomplete.md +++ b/docs/en-US/component/autocomplete.md @@ -37,7 +37,7 @@ autocomplete/remote-search ::: -## Autocomplete APIs +## API ### Attributes @@ -50,7 +50,7 @@ autocomplete/remote-search | model-value / v-model | binding value | ^[string] | — | | debounce | debounce delay when typing, in milliseconds | ^[number] | 300 | | placement | placement of the popup menu | ^[enum]`'top' \| 'top- start' \| 'top-end' \| 'bottom' \| 'bottom-start' \| 'bottom-end'` | bottom-start | -| fetch-suggestions | a method to fetch input suggestions. When suggestions are ready, invoke `callback(data:[])` to return them to Autocomplete | ^[Function]`(queryString: string, callback: callbackfn) => void` | — | +| fetch-suggestions | a method to fetch input suggestions. When suggestions are ready, invoke `callback(data:[])` to return them to Autocomplete | ^[Function]`(queryString: string, callback: callbackfn) => void` | — | | popper-class | custom class name for autocomplete's dropdown | ^[string] | — | | trigger-on-focus | whether show suggestions when input focus | ^[boolean] | true | | name | same as `name` in native input | ^[string] | — | @@ -62,6 +62,13 @@ autocomplete/remote-search | highlight-first-item | whether to highlight first item in remote search suggestions by default | ^[boolean] | false | | fit-input-width | whether the width of the dropdown is the same as the input | ^[boolean] | false | +### Events + +| Name | Description | Type | +| ------ | ------------------------------------------------ | ----------------------------------------------------- | +| select | triggers when a suggestion is clicked | ^[Function]`(item: typeof modelValue \| any) => void` | +| change | triggers when the icon inside Input value change | ^[Function]`(value: string \| number) => void` | + ### Slots | Name | Description | @@ -72,13 +79,6 @@ autocomplete/remote-search | prepend | content to prepend before Input | | append | content to append after Input | -### Events - -| Name | Description | Type | -| ------ | ------------------------------------------------ | ----------------------------------------------------- | -| select | triggers when a suggestion is clicked | ^[Function]`(item: typeof modelValue \| any) => void` | -| change | triggers when the icon inside Input value change | ^[Function]`(value: string \| number) => void` | - ### Instance Exposes | Name | Description | Type |