import { extractPerSpecData } from './spec-data-extractor.js';
import { buildSpecHeaderSection, buildSpecMetricsSection, buildSpecDependenciesSection, buildSpecTagsSection, buildEffortDistributionSvg, buildSpecFooterSection, } from './spec-section-builders.js';
import { wrapPerSpecHtml } from './html-wrapper.js';
/**
 * Generate a self-contained HTML executive report for a single spec.
 * Includes: header, metrics, dependencies, effort distribution SVG, tags.
 */
export function generatePerSpecExecutiveReport(spec, affectedFiles, architecturalDecisions) {
    const data = extractPerSpecData(spec, affectedFiles, architecturalDecisions);
    const body = [
        buildSpecHeaderSection(data),
        buildSpecMetricsSection(data),
        buildEffortDistributionSvg(data.devHours, data.reviewHours),
        buildSpecDependenciesSection(data),
        buildSpecTagsSection(data),
        buildSpecFooterSection(),
    ]
        .filter(Boolean)
        .join('\n');
    const title = `Executive Report — ${data.specId}: ${data.title}`;
    const content = wrapPerSpecHtml(title, body);
    return {
        type: 'per-spec-executive',
        title,
        path: `executive-report.html`,
        content,
        audience: 'stakeholder',
        sections: [],
        diagrams: [],
        relatedSpecs: [data.specId],
    };
}
//# sourceMappingURL=executive-report.js.map