Skip to content

Commit

Permalink
Fix scroll
Browse files Browse the repository at this point in the history
  • Loading branch information
TIT8 committed Aug 28, 2024
1 parent cb990be commit afa34fc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions layouts/shortcodes/goup.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@


function scrollFunction() {
document.documentElement.style.scrollBehavior = 'smooth';
if (document.body.scrollTop > 1000 || document.documentElement.scrollTop > 1000 || window.scrollY > 1000) {
goup.classList.add("add");
} else {
Expand Down
1 change: 1 addition & 0 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -707,6 +707,7 @@ <h1 id="extra">Extra</h1>


function scrollFunction() {
document.documentElement.style.scrollBehavior = 'smooth';
if (document.body.scrollTop > 1000 || document.documentElement.scrollTop > 1000 || window.scrollY > 1000) {
goup.classList.add("add");
} else {
Expand Down

0 comments on commit afa34fc

Please sign in to comment.