108 lines
2.6 KiB
TypeScript
108 lines
2.6 KiB
TypeScript
import { siteConfig } from "@/config/site";
|
|
import { getBaseUrl } from "@/lib/utils";
|
|
import {
|
|
Body,
|
|
Button,
|
|
Container,
|
|
Head,
|
|
Hr,
|
|
Html,
|
|
Img,
|
|
Link,
|
|
Preview,
|
|
Section,
|
|
Text,
|
|
} from "@react-email/components";
|
|
import {
|
|
anchor,
|
|
box,
|
|
button,
|
|
container,
|
|
footer,
|
|
footerLeft,
|
|
footerRight,
|
|
hr,
|
|
main,
|
|
paragraph,
|
|
} from "./email-formats";
|
|
|
|
interface RejectionEmailProps {
|
|
userName?: string;
|
|
dashboardLink?: string;
|
|
}
|
|
|
|
/**
|
|
* https://demo.react.email/preview/welcome/stripe-welcome
|
|
*/
|
|
export const RejectionEmail = ({
|
|
userName,
|
|
dashboardLink,
|
|
}: RejectionEmailProps) => {
|
|
const baseUrl = getBaseUrl();
|
|
return (
|
|
<Html>
|
|
<Head />
|
|
<Preview>Your submission has been rejected</Preview>
|
|
<Body style={main}>
|
|
<Container style={container}>
|
|
<Section style={box}>
|
|
<Img
|
|
src={`${baseUrl}/logo.png`}
|
|
width="32"
|
|
height="32"
|
|
alt="Logo"
|
|
/>
|
|
<Hr style={hr} />
|
|
<Text style={paragraph}>Hi {userName},</Text>
|
|
<Text style={paragraph}>
|
|
Thanks for submitting your product to{" "}
|
|
<Link style={anchor} href={baseUrl}>
|
|
{siteConfig.name}
|
|
</Link>
|
|
. We're sorry to inform you that your product has been rejected.
|
|
</Text>
|
|
<Text style={paragraph}>
|
|
Please check your submission and make the necessary changes.
|
|
</Text>
|
|
<Button style={button} href={dashboardLink}>
|
|
View in dashboard
|
|
</Button>
|
|
<Hr style={hr} />
|
|
<Text style={paragraph}>
|
|
Thanks, <br />
|
|
The{" "}
|
|
<Link style={anchor} href={baseUrl}>
|
|
{siteConfig.name}
|
|
</Link>{" "}
|
|
team
|
|
</Text>
|
|
<Hr style={hr} />
|
|
<Text style={footer}>
|
|
<span style={footerLeft}>
|
|
© {new Date().getFullYear()}
|
|
All Rights Reserved.
|
|
</span>
|
|
<span style={footerRight}>
|
|
<Link style={anchor} href={siteConfig.links.twitter}>
|
|
Twitter
|
|
</Link>
|
|
|
|
<Link style={anchor} href={siteConfig.links.github}>
|
|
GitHub
|
|
</Link>
|
|
</span>
|
|
</Text>
|
|
</Section>
|
|
</Container>
|
|
</Body>
|
|
</Html>
|
|
);
|
|
};
|
|
|
|
RejectionEmail.PreviewProps = {
|
|
userName: "Javayhu",
|
|
itemLink: "https://demo.mkdirs.com",
|
|
} as RejectionEmailProps;
|
|
|
|
export default RejectionEmail;
|