i18n: títulos de pestaña por idioma (metadata -> generateMetadata)
Los <title> estáticos estaban en español fijo. Se migran 31 páginas a generateMetadata reutilizando la clave de título ya traducida de cada página (o del <h1>). Se traducen además los PageShell title hardcodeados de las 6 páginas CharServiceB y los títulos de download-client y changelogs (+ su mensaje de error). tsc/build OK, paridad es/en, <title> cambia por idioma. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import type { Metadata } from 'next'
|
||||
import { getTranslations } from 'next-intl/server'
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'Política de reembolso',
|
||||
export async function generateMetadata({ params }: { params: Promise<{ locale: string }> }): Promise<Metadata> {
|
||||
const { locale } = await params
|
||||
const t = await getTranslations({ locale, namespace: 'Legal' })
|
||||
return { title: t('refund.title') }
|
||||
}
|
||||
|
||||
export default async function RefundPolicyPage() {
|
||||
|
||||
Reference in New Issue
Block a user