This commit is contained in:
Timothy Jaeryang Baek committed 2026-05-09 03:40:23 +09:00
1 parent 4d766a3edf
commit cdfcbc4af6
5 files changed
+76 -10

No files matched your search

+12
View File
@@ -143,6 +143,18 @@
element.scrollTop = element.scrollHeight;
};
export const scrollToTop = async () => {
messagesCount = null;
buildMessages();
await tick();
if (messages.length > 0) {
const firstMessageEl = document.getElementById(`message-${messages[0].id}`);
if (firstMessageEl) {
firstMessageEl.scrollIntoView({ behavior: 'smooth', block: 'start' });
}
}
};
const updateChat = async () => {
if (!$temporaryChatEnabled) {
history = history;