From 1fc235c24fefc0cb95d33bb84da60b7d919cc63a Mon Sep 17 00:00:00 2001 From: adevopg Date: Mon, 13 Jul 2026 13:34:51 +0000 Subject: [PATCH] =?UTF-8?q?web-next:=20usar=20el=20nombre=20del=20reino=20?= =?UTF-8?q?(realmlist)=20en=20men=C3=BA,=20estado=20y=20t=C3=ADtulo?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Menú de navegación: el desplegable «NovaWoW» ahora muestra el nombre del reino de realmlist (Header pasa realmName a SiteHeader). - Home: el título «NovaWoW WOTLK 3.4.3» y el nombre del recuadro de estado (antes home_serverselection.name) usan el nombre del reino de realmlist. Ahora el reino es «Trinity». El logo (alt) y el texto de intro se mantienen como marca. Co-Authored-By: Claude Opus 4.8 (1M context) --- web-next/app/[locale]/page.tsx | 6 ++++-- web-next/components/Header.tsx | 15 ++++++++++++--- web-next/components/SiteHeader.tsx | 4 +++- 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/web-next/app/[locale]/page.tsx b/web-next/app/[locale]/page.tsx index 2efeadc..28782ba 100644 --- a/web-next/app/[locale]/page.tsx +++ b/web-next/app/[locale]/page.tsx @@ -1,6 +1,7 @@ import { setRequestLocale } from 'next-intl/server' import { ServerClock } from '@/components/ServerClock' import { getNoticias, getServerStatus, type Noticia, type ServerStatus } from '@/lib/home' +import { getRealmName } from '@/lib/realm' const SERVER_NAME = 'NovaWoW' @@ -30,6 +31,7 @@ export default async function HomePage({ params }: { params: Promise<{ locale: s const { locale } = await params setRequestLocale(locale) const { noticias, status } = await getData() + const realmName = await getRealmName() const worldStatus = status ? status.world_status : 'Offline' const worldClass = worldStatus === 'Online' ? 'green-info' : 'red-info' @@ -41,7 +43,7 @@ export default async function HomePage({ params }: { params: Promise<{ locale: s
-

{SERVER_NAME} WOTLK 3.4.3

+

{realmName} WOTLK 3.4.3

@@ -52,7 +54,7 @@ export default async function HomePage({ params }: { params: Promise<{ locale: s - {status?.server_name ?? '—'}{' '} + {realmName}{' '} {status?.expansion ?? ''} {worldStatus} diff --git a/web-next/components/Header.tsx b/web-next/components/Header.tsx index 6470485..1d18f00 100644 --- a/web-next/components/Header.tsx +++ b/web-next/components/Header.tsx @@ -7,10 +7,19 @@ export async function Header() { const loggedIn = Boolean(session.username) // Django muestra bnet_email si existe, si no el username. const accountLabel = session.bnetEmail || session.username || '' - // Enlaces al reino/jugadores según el nombre en realmlist (p. ej. /trinity-realm, /trinity-players). - const slug = realmSlug(await getRealmName()) + // Nombre y enlaces del reino según realmlist (p. ej. Trinity → /trinity-realm, /trinity-players). + const realmName = await getRealmName() + const slug = realmSlug(realmName) const realmHref = `/${slug}-realm` const playersHref = `/${slug}-players` - return + return ( + + ) } diff --git a/web-next/components/SiteHeader.tsx b/web-next/components/SiteHeader.tsx index 5e4209e..2e93fba 100644 --- a/web-next/components/SiteHeader.tsx +++ b/web-next/components/SiteHeader.tsx @@ -16,11 +16,13 @@ const SERVER_NAME = 'NovaWoW' export function SiteHeader({ loggedIn, accountLabel, + realmName, realmHref, playersHref, }: { loggedIn: boolean accountLabel: string + realmName: string realmHref: string playersHref: string }) { @@ -74,7 +76,7 @@ export function SiteHeader({
- {SERVER_NAME} + {realmName}