import type { ReactNode } from 'react' import { Html, Head, Body, Container, Section, Text, Heading, Hr, Img, Preview, Link, } from '@react-email/components' import type { Brand } from './types' type EmailShellProps = { brand: Brand title: string previewText: string children: ReactNode } const DEFAULT_LOGO_PLACEHOLDER = 'https://dummyimage.com/120x40/0f172a/ffffff&text=Shitaye' export function EmailShell({ brand, title, previewText, children }: EmailShellProps) { const logoUrl = brand.logoUrl?.trim() ? brand.logoUrl.trim() : DEFAULT_LOGO_PLACEHOLDER return ( {previewText}
{brand.hotelName} {brand.hotelName} {title}
{children}

{brand.footer.address ? `${brand.footer.address} ` : ''} {brand.footer.email ? `\u2709 ${brand.footer.email}` : ''} {brand.footer.phone1 ? `\u260E ${brand.footer.phone1}` : ''} {brand.footer.phone1 && brand.footer.phone2 ? ' · ' : ''} {brand.footer.phone2 ? brand.footer.phone2 : ''}
Follow us
© {new Date().getFullYear()} {brand.hotelName}. All rights reserved.
) }