Dithered sign-in email

The sign-in email this site sends: a dithered blue header, one button and a short note.

Logoipsum

Sign in to Logoipsum

Use the button below to sign in. It works once and expires in 15 minutes.

Sign in to Logoipsum

If you did not ask for this, you can ignore this email.

Logoipsum · 100 Example Street, Springfield

Options

Screen

Code

import { Body, Button, Container, Head, Heading, Html, Img, Preview, Section, Text } from "@react-email/components";

const font = "-apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif";
const images = "https://designs.here/emails";

export function DitherSignInEmail({ link = "https://example.com/sign-in?token=abc123", minutes = 15 }) {
  return (
    <Html lang="en">
      <Head />
      <Preview>{"Your sign-in link. It expires in " + minutes + " minutes."}</Preview>
      <Body style={{ margin: 0, padding: "32px 16px", background: "#ffffff", fontFamily: font }}>
        <Container style={{ width: "100%", maxWidth: 400, border: "1px solid #e3e3e0", borderRadius: 10, overflow: "hidden", background: "#ffffff" }}>
          <Section style={{ height: 96, background: "#1647d6 url(" + images + "/dither-header.png) center top / 100% 96px no-repeat" }}>
            <Img src={images + "/logo-white.png"} width={114} height={20} alt="Logoipsum" style={{ display: "block", margin: "20px 24px 56px" }} />
          </Section>
          <Section style={{ padding: "12px 24px 24px" }}>
            <Heading style={{ margin: "0 0 4px", fontSize: 16, lineHeight: "24px", fontWeight: 500, letterSpacing: "-0.02em", color: "#171717" }}>
              Sign in to Logoipsum
            </Heading>
            <Text style={{ margin: "0 0 20px", fontSize: 13, lineHeight: "20px", color: "#5c5c5c" }}>
              Use the button below to sign in. It works once and expires in {minutes} minutes.
            </Text>
            <Button href={link} style={{ padding: "7px 14px", border: "1px solid #1647d6", borderRadius: 7, background: "#2563ff", color: "#ffffff", fontSize: 13, lineHeight: "18px", fontWeight: 500, letterSpacing: "-0.01em", textDecoration: "none" }}>
              Sign in to Logoipsum
            </Button>
            <Text style={{ margin: "20px 0 0", paddingTop: 16, borderTop: "1px solid #e3e3e0", fontSize: 12, lineHeight: "18px", color: "#8a8a8a" }}>
              If you did not ask for this, you can ignore this email.
            </Text>
          </Section>
        </Container>
        <Text style={{ margin: "16px 0 0", fontSize: 11, lineHeight: "16px", color: "#8a8a8a", textAlign: "center", fontFamily: "ui-monospace, SFMono-Regular, Menlo, monospace" }}>
          Logoipsum · 100 Example Street, Springfield
        </Text>
      </Body>
    </Html>
  );
}

export default DitherSignInEmail;
Logoipsum

Sign in to Logoipsum

Use the button below to sign in. It works once and expires in 15 minutes.

Sign in to Logoipsum

If you did not ask for this, you can ignore this email.

Logoipsum · 100 Example Street, Springfield