Skip to content

Job application tracker and AI-powered job search assistant. Helps job seekers manage their search journey with AI resume review, job matching, task logging, and application analytics, all while keeping your data private.

check resume content sections before exporting

Khuram Niaz09554941bf51
diff --git a/src/components/profile/ResumeContainer.tsx b/src/components/profile/ResumeContainer.tsx
index 794f7de..48d086c 100644
--- a/src/components/profile/ResumeContainer.tsx
+++ b/src/components/profile/ResumeContainer.tsx
@@ -74,6 +74,26 @@ function ResumeContainer({ resume }: { resume: Resume }) {
};
const handleExportPdf = async () => {
+ const hasName =
+ resume.ContactInfo?.firstName?.trim() ||
+ resume.ContactInfo?.lastName?.trim();
+ const hasSections = resume.ResumeSections?.some(
+ (s) =>
+ s.summary?.content ||
+ s.workExperiences?.length ||
+ s.educations?.length ||
+ s.licenseOrCertifications?.length,
+ );
+ if (!hasName && !hasSections) {
+ toast({
+ title: "Nothing to export",
+ description:
+ "Add your contact info and at least one section (Summary, Experience, or Education) before exporting.",
+ variant: "destructive",
+ });
+ return;
+ }
+
setIsExporting(true);
try {
const { generateResumePdfBlob } = await import("./resume-pdf");