diff --git a/types/react-native-calendars/index.d.ts b/types/react-native-calendars/index.d.ts index 647e64c0f2..20adae432a 100644 --- a/types/react-native-calendars/index.d.ts +++ b/types/react-native-calendars/index.d.ts @@ -2,6 +2,7 @@ // Project: https://github.com/wix/react-native-calendars#readme // Definitions by: Tyler Zhang // David NoreƱa +// Fabian Meul // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.8 @@ -23,6 +24,10 @@ export interface CalendarDot { selectedDotColor?: string; } +export interface CalendarThemeIdStyle { + [themeId: string]: ViewStyle; +} + export interface CalendarTheme { arrowColor?: string; backgroundColor?: string; @@ -43,6 +48,17 @@ export interface CalendarTheme { textMonthFontSize?: number; textSectionTitleColor?: string; todayTextColor?: string; + + // Theme ID's to style for + "stylesheet.calendar.header"?: CalendarThemeIdStyle; + "stylesheet.calendar.main"?: CalendarThemeIdStyle; + "stylesheet.calendar-list.main"?: CalendarThemeIdStyle; + "stylesheet.agenda.main"?: CalendarThemeIdStyle; + "stylesheet.agenda.list"?: CalendarThemeIdStyle; + "stylesheet.day.basic"?: CalendarThemeIdStyle; + "stylesheet.day.single"?: CalendarThemeIdStyle; + "stylesheet.day.multiDot"?: CalendarThemeIdStyle; + "stylesheet.day.period"?: CalendarThemeIdStyle; } export type DateCallbackHandler = (date: DateObject) => void; @@ -319,6 +335,11 @@ export interface CalendarListBaseProps extends CalendarBaseProps { * Enable or disable vertical scroll indicator. Default = false */ showScrollIndicator?: boolean; + + /** + * Initially selected day + */ + selected?: string; } export class CalendarList extends React.Component { }