mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-25 03:42:30 +00:00
Fix scroll behavior for navigation (#4406)
This commit is contained in:
@@ -85,7 +85,9 @@ function scrollToHash(hash: string) {
|
||||
if (element) {
|
||||
element.scrollIntoView({
|
||||
block: 'start',
|
||||
behavior: 'smooth',
|
||||
// Looks like there is a bug when using smooth scroll on navigation between pages.
|
||||
// The browser does not scroll, probably some kind of browser optimization.
|
||||
behavior: 'instant',
|
||||
});
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user