Flutter calendar use a overlay window to select a range of date on mobile.

You can choose a date range.

alt tag

Or you can choose one date.

alt tag

Usage import 'package:calendar/custom_calendar.dart'; ...

      onTap:() => CustomCalendar(context,disabledDate: disabledDate),
      child: Container(
        width: 300,
        height: 50,
        decoration: BoxDecoration(
          borderRadius: const BorderRadius.all(Radius.circular(20)),
          border: Border.all(color: Colors.black),
        child: Center(
          child: StreamBuilder<List<DateTime>>(
            stream: selectedDates,
            builder: (context, snapshot) {
              if (snapshot != null && snapshot.hasData) {
                final text = dateFormat(snapshot);
                return Text(text);
              return const Text('Выберите дату');



borderColor - Color

Color for calendar border.

enabledWorkdayColor - Color

Text color for selectable workday days.

disabledWorkdayColor - Color

Text color for unavailable workday days.

enabledHolidayColor - Color

Text color for selectable weekends.

disabledHolidayColor - Color

Text color for unavailable holidays.

Please note that Saturday and Sunday are always unavailable weekends.

inversionWorkdayColor - Color

Text color for the selected workday.

inversionHolidayColor - Color

Text color for the selected weekend.

primaryTextColor - Color

Text color for the month.

secondaryTextColor - Color

Text color for year.

roundColor - Color

Fill color of the selected date.

disabledRoundColor - Color

Fill color for a date that is not selectable but falls within the range.

disabledDate - List

List of non-selectable days or holidays.

class Day { DateTime dateTime; bool isHoliday; bool isDisabled; }