Skip to content

Commit

Permalink
Merge pull request #1574 from rowyio/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
shams-mosowi authored Nov 23, 2024
2 parents a8c6682 + 89b9d12 commit 147a7fa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/components/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ export default function Table({
const [tablePage, setTablePage] = useAtom(tablePageAtom, tableScope);
const setReactTable = useSetAtom(reactTableAtom, tableScope);

const setSelectedCell = useSetAtom(selectedCellAtom, tableScope);
const updateColumn = useSetAtom(updateColumnAtom, tableScope);

// Get user settings and tableId for applying sort sorting
Expand Down Expand Up @@ -313,6 +314,8 @@ export default function Table({

const { scrollHeight, scrollTop, clientHeight } = containerElement;
if (scrollHeight - scrollTop - clientHeight < 300) {
// deselect cell on next page load
setSelectedCell(null);
setTablePage((p) => p + 1);
}
},
Expand Down

0 comments on commit 147a7fa

Please sign in to comment.