import { DNode, RenderResult } from '@dojo/framework/core/interfaces'; export declare type CalendarMessages = { chooseMonth: string; chooseYear: string; previousMonth: string; nextMonth: string; previousYears: string; nextYears: string; }; export declare enum FirstDayOfWeek { sunday = 0, monday = 1, tuesday = 2, wednesday = 3, thursday = 4, friday = 5, saturday = 6 } export interface CalendarProperties { /** Custom aria attributes */ aria?: { [key: string]: string | null; }; /** Customize or internationalize accessible text for the Calendar widget */ labels?: CalendarMessages; /** Set the latest date the calendar will display (it will show the whole month but not allow later selections) */ maxDate?: Date; /** Set the earliest date the calendar will display (it will show the whole month but not allow previous selections) */ minDate?: Date; /** Customize or internationalize full month names and abbreviations */ monthNames?: { short: string; long: string; }[]; /** Customize or internationalize weekday names and abbreviations */ weekdayNames?: { short: string; long: string; }[]; /** Configure the first day of the calendar week, defaults to 0 (sunday) */ firstDayOfWeek?: 0 | 1 | 2 | 3 | 4 | 5 | 6; /** The initial value */ initialValue?: Date; /** A controlled date value */ value?: Date; /** Function called when the user selects a date */ onValue?: (value: Date) => void; /** The initial month to display */ initialMonth?: number; /** A controlled month value */ month?: number; /** Function called when the month changes */ onMonth?(month: number): void; /** The initial year to display */ initialYear?: number; /** A controlled year value */ year?: number; /** Function called when the year changes */ onYear?(year: number): void; } export interface CalendarIcache { value: Date; initialValue: Date; initialMonth: number; month: number; initialYear: number; year: number; callDateFocus?: boolean; focusedDay: number; monthLabelId: string; popupOpen?: boolean; } export interface CalendarChildren { /** Format the displayed current month and year */ monthLabel?: (month: number, year: number) => RenderResult; /** Format the weekday column headers */ weekdayCell?: (day: { short: string; long: string; }) => RenderResult; } interface CalendarCellProperties { /** Used to immediately call focus on the cell */ callFocus?: boolean; /** The set date value */ date: number; /** Whether the date is in the displayed month */ disabled?: boolean; /** Whether the date can receive tab focus */ focusable?: boolean; /** Handler for the click event */ onClick?(date: number, disabled: boolean): void; /** Handler for when the cell receives focus */ onFocusCalled?(): void; /** Handler for the key down event */ onKeyDown?(key: number, preventDefault: () => void): void; /** if the date is outside the min/max */ outOfRange?: boolean; /** if the date is currently selected */ selected?: boolean; /** if the date the same as the current day */ today?: boolean; } interface DatePickerProperties { /** Id to reference label containing current month and year */ labelId?: string; /** Customize or internationalize accessible helper text */ labels: CalendarMessages; /** Maximum date to be picked */ maxDate?: Date; /** Minimum date to be picked */ minDate?: Date; /** Currently displayed month (zero-based) */ month: number; /** Array of full and abbreviated month names */ monthNames: { short: string; long: string; }[]; /** Handles when a user action occurs that triggers a change in the month or year popup state */ onPopupChange?(open: boolean): void; /** Handles when a month should change (month is zero-based) */ onRequestMonthChange?(month: number): void; /** Handles when a year should change */ onRequestYearChange?(year: number): void; /** Formats the displayed current month and year */ renderMonthLabel?(month: number, year: number): RenderResult; /** Currently displayed year */ year: number; /** Number of years to display in a single page of the year popup */ yearRange?: number; } export declare const CalendarCell: import("@dojo/framework/core/interfaces").DefaultChildrenWNodeFactory<{ properties: CalendarCellProperties & import("@dojo/framework/core/interfaces").WidgetProperties & { variant?: "default" | "inherit" | undefined; } & import("@dojo/framework/core/middleware/theme").ThemeProperties; children: DNode[]; }>; export declare const DatePicker: import("@dojo/framework/core/interfaces").DefaultChildrenWNodeFactory<{ properties: DatePickerProperties & import("@dojo/framework/core/interfaces").WidgetProperties & { variant?: "default" | "inherit" | undefined; } & import("@dojo/framework/core/middleware/theme").ThemeProperties & import("@dojo/framework/core/interfaces").FocusProperties; children: DNode[]; }>; export declare const Calendar: import("@dojo/framework/core/interfaces").OptionalWNodeFactory<{ properties: CalendarProperties & import("@dojo/framework/core/interfaces").WidgetProperties & { variant?: "default" | "inherit" | undefined; } & import("@dojo/framework/core/middleware/theme").ThemeProperties & import("@dojo/framework/core/interfaces").FocusProperties & import("@dojo/framework/core/interfaces").I18nProperties; children: CalendarChildren; }>; export default Calendar;