table_calendar icon indicating copy to clipboard operation
table_calendar copied to clipboard

ReorderableDelayedDragStartListener causes changing months not to work

Open Sun3 opened this issue 1 year ago • 0 comments

Describe the bug When you wrap a Table Calendar in a ReorderableDelayedDragStartListener() and trying to view previous or next months, it let's you scroll a few months then it bounces back to last scrolled month.

To reproduce Please include a short code sample that can be used to reproduce the problem.

body: CustomScrollView(
  slivers: [
    SliverReorderableList(
      itemBuilder: (context, index) {
        return ReorderableDelayedDragStartListener(
          index: index,
          child: TableCalendar(
            calendarFormat: CalendarFormat.month,
            firstDay: DateTime.utc(2023, 1, 01),
            lastDay: DateTime.utc(2024, 2, 29),
            focusedDay: DateTime.now(),
          ),
        );
      },
      itemCount: 7,
      onReorder: (oldIndex, newIndex) {},
    ),
  ],
),

Steps to reproduce the behavior:

  1. In TableCalendar navigate back or forward a few months
  2. It will show a few months, then it stops navigating back
  3. It will now show the previous last month scrolled

Expected behavior I expected the TableCalendar to keep scrolling backwards in months

Sun3 avatar Feb 09 '24 06:02 Sun3