Show user badges on message details screen

This commit is contained in:
Evan Hahn 2021-11-16 09:53:41 -06:00 committed by GitHub
parent 4a055d4b95
commit a466b939bc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 1 deletions

View file

@ -8,6 +8,7 @@ import { MessageDetail } from '../../components/conversation/MessageDetail';
import { mapDispatchToProps } from '../actions';
import type { StateType } from '../reducer';
import { getPreferredBadgeSelector } from '../selectors/badges';
import { getIntl, getInteractionMode, getTheme } from '../selectors/user';
import { renderAudioAttachment } from './renderAudioAttachment';
import { renderEmojiPicker } from './renderEmojiPicker';
@ -17,6 +18,7 @@ import { getContactNameColorSelector } from '../selectors/conversations';
export { Contact } from '../../components/conversation/MessageDetail';
export type OwnProps = Omit<
MessageDetailProps,
| 'getPreferredBadge'
| 'i18n'
| 'interactionMode'
| 'renderAudioAttachment'
@ -63,6 +65,8 @@ const mapStateToProps = (
)
: undefined;
const getPreferredBadge = getPreferredBadgeSelector(state);
return {
contacts,
contactNameColor,
@ -71,6 +75,7 @@ const mapStateToProps = (
receivedAt,
sentAt,
getPreferredBadge,
i18n: getIntl(state),
interactionMode: getInteractionMode(state),
theme: getTheme(state),