Open neopit opened 5 days ago
Hey @neopit, as discussed on our Slack channel, this issue has to be addressed by the Stream backend and is more of a product discussion, so we are awaiting a response from them, and then we can handle it in the SDK. Until then, you can choose to show deleted messages in the UI.
Issue
A user reported an issue where no messages were visible in their chat, despite being certain that messages were present.
After investigating, we found that the user had deleted more than 100 messages. The chat was configured with deletedMessagesVisibilityType={'never'}, which means deleted messages are hidden. As a result, the chat appeared empty because all visible messages had been deleted, triggering the empty state component.
Due to the empty state, the user was unable to scroll through the list, preventing the system from fetching the next page of messages.
We believe this is a bug. In cases where deletedMessagesVisibilityType={'never'} is active and more than 100 messages have been deleted on the current page, the component should handle this scenario by automatically fetching subsequent pages until an active message is found.
Steps to reproduce
Steps to reproduce the behavior:
Expected behavior
When more than 100 messages are deleted and deletedMessagesVisibilityType={'never'} is configured on , the chat should automatically load the next page of messages, skipping over deleted ones, until an active (non-deleted) message is displayed.
Technically, if the component displays 100 messages per page, and if deletedMessagesVisibilityType={'never'}, then the component has to pull the next active 100 messages even if there is a deleted message in the middle.
Project Related Information
Customization
N/A
Offline support
N/A
package.json
:react-native info
output:stream-chat-react-native
version you're using that has this issue:5.39.4
e.g. Android 10
e.g. iPhone 11
Additional context
N/A
Screenshots
N/A