feat(templates): add styles to Message

This commit is contained in:
Julien Oculi 2024-04-11 16:48:52 +02:00
parent f3918321bd
commit 8194fd3aa3

View file

@ -1,18 +1,19 @@
import { Body, Html, Markdown, Preview, Section, Text } from 'jsx-email'
import { Body, Container, Html, Markdown, Preview } from 'jsx-email'
import { Signature } from './components/Signature.tsx'
import type { Template } from '../types.ts'
import { BaseStyle, bodyCss, messageCss, textCss } from './styles/base.tsx'
function Message(
{ summary, body }: { summary?: string; body: string },
) {
return (
<Html lang='fr'>
<Html lang='fr' style={{ fontSize: '14px' }}>
<BaseStyle />
<Preview>{summary}</Preview>
<Body>
<Markdown>{body}</Markdown>
<Section>
<Text>Coh@bit</Text>
</Section>
<Body style={bodyCss}>
<Container style={messageCss}>
<Markdown style={textCss}>{body}</Markdown>
</Container>
<Signature />
</Body>
</Html>