|
3 | 3 | import * as Tabs from '@radix-ui/react-tabs'; |
4 | 4 | import { LayoutGroup } from 'framer-motion'; |
5 | 5 | import { usePathname, useRouter, useSearchParams } from 'next/navigation'; |
| 6 | +import type { ComponentProps } from 'react'; |
6 | 7 | import * as React from 'react'; |
7 | 8 | import type { CompatibilityCheckingResult } from '../actions/email-validation/check-compatibility'; |
8 | 9 | import { isBuilding } from '../app/env'; |
@@ -183,7 +184,7 @@ const ToolbarInner = ({ |
183 | 184 | (activeTab === 'compatibility' && |
184 | 185 | 'The Compatibility tab shows how well the HTML/CSS is supported across mail clients like Outlook, Gmail, etc. Powered by Can I Email.') || |
185 | 186 | (activeTab === 'resend' && |
186 | | - "The Resend tab allows you to upload your React Email's HTML using the Templates API. It does not yet upload with variables.") || |
| 187 | + 'The Resend tab allows you to upload your React Email code using the Resend Templates API.') || |
187 | 188 | 'Info' |
188 | 189 | } |
189 | 190 | > |
@@ -288,9 +289,12 @@ const ToolbarInner = ({ |
288 | 289 | ) : ( |
289 | 290 | <SuccessWrapper> |
290 | 291 | <SuccessTitle>Connect to Resend</SuccessTitle> |
291 | | - <SuccessDescription> |
292 | | - Run <CodeSnippet>email resend setup re_xxxxxx</CodeSnippet>{' '} |
293 | | - to connect your Resend account and refresh. |
| 292 | + <SuccessDescription className="max-w-lg"> |
| 293 | + Run{' '} |
| 294 | + <CodeSnippet> |
| 295 | + npx react-email@latest resend setup |
| 296 | + </CodeSnippet>{' '} |
| 297 | + on your terminal to connect your Resend account. |
294 | 298 | </SuccessDescription> |
295 | 299 | </SuccessWrapper> |
296 | 300 | )} |
@@ -340,15 +344,34 @@ const SuccessIcon = () => { |
340 | 344 | ); |
341 | 345 | }; |
342 | 346 |
|
343 | | -const SuccessTitle = ({ children }) => { |
| 347 | +const SuccessTitle = ({ |
| 348 | + children, |
| 349 | + className, |
| 350 | + ...props |
| 351 | +}: ComponentProps<'h3'>) => { |
344 | 352 | return ( |
345 | | - <h3 className="text-slate-12 font-medium text-base mb-1">{children}</h3> |
| 353 | + <h3 |
| 354 | + className={cn('text-slate-12 font-medium text-base mb-1', className)} |
| 355 | + {...props} |
| 356 | + > |
| 357 | + {children} |
| 358 | + </h3> |
346 | 359 | ); |
347 | 360 | }; |
348 | 361 |
|
349 | | -const SuccessDescription = ({ children }) => { |
| 362 | +const SuccessDescription = ({ |
| 363 | + children, |
| 364 | + className, |
| 365 | + ...props |
| 366 | +}: ComponentProps<'p'>) => { |
350 | 367 | return ( |
351 | | - <p className="text-slate-11 text-sm text-center max-w-[320px]"> |
| 368 | + <p |
| 369 | + className={cn( |
| 370 | + 'text-slate-11 text-sm text-center max-w-[320px]', |
| 371 | + className, |
| 372 | + )} |
| 373 | + {...props} |
| 374 | + > |
352 | 375 | {children} |
353 | 376 | </p> |
354 | 377 | ); |
|
0 commit comments