From 0a3b5d50f2aae4f2a90e79bb09a12f30a399ba94 Mon Sep 17 00:00:00 2001 From: Kato Twofold Date: Tue, 7 Jun 2022 00:39:05 +0300 Subject: [PATCH] * Default to scroll at the bottom of content --- static/js/pad-scripts.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/static/js/pad-scripts.js b/static/js/pad-scripts.js index cb355e9..83b945d 100644 --- a/static/js/pad-scripts.js +++ b/static/js/pad-scripts.js @@ -213,6 +213,8 @@ function setTextareaPreview(t = true) { padContentArea.classList.add(`read-only-content`); + prev.scrollTop = prev.scrollHeight; + textarea.classList.add(`hidden`); } else { // Toggle edit mode