Divide Conversation into ConversationInfos, ConversationMember, and ConversationSummary
- ConversationSummary is used to display ConversationList.
- Having the three separated will help managing queries.
- Adding ConversationSummary required to solve some inconsistencies in ConversationList, which was mixing contacts and conversations. ContactSearchResultList has been added as a quick fix . It will need more work.
- Some tools to uniformize conversation names have been introduced. They will need more work.
Note the diplaying of ConversationList is left broken in this commit.
Change-Id: I29337906cc43781a9c4790735490a6ee2cc51cb0
diff --git a/client/src/components/CallChatDrawer.tsx b/client/src/components/CallChatDrawer.tsx
index b87f37d..d094554 100644
--- a/client/src/components/CallChatDrawer.tsx
+++ b/client/src/components/CallChatDrawer.tsx
@@ -44,10 +44,7 @@
const CallChatDrawerHeader = () => {
const { setIsChatShown } = useCallContext();
- const { conversation } = useConversationContext();
-
- // TODO: Improve this to support multiple members
- const contact = conversation.getFirstMember().contact;
+ const { conversationDisplayName } = useConversationContext();
return (
<Stack direction="row" padding={2} spacing={2} alignItems="center">
@@ -58,7 +55,7 @@
/>
<Stack direction="column">
<Typography variant="h3" textOverflow="ellipsis">
- {contact.getDisplayName()}
+ {conversationDisplayName}
</Typography>
</Stack>
</Stack>