feat: add language context and translation support

- Introduced LanguageProvider to manage language state and translations.
- Updated components (Header, Hero, About, Skills, Projects, Education, Contact) to utilize translations.
- Added language toggle button in the header for switching between French and English.
- Enhanced styling for language toggle button in the header.
This commit is contained in:
Dayron
2025-11-12 18:36:51 +01:00
parent a4b4423ff4
commit e8722cf25d
10 changed files with 468 additions and 130 deletions

View File

@@ -1,7 +1,10 @@
import { motion } from 'framer-motion';
import { Download, Github, Linkedin, Mail } from 'lucide-react';
import { useLanguage } from '../contexts/LanguageContext';
const Hero = () => {
const { t } = useLanguage();
const handleDownloadCV = () => {
// Ici, vous pouvez ajouter le lien vers votre CV
const link = document.createElement('a');
@@ -25,7 +28,7 @@ const Hero = () => {
animate={{ opacity: 1, x: 0 }}
transition={{ duration: 0.8, delay: 0.4 }}
>
Dayron Van Leemput
{t('hero.title')}
</motion.h1>
<motion.h2
@@ -34,7 +37,7 @@ const Hero = () => {
animate={{ opacity: 1, x: 0 }}
transition={{ duration: 0.8, delay: 0.6 }}
>
Étudiant en Technologies de l'Informatique
{t('hero.subtitle')}
</motion.h2>
<motion.p
@@ -43,8 +46,7 @@ const Hero = () => {
animate={{ opacity: 1, y: 0 }}
transition={{ duration: 0.8, delay: 0.8 }}
>
Bac 3 à la HELHa de Tournai | Jeune développeur passionné par les nouvelles technologies
et le développement d'applications innovantes
{t('hero.description')}
</motion.p>
<motion.div
@@ -60,7 +62,7 @@ const Hero = () => {
whileTap={{ scale: 0.95 }}
>
<Download size={20} />
Télécharger mon CV
{t('btn.downloadCV')}
</motion.button>
<motion.a
@@ -74,7 +76,7 @@ const Hero = () => {
whileTap={{ scale: 0.95 }}
>
<Mail size={20} />
Me contacter
{t('btn.contactMe')}
</motion.a>
</motion.div>
@@ -96,7 +98,7 @@ const Hero = () => {
</motion.a>
<motion.a
href="https://linkedin.com/in/dayronvanleemput" // Remplacez par votre profil LinkedIn
href="https://www.linkedin.com/in/dayron-van-leemput-992a94398" // Remplacez par votre profil LinkedIn
target="_blank"
rel="noopener noreferrer"
className="social-link"