mirror of
https://github.com/documenso/documenso.git
synced 2026-07-11 05:25:08 +10:00
381293af0c
- **fix: interpolate inviterEmail in invite email mailto link** - **fix: add alt attributes to email template images**
18 lines
469 B
TypeScript
18 lines
469 B
TypeScript
import { Img } from '../components';
|
|
|
|
export interface TemplateImageProps {
|
|
assetBaseUrl: string;
|
|
className?: string;
|
|
staticAsset: string;
|
|
}
|
|
|
|
export const TemplateImage = ({ assetBaseUrl, className, staticAsset }: TemplateImageProps) => {
|
|
const getAssetUrl = (path: string) => {
|
|
return new URL(path, assetBaseUrl).toString();
|
|
};
|
|
|
|
return <Img className={className} src={getAssetUrl(`/static/${staticAsset}`)} alt="" />;
|
|
};
|
|
|
|
export default TemplateImage;
|