import { useState } from 'react' import { LayoutShell } from './components/LayoutShell' import { ConfigForm } from './components/ConfigForm' import { PreviewFrame } from './components/PreviewFrame' import { EmailSender } from './components/EmailSender' import type { CompanyConfig, InvitationInfo, InvoiceInfo, PaymentInfo, ReportConfig, PasswordResetInfo, TemplateId, } from './lib/types' const navItems: { id: TemplateId; label: string }[] = [ { id: 'invitation', label: 'Invitation' }, { id: 'proforma', label: 'Proforma invoice' }, { id: 'paymentRequest', label: 'Payment request' }, { id: 'vatSummary', label: 'VAT summary' }, { id: 'vatDetailed', label: 'VAT detailed' }, { id: 'withholdingSummary', label: 'Withholding summary' }, { id: 'withholdingDetailed', label: 'Withholding detailed' }, { id: 'newsletter', label: 'Newsletter' }, { id: 'passwordReset', label: 'Password reset' }, ] function App() { const [activeTemplate, setActiveTemplate] = useState('invitation') const [company, setCompany] = useState({ name: 'Yaltopia Ticket', primaryColor: '#f97316', logoUrl: '', paymentLink: '', bankDetails: { bankName: 'Example Bank', accountName: 'Yaltopia Ticket Ltd', accountNumber: '123456789', }, }) const [invitation, setInvitation] = useState({ eventName: 'Yaltopia Product Launch', dateTime: '24 March 2026, 15:00', location: 'Online webinar', ctaLabel: 'Reserve my seat', ctaUrl: 'https://example.com/rsvp', }) const [payment, setPayment] = useState({ amount: 150, currency: 'USD', description: 'Yaltopia Ticket subscription', dueDate: '31 March 2026', }) const [invoice, setInvoice] = useState({ invoiceNumber: 'INV-2026-001', issueDate: '11 March 2026', dueDate: '31 March 2026', currency: 'USD', items: [ { description: 'Yaltopia Ticket Pro (12 months)', quantity: 1, unitPrice: 150 }, { description: 'Onboarding & configuration', quantity: 1, unitPrice: 0 }, ], }) const [vatReport, setVatReport] = useState({ periodLabel: 'Q1 2026', totalAmount: 12000, taxAmount: 1800, currency: 'USD', }) const [withholdingReport, setWithholdingReport] = useState({ periodLabel: 'Q1 2026', totalAmount: 8000, taxAmount: 800, currency: 'USD', }) const [passwordReset, setPasswordReset] = useState({ resetLink: 'https://example.com/reset?token=demo', recipientName: 'Customer', }) return ( setActiveTemplate(id)} leftPanel={
} rightPanel={ } /> ) } export default App