diff --git a/src/components/LandingPage/SEOFooter.tsx b/src/components/LandingPage/SEOFooter.tsx index c4c3869eb..3a84f8ebc 100644 --- a/src/components/LandingPage/SEOFooter.tsx +++ b/src/components/LandingPage/SEOFooter.tsx @@ -1,112 +1,84 @@ import Link from 'next/link' +import footerManifest from '@/content/generated/footer-manifest.json' -// Curated "seed list" for Google crawl discovery. Renders below the main footer -// on non-marketing pages (homepage, /exchange, /lp, etc.). Marketing pages don't -// need this — they already have RelatedPages + CountryGrid linking to sibling content. +// SEO footer driven by peanut-content's generated/footer-manifest.json. +// To update: add `featured: true` to content frontmatter, run +// `node scripts/generate-footer-manifest.js` in peanut-content, and deploy. // -// Data is inlined (not imported from @/data/seo) because Footer.tsx is bundled -// by webpack for client-routed pages (e.g. /exchange) — importing fs-dependent -// modules would break the build. -// -// IMPORTANT: Only list slugs that have published content in peanut-content. -// The validate-links CI in peanut-content catches broken internal links, but -// this file lives in peanut-ui — verify manually when editing. +// JSON import is webpack-safe for client bundles (no fs dependency). + +interface FooterLink { + slug: string + name: string + href: string + external?: boolean +} + +const linkClass = 'text-xs text-white underline hover:text-white/70' + +function FooterColumn({ title, children }: { title: string; children: React.ReactNode }) { + return ( +
+

{title}

+ +
+ ) +} -const TOP_COUNTRIES: Array<{ slug: string; name: string }> = [ - { slug: 'argentina', name: 'Argentina' }, - { slug: 'brazil', name: 'Brazil' }, - { slug: 'mexico', name: 'Mexico' }, - { slug: 'colombia', name: 'Colombia' }, - { slug: 'philippines', name: 'Philippines' }, - { slug: 'nigeria', name: 'Nigeria' }, - { slug: 'india', name: 'India' }, - { slug: 'chile', name: 'Chile' }, -] +function FooterLink({ link, prefix }: { link: FooterLink; prefix?: string }) { + const label = prefix ? `${prefix} ${link.name}` : link.name -const COMPETITORS: Array<{ slug: string; name: string }> = [ - { slug: 'wise', name: 'Wise' }, - { slug: 'western-union', name: 'Western Union' }, - { slug: 'paypal', name: 'PayPal' }, - { slug: 'revolut', name: 'Revolut' }, - { slug: 'binance-p2p', name: 'Binance P2P' }, -] + if (link.external) { + return ( +
  • + + {label} + +
  • + ) + } -const EXCHANGES: Array<{ slug: string; name: string }> = [ - { slug: 'binance', name: 'Binance' }, - { slug: 'coinbase', name: 'Coinbase' }, - { slug: 'bybit', name: 'Bybit' }, - { slug: 'kraken', name: 'Kraken' }, -] + return ( +
  • + + {label} + +
  • + ) +} export function SEOFooter() { + const { sendMoney, compare, articles, resources } = footerManifest + return ( )