import { Trans } from '@lingui/react/macro'; import { Fragment } from 'react'; import { Link, Section, Text } from '../components'; import { useBranding } from '../providers/branding'; import { getSafeBrandingUrl } from '../utils/branding-url'; export type TemplateFooterProps = { isDocument?: boolean; reportUrl?: string; }; export const TemplateFooter = ({ isDocument = true, reportUrl }: TemplateFooterProps) => { const branding = useBranding(); const safeBrandingUrl = branding.brandingEnabled ? getSafeBrandingUrl(branding.brandingUrl) : null; return (
{reportUrl && ( Did not expect this email?{' '} Click here to report the sender . Never sign a document you don't recognize or weren't expecting. )} {isDocument && !branding.brandingHidePoweredBy && ( This document was sent using{' '} Documenso . )} {branding.brandingEnabled && branding.brandingCompanyDetails && ( {branding.brandingCompanyDetails.split('\n').map((line, idx) => { return ( {idx > 0 &&
} {line}
); })}
)} {branding.brandingEnabled && safeBrandingUrl && ( {safeBrandingUrl} )} {!branding.brandingEnabled && ( Documenso, Inc.
2261 Market Street, #5211, San Francisco, CA 94114, USA
)}
); }; export default TemplateFooter;