Skip to content

Commit

Permalink
fix: table dynamic change scrolly.
Browse files Browse the repository at this point in the history
  • Loading branch information
bestlyg authored and yinkaihui committed Mar 21, 2024
1 parent dbab675 commit d510d23
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion components/Table/table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,9 @@ function Table<T extends unknown>(baseProps: TableProps<T>, ref: React.Ref<Table
easing: 'quintInOut',
duration: 300,
onUpdate: (keys) => {
refTableBody.current.scrollTop = keys.scrollTop;
if (refTableBody.current) {
refTableBody.current.scrollTop = keys.scrollTop;
}
},
});
tween.start();
Expand Down

0 comments on commit d510d23

Please sign in to comment.