Skip to content
This repository has been archived by the owner on Jun 11, 2021. It is now read-only.

Commit

Permalink
fix(docsearch): use scrollTop on body
Browse files Browse the repository at this point in the history
  • Loading branch information
francoischalifour committed May 20, 2020
1 parent f8d0fbc commit 129c1d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/docsearch-react/src/DocSearchModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ export function DocSearchModal({

return () => {
document.body.classList.remove('DocSearch--active');
window.scrollTop = scrollY.current;
document.body.scrollTop = scrollY.current;
};
}, []);

Expand Down

0 comments on commit 129c1d1

Please sign in to comment.