import { Heading } from '@react-email/heading'; import { Text } from '@react-email/text'; import { Button } from '../components/Button'; import { EmailContainer } from '../components/EmailContainer'; import { THEME_COLORS } from '../theme'; import type { EmailBaseProps } from '../types'; export type TeamRoleGrantedEmailTemplateProps = { mode: EmailBaseProps['mode']; tenant: EmailBaseProps['tenant']; member: string; roles: string; grantedAt: string; grantedBy: string | null; partnerName: string | null; href: string; }; export const TeamRoleGrantedEmailTemplate = ({ mode, tenant, member, roles, grantedAt, grantedBy, partnerName, href, }: TeamRoleGrantedEmailTemplateProps) => ( New {roles} on your team {member} received {roles} on {tenant.name} on {grantedAt} {grantedBy ? ` from ${grantedBy}` : ''} {partnerName ? `, acting through your partner ${partnerName}` : ''}. If you did not expect this change, review the team members and remove the role.