nowCallback property
An optional callback that overrides how the calendar resolves "now".
The wall-clock components of the returned DateTime decide:
- where the time indicator sits, both its day and its time of day,
- which day DayHeader, MonthDayHeader and ScheduleDate highlight as today,
- whether EmptyDayBehavior.showOnlyToday keeps an empty day.
Useful when the calendar displays UTC but should follow the user's local wall clock:
MultiDayViewConfiguration.week(nowCallback: DateTime.now)
Pass the same function on every build, since this is included in ==. See
NowCallback for the shapes that qualify. dateResolver and the
multi-day resolvers are not compared, because they are read from the
incoming configuration at a view switch and so are already current.
Null, the default, uses the calendar's Location.
Implementation
final NowCallback? nowCallback;