+ {report.projectOverview && (
+
+
+ {report.projectOverview}
+
+
+ )}
+
+ {report.techStack && report.techStack.length > 0 && (
+
+
+ {report.techStack.map((t, i) => (
+
+ {t}
+
+ ))}
+
+
+ )}
+
+ {report.folderStructure && report.folderStructure.length > 0 && (
+
+
+ {report.folderStructure.map((f, i) => (
+ -
+
{f.path}
+ {f.description}
+
+ ))}
+
+
+ )}
+
+ {report.keyFiles && report.keyFiles.length > 0 && (
+
+
+ {report.keyFiles.map((f, i) => (
+ -
+
{f.file}
+ {f.whyImportant}
+
+ ))}
+
+
+ )}
+
+ {report.setupSteps && report.setupSteps.length > 0 && (
+
+
+ {report.setupSteps.map((s, i) => (
+ -
+ {s}
+
+ ))}
+
+
+ )}
+
+ {report.architectureNotes && (
+
+ {report.architectureNotes}
+
+ )}
+
+ {report.quiz && report.quiz.length > 0 && (
+
+
+ {report.quiz.map((q, i) => (
+
+ {q.question}
+
+ {q.answer}
+
+
+ ))}
+
+
+ )}
+
+ );
+}
+
+export function parseOnboardingReport(raw: unknown): OnboardingReport | null {
+ let value: unknown = raw;
+ if (typeof value === "string") {
+ try {
+ value = JSON.parse(value);
+ } catch {
+ return null;
+ }
+ }
+ if (!value || typeof value !== "object") return null;
+ const v = value as Record