import { LanguageType } from 'wix-style-react-tpa'; import { TPAComponentProps } from '../../types'; export interface DatePickerDateIndicationProps { date: Date; isSelected: boolean; } export type DatePickerLocale = LanguageType; export type DatePickerFirstDayOfWeek = 0 | 1 | 2 | 3 | 4 | 5 | 6; export interface WeeklyDatePickerProps extends TPAComponentProps { /** The selected date */ value?: Date; /** Callback function called with a Date or a Range whenever the user selects a day in the calendar */ onChange(selectedDays: string | Date): void; /** DatePicker instance locale */ locale?: DatePickerLocale; /** When true, past dates would be unselectable */ excludePastDates?: boolean; /** * Determines selectable dates * * `param` {Date} `date` - a date to check * * `return` {boolean} - true if `date` should be selectable, false otherwise */ filterDate?(date: Date): boolean; /** First day of the week, allowing only from 0 to 6 (Sunday to Saturday). The default value is 1 which means Monday. */ firstDayOfWeek?: DatePickerFirstDayOfWeek; /** Displays a selectable monthDropdown */ showMonthDropdown?: boolean; /** Displays a selectable yearDropdown */ showYearDropdown?: boolean; /** ##### This function allows you to add an indication under a specific date. The function should return the indication node of a specific date or null if this day doesn't have an indication. * `param` {date: Date, isSelected: boolean } `date` - a date, `isSelected` - whether this date is the selected date * `return` {React.node} - the indication node of a specific date or null if this day doesn't have an indication. */ dateIndication?: React.FC; /** Defines a string value that labels the Date Picker element. Optional. */ 'aria-label'?: string; /** Identifies the element that labels the Date Picker element. Optional. */ 'aria-labelledby'?: string; /** Defines a string value that labels the left arrow in calendar header */ leftArrowAriaLabel?: string; /** Identifies the element that labels the left arrow in calendar header */ leftArrowAriaLabelledBy?: string; /** Defines a string value that labels the right arrow in calendar header */ rightArrowAriaLabel?: string; /** Identifies the element that labels the right arrow in calendar header */ rightArrowAriaLabelledBy?: string; /** If true, renders date picker without outer padding */ removeOuterPadding?: boolean; /** Define today's date. The today indication is added automatically according to the user timezone but in some cases, we need the ability to add the today indication based on the business timezone. */ today?: Date; /** Defines a callback function that is called with the range of the current displayed week whenever the displayed week is changed.**/ onDisplayedWeekChange?(week: WeekDatesRange): void; /** * arrow location on picker. * dates: arrows are on the left and right of the dates * caption: arrows are on the left and right of the caption */ arrowLocation?: 'dates' | 'caption'; /** if true week names and and days will be displayed together * horizontal - week names and days will be displayed in one line * vertical - week names and days will be displayed in two lines */ groupWeekdaysAndDates?: boolean; } export interface WeekDatesRange { startOfWeek: Date; endOfWeek: Date; } //# sourceMappingURL=types.d.ts.map