mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-23 12:56:46 +08:00
committed by
Masahiro Wakame
parent
2bb5e51050
commit
8d0cdb374d
@@ -12,8 +12,10 @@ class SelectTest extends React.Component<React.Props<{}>, {}> {
|
||||
|
||||
render() {
|
||||
const options: ReactSelect.Option[] = [{ label: "Foo", value: "bar" }]
|
||||
const onOpen = () => { return; };
|
||||
const onClose = () => { return; };
|
||||
return <div>
|
||||
<Select options={options} />
|
||||
<Select options={options} onOpen={onOpen} onClose={onClose} />
|
||||
</div>
|
||||
}
|
||||
|
||||
|
||||
3
react-select/react-select.d.ts
vendored
3
react-select/react-select.d.ts
vendored
@@ -153,9 +153,12 @@ declare namespace ReactSelect {
|
||||
*/
|
||||
onBlurResetsInput?: boolean;
|
||||
onChange?: (newValue: Option | Option[]) => void;
|
||||
onClose?: () => void;
|
||||
onFocus?: __React.FocusEventHandler;
|
||||
onInputChange?: (inputValue: string) => void;
|
||||
onOpen?: () => void;
|
||||
onOptionLabelClick?: (value: string, event: Event) => void;
|
||||
|
||||
/**
|
||||
* function which returns a custom way to render the options in the menu
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user