docs(components): [autocomplete] (#10478)

* Normalized API
This commit is contained in:
Xc 2022-11-06 22:34:50 +08:00 committed by GitHub
parent 1ec01130d8
commit 8a694e729b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -37,7 +37,7 @@ autocomplete/remote-search
:::
## Autocomplete APIs
## API
### Attributes
@ -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 |