import { useTranslation } from 'react-i18next' import { UserEmailData } from '../../../../../../types/user-email' import ResendConfirmationEmailButton from './resend-confirmation-email-button' type EmailProps = { userEmailData: UserEmailData } function Email({ userEmailData }: EmailProps) { const { t } = useTranslation() return ( <> {userEmailData.email} {userEmailData.default ? ' (primary)' : ''} {!userEmailData.confirmedAt && (
{t('unconfirmed')}. {!userEmailData.ssoAvailable && ( {t('please_check_your_inbox')}. )}
{!userEmailData.ssoAvailable && ( )}
)} {userEmailData.confirmedAt && userEmailData.affiliation?.institution.confirmed && userEmailData.affiliation?.licence !== 'free' && (
{t('professional')}
)} ) } export default Email