UNPKG

@vectara/vectara-ui

Version:

Vectara's design system, codified as a React and Sass component library

30 lines (29 loc) 1.05 kB
import { Props as PopoverProps } from "../popover/Popover"; export type BasicProps = { placeholder?: string; canClear?: boolean; showTimeSelect?: boolean; timeIntervals?: number; minDate?: Date; maxDate?: Date; minTime?: Date; maxTime?: Date; filterDate?: (date: Date) => boolean; filterTime?: (time: Date) => boolean; injectTimes?: Date[]; "data-testid"?: string; }; type DatePickerProps = BasicProps & { date: Date | undefined; onChange?: (date: Date | undefined) => void; }; type InlineProps = DatePickerProps & { isInline: true; }; type InPopoverProps = DatePickerProps & Pick<PopoverProps, "isOpen" | "setIsOpen" | "anchorSide" | "header"> & { isInline?: false; fullWidth?: boolean; }; type Props = InlineProps | InPopoverProps; export declare const VuiDatePicker: ({ placeholder, canClear, showTimeSelect, timeIntervals, minDate, maxDate, minTime, maxTime, filterDate, filterTime, injectTimes, isInline, ...rest }: Props) => import("react/jsx-runtime").JSX.Element; export {};