Skip to content

Commit

Permalink
Merge pull request #253 from pateljannat/sidebar-scroll
Browse files Browse the repository at this point in the history
fix: sidebar scroll
  • Loading branch information
pateljannat authored Jun 19, 2024
2 parents 98ab0ca + e575036 commit 8aee44c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion wiki/public/js/render_wiki.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ window.RenderWiki = class RenderWiki extends Wiki {
{
scrollTop: offset,
},
500,
100,
);
});
});
Expand Down
5 changes: 1 addition & 4 deletions wiki/public/js/wiki.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,7 @@ window.Wiki = class Wiki {
let active_sidebar_item = $(".doc-sidebar .sidebar-item.active");
if (active_sidebar_item.length > 0) {
setTimeout(function () {
active_sidebar_item.get(0).scrollIntoView({
behavior: "instant",
block: "center",
});
active_sidebar_item.get(0).scrollIntoView(false);
}, 50);
}
}
Expand Down

0 comments on commit 8aee44c

Please sign in to comment.