Mercurial Hosting > chat
diff src/chat.js @ 78:2a602ef53eef
minor
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sun, 09 Mar 2025 22:20:36 -0600 |
parents | 624654817f99 |
children | b5a316575e64 |
line wrap: on
line diff
--- a/src/chat.js Sun Mar 09 19:29:41 2025 -0600 +++ b/src/chat.js Sun Mar 09 22:20:36 2025 -0600 @@ -71,6 +71,13 @@ } } +function editTextareaKey(event) { + if( event.keyCode===13 && !event.shiftKey && !event.ctrlKey && !isMobile ) { + event.preventDefault(); + savePost(event.target); + } +} + function fixPosts() { let divs = document.querySelectorAll('div[post][fix]'); for( let div of divs ) {