import { getPosts } from '@/lib/api' import type { Metadata } from 'next' import DashboardClient from './DashboardClient' export const revalidate = 30 const siteUrl = process.env.NEXT_PUBLIC_SITE_URL || 'https://trumpsignal.com' interface OverviewPageProps { params: Promise<{ locale: string }> } export async function generateMetadata({ params }: OverviewPageProps): Promise { const { locale } = await params const isZh = false // i18n shelved — Chinese branches kept as dead code for future revival; see messages/zh.json const title = isZh ? 'Trump Alpha — 实时加密信号研究台' : 'Trump Alpha — Live Crypto Signal Desk' const description = isZh ? 'Endorphin 研究台追踪四个先于市场共识的信号:Trump 帖子、BTC 宏观底部、资金费率极值,以及 KOL 言行偏离。每个信号公开且带时间戳。' : 'Endorphin tracks six signals that move crypto before the crowd: Trump posts, BTC macro bottoms, funding-rate extremes, KOL long-form calls, talks-vs-trades divergence, and the Breakout Monitor. Public and timestamped.' const path = `${siteUrl}/${locale}` return { title, description, alternates: { canonical: path, languages: { en: `${siteUrl}/en`, 'x-default': `${siteUrl}/en`, }, }, openGraph: { title, description, url: path, locale: isZh ? 'zh_CN' : 'en_US', alternateLocale: isZh ? ['en_US'] : ['zh_CN'], }, twitter: { title, description, }, } } export default async function OverviewPage() { // The overview only renders a small curated slice on first paint; pulling // 500 posts here bloats the server payload without improving the initial UI. const posts = await getPosts(80, 1).catch(() => []) return ( ) }