Use proxy-compare for message bubbles

This commit is contained in:
Fedor Indutny 2022-12-22 16:32:03 -08:00 committed by GitHub
parent f92f81dfd6
commit 55a1c5f6c5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 442 additions and 562 deletions

View file

@ -17,12 +17,12 @@ import type { ConversationType } from '../ducks/conversations';
import { getIntl, getTheme } from '../selectors/user';
import {
getMessages,
getConversationByUuidSelector,
getConversationMessagesSelector,
getConversationSelector,
getConversationsByTitleSelector,
getInvitedContactsForNewlyCreatedGroup,
getMessageSelector,
getSelectedMessage,
} from '../selectors/conversations';
@ -229,9 +229,8 @@ const mapStateToProps = (state: StateType, props: ExternalProps) => {
const conversationMessages = getConversationMessagesSelector(state)(id);
const selectedMessage = getSelectedMessage(state);
const messageSelector = getMessageSelector(state);
const getTimestampForMessage = (messageId: string): undefined | number =>
messageSelector(messageId)?.timestamp;
getMessages(state)[messageId]?.timestamp;
return {
id,