import { type FC } from 'react'; import Link from 'next/link'; import type { Route } from 'next'; interface LogoProps { /** Link destination. Set to null to render without a link */ href?: Route | null; showText?: boolean; size?: 'sm' | 'md' | 'lg'; } const sizeClasses = { sm: { icon: 'px-2 py-1 text-sm', text: 'text-lg', }, md: { icon: 'px-4 py-2 text-xl', text: 'text-2xl', }, lg: { icon: 'px-5 py-3 text-2xl', text: 'text-3xl', }, } as const; /** * Botsmann Logo component * Single source of truth for logo styling across the app */ export const Logo: FC = ({ href = '/' as Route, showText = true, size = 'md' }) => { const sizes = sizeClasses[size]; const logoContent = (
B
{showText && ( Botsmann )}
); if (href) { return ( {logoContent} ); } return logoContent; };