Skip to content

Commit

Permalink
reader: fix content aware scrolling
Browse files Browse the repository at this point in the history
  • Loading branch information
irq0 committed Feb 20, 2024
1 parent fab8783 commit ef71a0c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion resources/status/llar.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,9 @@ $("body").keypress(function (event) {
}
event.preventDefault();
scroll_to.addClass("viewport-pivot");
$("body,html").animate({
scrollTop: scroll_to.offset().top - main_top - 5,
});
}
}
});
Expand Down Expand Up @@ -266,7 +269,9 @@ if (is_touch_device()) {
}
event.preventDefault();
scroll_to.addClass("viewport-pivot");
$("body").animate({ scrollTop: scroll_to.offset().top - main_top - 5 });
$("body,html").animate({
scrollTop: scroll_to.offset().top - main_top - 5,
});
});
}

Expand Down

0 comments on commit ef71a0c

Please sign in to comment.