diff --git a/resources/js/components/certificate-generator.tsx b/resources/js/components/certificate-generator.tsx index b14ba79e..2bbd99e4 100644 --- a/resources/js/components/certificate-generator.tsx +++ b/resources/js/components/certificate-generator.tsx @@ -20,7 +20,7 @@ const CertificateGenerator = () => { const handleGenerateCertificate = async () => { if (!studentName || !courseName || !completionDate) { - toast.error('Please fill in all required fields.'); + toast.error('Bitte fülle alle Pflichtfelder aus.'); return; } @@ -28,8 +28,8 @@ const CertificateGenerator = () => { // Simulate certificate generation setTimeout(() => { - setIsGenerating(false); - toast.success('Your course completion certificate has been created successfully.'); + setIsGenerating(false); + toast.success('Dein Kursabschlusszertifikat wurde erfolgreich erstellt.'); }, 2000); }; @@ -73,7 +73,7 @@ const CertificateGenerator = () => { document.body.removeChild(a); URL.revokeObjectURL(url); - toast.success('Your PNG certificate has been saved to your downloads folder.'); + toast.success('Dein PNG-Zertifikat wurde in deinem Download-Ordner gespeichert.'); }, 'image/png'); }; @@ -107,7 +107,7 @@ const CertificateGenerator = () => { // Save the PDF pdf.save(`${studentName}_${courseName}_Certificate.pdf`); - toast.success('Your PDF certificate has been saved to your downloads folder.'); + toast.success('Dein PDF-Zertifikat wurde in deinem Download-Ordner gespeichert.'); }; const drawCertificate = (ctx: CanvasRenderingContext2D, dimensions: { width: number; height: number }) => { @@ -135,7 +135,7 @@ const CertificateGenerator = () => { // Title ctx.font = 'bold 42px serif'; - ctx.fillText('Certificate of Completion', dimensions.width / 2, 120); + ctx.fillText('Abschlusszertifikat', dimensions.width / 2, 120); // Decorative line under title ctx.strokeStyle = '#f59e0b'; @@ -148,7 +148,7 @@ const CertificateGenerator = () => { // "This is to certify that" ctx.font = '22px serif'; ctx.fillStyle = '#4b5563'; - ctx.fillText('This is to certify that', dimensions.width / 2, 190); + ctx.fillText('Hiermit wird bescheinigt, dass', dimensions.width / 2, 190); // Student name with underline ctx.font = 'bold 36px serif'; @@ -167,7 +167,7 @@ const CertificateGenerator = () => { // "has successfully completed the course" ctx.font = '22px serif'; ctx.fillStyle = '#4b5563'; - ctx.fillText('has successfully completed the course', dimensions.width / 2, 320); + ctx.fillText('den Kurs erfolgreich abgeschlossen hat', dimensions.width / 2, 320); // Course name ctx.font = 'bold 28px serif'; @@ -177,7 +177,7 @@ const CertificateGenerator = () => { // Completion date ctx.font = '18px serif'; ctx.fillStyle = '#6b7280'; - ctx.fillText(`Completed on: ${completionDate}`, dimensions.width / 2, 430); + ctx.fillText(`Abgeschlossen am: ${completionDate}`, dimensions.width / 2, 430); // Footer ctx.font = '16px serif'; @@ -190,9 +190,9 @@ const CertificateGenerator = () => { return (
Generate your official course completion certificate
-Erstelle dein offizielles Kursabschlusszertifikat
+This is to certify that
+Hiermit wird bescheinigt, dass
{studentName || 'Student Name'}
has successfully completed the course
-{courseName || 'Course Name'}
+den Kurs erfolgreich abgeschlossen hat
+{courseName || 'Kursname'}
Completed on: {completionDate || 'Date'}
+Abgeschlossen am: {completionDate || 'Datum'}
Authorized Certificate of Achievement
+Autorisierte Leistungsurkunde