-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a77d0e4
commit 951eef2
Showing
21 changed files
with
2,669 additions
and
243 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,3 +34,6 @@ yarn-error.log* | |
# typescript | ||
*.tsbuildinfo | ||
next-env.d.ts | ||
|
||
# react-email | ||
.react-email |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
import * as React from "react"; | ||
|
||
export const main: React.CSSProperties = { | ||
backgroundColor: "#ffffff", | ||
fontFamily: | ||
'-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif', | ||
}; | ||
|
||
export const container: React.CSSProperties = { | ||
margin: "0 auto", | ||
padding: "20px 12px 48px", | ||
maxWidth: "600px", | ||
}; | ||
|
||
export const h1: React.CSSProperties = { | ||
color: "#09090B", | ||
fontSize: "24px", | ||
fontWeight: "bold", | ||
margin: "40px 0 16px", | ||
padding: "0", | ||
}; | ||
|
||
export const buttonContainer: React.CSSProperties = { | ||
textAlign: "center", | ||
}; | ||
|
||
export const button: React.CSSProperties = { | ||
backgroundColor: "#18181B", | ||
color: "#FAFAFA", | ||
fontWeight: 500, | ||
fontSize: "14px", | ||
padding: "10.5px 18px", | ||
borderRadius: "8px", | ||
width: "fit-content", | ||
textDecoration: "none", | ||
textAlign: "center", | ||
display: "block", | ||
}; | ||
|
||
export const code: React.CSSProperties = { | ||
display: "inline-block", | ||
padding: "16px 4.5%", | ||
width: "90.5%", | ||
backgroundColor: "#F4F4F5", | ||
borderRadius: "5px", | ||
border: "1px solid #eee", | ||
color: "#09090B", | ||
}; | ||
|
||
export const link: React.CSSProperties = { | ||
color: "#2754C5", | ||
fontSize: "14px", | ||
textDecoration: "underline", | ||
}; | ||
|
||
export const text: React.CSSProperties = { | ||
color: "#09090B", | ||
fontSize: "14px", | ||
margin: "16px 0", | ||
}; | ||
|
||
export const hr: React.CSSProperties = { | ||
borderColor: "#dfe1e4", | ||
margin: "24px 0", | ||
}; | ||
|
||
export const footer: React.CSSProperties = { | ||
color: "#898989", | ||
fontSize: "12px", | ||
lineHeight: "22px", | ||
marginTop: "12px", | ||
marginBottom: "24px", | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import { | ||
Body, | ||
Button, | ||
Container, | ||
Head, | ||
Heading, | ||
Hr, | ||
Html, | ||
Link, | ||
Preview, | ||
Section, | ||
Text, | ||
} from "@react-email/components"; | ||
import * as React from "react"; | ||
import * as styles from "./_components/styles"; | ||
import { EmailOtpType } from "@supabase/supabase-js"; | ||
|
||
const redirectTo = `/login`; | ||
const type: EmailOtpType = "signup"; | ||
const confirmationURL = `{{ .SiteURL }}/auth/confirm?token_hash={{ .TokenHash }}&type=${type}&next=${redirectTo}`; | ||
|
||
export default function Email() { | ||
return ( | ||
<Html> | ||
<Head /> | ||
<Preview>Configm your signup</Preview> | ||
<Body style={styles.main}> | ||
<Container style={styles.container}> | ||
<Heading style={styles.h1}>Confirm your signup</Heading> | ||
<Text style={styles.text}> | ||
Almost there! Click below to confirm your signup: | ||
</Text> | ||
<Section style={styles.buttonContainer}> | ||
<Button style={styles.button} href={confirmationURL}> | ||
Click here to confirm | ||
</Button> | ||
</Section> | ||
<Text | ||
style={{ | ||
...styles.text, | ||
color: "#71717A", | ||
}} | ||
> | ||
If you didn't try to create an account, you can safely ignore | ||
this email. | ||
</Text> | ||
<Hr style={styles.hr} /> | ||
<Text style={styles.footer}> | ||
<Link | ||
href="https://supabase-modules-docs.vercel.app" | ||
target="_blank" | ||
style={{ ...styles.link, color: "#71717A" }} | ||
> | ||
Supabase Modules | ||
</Link> | ||
<br /> | ||
Build smarter with pre-built modules today | ||
</Text> | ||
</Container> | ||
</Body> | ||
</Html> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
import { | ||
Body, | ||
Button, | ||
Container, | ||
Head, | ||
Heading, | ||
Hr, | ||
Html, | ||
Link, | ||
Preview, | ||
Section, | ||
Text, | ||
} from "@react-email/components"; | ||
import * as React from "react"; | ||
import * as styles from "./_components/styles"; | ||
import { EmailOtpType } from "@supabase/supabase-js"; | ||
|
||
const redirectTo = `/login`; | ||
const type: EmailOtpType = "email_change"; | ||
|
||
const confirmationURL = `{{ .SiteURL }}/auth/confirm?token_hash={{ .TokenHash }}&type=${type}&next=${redirectTo}`; | ||
|
||
export default function Email() { | ||
return ( | ||
<Html> | ||
<Head /> | ||
<Preview>Configm email change</Preview> | ||
<Body style={styles.main}> | ||
<Container style={styles.container}> | ||
<Heading style={styles.h1}>Confirm email change</Heading> | ||
<Text | ||
style={styles.text} | ||
>{`Click below to confirm the update of your email from {{ .Email }} to {{ .NewEmail }}:`}</Text> | ||
<Section style={styles.buttonContainer}> | ||
<Button style={styles.button} href={confirmationURL}> | ||
Click here to confirm | ||
</Button> | ||
</Section> | ||
<Text | ||
style={{ | ||
...styles.text, | ||
color: "#71717A", | ||
}} | ||
> | ||
If you didn't request an email change, you can safely ignore | ||
this email. | ||
</Text> | ||
<Hr style={styles.hr} /> | ||
<Text style={styles.footer}> | ||
<Link | ||
href="https://supabase-modules-docs.vercel.app" | ||
target="_blank" | ||
style={{ ...styles.link, color: "#71717A" }} | ||
> | ||
Supabase Modules | ||
</Link> | ||
<br /> | ||
Build smarter with pre-built modules today | ||
</Text> | ||
</Container> | ||
</Body> | ||
</Html> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import { | ||
Body, | ||
Container, | ||
Head, | ||
Heading, | ||
Hr, | ||
Html, | ||
Link, | ||
Preview, | ||
Text, | ||
} from "@react-email/components"; | ||
import * as React from "react"; | ||
import * as styles from "./_components/styles"; | ||
|
||
export default function Email() { | ||
return ( | ||
<Html> | ||
<Head /> | ||
<Preview>Your One-Time password</Preview> | ||
<Body style={styles.main}> | ||
<Container style={styles.container}> | ||
<Heading style={styles.h1}>Your One-Time password</Heading> | ||
<Text style={styles.text}>Copy and paste this temporary code:</Text> | ||
<code style={styles.code}>{`{{ .Token }}`}</code> | ||
<Text | ||
style={{ | ||
...styles.text, | ||
color: "#71717A", | ||
}} | ||
> | ||
If you didn't try to log in, you can safely ignore this email. | ||
</Text> | ||
<Hr style={styles.hr} /> | ||
<Text style={styles.footer}> | ||
<Link | ||
href="https://supabase-modules-docs.vercel.app" | ||
target="_blank" | ||
style={{ ...styles.link, color: "#71717A" }} | ||
> | ||
Supabase Modules | ||
</Link> | ||
<br /> | ||
Build smarter with pre-built modules today | ||
</Text> | ||
</Container> | ||
</Body> | ||
</Html> | ||
); | ||
} |
Oops, something went wrong.