Skip to content

Commit c96d136

Browse files
committed
Add documentation of the inputDelay options
1 parent 8e44871 commit c96d136

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

components/content-picker/readme.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ function MyComponent( props ) {
4040
| `content` | `array` | `[]` | Array of items to pre-populate picker with. Must be in the format of: `[{id: 1, type: 'post', uuid: '...',}, {id: 1, uuid: '...', type: 'page'},... ]`. You cannot provide terms and posts to the same picker. `uuid` was added as of version 1.5.0. It is only used as the React component list key in the admin. If it is not included, `id` will be used which will cause errors if you select the same post twice. |
4141
| `perPage` | `number` | `50` | Number of items to show during search
4242
| `fetchInitialResults` | `bool` | `false` | Fetch initial results to present when focusing the search input |
43+
| `options.inputDelay` | `number` | `undefined` | Debounce delay passed to the internal search input, defaults to 350ms |
4344
| `PickedItemPreviewComponent` | `React.ComponentType<item>` | `undefined` | Allow replacing the default picked item preview. The `item` prop includes information about the selected entry (please check the `PickedItemType` interface in `./PickedItem.tsx`). | |
4445
__NOTE:__ Content picker cannot validate that posts you pass it via `content` prop actually exist. If a post does not exist, it will not render as one of the picked items but will still be passed back as picked items if new items are picked/sorted. Therefore, on save you need to validate that all the picked posts/terms actually exist.
4546

components/content-search/readme.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,4 @@ function MyComponent( props ) {
3535
| `perPage` | `number` | `50` | Number of items to show during search |
3636
| `renderItemType` | `function` | `undefined` | Function called to override the item type label in `SearchItem`. Must return the new label. |
3737
| `fetchInitialResults` | `bool` | `false` | Fetch initial results to present when focusing the search input |
38+
| `options.inputDelay` | `number` | `undefined` | Debounce delay passed to the internal search input, defaults to 350ms |

0 commit comments

Comments
 (0)