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

The ability to break down unread count by channel type #1085

Open
aharwood9 opened this issue Jan 3, 2023 · 1 comment
Open

The ability to break down unread count by channel type #1085

aharwood9 opened this issue Jan 3, 2023 · 1 comment

Comments

@aharwood9
Copy link

aharwood9 commented Jan 3, 2023

Motivation
A clear and concise description of what the problem/opportunity is. Ex. I'm always frustrated when [...]

hi 👋 we use different channel types within our app I.e messaging vs live stream etc. We separate out the different functionality into different tabs and only query certain channel types within each tab. We would like to show the total unread count of each channel type on each tab. For example, lets say a user has 11 unread messages in total across all channel types. We would like to show 1 unread message on the messaging tab vs 10 on the live stream tab. This is important to bring users to those tabs to indicate something has changed. Having a single unread counter makes this very difficult as you can't even just put a red dot on the tab as you don't know if all unread messages are just from a single channel type.

Proposed solution
A clear and concise description of what you want to happen.

The total unread count across all channels is still critical to app badges so that should remain but after using connectUser and accessing the OwnUserResponse you should have some way to break down the total_unread_count by channel.

The solution would also need to update the listener on client for new events. When a new event is triggered with an updated unread count, we would need to know what channel type this is so we can update the tab accordingly.

Acceptance Criteria
A set of predefined requirements that must be met to mark a user story complete.

  1. Connect to a user
  2. Still be able to access the total unread count across all channels
  3. Be able to break down the total unread count across all channels by channel type.
  4. Recieve a new event on the client
  5. See the event contains the total unread count across all channels and can be broken down by channel type

P.S happy to move this to stream-chat-js if not directly related to the react native library

@vanGalilea vanGalilea transferred this issue from GetStream/stream-chat-react-native Jan 5, 2023
@vanGalilea
Copy link
Contributor

@aharwood9 thanks for reaching out. We will add this to our internal backlog, definitely a missing feature 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants