import "./DateInput.css"; import { AriaLabelingProps, InteractionStatesProps } from "../../shared"; import { BoxProps as BoxPropsForDocumentation } from "../../box"; import { CSSProperties, ChangeEvent, ChangeEventHandler, ComponentProps, ElementType, ForwardedRef } from "react"; interface BoxProps extends BoxPropsForDocumentation { } export interface DatePreset { text: string; date: Date; } export interface InnerDateInputProps extends InteractionStatesProps, AriaLabelingProps { /** * A controlled value. */ value?: Date | null; /** * The default value of `value` when uncontrolled. */ defaultValue?: Date; /** * Temporary text that occupies the input when it is empty. */ placeholder?: string; /** * The minimum (inclusive) date. */ min?: Date; /** * The maximum (inclusive) date. */ max?: Date; /** * Whether or not a user input is required before form submission. */ required?: boolean; /** * Whether or not the input should display as "valid" or "invalid". */ validationState?: "valid" | "invalid"; /** * @ignore */ onChange?: ChangeEventHandler; /** * Called when the date change. * @param {ChangeEvent} event - React's original synthetic event. * @param {object} date - The new date value. * @returns {void} */ onDateChange?: (event: ChangeEvent, date: Date) => void; /** * Array of pre-determined dates. */ presets?: DatePreset[]; /** * The presets style to use. */ presetsVariant?: "compact" | "expanded"; /** * Whether or not the input should autofocus on render. */ autoFocus?: boolean | number; /** * Whether or not the input take up the width of its container. */ fluid?: boolean; /** * Additional props to render on the wrapper element. */ wrapperProps?: Partial; /** * @ignore */ disabled?: boolean; /** * Whether or not the input is readonly. */ readOnly?: boolean; /** * @ignore */ className?: string; /** * @ignore */ style?: CSSProperties; /** * An HTML element type or a custom React element type to render as. */ as?: ElementType; /** * @ignore */ forwardedRef: ForwardedRef; } export declare function InnerDateInput({ value: valueProp, defaultValue, placeholder, onDateChange, presets, presetsVariant, fluid, wrapperProps, disabled, readOnly, className, style, as, forwardedRef, ...rest }: InnerDateInputProps): JSX.Element; export declare const DateInput: import("../../shared").OrbitComponent<"input", InnerDateInputProps>; export declare type DateInputProps = ComponentProps; export {};