fix(i18n): 🌍 home page now uses translations properly
This commit is contained in:
parent
8544ca5cfc
commit
9edfbcdc93
4 changed files with 98 additions and 174 deletions
|
|
@ -11,11 +11,13 @@ import { FileText, CheckCircle, ArrowRight, Building2, Users } from "lucide-reac
|
|||
import Link from "next/link"
|
||||
import { motion } from "framer-motion"
|
||||
import Image from "next/image"
|
||||
import { useTranslation } from "@/lib/i18n"
|
||||
|
||||
import { useState, useEffect } from "react"
|
||||
import type { Job } from "@/lib/types"
|
||||
|
||||
export default function HomePage() {
|
||||
const { t } = useTranslation()
|
||||
const [featuredJobs, setFeaturedJobs] = useState<Job[]>([])
|
||||
const [loading, setLoading] = useState(true)
|
||||
|
||||
|
|
@ -70,7 +72,7 @@ export default function HomePage() {
|
|||
transition={{ duration: 0.5 }}
|
||||
className="text-4xl sm:text-5xl lg:text-6xl font-bold text-balance mb-6"
|
||||
>
|
||||
Encontre o emprego certo, de forma simples
|
||||
{t('home.hero.title')}
|
||||
</motion.h1>
|
||||
<motion.p
|
||||
initial={{ opacity: 0, y: 20 }}
|
||||
|
|
@ -78,7 +80,7 @@ export default function HomePage() {
|
|||
transition={{ duration: 0.5, delay: 0.1 }}
|
||||
className="text-lg sm:text-xl text-muted-foreground text-balance mb-8 leading-relaxed"
|
||||
>
|
||||
Conectamos candidatos e empresas de forma rápida e direta
|
||||
{t('home.hero.subtitle')}
|
||||
</motion.p>
|
||||
<motion.div
|
||||
initial={{ opacity: 0, y: 20 }}
|
||||
|
|
@ -88,14 +90,14 @@ export default function HomePage() {
|
|||
>
|
||||
<Link href="/login">
|
||||
<Button size="lg" className="w-full sm:w-auto">
|
||||
Procurar vagas
|
||||
{t('home.hero.searchJobs')}
|
||||
<ArrowRight className="ml-2 h-4 w-4" />
|
||||
</Button>
|
||||
</Link>
|
||||
<Link href="/cadastro/empresa">
|
||||
<Button size="lg" variant="outline" className="w-full sm:w-auto bg-transparent">
|
||||
<Building2 className="mr-2 h-4 w-4" />
|
||||
Sou empresa
|
||||
{t('home.hero.imCompany')}
|
||||
</Button>
|
||||
</Link>
|
||||
</motion.div>
|
||||
|
|
@ -125,8 +127,8 @@ export default function HomePage() {
|
|||
<section className="bg-muted/30 py-20">
|
||||
<div className="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||
<div className="text-center mb-12">
|
||||
<h2 className="text-3xl font-bold mb-4">Vagas em Destaque</h2>
|
||||
<p className="text-muted-foreground text-base">Oportunidades selecionadas para você</p>
|
||||
<h2 className="text-3xl font-bold mb-4">{t('home.featured.title')}</h2>
|
||||
<p className="text-muted-foreground text-base">{t('home.featured.subtitle')}</p>
|
||||
</div>
|
||||
|
||||
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6 max-w-7xl mx-auto">
|
||||
|
|
@ -146,7 +148,7 @@ export default function HomePage() {
|
|||
<div className="text-center mt-12">
|
||||
<Link href="/login">
|
||||
<Button variant="outline" size="lg">
|
||||
Ver todas as vagas
|
||||
{t('home.featured.viewAll')}
|
||||
<ArrowRight className="ml-2 h-4 w-4" />
|
||||
</Button>
|
||||
</Link>
|
||||
|
|
@ -161,8 +163,8 @@ export default function HomePage() {
|
|||
</div>
|
||||
<div className="container mx-auto px-4 sm:px-6 lg:px-8 relative">
|
||||
<div className="text-center mb-16">
|
||||
<h2 className="text-3xl font-bold mb-4">Como Funciona?</h2>
|
||||
<p className="text-muted-foreground text-base">Três passos simples para sua próxima oportunidade</p>
|
||||
<h2 className="text-3xl font-bold mb-4">{t('home.howItWorks.title')}</h2>
|
||||
<p className="text-muted-foreground text-base">{t('home.howItWorks.subtitle')}</p>
|
||||
</div>
|
||||
|
||||
<div className="grid grid-cols-1 md:grid-cols-3 gap-8 max-w-5xl mx-auto">
|
||||
|
|
@ -176,8 +178,8 @@ export default function HomePage() {
|
|||
<div className="w-16 h-16 rounded-full flex items-center justify-center mx-auto mb-6 bg-background">
|
||||
<Users className="text-primary w-9 h-9" />
|
||||
</div>
|
||||
<h3 className="text-xl font-semibold mb-3">1. Cadastre-se</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">Crie seu perfil gratuitamente em poucos minutos</p>
|
||||
<h3 className="text-xl font-semibold mb-3">{t('home.howItWorks.step1.title')}</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">{t('home.howItWorks.step1.description')}</p>
|
||||
</motion.div>
|
||||
|
||||
<motion.div
|
||||
|
|
@ -190,8 +192,8 @@ export default function HomePage() {
|
|||
<div className="w-16 h-16 rounded-full flex items-center justify-center mx-auto mb-6 bg-background">
|
||||
<FileText className="text-primary w-9 h-9" />
|
||||
</div>
|
||||
<h3 className="text-xl font-semibold mb-3">2. Envie seu currículo</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">Adicione suas experiências e habilidades</p>
|
||||
<h3 className="text-xl font-semibold mb-3">{t('home.howItWorks.step2.title')}</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">{t('home.howItWorks.step2.description')}</p>
|
||||
</motion.div>
|
||||
|
||||
<motion.div
|
||||
|
|
@ -204,8 +206,8 @@ export default function HomePage() {
|
|||
<div className="w-16 h-16 rounded-full flex items-center justify-center mx-auto mb-6 bg-background">
|
||||
<CheckCircle className="text-primary h-9 w-9" />
|
||||
</div>
|
||||
<h3 className="text-xl font-semibold mb-3">3. Seja encontrado</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">Receba ofertas de empresas interessadas</p>
|
||||
<h3 className="text-xl font-semibold mb-3">{t('home.howItWorks.step3.title')}</h3>
|
||||
<p className="text-muted-foreground leading-relaxed">{t('home.howItWorks.step3.description')}</p>
|
||||
</motion.div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -215,8 +217,8 @@ export default function HomePage() {
|
|||
<section className="bg-muted/30 py-20 border-0">
|
||||
<div className="container mx-auto px-4 sm:px-6 lg:px-8">
|
||||
<div className="text-center mb-12">
|
||||
<h2 className="text-3xl font-bold mb-4">O que nossos usuários dizem?</h2>
|
||||
<p className="text-muted-foreground text-base">Histórias de sucesso de quem encontrou sua oportunidade</p>
|
||||
<h2 className="text-3xl font-bold mb-4">{t('home.testimonials.title')}</h2>
|
||||
<p className="text-muted-foreground text-base">{t('home.testimonials.subtitle')}</p>
|
||||
</div>
|
||||
|
||||
<div className="grid grid-cols-1 md:grid-cols-3 gap-6 max-w-6xl mx-auto">
|
||||
|
|
@ -253,14 +255,14 @@ export default function HomePage() {
|
|||
<div className="grid lg:grid-cols-2 gap-0">
|
||||
{/* Text Content */}
|
||||
<CardContent className="py-16 px-8 lg:px-12 flex flex-col justify-center bg-primary text-primary-foreground">
|
||||
<h2 className="text-3xl lg:text-4xl font-bold mb-4 text-balance">Pronto para começar?</h2>
|
||||
<h2 className="text-3xl lg:text-4xl font-bold mb-4 text-balance">{t('home.cta.title')}</h2>
|
||||
<p className="mb-8 text-primary-foreground/90 text-balance leading-relaxed text-base">
|
||||
Crie seu perfil gratuito e comece a receber ofertas de emprego hoje mesmo!
|
||||
{t('home.cta.subtitle')}
|
||||
</p>
|
||||
<div>
|
||||
<Link href="/cadastro/candidato">
|
||||
<Button size="lg" variant="secondary">
|
||||
Criar perfil gratuito
|
||||
{t('home.cta.button')}
|
||||
<ArrowRight className="ml-2 h-4 w-4" />
|
||||
</Button>
|
||||
</Link>
|
||||
|
|
|
|||
|
|
@ -8,8 +8,10 @@
|
|||
},
|
||||
"home": {
|
||||
"hero": {
|
||||
"title": "Find your next opportunity",
|
||||
"subtitle": "6 jobs available at the best companies"
|
||||
"title": "Find the right job, the simple way",
|
||||
"subtitle": "Connecting candidates and companies quickly and directly",
|
||||
"searchJobs": "Search jobs",
|
||||
"imCompany": "I'm a company"
|
||||
},
|
||||
"featured": {
|
||||
"title": "Featured Jobs",
|
||||
|
|
@ -17,64 +19,36 @@
|
|||
"viewAll": "View all jobs"
|
||||
},
|
||||
"howItWorks": {
|
||||
"title": "How it works",
|
||||
"title": "How it works?",
|
||||
"subtitle": "Three simple steps to your next opportunity",
|
||||
"step1": {
|
||||
"title": "Browse Jobs",
|
||||
"description": "Explore hundreds of opportunities from top companies"
|
||||
},
|
||||
"step2": {
|
||||
"title": "Apply Easily",
|
||||
"description": "One-click applications with your profile"
|
||||
},
|
||||
"step3": {
|
||||
"title": "Get Hired",
|
||||
"description": "Land your dream job and start your new journey"
|
||||
}
|
||||
"step1": { "title": "1. Sign up", "description": "Create your free profile in just a few minutes" },
|
||||
"step2": { "title": "2. Send your resume", "description": "Add your experiences and skills" },
|
||||
"step3": { "title": "3. Get found", "description": "Receive offers from interested companies" }
|
||||
},
|
||||
"testimonials": {
|
||||
"title": "What our users say?",
|
||||
"subtitle": "Success stories from those who found their opportunity"
|
||||
},
|
||||
"cta": {
|
||||
"title": "Ready to start?",
|
||||
"subtitle": "Create your free profile and start receiving job offers today!",
|
||||
"button": "Create free profile"
|
||||
}
|
||||
},
|
||||
"jobs": {
|
||||
"title": "Find your next opportunity",
|
||||
"subtitle": "{count} jobs available at the best companies",
|
||||
"search": "Search jobs by title, company...",
|
||||
"filters": {
|
||||
"all": "All",
|
||||
"onsite": "On-site",
|
||||
"hybrid": "Hybrid",
|
||||
"remote": "Remote",
|
||||
"workMode": "Work Mode"
|
||||
},
|
||||
"card": {
|
||||
"viewDetails": "View details",
|
||||
"apply": "Apply now",
|
||||
"perMonth": "/month",
|
||||
"postedAgo": "Posted {time} ago"
|
||||
},
|
||||
"pagination": {
|
||||
"previous": "Previous",
|
||||
"next": "Next",
|
||||
"showing": "Showing {from} to {to} of {total} jobs"
|
||||
}
|
||||
},
|
||||
"workMode": {
|
||||
"onsite": "On-site",
|
||||
"hybrid": "Hybrid",
|
||||
"remote": "Remote"
|
||||
"filters": { "all": "All", "onsite": "On-site", "hybrid": "Hybrid", "remote": "Remote", "workMode": "Work Mode" },
|
||||
"card": { "viewDetails": "View details", "apply": "Apply now", "perMonth": "/month", "postedAgo": "Posted {time} ago" },
|
||||
"pagination": { "previous": "Previous", "next": "Next", "showing": "Showing {from} to {to} of {total} jobs" }
|
||||
},
|
||||
"workMode": { "onsite": "On-site", "hybrid": "Hybrid", "remote": "Remote" },
|
||||
"footer": {
|
||||
"company": "Company",
|
||||
"about": "About",
|
||||
"careers": "Careers",
|
||||
"jobsByTech": "Jobs by Technology",
|
||||
"legal": "Legal",
|
||||
"privacy": "Privacy Policy",
|
||||
"terms": "Terms of Use",
|
||||
"company": "Company", "about": "About", "careers": "Careers",
|
||||
"jobsByTech": "Jobs by Technology", "legal": "Legal",
|
||||
"privacy": "Privacy Policy", "terms": "Terms of Use",
|
||||
"copyright": "© {year} GoHorse Jobs. All rights reserved."
|
||||
},
|
||||
"common": {
|
||||
"loading": "Loading...",
|
||||
"error": "Error",
|
||||
"retry": "Retry",
|
||||
"noResults": "No results found"
|
||||
}
|
||||
"common": { "loading": "Loading...", "error": "Error", "retry": "Retry", "noResults": "No results found" }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,8 +8,10 @@
|
|||
},
|
||||
"home": {
|
||||
"hero": {
|
||||
"title": "Encuentra tu próxima oportunidad",
|
||||
"subtitle": "6 empleos disponibles en las mejores empresas"
|
||||
"title": "Encuentra el empleo correcto, de forma sencilla",
|
||||
"subtitle": "Conectamos candidatos y empresas de forma rápida y directa",
|
||||
"searchJobs": "Buscar empleos",
|
||||
"imCompany": "Soy empresa"
|
||||
},
|
||||
"featured": {
|
||||
"title": "Empleos Destacados",
|
||||
|
|
@ -17,64 +19,36 @@
|
|||
"viewAll": "Ver todos los empleos"
|
||||
},
|
||||
"howItWorks": {
|
||||
"title": "Cómo funciona",
|
||||
"subtitle": "Tres pasos simples para tu próxima oportunidad",
|
||||
"step1": {
|
||||
"title": "Buscar Empleos",
|
||||
"description": "Explora cientos de oportunidades en las mejores empresas"
|
||||
},
|
||||
"step2": {
|
||||
"title": "Postúlate Fácil",
|
||||
"description": "Postulaciones con un clic usando tu perfil"
|
||||
},
|
||||
"step3": {
|
||||
"title": "Consigue el Trabajo",
|
||||
"description": "Obtén el trabajo de tus sueños y comienza tu nueva jornada"
|
||||
}
|
||||
"title": "¿Cómo funciona?",
|
||||
"subtitle": "Tres pasos sencillos para tu próxima oportunidad",
|
||||
"step1": { "title": "1. Regístrate", "description": "Crea tu perfil gratis en pocos minutos" },
|
||||
"step2": { "title": "2. Envía tu currículum", "description": "Agrega tus experiencias y habilidades" },
|
||||
"step3": { "title": "3. Sé encontrado", "description": "Recibe ofertas de empresas interesadas" }
|
||||
},
|
||||
"testimonials": {
|
||||
"title": "¿Qué dicen nuestros usuarios?",
|
||||
"subtitle": "Historias de éxito de quienes encontraron su oportunidad"
|
||||
},
|
||||
"cta": {
|
||||
"title": "¿Listo para empezar?",
|
||||
"subtitle": "¡Crea tu perfil gratis y comienza a recibir ofertas de empleo hoy!",
|
||||
"button": "Crear perfil gratis"
|
||||
}
|
||||
},
|
||||
"jobs": {
|
||||
"title": "Encuentra tu próxima oportunidad",
|
||||
"subtitle": "{count} empleos disponibles en las mejores empresas",
|
||||
"search": "Buscar empleos por título, empresa...",
|
||||
"filters": {
|
||||
"all": "Todos",
|
||||
"onsite": "Presencial",
|
||||
"hybrid": "Híbrido",
|
||||
"remote": "Remoto",
|
||||
"workMode": "Modalidad"
|
||||
},
|
||||
"card": {
|
||||
"viewDetails": "Ver detalles",
|
||||
"apply": "Postularse",
|
||||
"perMonth": "/mes",
|
||||
"postedAgo": "Publicado hace {time}"
|
||||
},
|
||||
"pagination": {
|
||||
"previous": "Anterior",
|
||||
"next": "Siguiente",
|
||||
"showing": "Mostrando {from} a {to} de {total} empleos"
|
||||
}
|
||||
},
|
||||
"workMode": {
|
||||
"onsite": "Presencial",
|
||||
"hybrid": "Híbrido",
|
||||
"remote": "Remoto"
|
||||
"filters": { "all": "Todos", "onsite": "Presencial", "hybrid": "Híbrido", "remote": "Remoto", "workMode": "Modalidad" },
|
||||
"card": { "viewDetails": "Ver detalles", "apply": "Postularse", "perMonth": "/mes", "postedAgo": "Publicado hace {time}" },
|
||||
"pagination": { "previous": "Anterior", "next": "Siguiente", "showing": "Mostrando {from} a {to} de {total} empleos" }
|
||||
},
|
||||
"workMode": { "onsite": "Presencial", "hybrid": "Híbrido", "remote": "Remoto" },
|
||||
"footer": {
|
||||
"company": "Empresa",
|
||||
"about": "Sobre",
|
||||
"careers": "Carreras",
|
||||
"jobsByTech": "Empleos por Tecnología",
|
||||
"legal": "Legal",
|
||||
"privacy": "Política de Privacidad",
|
||||
"terms": "Términos de Uso",
|
||||
"company": "Empresa", "about": "Sobre", "careers": "Carreras",
|
||||
"jobsByTech": "Empleos por Tecnología", "legal": "Legal",
|
||||
"privacy": "Política de Privacidad", "terms": "Términos de Uso",
|
||||
"copyright": "© {year} GoHorse Jobs. Todos los derechos reservados."
|
||||
},
|
||||
"common": {
|
||||
"loading": "Cargando...",
|
||||
"error": "Error",
|
||||
"retry": "Reintentar",
|
||||
"noResults": "No se encontraron resultados"
|
||||
}
|
||||
"common": { "loading": "Cargando...", "error": "Error", "retry": "Reintentar", "noResults": "No se encontraron resultados" }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,8 +8,10 @@
|
|||
},
|
||||
"home": {
|
||||
"hero": {
|
||||
"title": "Encontre sua próxima oportunidade",
|
||||
"subtitle": "6 vagas disponíveis nas melhores empresas"
|
||||
"title": "Encontre o emprego certo, de forma simples",
|
||||
"subtitle": "Conectamos candidatos e empresas de forma rápida e direta",
|
||||
"searchJobs": "Procurar vagas",
|
||||
"imCompany": "Sou empresa"
|
||||
},
|
||||
"featured": {
|
||||
"title": "Vagas em Destaque",
|
||||
|
|
@ -17,64 +19,36 @@
|
|||
"viewAll": "Ver todas as vagas"
|
||||
},
|
||||
"howItWorks": {
|
||||
"title": "Como Funciona",
|
||||
"title": "Como Funciona?",
|
||||
"subtitle": "Três passos simples para sua próxima oportunidade",
|
||||
"step1": {
|
||||
"title": "Buscar Vagas",
|
||||
"description": "Explore centenas de oportunidades nas melhores empresas"
|
||||
},
|
||||
"step2": {
|
||||
"title": "Candidate-se Fácil",
|
||||
"description": "Candidatura com um clique usando seu perfil"
|
||||
},
|
||||
"step3": {
|
||||
"title": "Seja Contratado",
|
||||
"description": "Conquiste o trabalho dos seus sonhos e comece sua nova jornada"
|
||||
}
|
||||
"step1": { "title": "1. Cadastre-se", "description": "Crie seu perfil gratuitamente em poucos minutos" },
|
||||
"step2": { "title": "2. Envie seu currículo", "description": "Adicione suas experiências e habilidades" },
|
||||
"step3": { "title": "3. Seja encontrado", "description": "Receba ofertas de empresas interessadas" }
|
||||
},
|
||||
"testimonials": {
|
||||
"title": "O que nossos usuários dizem?",
|
||||
"subtitle": "Histórias de sucesso de quem encontrou sua oportunidade"
|
||||
},
|
||||
"cta": {
|
||||
"title": "Pronto para começar?",
|
||||
"subtitle": "Crie seu perfil gratuito e comece a receber ofertas de emprego hoje mesmo!",
|
||||
"button": "Criar perfil gratuito"
|
||||
}
|
||||
},
|
||||
"jobs": {
|
||||
"title": "Encontre sua próxima oportunidade",
|
||||
"subtitle": "{count} vagas disponíveis nas melhores empresas",
|
||||
"search": "Buscar vagas por título, empresa...",
|
||||
"filters": {
|
||||
"all": "Todas",
|
||||
"onsite": "Presencial",
|
||||
"hybrid": "Híbrido",
|
||||
"remote": "Remoto",
|
||||
"workMode": "Modalidade"
|
||||
},
|
||||
"card": {
|
||||
"viewDetails": "Ver detalhes",
|
||||
"apply": "Candidatar-se",
|
||||
"perMonth": "/mês",
|
||||
"postedAgo": "Publicada há {time}"
|
||||
},
|
||||
"pagination": {
|
||||
"previous": "Anterior",
|
||||
"next": "Próximo",
|
||||
"showing": "Mostrando {from} a {to} de {total} vagas"
|
||||
}
|
||||
},
|
||||
"workMode": {
|
||||
"onsite": "Presencial",
|
||||
"hybrid": "Híbrido",
|
||||
"remote": "Remoto"
|
||||
"filters": { "all": "Todas", "onsite": "Presencial", "hybrid": "Híbrido", "remote": "Remoto", "workMode": "Modalidade" },
|
||||
"card": { "viewDetails": "Ver detalhes", "apply": "Candidatar-se", "perMonth": "/mês", "postedAgo": "Publicada há {time}" },
|
||||
"pagination": { "previous": "Anterior", "next": "Próximo", "showing": "Mostrando {from} a {to} de {total} vagas" }
|
||||
},
|
||||
"workMode": { "onsite": "Presencial", "hybrid": "Híbrido", "remote": "Remoto" },
|
||||
"footer": {
|
||||
"company": "Empresa",
|
||||
"about": "Sobre",
|
||||
"careers": "Carreiras",
|
||||
"jobsByTech": "Vagas por Tecnologia",
|
||||
"legal": "Legal",
|
||||
"privacy": "Política de Privacidade",
|
||||
"terms": "Termos de Uso",
|
||||
"company": "Empresa", "about": "Sobre", "careers": "Carreiras",
|
||||
"jobsByTech": "Vagas por Tecnologia", "legal": "Legal",
|
||||
"privacy": "Política de Privacidade", "terms": "Termos de Uso",
|
||||
"copyright": "© {year} GoHorse Jobs. Todos os direitos reservados."
|
||||
},
|
||||
"common": {
|
||||
"loading": "Carregando...",
|
||||
"error": "Erro",
|
||||
"retry": "Tentar novamente",
|
||||
"noResults": "Nenhum resultado encontrado"
|
||||
}
|
||||
"common": { "loading": "Carregando...", "error": "Erro", "retry": "Tentar novamente", "noResults": "Nenhum resultado encontrado" }
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue