// Copyright 2020 Signal Messenger, LLC // SPDX-License-Identifier: AGPL-3.0-only import * as React from 'react'; import { ContactName } from './ContactName'; import { Button, ButtonVariant } from '../Button'; import type { MessageRequestActionsConfirmationProps } from './MessageRequestActionsConfirmation'; import { MessageRequestActionsConfirmation, MessageRequestState, } from './MessageRequestActionsConfirmation'; import { I18n } from '../I18n'; import type { LocalizerType } from '../../types/Util'; export type Props = { i18n: LocalizerType; } & Pick< MessageRequestActionsConfirmationProps, | 'addedByName' | 'conversationId' | 'conversationType' | 'conversationName' | 'isBlocked' | 'isReported' | 'acceptConversation' | 'reportSpam' | 'blockAndReportSpam' | 'blockConversation' | 'deleteConversation' >; const learnMoreLink = (parts: Array) => ( {parts} ); export function MandatoryProfileSharingActions({ addedByName, conversationId, conversationType, conversationName, i18n, isBlocked, isReported, acceptConversation, reportSpam, blockAndReportSpam, blockConversation, deleteConversation, }: Props): JSX.Element { const [mrState, setMrState] = React.useState(MessageRequestState.default); const firstNameContact = ( ); return ( <> {mrState !== MessageRequestState.default ? ( { throw new Error( 'Should not be able to unblock from MandatoryProfileSharingActions' ); }} blockConversation={blockConversation} deleteConversation={deleteConversation} reportSpam={reportSpam} blockAndReportSpam={blockAndReportSpam} onChangeState={setMrState} /> ) : null}

{conversationType === 'direct' ? ( ) : ( )}

); }