Skip to content

Commit 3f3a865

Browse files
authored
Merge pull request #452 from arduino/console_autoscroll_fix
fixed autoscroll in debug console
2 parents c2363f2 + 607eed8 commit 3f3a865

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

main.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -357,9 +357,8 @@ const homeTemplateHtml = `<!DOCTYPE html>
357357
if (messages.length > 2000) {
358358
messages.shift();
359359
}
360-
var doScroll = log.scrollTop == log.scrollHeight - log.clientHeight;
361360
log.innerHTML = messages.join('<br>');
362-
if (autoscroll.checked && doScroll) {
361+
if (autoscroll.checked) {
363362
log.scrollTop = log.scrollHeight - log.clientHeight;
364363
}
365364
}
@@ -429,6 +428,7 @@ body {
429428
}
430429
431430
.buttons {
431+
align-items: center;
432432
display: flex;
433433
padding: 0 .5em;
434434
margin: 0;

0 commit comments

Comments
 (0)