mail view: focus the cursor in the correct place when composing
authorArt Cancro <ajc@citadel.org>
Tue, 21 Nov 2023 23:22:57 +0000 (18:22 -0500)
committerArt Cancro <ajc@citadel.org>
Tue, 21 Nov 2023 23:22:57 +0000 (18:22 -0500)
webcit-ng/static/js/view_mail.js

index 830768a50476e3b83124a27f667fbee52ed818c0..e44a73a032990786b07f11793f48ceebb0f85f6d 100644 (file)
@@ -534,6 +534,8 @@ function mail_compose(is_quoted, references, quoted_msgnum, m_to, m_cc, m_subjec
                document.getElementById(quoted_div_name).innerHTML = quoted_msgnum;
                mail_display_message(quoted_msgnum, document.getElementById(quoted_div_name), 0);
        }
+
+       setTimeout(() => { document.getElementById("ctdl-editor-body").focus(); }, 0);
 }
 
 // Called when the user clicks the button to make the hidden "CC" and "BCC" lines appear.