email styling

This commit is contained in:
ThatOneCalculator 2023-04-19 21:26:49 -07:00
parent a1f723a18e
commit 89d2a83d7a
No known key found for this signature in database
GPG Key ID: 8703CACD01000000
1 changed files with 11 additions and 8 deletions

View File

@ -39,14 +39,14 @@ export async function sendEmail(
to: to, to: to,
subject: subject, subject: subject,
text: text, text: text,
html: `<!doctype html> html: `<!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>${subject}</title> <title>${subject}</title>
<style> <style>
html { html {
background: #eee; background: #191724;
} }
body { body {
@ -67,17 +67,19 @@ export async function sendEmail(
main { main {
max-width: 500px; max-width: 500px;
margin: 0 auto; margin: 0 auto;
background: #e0def4; background: #1f1d2e;
color: #6e6a86; color: #e0def4;
} }
main > header { main > header {
padding: 32px; padding: 32px;
background: #31748f; background: #31748f;
display: flex;
} }
main > header > img { main > header > img {
max-width: 128px; max-width: 128px;
max-height: 28px; max-height: 72px;
vertical-align: bottom; vertical-align: bottom;
margin-right: 16px;
} }
main > article { main > article {
padding: 32px; padding: 32px;
@ -87,7 +89,7 @@ export async function sendEmail(
} }
main > footer { main > footer {
padding: 32px; padding: 32px;
border-top: solid 1px #eee; border-top: solid 1px #26233a;
} }
nav { nav {
@ -97,14 +99,15 @@ export async function sendEmail(
padding: 0 32px; padding: 0 32px;
} }
nav > a { nav > a {
color: #888; color: #6e6a86;
} }
</style> </style>
</head> </head>
<body> <body>
<main> <main>
<header> <header>
<img src="${meta.logoImageUrl || meta.iconUrl || iconUrl}"/> <img src="${meta.logoImageUrl || meta.iconUrl || iconUrl}" height="100"/>
<h1>${meta.name}</h1>
</header> </header>
<article> <article>
<h1>${subject}</h1> <h1>${subject}</h1>