diff --git a/app/components/chat.tsx b/app/components/chat.tsx index 7589f0037d3..967adad45b3 100644 --- a/app/components/chat.tsx +++ b/app/components/chat.tsx @@ -449,10 +449,8 @@ function useScrollToBottom() { function scrollDomToBottom() { const dom = scrollRef.current; if (dom) { - requestAnimationFrame(() => { - setAutoScroll(true); - dom.scrollTo(0, dom.scrollHeight); - }); + // Improve Use smooth scrolling behavior + dom.scrollTo({ top: dom.scrollHeight, behavior: 'smooth' }); } }