CalendarApp constructor

CalendarApp({
  1. Key? key,
  2. dynamic onSelectedDate(
    1. DateTime
    )?,
  3. BoxDecoration? selectedDecoration,
  4. BoxDecoration? todayDecoration,
  5. HeaderStyle? headerStyle,
  6. EnableDateStyle? enableDateStyle,
  7. DisableDateStyle? disableDateStyle,
  8. bool enablePredicate(
    1. DateTime
    )?,
  9. bool swipeAnimationEnable = false,
  10. bool showHeader = true,
  11. required DateTime startDate,
  12. required DateTime endDate,
})

Implementation

CalendarApp(
    {Key? key,
    this.onSelectedDate,
    this.selectedDecoration,
    this.todayDecoration,
    HeaderStyle? headerStyle,
    EnableDateStyle? enableDateStyle,
    DisableDateStyle? disableDateStyle,
    bool Function(DateTime)? enablePredicate,
    this.swipeAnimationEnable = false,
    this.showHeader = true,
    required this.startDate,
    required this.endDate})
    : enablePredicate = enablePredicate ?? ((date) => true),
      headerStyle = headerStyle ?? HeaderStyle.normal(),
      disableDateStyle = disableDateStyle ?? DisableDateStyle.defaultTextStyle(),
      enableDateStyle = enableDateStyle ?? EnableDateStyle.defaultTextStyle(), // Set a default value if not provided
      super(key: key);