|
19 | 19 | | groups | [Group] | collection of objects where each object must atleast have a groupId property|
|
20 | 20 | | groupsAsColumns | Boolean | display option groups in columns|
|
21 | 21 | | hideResetButton | Boolean | hides the reset button, even if the select element is not empty |
|
| 22 | +| highlightedUid | object | the uid (unique id) of the currently highlighted option, uid of an option is obtained from the `uid` prop defined below | |
22 | 23 | | name | String | defaults to undefined, provide a name property to create an hidden input element for html form serialization |
|
23 | 24 | | open | Boolean | controls the visibility of the dropdown menu |
|
24 | 25 | | onBlur | Event -> Void | `({originalEvent :: e, value :: Item, open :: Boolean}){}` |
|
25 | 26 | | onFocus | Event -> Void | `({originalEvent :: e, value :: Item, open :: Boolean}){}` |
|
| 27 | +| onHighlightedUidChange | object -> Void | `(uid){}` invoked when the highlighted option changes | |
26 | 28 | | onKeyboardSelectionFailed | Int -> Void | `(keyCode){}` fired when the user hits the return key on an empty list of options |
|
27 | 29 | | onOpenChange | Boolean -> Void | `(open){}` open is true if the dropdown opened and false if it closed|
|
| 30 | +| onPaste | Event -> Void | invoked when the user pastes text in the input field and `props.valueFromPaste` is not specified| |
28 | 31 | | onSearchChange | String -> Void | `(search){}` invoked when the search text in the input field changes|
|
29 | 32 | | onValueChange | Item -> Void | `(selectedValue){}` invoked when the user selects an option (by click on enter)|
|
30 | 33 | | options | [Item] | list of items by default each option object MUST have label & value property, otherwise you must implement the render* & filterOptions methods|
|
|
48 | 51 | | transitionLeaveTimeout | Number | duration specified in milliseconds, it must match the transition duration specified under the CSS class `.slide-leave-active` |
|
49 | 52 | | uid | (Eq e) => Item -> e | `(item){return item.value}` returns a unique id for a given option, defaults to the value property|
|
50 | 53 | | value | Item | the selected value, i.e. one of the objects in the options array|
|
| 54 | +| valueFromPaste | [Item] -> Item -> String -> Item | `(options, value, pastedText){}` invoked when the user pastes text in the input field, here you can convert the pasted text into an item that will then show up as selected | |
51 | 55 |
|
52 | 56 | ### SimpleSelect methods
|
53 | 57 |
|
|
0 commit comments