import React from 'react' import Link from 'next/link' import Image from 'next/image' import { TbCopyrightOff, TbMail, TbBrandGithub, TbBrandX, } from "react-icons/tb" import { ChevronRight } from 'lucide-react' import RandomFooterMsg from "../objects/RandomFooterMsg" import { cn } from '@/lib/utils' import { colors, surfaces } from '@/lib/theme' import { getRecentGitHubRepos } from '@/lib/github' import { footerNavigationLinks, footerSupportLinks, } from './footer-config' import type { FooterMenuRenderContext, FooterMenuSection, NavigationIcon, } from '@/lib/types/navigation' const FOOTER_MENU_SECTIONS: FooterMenuSection[] = [ { type: 'links', title: 'Navigation', links: footerNavigationLinks, }, { type: 'custom', title: 'Latest Projects', render: ({ githubRepos, githubUsername }: FooterMenuRenderContext) => ( githubRepos.length > 0 ? githubRepos.map((repo) => ( {repo.name} )) : ( Projects unavailable — visit GitHub ) ), }, { type: 'links', title: 'Support Me', links: footerSupportLinks, }, ] interface FooterLinkProps { href: string children: React.ReactNode external?: boolean icon?: NavigationIcon } const FooterLink = ({ href, children, external = false, icon: Icon }: FooterLinkProps) => { const linkProps = external ? { target: "_blank", rel: "noopener noreferrer" } : {} return ( {Icon && ( )} {children} {external && } ) } interface FooterSectionProps { title: string children: React.ReactNode } const FooterSection = ({ title, children }: FooterSectionProps) => (

{title}

{children}
) type Persona = { role: string description: string } const personaOptions: Persona[] = [ { role: 'Chief Synergy Evangelist', description: 'Drives enterprise-wide alignment through scalable cross-functional touchpoints.' }, { role: 'Director of Strategic Buzzwords', description: 'Operationalizes high-impact vocabulary to maximize stakeholder resonance.' }, { role: 'Vice President of Change Management', description: 'Leads transformational roadmaps that empower teams to pivot at scale.' }, { role: 'Global KPI Whisperer', description: 'Ensures metric integrity through proactive dashboard storytelling.' }, { role: 'Head of Agile Communications', description: 'Facilitates sprint cadence narratives for executive-level consumption.' }, { role: 'VP of Continuous Optimization', description: 'Champions always-on iteration loops to unlock compounding efficiency gains.' }, { role: 'Principal Narrative Architect', description: 'Synthesizes cross-team input into unified, board-ready success frameworks.' }, { role: 'Lead Alignment Strategist', description: 'Converts strategic pivots into measurable OKR cascades and culture moments.' }, { role: 'Chief Risk Mitigator', description: 'De-risks enterprise bets through proactive dependency orchestration.' }, { role: 'Director of Value Realization', description: 'Translates initiatives into quantifiable ROI across all stakeholder tiers.' } ] const defaultPersona: Persona = personaOptions[0] ?? { role: 'Developer & Creator', description: 'Building thoughtful digital experiences and exploring the intersection of technology, music, and creativity. Currently focused on web development and AI integration.' } const getPersonaByIndex = (index: number | undefined): Persona => { if (!personaOptions.length) { return defaultPersona } if (typeof index !== 'number' || Number.isNaN(index)) { return defaultPersona } const safeIndex = ((Math.floor(index) % personaOptions.length) + personaOptions.length) % personaOptions.length return personaOptions[safeIndex] ?? defaultPersona } interface FooterProps { footerMessageIndex?: number } export default async function Footer({ footerMessageIndex }: FooterProps) { const persona = getPersonaByIndex(footerMessageIndex) const { username: githubUsername, repos: githubRepos } = await getRecentGitHubRepos() return ( ) }