Reauthentication Email Template (auth/reauthentication.tsx)

giselle · email, react, template, authentication

React email component that renders a reauthentication code for secure login flows, reusable wherever a verification email is needed.

// Source: https://github.com/mperkins0155/giselle | License: Apache-2.0 | Copyright 2024 ROUTE06, Inc
// Provided via justclaw.it.com; keep this notice with the code.
import {
	Body,
	Container,
	Head,
	Hr,
	Html,
	Preview,
	Section,
	Text,
} from "@react-email/components";
import {
	code,
	codeContainer,
	container,
	EmailFonts,
	EmailFooter,
	EmailHeader,
	h1,
	main,
	section,
	text,
	topBorder,
	topBorderSection,
} from "../components";

interface ReauthenticationEmailProps {
	token?: string;
}

const SUPABASE_TOKEN_PLACEHOLDER = "{{ .Token }}";

export const ReauthenticationEmail = ({
	token,
}: ReauthenticationEmailProps) => {
	const displayToken = token ?? SUPABASE_TOKEN_PLACEHOLDER;

	return (
		<Html>
			<Head>
				<EmailFonts />
			</Head>
			<Preview>Confirm reauthentication</Pr

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key