import { FC } from 'react' import { useTranslation } from 'react-i18next' import getMeta from '@/utils/meta' export type RequireAcceptData = { projectName?: string linkSharingChanges: boolean } export const RequireAcceptScreen: FC<{ requireAcceptData: RequireAcceptData sendPostRequest: (confirmedByUser: boolean) => void }> = ({ requireAcceptData, sendPostRequest }) => { const { t } = useTranslation() const user = getMeta('ol-user') if (requireAcceptData.linkSharingChanges) { return (

{t('youre_joining')}
{requireAcceptData.projectName || 'This project'} {user && ( <>
{t('as_email', { email: user.email })} )}

{t( 'your_name_and_email_address_will_be_visible_to_the_project_owner_and_other_editors' )}

) } return (

{t('invited_to_join')}
{requireAcceptData.projectName || 'This project'}

{user && (

{t('accepting_invite_as')} {user.email}

)}
) }