Receive support for DOE messages
This commit is contained in:
parent
b8a674bbb6
commit
ba5e2ff6e5
17 changed files with 291 additions and 42 deletions
|
@ -31,6 +31,7 @@ export type PropsData = {
|
|||
lastMessage?: {
|
||||
status: 'sending' | 'sent' | 'delivered' | 'read' | 'error';
|
||||
text: string;
|
||||
deletedForEveryone?: boolean;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -152,6 +153,9 @@ export class ConversationListItem extends React.PureComponent<Props> {
|
|||
}
|
||||
|
||||
const showingDraft = shouldShowDraft && draftPreview;
|
||||
const deletedForEveryone = Boolean(
|
||||
lastMessage && lastMessage.deletedForEveryone
|
||||
);
|
||||
|
||||
// Note: instead of re-using showingDraft here we explode it because
|
||||
// typescript can't tell that draftPreview is truthy otherwise
|
||||
|
@ -181,6 +185,10 @@ export class ConversationListItem extends React.PureComponent<Props> {
|
|||
<span className="module-conversation-list-item__message__draft-prefix">
|
||||
{i18n('ConversationListItem--draft-prefix')}
|
||||
</span>
|
||||
) : deletedForEveryone ? (
|
||||
<span className="module-conversation-list-item__message__deleted-for-everyone">
|
||||
{i18n('message--deletedForEveryone')}
|
||||
</span>
|
||||
) : null}
|
||||
<MessageBody
|
||||
text={text.split('\n')[0]}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue