fix(chat): prevent page scroll on mobile when sending/receiving messages
This commit is contained in:
@@ -77,7 +77,9 @@ const EventChatPage = () => {
|
||||
}, [searchParams]);
|
||||
|
||||
const scrollToBottom = () => {
|
||||
messagesEndRef.current?.scrollIntoView({ behavior: 'smooth' });
|
||||
if (messagesContainerRef.current) {
|
||||
messagesContainerRef.current.scrollTop = messagesContainerRef.current.scrollHeight;
|
||||
}
|
||||
};
|
||||
|
||||
// Fetch event data and check participation
|
||||
|
||||
Reference in New Issue
Block a user