We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 422e6fe + 9d741b9 commit dd97ef5Copy full SHA for dd97ef5
packages/mantine-react-table/src/hooks/useMRT_RowVirtualizer.ts
@@ -60,7 +60,11 @@ export const useMRT_RowVirtualizer = <
60
overscan: 4,
61
rangeExtractor: useCallback(
62
(range: Range) => {
63
- return extraIndexRangeExtractor(range, draggingRow?.index ?? 0);
+ const current_index = getRowModel().rows.findIndex(
64
+ (row) => row.id === draggingRow?.id,
65
+ );
66
+
67
+ return extraIndexRangeExtractor(range, current_index >= 0 ? current_index: 0);
68
},
69
[draggingRow],
70
),
0 commit comments