Skip to content

Commit 4f2dd51

Browse files
author
Bent
authored
Fix terminal scrolling and terminalNotify
The original statement seems to be a bit too precise regarding the height. Any tiny lag or one pixel movement leads to the console not being scrolled to the bottom anymore. Same applies for manually scrolling down which does not hide the `terminalNotify` properly. A bit larger "buffer" fixes this.
1 parent db2a804 commit 4f2dd51

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

public/themes/pterodactyl/js/frontend/console.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ $(document).ready(function () {
116116
});
117117

118118
$terminal.on('scroll', function () {
119-
if ($(this).scrollTop() + $(this).innerHeight() < $(this)[0].scrollHeight) {
119+
if ($(this).scrollTop() + $(this).innerHeight() + 50 < $(this)[0].scrollHeight) {
120120
$scrollNotify.removeClass('hidden');
121121
} else {
122122
$scrollNotify.addClass('hidden');

0 commit comments

Comments
 (0)