Smooth scroll to the top on page change
This commit is contained in:
@@ -369,6 +369,7 @@ export class Search extends React.Component {
|
|||||||
|
|
||||||
handlePageChange = (who, page) => {
|
handlePageChange = (who, page) => {
|
||||||
this.setState({who: who, page: page}, this.navigateToState);
|
this.setState({who: who, page: page}, this.navigateToState);
|
||||||
|
window.scroll({left: 0, top: 0, behavior: 'smooth'});
|
||||||
};
|
};
|
||||||
|
|
||||||
render = () => (
|
render = () => (
|
||||||
|
|||||||
Reference in New Issue
Block a user