Skip to content

Logo

The Logo component displays your brand logo with automatic dark mode switching.

---
import Logo from '@/components/ui/Logo.astro';
---
<Logo />
<Logo size="sm" /> <!-- 20x20 -->
<Logo size="md" /> <!-- 24x24 -->
<Logo size="lg" /> <!-- 32x32 -->
<Logo size="xl" /> <!-- 48x48 -->
<Logo size="2xl" /> <!-- 96x96 -->
<!-- Icon only -->
<Logo variant="logomark" />
<!-- Full logo with text -->
<Logo variant="full" />

For dark backgrounds where you need the light version:

<section class="bg-surface-invert">
<Logo forceDark />
</section>
PropTypeDefaultDescription
size'sm' | 'md' | 'lg' | 'xl' | '2xl''md'Logo size
variant'logomark' | 'full''logomark'Logo type
forceDarkbooleanfalseForce dark version

Replace the SVG files in src/assets/branding/:

FilePurpose
logomark.svgIcon for light backgrounds
logomark-dark.svgIcon for dark backgrounds
logo-full.svgFull logo for light backgrounds
logo-full-dark.svgFull logo for dark backgrounds

The Logo component automatically switches between light and dark versions based on:

  1. The current theme (.dark class on <html>)
  2. The forceDark prop for manual override
<header class="flex items-center justify-between">
<a href="/">
<Logo variant="full" size="lg" />
</a>
<nav>...</nav>
</header>
<footer class="bg-surface-invert">
<Logo variant="full" size="xl" forceDark />
</footer>

The logomark is also used as the favicon. Update public/favicon.svg with your icon.