@lobehub/ui
Version:
Lobe UI is an open-source UI component library for building AIGC web apps
35 lines • 1.11 kB
text/typescript
import { InputSize, InputVariant } from "../Input/type.mjs";
import { CalendarMode } from "./calendar.mjs";
import { CSSProperties, ReactNode } from "react";
//#region src/base-ui/DatePicker/type.d.ts
interface PickerCommonProps {
allowClear?: boolean;
className?: string;
disabled?: boolean;
disabledDate?: (date: Date) => boolean;
format?: string | ((date: Date) => string);
max?: Date;
min?: Date;
shadow?: boolean;
size?: InputSize;
style?: CSSProperties;
variant?: InputVariant;
}
interface DatePickerProps extends PickerCommonProps {
defaultValue?: Date | null;
footer?: ReactNode;
mode?: CalendarMode;
onChange?: (date: Date | null) => void;
placeholder?: string;
value?: Date | null;
}
type DateRangeValue = [Date | null, Date | null];
interface DateRangePickerProps extends PickerCommonProps {
defaultValue?: DateRangeValue;
onChange?: (range: DateRangeValue) => void;
placeholder?: [string, string];
value?: DateRangeValue;
}
//#endregion
export { type CalendarMode, DatePickerProps, DateRangePickerProps, DateRangeValue };
//# sourceMappingURL=type.d.mts.map