import type { Metadata } from 'next' import { getTranslations, setRequestLocale } from 'next-intl/server' import { redirect, Link } from '@/i18n/navigation' import { getSession } from '@/lib/session' import { getGameCharacters } from '@/lib/characters' import { PageShell } from '@/components/PageShell' import { ServiceBox } from '@/components/ServiceBox' import { TradePointsForm } from '@/components/TradePointsForm' export const dynamic = 'force-dynamic' export const metadata: Metadata = { title: 'Comercio de PD' } export default async function TradePointsPage({ params }: { params: Promise<{ locale: string }> }) { const { locale } = await params setRequestLocale(locale) const t = await getTranslations('Points') const session = await getSession() if (!session.bnetId) redirect({ href: '/login', locale }) if (!session.username) redirect({ href: '/select-account', locale }) const chars = await getGameCharacters(session.accountId!) return (

{t.rich('trade.intro1', { s: (c) => {c} })}


{t('trade.intro2')}

{t('trade.intro3')}


{t('trade.sellTitle')}

{t('trade.sell1')}

{t('trade.sell2')}

{t('trade.sell3')}

{t('trade.sell4')}

{t('trade.sell5')}

{t('trade.sell6')}


{t('trade.buyTitle')}

{t('trade.buy1')}

{t('trade.buy2')}

{t('trade.buy3')}

{t('trade.buy4')}

{t('trade.buy5')}

{t('trade.buy6')}



{t('trade.duration')}

{t('trade.onceRedeemed')}

{t('trade.redeemed1')}

{t('trade.redeemed2')}

{t('trade.redeemed3')}


{t('trade.lockNote')}


{t.rich('trade.tokenHelp', { link: (c) => ( {c} ), })}


{t('trade.note')}

{t('trade.noteText')}

({ name: c.name, classCss: c.classCss }))} />
) }