-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7b4a0ed
commit cb08a80
Showing
2 changed files
with
15 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,15 @@ | ||
# SearchSelect | ||
|
||
`<SearchSelect>` allows for external options to be provided and selected through a dropdown. | ||
|
||
| Name | Default | Description | type | | ||
| ------------ | ----------------- | ------------------------------------------------------------------------------------------------ | -------- | | ||
| debounceTime | 300 | Time to wait before the `onChange` handler is called | Number | | ||
| isFocused | false | Sets the `autoFocus` input attribute to `true`, so the element will be focused on mount | Bool | | ||
| isLoading | false | Indicate if the the loading component should render | Bool | | ||
| onChange | | Debounced change event handler that will be called with the current value in the input | Function | | ||
| onSelect | | Select even handler which will be called with the selected option, e.g. `{ id: 1, title: 'foo'}` | Function | | ||
| options | [] | Array of options with the following shape `[{ id: 1, title: 'foo'}, { id: 2, title: 'bar'}]` | Array | | ||
| placeholder | 'Start Typing...' | Placeholder value to display on an empty input | String | | ||
| renderLoader | | Function to render a loading component such as `() => <LoadingDots size="sm" />` | Function | | ||
| size | 'sm' | Size of the input, one of `xs`, `sm`, or `md` | String | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters