Skip to content

JacGPT/Add scrolling behaviour to meesage streaming#525

Open
RavimalRanathunga wants to merge 5 commits intomainfrom
514-jac-gpt-issues
Open

JacGPT/Add scrolling behaviour to meesage streaming#525
RavimalRanathunga wants to merge 5 commits intomainfrom
514-jac-gpt-issues

Conversation

@RavimalRanathunga
Copy link
Copy Markdown
Collaborator

Changes associate with this PR:-

  • Add a smooth scrolling behavior in the frontend when response is streaming

@RavimalRanathunga RavimalRanathunga self-assigned this Mar 10, 2026
Copilot AI review requested due to automatic review settings March 10, 2026 18:19
@RavimalRanathunga RavimalRanathunga linked an issue Mar 10, 2026 that may be closed by this pull request
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds automatic smooth scrolling to the chat UI while assistant responses are streaming, implemented in the useChat hook that powers the main chat page.

Changes:

  • Introduces a new useEffect that scrolls to the bottom on every messages update (including streaming chunk updates).
  • Uses a setTimeout(..., 0) to defer scrolling until after the DOM update.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread jac-gpt-fullstack/hooks/useChat.cl.jac
Comment thread jac-gpt-fullstack/hooks/useChat.cl.jac
Copy link
Copy Markdown
Collaborator

@udithishanka udithishanka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3 issues to fix.

Comment thread jac-gpt-fullstack/hooks/useChat.cl.jac Outdated
Comment thread jac-gpt-fullstack/hooks/useChat.cl.jac
Comment thread jac-gpt-fullstack/hooks/useChat.cl.jac
@RavimalRanathunga RavimalRanathunga changed the title Add scrolling behaviour to meesage streaming JacGPT/Add scrolling behaviour to meesage streaming Mar 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Jac-gpt Issues

3 participants