Skip to content

Commit

Permalink
Merge pull request #6003 from marmelab/debounce-autocompletearrayinpu…
Browse files Browse the repository at this point in the history
…t-setfilter

Debounce AutocompleteArrayInput setFilter call
  • Loading branch information
fzaninotto committed Mar 18, 2021
2 parents 0a5ff63 + e532f27 commit 752a2f0
Show file tree
Hide file tree
Showing 3 changed files with 322 additions and 287 deletions.
1 change: 1 addition & 0 deletions docs/Inputs.md
Original file line number Diff line number Diff line change
Expand Up @@ -1036,6 +1036,7 @@ import { AutocompleteArrayInput } from 'react-admin';
| ------------------------- | -------- | -------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `allowEmpty` | Optional | `boolean` | `false` | If `true`, the first option is an empty one |
| `allowDuplicates` | Optional | `boolean` | `false` | If `true`, the options can be selected several times |
| `debounce` | Optional | `number` | `250` | The delay to wait before calling the setFilter function injected when used in a ReferenceInput. |
| `choices` | Required | `Object[]` | - | List of items to autosuggest |
| `matchSuggestion` | Optional | `Function` | - | Required if `optionText` is a React element. Function returning a boolean indicating whether a choice matches the filter. `(filter, choice) => boolean` |
| `optionValue` | Optional | `string` | `id` | Field name of record containing the value to use as input value |
Expand Down
Loading

0 comments on commit 752a2f0

Please sign in to comment.