overleaf/services/web/frontend/js/features/subscription/components/group-invite/accepted-invite.tsx
Jakob Ackermann aa480a2663 Merge pull request #18898 from overleaf/jpa-no-window
[web] migrate from window attributes to getMeta

GitOrigin-RevId: 3dcf1ab6b01155e5e4abeb3e78d0fa9053e055bc
2024-06-19 08:04:21 +00:00

24 lines
646 B
TypeScript

import getMeta from '@/utils/meta'
import { useTranslation } from 'react-i18next'
export default function AcceptedInvite() {
const { t } = useTranslation()
const inviterName = getMeta('ol-inviterName')
const groupSSOActive = getMeta('ol-groupSSOActive')
const subscriptionId = getMeta('ol-subscriptionId')
const doneLink = groupSSOActive
? `/subscription/${subscriptionId}/sso_enrollment`
: '/project'
return (
<div className="text-center">
<p>{t('joined_team', { inviterName })}</p>
<p>
<a href={doneLink} className="btn btn-primary">
{t('done')}
</a>
</p>
</div>
)
}