Mercurial Hosting > chat
comparison src/chat.js @ 54:1d724f187cff
minor fix
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Mon, 03 Mar 2025 21:19:12 -0700 |
parents | 9298b04607ae |
children | 323ddacc1593 |
comparison
equal
deleted
inserted
replaced
53:9298b04607ae | 54:1d724f187cff |
---|---|
150 function added(html) { | 150 function added(html) { |
151 let input = document.querySelector('div[input]'); | 151 let input = document.querySelector('div[input]'); |
152 input.insertAdjacentHTML('beforebegin',html); | 152 input.insertAdjacentHTML('beforebegin',html); |
153 fixPosts(); | 153 fixPosts(); |
154 input.scrollIntoView({block: 'end'}); | 154 input.scrollIntoView({block: 'end'}); |
155 ajax(`added.js?chat=${currentChatId}`); | |
155 if( document.hasFocus() ) | 156 if( document.hasFocus() ) |
156 ajax('active.js'); | 157 ajax('active.js'); |
157 } | 158 } |
158 | 159 |
159 function getChats(chatId,updated) { | 160 function getChats(chatId,updated) { |