import * as React from 'react'; import * as PropTypes from 'prop-types'; import { InlineBlockProps as ReakitInlineBlockProps } from 'reakit/ts/InlineBlock/InlineBlock'; import { InputProps as ReakitInputProps } from 'reakit/ts/Input/Input'; import { Omit } from '../types'; export declare type LocalSelectProps = { /** ID for the select field */ a11yId?: string; /** An accessible label for the select field */ a11yLabel?: string; autoComplete?: string; /** Automatically focus the select field */ autoFocus?: boolean; className?: string; /** Default value of the select field */ defaultValue?: string; /** Disables the select field */ disabled?: boolean; /** Makes the select field span full width */ isFullWidth?: boolean; /** Adds a cute loading indicator to the select field */ isLoading?: boolean; /** Makes the select field required and sets aria-invalid to true */ isRequired?: boolean; /** Name of the select field */ name?: string; /** Select field options */ options: Array<{ label: string; value: string; disabled?: boolean; }>; /** Hint text to display */ placeholder?: string; selectProps?: ReakitInputProps; selectRef?: React.RefObject; /** Alters the size of the select field. Can be "small", "medium" or "large" */ size?: string; /** State of the select field. Can be any color in the palette. */ state?: string; /** Value of the select field */ value?: string; /** Function to invoke when focus is lost */ onBlur?: React.FocusEventHandler; /** Function to invoke when the select field has changed */ onChange?: React.FormEventHandler; /** Function to invoke when the select field is focused */ onFocus?: React.FocusEventHandler; }; export declare type SelectProps = Omit, 'size'> & LocalSelectProps; export declare type SelectComponents = { Formik: React.FunctionComponent; ReduxForm: React.FunctionComponent; }; export declare type SelectState = { isPlaceholderSelected: boolean; }; export declare const selectDefaultProps: { a11yId: any; a11yLabel: any; autoComplete: any; autoFocus: boolean; className: any; defaultValue: any; disabled: boolean; isFullWidth: boolean; isLoading: boolean; isRequired: boolean; name: any; onBlur: any; onChange: any; onFocus: any; placeholder: any; selectProps: {}; selectRef: any; size: string; state: any; value: any; }; export declare const selectPropTypes: { a11yId: PropTypes.Requireable; a11yLabel: PropTypes.Requireable; autoComplete: PropTypes.Requireable; autoFocus: PropTypes.Requireable; className: PropTypes.Requireable; defaultValue: PropTypes.Requireable; disabled: PropTypes.Requireable; isFullWidth: PropTypes.Requireable; isLoading: PropTypes.Requireable; isRequired: PropTypes.Requireable; name: PropTypes.Requireable; options: PropTypes.Validator; placeholder: PropTypes.Requireable; selectProps: PropTypes.Requireable; selectRef: PropTypes.Validator>; size: PropTypes.Requireable; state: PropTypes.Requireable; value: PropTypes.Requireable; onBlur: PropTypes.Requireable<(...args: any[]) => any>; onChange: PropTypes.Requireable<(...args: any[]) => any>; onFocus: PropTypes.Requireable<(...args: any[]) => any>; }; export declare class Select extends React.PureComponent { static defaultProps: { a11yId: any; a11yLabel: any; autoComplete: any; autoFocus: boolean; className: any; defaultValue: any; disabled: boolean; isFullWidth: boolean; isLoading: boolean; isRequired: boolean; name: any; onBlur: any; onChange: any; onFocus: any; placeholder: any; selectProps: {}; selectRef: any; size: string; state: any; value: any; }; static propTypes: { a11yId: PropTypes.Requireable; a11yLabel: PropTypes.Requireable; autoComplete: PropTypes.Requireable; autoFocus: PropTypes.Requireable; className: PropTypes.Requireable; defaultValue: PropTypes.Requireable; disabled: PropTypes.Requireable; isFullWidth: PropTypes.Requireable; isLoading: PropTypes.Requireable; isRequired: PropTypes.Requireable; name: PropTypes.Requireable; options: PropTypes.Validator; placeholder: PropTypes.Requireable; selectProps: PropTypes.Requireable; selectRef: PropTypes.Validator>; size: PropTypes.Requireable; state: PropTypes.Requireable; value: PropTypes.Requireable; onBlur: PropTypes.Requireable<(...args: any[]) => any>; onChange: PropTypes.Requireable<(...args: any[]) => any>; onFocus: PropTypes.Requireable<(...args: any[]) => any>; }; state: { isPlaceholderSelected: boolean; }; handleChange: (e: any) => void; render: () => JSX.Element; } declare const C: React.FunctionComponent & SelectComponents; export default C;