Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PBE-6017] message list does not scroll on new msg #5427

Merged
merged 7 commits into from
Oct 9, 2024

Conversation

kanat
Copy link
Collaborator

@kanat kanat commented Oct 3, 2024

🎯 Goal

Closes:

Related PR:

ℹ️ Details

It seems like this is a side effect of the fix for XML (#5280).
NewMessageState changes too fast for Compose to reflect all state changes, that leads to position where Compose thinks that nothing has changed.

I've revisited scrolling logic in both XML and Compose:

  1. NewMessageState should always reflect latest new message, we only change it when a new message is being received
  2. Re-fixed XML scrolling behaviour in MessageListScrollHelper
  3. Added a new test to MessageListControllerTests to make sure we won't break statement from N1

☑️Contributor Checklist

General

  • I have signed the Stream CLA (required)
  • Assigned a person / code owner group (required)
  • Thread with the PR link started in a respective Slack channel (#android-chat-core or #android-chat-ui) (required)
  • PR targets the develop branch
  • PR is linked to the GitHub issue it resolves

Code & documentation

  • Changelog is updated with client-facing changes
  • New code is covered by unit tests
  • Comparison screenshots added for visual changes
  • Affected documentation updated (KDocs, docusaurus, tutorial)

☑️Reviewer Checklist

  • UI Components sample runs & works
  • Compose sample runs & works
  • UI Changes correct (before & after images)
  • Bugs validated (bugfixes)
  • New feature tested and works
  • Release notes and docs clearly describe changes
  • All code we touched has new or updated KDocs

🎉 GIF

Please provide a suitable gif that describes your work on this pull request

@kanat kanat requested a review from a team as a code owner October 3, 2024 22:22
@kanat kanat enabled auto-merge (squash) October 9, 2024 15:14
@kanat kanat merged commit d7717c7 into develop Oct 9, 2024
7 checks passed
@kanat kanat deleted the fix/message-list-scroll branch October 9, 2024 21:01
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.

2 participants