refactor: migrate TrumpSignal to TypeScript monorepo and Pages Router

This commit is contained in:
2026-11-03 20:42:30 +08:00
parent de1a903462
commit 1791dbb557
188 changed files with 52461 additions and 2 deletions
@@ -0,0 +1,58 @@
'use client'
import dynamic from 'next/dynamic'
import Link from 'next/link'
import { usePathname } from '@/lib/navigation'
import TelegramCard from '@/components/telegram/TelegramCard'
// BotConfigPanel is heavy and only needed after wallet connect — lazy load it.
const BotConfigPanel = dynamic(() => import('@/components/trades/BotConfigPanel'), {
ssr: false,
loading: () => (
<div
style={{ height: 200, background: 'var(--bg-sunk)', borderRadius: 12, marginBottom: 16 }}
/>
),
})
export default function SettingsClient() {
const pathname = usePathname()
const locale = pathname.split('/')[1] || 'en'
const href = (path: string) => `/${locale}${path}`
return (
<>
<div id="bot-config">
<BotConfigPanel />
</div>
<div style={{ marginTop: 8 }}>
<TelegramCard />
</div>
<div className="card" style={{ padding: '14px 20px', marginTop: 8 }}>
<div style={{ display: 'flex', gap: 20, flexWrap: 'wrap' }}>
<Link
href={href('/privacy')}
style={{ fontSize: 13, color: 'var(--ink-3)', textDecoration: 'none' }}
>
Privacy Policy →
</Link>
<Link
href={href('/terms')}
style={{ fontSize: 13, color: 'var(--ink-3)', textDecoration: 'none' }}
>
Terms →
</Link>
<Link
href={href('/contact')}
style={{ fontSize: 13, color: 'var(--ink-3)', textDecoration: 'none' }}
>
Contact →
</Link>
</div>
</div>
</>
)
}