import { Section, GlobalStyles, DEFAULT_GLOBAL_STYLES, createSection, createRow, createBlock, } from '../types' // Preset themes export interface ThemePreset { id: string name: string description: string globalStyles: GlobalStyles sectionDefaults: { backgroundColor?: string paddingTop?: number paddingBottom?: number } } export const THEME_PRESETS: ThemePreset[] = [ { id: 'clean', name: 'Clean', description: 'White background with subtle gray accents', globalStyles: { ...DEFAULT_GLOBAL_STYLES, backgroundColor: '#f3f4f6', theme: 'clean', }, sectionDefaults: { paddingTop: 16, paddingBottom: 16, }, }, { id: 'minimal', name: 'Minimal', description: 'Pure white with thin borders', globalStyles: { ...DEFAULT_GLOBAL_STYLES, backgroundColor: '#ffffff', theme: 'minimal', }, sectionDefaults: { paddingTop: 12, paddingBottom: 12, }, }, { id: 'bold', name: 'Bold', description: 'Dark background with vivid accents', globalStyles: { ...DEFAULT_GLOBAL_STYLES, backgroundColor: '#1f2937', theme: 'bold', }, sectionDefaults: { backgroundColor: '#111827', paddingTop: 20, paddingBottom: 20, }, }, ] // Starter template: basic investor update export function createInvestorUpdateTemplate(): Section[] { const headerBlock = createBlock('header') const introText = createBlock('text') if (introText.type === 'text') { introText.content = '

Hi {{investor.firstName}},

Here is our latest update for {{date.quarter}}.

' } const metricsBlock = createBlock('metrics') const bodyText = createBlock('text') if (bodyText.type === 'text') { bodyText.content = '

Highlights

' } const ctaBlock = createBlock('cta') const divider = createBlock('divider') const footerBlock = createBlock('footer') const headerSection = createSection() headerSection.rows = [createRow('1')] headerSection.rows[0].columns[0] = [headerBlock] const introSection = createSection() introSection.rows = [createRow('1')] introSection.rows[0].columns[0] = [introText] const metricsSection = createSection() metricsSection.rows = [createRow('1')] metricsSection.rows[0].columns[0] = [metricsBlock] const bodySection = createSection() bodySection.rows = [createRow('1')] bodySection.rows[0].columns[0] = [bodyText] const ctaSection = createSection() ctaSection.rows = [createRow('1')] ctaSection.rows[0].columns[0] = [ctaBlock] const footerSection = createSection() footerSection.rows = [createRow('1'), createRow('1')] footerSection.rows[0].columns[0] = [divider] footerSection.rows[1].columns[0] = [footerBlock] return [headerSection, introSection, metricsSection, bodySection, ctaSection, footerSection] } // Empty starter export function createEmptyTemplate(): Section[] { return [createSection()] }