weekly_calendar library

Deprecated 1.x compatibility library retained for gradual v2 migration.

Classes

CalendarEvent
Represents an event in the calendar with its properties.
EventCalendar
A calendar widget that displays events for each day of the week.
EventCalendarStyle
Style configuration for the event calendar, allowing customization of appearance.
FocusDate
Represents a date with an associated color to highlight or focus it in the calendar.
HorizontalCalendarStyle
Contains all visual styling parameters for the calendar
HorizontalWeeklyCalendar
A horizontally scrollable weekly calendar widget with multiple visual styles
TableWeeklyCalendar
A widget that displays a table-based weekly calendar with customizable styles, focus dates, and navigation.

Enums

HorizontalCalendarType
Defines visual variations of the horizontal calendar
Weekday
Represents days of the week with ISO 8601 numbering (Monday = 1)

Functions

buildNavigationIcon({required IconData icon, required bool enabled, required Color? iconColor, required BuildContext context, required double size, required VoidCallback? onPressed}) Widget
Builds a navigation icon button that appears disabled when enabled is false.
canNavigateToNextMonth(DateTime currentDate, DateTime? maxDate) bool
Returns true if navigating to the next month is allowed given maxDate.
canNavigateToPreviousMonth(DateTime currentDate, DateTime? minDate) bool
Returns true if navigating to the previous month is allowed given minDate.
generateWeeks(DateTime date, int startDay) List<List<DateTime>>
Generates a list of complete 7-day weeks covering the full date month, aligned to startDay (1=Monday … 7=Sunday).
generateWeeksChunked(DateTime date) List<List<DateTime>>
Generates sequential chunks of up to 7 days for the date month without weekday alignment. The last chunk may have fewer than 7 days.
isDateDisabled(DateTime date, DateTime? minDate, DateTime? maxDate) bool
Returns true if date falls outside the minDatemaxDate range.
isSameDay(DateTime a, DateTime b) bool
Returns true if a and b represent the same calendar date.

Typedefs

TableWeeklyCalendarHeaderBuilder = Widget Function(BuildContext context, DateTime currentDate, VoidCallback onPreviousMonth, VoidCallback onNextMonth)
A builder function type for creating a custom header widget for the weekly calendar.