MonthGrid constructor
MonthGrid(
- YearMonth yearMonth, {
- required CurrentDatePickedEvent currentDatePickedEvent,
- FirstDayOfWeek firstDayOfWeek = FirstDayOfWeek.sun,
- DayBoxStyle? dayBoxStyle,
- Axis direction = Axis.vertical,
- List<
Events> events = const <Events>[], - List<
Holiday> holiday = const <Holiday>[],
Create new GridView of yearMonth
Implementation
MonthGrid(this.yearMonth,
{required this.currentDatePickedEvent,
this.firstDayOfWeek = FirstDayOfWeek.sun,
this.dayBoxStyle,
this.direction = Axis.vertical,
this.events = const <Events>[],
this.holiday = const <Holiday>[]})
: assert(_checkHolidayListReduced(holiday, yearMonth)),
assert(_checkEventsListReduced(events, yearMonth)),
_dim = List<DateTime?>.filled(
firstDayOfWeek.calculatePlaceholderFromStart(yearMonth), null,
growable: true)
..addAll(yearMonth.allDaysInMonth)
..addAll(List.filled(
firstDayOfWeek.calculatePlaceholderFromEnd(yearMonth), null));