feat(config, layout, components): enhance security headers, improve SEO, and update project descriptions

- Added security headers in the Next.js configuration to enhance application security.
- Updated metadata in the layout component for improved SEO, including new titles, descriptions, and keywords.
- Introduced JSON-LD schema for projects to enhance search engine visibility.
- Enhanced project descriptions in the portfolio data for clarity and detail.
- Improved header component with logo integration and refined social media links for better accessibility.
This commit is contained in:
Evandro Fonseca Junior committed 2026-01-20 21:00:50 -03:00
1 parent 3f3fca11ab
commit ad6a76efdd
14 files changed
+467 -57

No files matched your search

+57
View File
@@ -24,6 +24,23 @@ const CATEGORY_THEMES: Record<string, any> = {
desktop: { color: "text-emerald-400", bg: "bg-emerald-500/10", border: "border-emerald-500/20", icon: Terminal },
};
// Funções auxiliares para Schema
function getApplicationCategory(category: string): string {
const map: Record<string, string> = {
"full-stack": "WebApplication",
"iot": "DesktopApplication",
"api": "WebApplication",
"web": "WebApplication",
"desktop": "DesktopApplication"
};
return map[category.toLowerCase()] || "WebApplication";
}
function getOperatingSystem(category: string): string {
if (category.toLowerCase() === "desktop") return "Windows, Linux";
return "Web Browser";
}
export default function Projects() {
const { data, loading, error } = usePortfolioData();
@@ -31,6 +48,38 @@ export default function Projects() {
data?.projects.filter((p) => p.featured) || [],
[data]);
const projectsJsonLd = useMemo(() => {
if (!projects || projects.length === 0) return null;
return {
"@context": "https://schema.org",
"@type": "ItemList",
"itemListElement": projects.map((project, index) => ({
"@type": "ListItem",
"position": index + 1,
"item": {
"@type": "SoftwareApplication",
"name": project.title,
"description": project.description,
"applicationCategory": getApplicationCategory(project.category),
"operatingSystem": getOperatingSystem(project.category),
"url": project.demoUrl || project.githubUrl || `https://evandro.dev.br/#projects`,
"offers": {
"@type": "Offer",
"price": "0",
"priceCurrency": "BRL"
},
"softwareVersion": "1.0.0",
"author": {
"@type": "Person",
"name": "Evandro Fonseca Junior",
"url": "https://evandro.dev.br"
}
}
}))
};
}, [projects]);
if (loading) return <div className="py-20 text-center animate-pulse text-slate-500 font-mono">Loading_Assets...</div>;
if (error) return <div className="py-20 text-center text-red-500">System_Error: Failed to sync projects.</div>;
@@ -118,6 +167,14 @@ export default function Projects() {
);
})}
</BentoGrid>
{/* JSON-LD Schema for Projects */}
{projectsJsonLd && (
<script
type="application/ld+json"
dangerouslySetInnerHTML={{ __html: JSON.stringify(projectsJsonLd) }}
/>
)}
</div>
</section>
);