HomePhabricator
Diffusion Comm 9e834fe59da5

[lib/web/native] Update ChatMentionCandidates type to include a rawChatName

Description

[lib/web/native] Update ChatMentionCandidates type to include a rawChatName

Summary:
When a user adds some ENS users to a chat, then clears the name, we can @-mention the chat by their ENS names (since we use the thread name from the ResolvedThread when constructing the search index for chat mentions).

The way we can allow people to @-mention this chat by the ENS users' wallet addresses (i.e. @0x should match the chat) is by including the raw chat name (before it's resolved) in our chat mention candidates object. This diff makes the necessary type updates and changes to deal with Flow. The next diff will utilize this new rawChatName and handle the entity text resolution (if necessary) when creating the chat mention search index.

Part of ENG-5436

Depends on D10459

Test Plan: Ran flow and manually tested @-mentioning to make sure no React errors logged in the console and that everythig still worked as expected.

Reviewers: atul, ginsu, inka

Reviewed By: inka

Subscribers: ashoat, tomek

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

Details

Provenance
rohanAuthored on Dec 26 2023, 9:39 AM
Reviewer
inka
Differential Revision
D10460: [lib/web/native] Update ChatMentionCandidates type to include a rawChatName
Parents
rCOMMf0db11d1b4e7: [lib] Pass in threadInfos into getChatMentionCandidates
Branches
Unknown
Tags
Unknown