forked from retoor/snek
feat: change scroll load offset from first to tenth child element
The offset element for loading additional chat messages was changed from the first child to the tenth child of the messages container, altering the scroll trigger point for infinite loading behavior.
This commit is contained in:
@@ -59,7 +59,7 @@
|
||||
const messagesContainer = document.querySelector(".chat-messages");
|
||||
async function loadExtra() {
|
||||
|
||||
const offsetMessage = messagesContainer.querySelector(".chat-messages :nth-child(1)");
|
||||
const offsetMessage = messagesContainer.querySelector(".chat-messages :nth-child(10)");
|
||||
if(!offsetMessage){
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user