@@ -9,8 +9,10 @@ import {
99 Link ,
1010 Preview ,
1111 Section ,
12+ Tailwind ,
1213 Text ,
1314} from '@react-email/components' ;
15+ import tailwindConfig from '../tailwind.config' ;
1416
1517interface RaycastMagicLinkEmailProps {
1618 magicLink ?: string ;
@@ -25,47 +27,52 @@ export const RaycastMagicLinkEmail = ({
2527} : RaycastMagicLinkEmailProps ) => (
2628 < Html >
2729 < Head />
28- < Body style = { main } >
29- < Preview > Log in with this magic link.</ Preview >
30- < Container style = { container } >
31- < Img
32- src = { `${ baseUrl } /static/raycast-logo.png` }
33- width = { 48 }
34- height = { 48 }
35- alt = "Raycast"
36- />
37- < Heading style = { heading } > 🪄 Your magic link</ Heading >
38- < Section style = { body } >
39- < Text style = { paragraph } >
40- < Link style = { link } href = { magicLink } >
41- 👉 Click here to sign in 👈
42- </ Link >
30+ < Tailwind config = { tailwindConfig } >
31+ < Body className = "bg-white font-raycast" >
32+ < Preview > Log in with this magic link.</ Preview >
33+ < Container className = "mx-auto my-0 pt-5 px-6 pb-12 bg-[url('/static/raycast-bg.png')] [background-position:bottom] [background-repeat:no-repeat]" >
34+ < Img
35+ src = { `${ baseUrl } /static/raycast-logo.png` }
36+ width = { 48 }
37+ height = { 48 }
38+ alt = "Raycast"
39+ />
40+ < Heading className = "text-[28px] font-bold mt-12" >
41+ 🪄 Your magic link
42+ </ Heading >
43+ < Section className = "my-6 mx-0" >
44+ < Text className = "text-base leading-6.5" >
45+ < Link className = "text-[#FF6363]" href = { magicLink } >
46+ 👉 Click here to sign in 👈
47+ </ Link >
48+ </ Text >
49+ < Text className = "text-base leading-6.5" >
50+ If you didn't request this, please ignore this email.
51+ </ Text >
52+ </ Section >
53+ < Text className = "text-base leading-6.5" >
54+ Best,
55+ < br /> - Raycast Team
4356 </ Text >
44- < Text style = { paragraph } >
45- If you didn't request this, please ignore this email.
57+ < Hr className = "border-[#dddddd] mt-12" />
58+ < Img
59+ src = { `${ baseUrl } /static/raycast-logo.png` }
60+ width = { 32 }
61+ height = { 32 }
62+ style = { {
63+ WebkitFilter : 'grayscale(100%)' ,
64+ } }
65+ className = "[filter:grayscale(100%)] my-5 mx-0"
66+ />
67+ < Text className = "text-[#8898aa] text-xs leading-6 ml-1" >
68+ Raycast Technologies Inc.
4669 </ Text >
47- </ Section >
48- < Text style = { paragraph } >
49- Best,
50- < br /> - Raycast Team
51- </ Text >
52- < Hr style = { hr } />
53- < Img
54- src = { `${ baseUrl } /static/raycast-logo.png` }
55- width = { 32 }
56- height = { 32 }
57- style = { {
58- WebkitFilter : 'grayscale(100%)' ,
59- filter : 'grayscale(100%)' ,
60- margin : '20px 0' ,
61- } }
62- />
63- < Text style = { footer } > Raycast Technologies Inc.</ Text >
64- < Text style = { footer } >
65- 2093 Philadelphia Pike #3222, Claymont, DE 19703
66- </ Text >
67- </ Container >
68- </ Body >
70+ < Text className = "text-[#8898aa] text-xs leading-6 ml-1" >
71+ 2093 Philadelphia Pike #3222, Claymont, DE 19703
72+ </ Text >
73+ </ Container >
74+ </ Body >
75+ </ Tailwind >
6976 </ Html >
7077) ;
7178
@@ -74,47 +81,3 @@ RaycastMagicLinkEmail.PreviewProps = {
7481} as RaycastMagicLinkEmailProps ;
7582
7683export default RaycastMagicLinkEmail ;
77-
78- const main = {
79- backgroundColor : '#ffffff' ,
80- fontFamily :
81- '-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif' ,
82- } ;
83-
84- const container = {
85- margin : '0 auto' ,
86- padding : '20px 25px 48px' ,
87- backgroundImage : 'url("/static/raycast-bg.png")' ,
88- backgroundPosition : 'bottom' ,
89- backgroundRepeat : 'no-repeat, no-repeat' ,
90- } ;
91-
92- const heading = {
93- fontSize : '28px' ,
94- fontWeight : 'bold' ,
95- marginTop : '48px' ,
96- } ;
97-
98- const body = {
99- margin : '24px 0' ,
100- } ;
101-
102- const paragraph = {
103- fontSize : '16px' ,
104- lineHeight : '26px' ,
105- } ;
106-
107- const link = {
108- color : '#FF6363' ,
109- } ;
110-
111- const hr = {
112- borderColor : '#dddddd' ,
113- marginTop : '48px' ,
114- } ;
115-
116- const footer = {
117- color : '#8898aa' ,
118- fontSize : '12px' ,
119- marginLeft : '4px' ,
120- } ;
0 commit comments