import { getTranslations, setRequestLocale } from 'next-intl/server' import { Link } from '@/i18n/navigation' import { getForumProfile } from '@/lib/forum' export const dynamic = 'force-dynamic' export default async function ForumProfilePage({ params, }: { params: Promise<{ locale: string; username: string }> }) { const { locale, username } = await params setRequestLocale(locale) const t = await getTranslations('Forum') const p = await getForumProfile(decodeURIComponent(username)) return (

← {t('backToForum')}

{p.username} {p.status && ( {p.status === 'admin' ? t('roleAdmin') : t('roleGm')} )}

{t('posts')}

{p.postCount}

{t('topics')}

{p.topicCount}

{t('memberSince')}

{p.joindate ? new Date(p.joindate).toLocaleDateString(locale) : '—'}

{p.recentTopics.length > 0 && (

{t('recentTopics')}

)}
) }