import { AbstractPureComponent, HTMLInputProps, IButtonProps, IInputGroupProps, IPopoverProps, IProps } from "reui-core"; import { TimezoneDisplayFormat } from "./timezoneDisplayFormat"; export { TimezoneDisplayFormat }; export interface ITimezonePickerProps extends IProps { /** * The currently selected timezone UTC identifier, e.g. "Pacific/Honolulu". * See https://www.iana.org/time-zones for more information. */ value: string | undefined; /** * Callback invoked when the user selects a timezone. */ onChange: (timezone: string) => void; /** * This component does not support children. * Use `value`, `valueDisplayFormat` and `buttonProps` to customize the button child. */ children?: never; /** * The date to use when formatting timezone offsets. * An offset date is necessary to account for DST, but typically the default value of `now` will be sufficient. * @default now */ date?: Date; /** * Whether this component is non-interactive. * @default false */ disabled?: boolean; /** * Whether to show the local timezone at the top of the list of initial timezone suggestions. * @default true */ showLocalTimezone?: boolean; /** * Format to use when displaying the selected (or default) timezone within the target element. * @default TimezoneDisplayFormat.OFFSET */ valueDisplayFormat?: TimezoneDisplayFormat; /** * Text to show when no timezone has been selected (`value === undefined`). * @default "Select timezone..." */ placeholder?: string; /** Props to spread to the target `Button`. */ buttonProps?: Partial; /** * Props to spread to the filter `InputGroup`. * All props are supported except `ref` (use `inputRef` instead). * If you want to control the filter input, you can pass `value` and `onChange` here * to override `Select`'s own behavior. */ inputProps?: IInputGroupProps & HTMLInputProps; /** Props to spread to `Popover`. Note that `content` cannot be changed. */ popoverProps?: Partial; } export interface ITimezonePickerState { query: string; } export declare class TimezonePicker extends AbstractPureComponent { static displayName: string; static defaultProps: Partial; private timezoneItems; private initialTimezoneItems; constructor(props: ITimezonePickerProps, context?: any); render(): JSX.Element; componentWillReceiveProps(nextProps: ITimezonePickerProps): void; private renderButton(); private filterItems; private renderItem; private handleItemSelect; private handleQueryChange; }