// @ts-nocheck
/**
 * Creates a typed email component with required metadata.
 *
 * @example
 * ```tsx
 * export const WelcomeEmail = defineEmail(
 *   function WelcomeEmail({ name }: { name: string }) {
 *     return <EmailLayout subject="Welcome!">Hello {name}</EmailLayout>;
 *   },
 *   { subject: 'Welcome!', PreviewProps: { name: 'John Doe' } },
 * );
 * ```
 */
export function defineEmail(component, options) {
    const emailComponent = component;
    emailComponent.subject = options.subject;
    emailComponent.displayName = options.name ?? component.name;
    emailComponent.PreviewProps = options.previewProps;
    return emailComponent;
}
//# sourceMappingURL=email-component.types.js.map