mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-04 01:46:52 -05:00
537c822789
Learn wiki links should open in new tab GitOrigin-RevId: 7e87feff971bc2c28d0e0bac85e0e20ef139e321
44 lines
1.1 KiB
TypeScript
44 lines
1.1 KiB
TypeScript
import { Trans, useTranslation } from 'react-i18next'
|
|
import getMeta from '../../../utils/meta'
|
|
|
|
export default function ManagedAccountAlert() {
|
|
const { t } = useTranslation()
|
|
const isManaged = getMeta('ol-isManagedAccount', false)
|
|
const currentManagedUserAdminEmail: string = getMeta(
|
|
'ol-currentManagedUserAdminEmail',
|
|
''
|
|
)
|
|
|
|
if (!isManaged) {
|
|
return null
|
|
}
|
|
|
|
return (
|
|
<div className="enrollment-alert">
|
|
<div className="icon">
|
|
<span className="info-badge" />
|
|
</div>
|
|
<div>
|
|
<div>
|
|
<strong>
|
|
{t('account_managed_by_group_administrator', {
|
|
admin: currentManagedUserAdminEmail,
|
|
})}
|
|
</strong>
|
|
</div>
|
|
<div>
|
|
<Trans
|
|
i18nKey="need_contact_group_admin_to_make_changes"
|
|
components={[
|
|
// eslint-disable-next-line jsx-a11y/anchor-has-content, react/jsx-key
|
|
<a
|
|
href="/learn/how-to/Understanding_Managed_Overleaf_Accounts"
|
|
target="_blank"
|
|
/>,
|
|
]}
|
|
/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|