// Copyright 2021 Signal Messenger, LLC // SPDX-License-Identifier: AGPL-3.0-only import React from 'react'; import { Avatar } from '../../Avatar'; import { Emojify } from '../Emojify'; import { LocalizerType } from '../../../types/Util'; import { ConversationType } from '../../../state/ducks/conversations'; import { GroupV2Membership } from './ConversationDetailsMembershipList'; import { bemGenerator } from './util'; export type Props = { canEdit: boolean; conversation: ConversationType; i18n: LocalizerType; memberships: Array; startEditing: () => void; }; const bem = bemGenerator('module-conversation-details-header'); export const ConversationDetailsHeader: React.ComponentType = ({ canEdit, conversation, i18n, memberships, startEditing, }) => { const contents = ( <>
{i18n('ConversationDetailsHeader--members', [ memberships.length.toString(), ])}
); if (canEdit) { return ( ); } return
{contents}
; };