HomePhabricator
Diffusion Comm 303fafe8b2b2

[web] Add a selector for getting the number of unnreads in the selected…

Description

[web] Add a selector for getting the number of unnreads in the selected community

Summary:
issue: https://linear.app/comm/issue/ENG-3179/make-the-badge-on-the-chat-tab-responsive-to-drawer-selection
We want the badge on the chat tab to display the number of unreads for the selected community.
This selector is almost identical to unreadCount selector that was used here before, for getting the number of all unreads, it only adds the (!communityID || communityID === threadInfo.community) condition

when we navigate to Calendar the number on the Chat tab is still supposed to display the number for the community selected in the Chat tab

Test Plan: run web app, checked that the number on the badge takes into account only chats from the current community

Reviewers: michal, kuba

Reviewed By: michal

Subscribers: ashoat, tomek, atul

Differential Revision: https://phab.comm.dev/D6979

Details

Provenance
InkaSokolowskaAuthored on May 23 2023, 12:47 AM
Reviewer
michal
Differential Revision
D6979: [web] Add a selector for getting the number of unnreads in the selected community
Parents
rCOMM65ad778124ed: [web] Add a badge on the Inbox button
Branches
Unknown
Tags
Unknown