import Link from 'next/link' import type { Lang } from '@/lib/i18n' import { englishSeoPageSlugs, germanSeoPageSlugs, getSeoPageBySlug } from '@/lib/seoPages' import { spanishSeoPageProfiles } from '@/lib/spanishSeoPages' import { seoTemplateCopy } from '@/lib/seoTemplateCopy' import { siteConfig, hasIosStoreUrl, hasAndroidStoreUrl } from '@/lib/site' interface SeoFooterProps { locale: Lang } function slugLinks(slugs: readonly string[]) { return slugs .map((slug) => getSeoPageBySlug(slug)) .filter((profile): profile is NonNullable => Boolean(profile)) .map((profile) => ({ href: profile.canonical, label: profile.h1 })) } export default function SeoFooter({ locale }: SeoFooterProps) { const copy = seoTemplateCopy[locale].footer const useCaseLinks = [ ...slugLinks(englishSeoPageSlugs), { href: '/vs/picturethis', label: 'vs PictureThis' }, { href: '/vs/plantum', label: 'vs Plantum' }, { href: '/vs/inaturalist', label: 'vs iNaturalist' }, { href: '/vs/google-lens', label: 'vs Google Lens' }, ] const germanLinks = slugLinks(germanSeoPageSlugs) const spanishLinks = Object.values(spanishSeoPageProfiles).map((profile) => ({ href: profile.canonical, label: profile.h1, })) return ( ) }