From 58e45bb47cb569b8741f31db9722aa21bf3fb399 Mon Sep 17 00:00:00 2001 From: "dong.nguyen" Date: Sun, 18 Oct 2026 23:45:26 +0700 Subject: [PATCH] fix(contact): drive social handles and project titles from data Contact cards spelled out the handle in JSX while profile data already carried the URLs. profile.ts now holds githubHandle and linkedinHandle, and both the homepage section and the Contact page read them. Project titles were rendered straight from data, bypassing the language resolver, so English mode showed Vietnamese titles. Drops the githubUrl placeholder and the unused githubUrl/demoUrl pair from the Project type. --- src/components/sections/Contact.tsx | 4 ++-- src/data/profile.ts | 2 ++ src/data/projects.ts | 3 +-- src/pages/ContactPage.tsx | 4 ++-- src/types/index.ts | 5 ++--- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/components/sections/Contact.tsx b/src/components/sections/Contact.tsx index c3ce2fe..8e7de9c 100644 --- a/src/components/sections/Contact.tsx +++ b/src/components/sections/Contact.tsx @@ -79,7 +79,7 @@ export function Contact() { {strings.contact.github[lang]}
- @yourusername + @{profile.githubHandle}
@@ -108,7 +108,7 @@ export function Contact() { {strings.contact.linkedin[lang]}
- Your Name + @{profile.linkedinHandle}
diff --git a/src/data/profile.ts b/src/data/profile.ts index b6ee353..56d71dc 100644 --- a/src/data/profile.ts +++ b/src/data/profile.ts @@ -16,6 +16,8 @@ export const profile: Profile = { email: "nguyendong_bkdn@yahoo.com", githubUrl: "https://github.com/dong-nz", linkedinUrl: "https://www.linkedin.com/in/dong-nz", + githubHandle: "dong-nz", + linkedinHandle: "dong-nz", currentInterests: [ "AI in logistics", "Digital twins", diff --git a/src/data/projects.ts b/src/data/projects.ts index b514f6b..695e6bc 100644 --- a/src/data/projects.ts +++ b/src/data/projects.ts @@ -3,7 +3,7 @@ import type { ProjectDetail } from "@/types"; export const projects: ProjectDetail[] = [ { id: "iot-dws-integration", - title: "IoT-DWS Integration System", + title: "Tích hợp hệ thống IoT-DWS", titleEn: "IoT-DWS Integration System", summary: "Thiết kế và triển khai hệ thống integration giữa IoT devices và DWS (Dimensioning Weighing Scanning) machines cho 16 sortations.", @@ -14,7 +14,6 @@ export const projects: ProjectDetail[] = [ technologies: ["Java", "HTTP", "HMAC", "RocketMQ", "DWS"], metrics: ["16 sortations deployed"], featured: true, - githubUrl: "https://github.com/yourusername", sections: [ { id: "context", diff --git a/src/pages/ContactPage.tsx b/src/pages/ContactPage.tsx index 2b69150..bce81b4 100644 --- a/src/pages/ContactPage.tsx +++ b/src/pages/ContactPage.tsx @@ -58,7 +58,7 @@ export function ContactPage() {
{strings.contact.github[lang]}
-
@dong-nz
+
@{profile.githubHandle}
{strings.contact.linkedin[lang]}
-
@dong-nz
+
@{profile.linkedinHandle}
diff --git a/src/types/index.ts b/src/types/index.ts index cba41a5..4f8c43c 100644 --- a/src/types/index.ts +++ b/src/types/index.ts @@ -23,8 +23,6 @@ export interface Project { technologies: string[]; metrics?: string[]; featured: boolean; - githubUrl?: string; - demoUrl?: string; } export interface ProjectSection { @@ -96,7 +94,8 @@ export interface Profile { email: string; githubUrl: string; linkedinUrl: string; - resumeUrl?: string; + githubHandle: string; + linkedinHandle: string; currentInterests: string[]; roles: string[]; philosophy: PhilosophyPoint[];