onTap property

CalendarTapCallback? onTap
final

Called whenever the SfCalendar elements tapped on view.

The tapped date, appointments, and element details when the tap action performed on element available in the CalendarTapDetails.

see also:


return Container(
     child: SfCalendar(
       view: CalendarView.week,
       onTap: (CalendarTapDetails details){
         DateTime date = details.date!;
         dynamic appointments = details.appointments;
         CalendarElement view = details.targetElement;
       },
     ),
   );
 }

Implementation

final CalendarTapCallback? onTap;