Footers
JS behaviour
Sitemap footer
The dense sitemap: five categories under tiny headers, annotated links (new with a spark, stable with a check, sunsetting with a warning), a small globe language menu and the legal row — the whole site at a glance.
Real scenarios
The component as it is used in a product — not a specimen grid.
Important props
| Prop | Type | Default | What it does |
|---|---|---|---|
| columns | array | '5' | Product, Developers, Company, Resources, Legal; two columns on tablet, a single rail at 375px. |
| statusIcons | array | 'new · stable · sunsetting' | A spark for the new, a green check for the stable, a warning triangle for the sunsetting — each link’s state is readable without a click. |
| lang | string | 'en' | The small globe language menu; Escape and outside clicks close it, and choosing only swaps the label. |
| density | px | '14px · 1.9' | The link font size and line height; the sitemap’s density lives in these two numbers. |
| legalRow | slot | '© · privacy · terms · cookies' | The dotted legal row at the very bottom, kept apart from the Legal column so it never reads twice. |
Snippet
<footer class="smf-foot" x-data="{ lang: 'en', open: false,
langs: { en: 'English', de: 'Deutsch', fr: 'Français', ja: '日本語' } }">
<nav class="smf-grid" aria-label="Site map">
<div><h4>Product</h4>
<a href="#">Feature flags <i data-status="new"></i></a>
<a href="#">Observability <i data-status="stable"></i></a>
<a href="#">Release automation</a>
</div>
<div><h4>Developers</h4>
<a href="#">Documentation <i data-status="stable"></i></a>
<a href="#">Legacy API <i data-status="sunsetting"></i></a>
</div>
<div><h4>Company</h4><a href="#">About</a><a href="#">Careers <i data-status="new"></i></a></div>
<div><h4>Resources</h4><a href="#">Changelog</a><a href="#">Status <i data-status="stable"></i></a></div>
<div><h4>Legal</h4><a href="#">Privacy</a><a href="#">Terms</a></div>
</nav>
<div class="smf-bottom">
<small>© 2026 Meridian</small>
<div class="smf-legal"><a href="#">Privacy</a> · <a href="#">Terms</a> · <a href="#">Cookies</a></div>
<div class="smf-lang" x-data="{ open: false }">
<button type="button" x-on:click="open = !open" aria-haspopup="listbox"
x-bind:aria-expanded="open">🌐 <span x-text="langs[lang]"></span> ▾</button>
<ul role="listbox" x-show="open" x-on:click.outside="open = false" x-cloak>
<template x-for="(label, code) in langs" :key="code">
<li role="option" x-bind:aria-selected="lang === code"
x-on:click="lang = code; open = false" x-text="label"></li>
</template>
</ul>
</div>
</div>
</footer>
<style>
.smf-foot { padding: 3rem 1.5rem 1.25rem; background: #FFFBF5; color: #292524;
font-family: 'Inter', 'Vazirmatn', sans-serif; }
.smf-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; }
.smf-grid h4 { margin: 0 0 .6rem; font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; color: #A8A29E; }
.smf-grid a { display: flex; align-items: center; gap: .35rem; padding-block: .18rem;
font-size: .8rem; line-height: 1.9; color: #57534E; text-decoration: none; }
.smf-grid a:hover { color: #B45309; text-decoration: underline; }
.smf-grid i[data-status] { inline-size: .8rem; aspect-ratio: 1; border-radius: 50%; flex: none; }
.smf-grid i[data-status='new'] { background: #F59E0B; clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); }
.smf-grid i[data-status='stable'] { background: #059669; clip-path: polygon(14% 52%, 0 66%, 40% 100%, 100% 22%, 86% 8%, 40% 72%); }
.smf-grid i[data-status='sunsetting'] { background: #DC2626; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.smf-bottom { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between;
margin-block-start: 2.5rem; padding-block-start: 1rem; border-block-start: 1px solid #EFE7DA; }
.smf-legal { display: flex; gap: .5rem; font-size: .75rem; color: #A8A29E; }
.smf-legal a { color: #78716C; text-decoration: none; }
.smf-lang { position: relative; }
.smf-lang button { display: inline-flex; gap: .4rem; align-items: center; padding: .35rem .8rem;
font-size: .78rem; color: #57534E; background: #fff; border: 1px solid #EFE7DA;
border-radius: .55rem; cursor: pointer; }
.smf-lang ul { position: absolute; inset-block-end: calc(100% + .4rem); inset-inline-end: 0; margin: 0;
padding: .35rem; min-inline-size: 9rem; list-style: none; background: #fff;
border: 1px solid #EFE7DA; border-radius: .6rem; box-shadow: 0 10px 30px -12px rgba(0,0,0,.25); }
.smf-lang li { padding: .4rem .6rem; font-size: .8rem; border-radius: .4rem; cursor: pointer; }
.smf-lang li:hover { background: #FDF6EC; }
.smf-lang li[aria-selected='true'] { font-weight: 700; }
[x-cloak] { display: none; }
@media (max-width: 720px) { .smf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .smf-foot * { transition: none; } }
</style>
// app/Pages/Home.jsx — Inertia (React) page; renders the React snippet
// below unchanged, with Inertia's Link wired into the provider.
import { Link } from '@inertiajs/react';
import { NabuXUIProvider } from '@nabuxai/ui-react';
import SitemapFooter from '@/components/SitemapFooter';
export default function Home() {
return (
<NabuXUIProvider locale="en" linkComponent={Link}>
<main className="nx-page">
<SitemapFooter />
</main>
</NabuXUIProvider>
);
}
// SitemapFooter.jsx — dense sitemap, status icons, language menu
import { useEffect, useRef, useState } from 'react';
import '@nabuxai/ui-core/css';
const COLUMNS = [
{ head: 'Product', links: [
{ label: 'Feature flags', status: 'new' },
{ label: 'Observability', status: 'stable' },
{ label: 'Release automation' },
]},
{ head: 'Developers', links: [
{ label: 'Documentation', status: 'stable' },
{ label: 'Legacy API', status: 'sunsetting' },
]},
{ head: 'Company', links: [{ label: 'About' }, { label: 'Careers', status: 'new' }] },
{ head: 'Resources', links: [{ label: 'Changelog' }, { label: 'Status', status: 'stable' }] },
{ head: 'Legal', links: [{ label: 'Privacy' }, { label: 'Terms' }] },
];
const LANGS = { en: 'English', de: 'Deutsch', fr: 'Français', ja: '日本語' };
export default function SitemapFooter() {
const [lang, setLang] = useState('en');
const [open, setOpen] = useState(false);
const menu = useRef(null);
useEffect(() => {
const close = (e) => { if (!menu.current?.contains(e.target)) setOpen(false); };
const esc = (e) => { if (e.key === 'Escape') setOpen(false); };
document.addEventListener('pointerdown', close);
document.addEventListener('keydown', esc);
return () => {
document.removeEventListener('pointerdown', close);
document.removeEventListener('keydown', esc);
};
}, []);
return (
<>
<style>{`
.smf-foot { padding: 3rem 1.5rem 1.25rem; background: #FFFBF5; color: #292524; font-family: 'Inter', sans-serif; }
.smf-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; }
.smf-grid h4 { margin: 0 0 .6rem; font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; color: #A8A29E; }
.smf-grid a { display: flex; align-items: center; gap: .35rem; padding-block: .18rem;
font-size: .8rem; line-height: 1.9; color: #57534E; text-decoration: none; }
.smf-grid a:hover { color: #B45309; text-decoration: underline; }
.smf-dot { inline-size: .55rem; aspect-ratio: 1; border-radius: 50%; flex: none; }
.smf-dot[data-status='new'] { background: #F59E0B; }
.smf-dot[data-status='stable'] { background: #059669; }
.smf-dot[data-status='sunsetting'] { background: #DC2626; border-radius: 2px; }
.smf-bottom { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between;
margin-block-start: 2.5rem; padding-block-start: 1rem; border-block-start: 1px solid #EFE7DA; }
.smf-legal { display: flex; gap: .5rem; font-size: .75rem; color: #A8A29E; }
.smf-lang { position: relative; }
.smf-lang button { display: inline-flex; gap: .4rem; align-items: center; padding: .35rem .8rem;
font-size: .78rem; color: #57534E; background: #fff; border: 1px solid #EFE7DA;
border-radius: .55rem; cursor: pointer; }
.smf-lang ul { position: absolute; inset-block-end: calc(100% + .4rem); inset-inline-end: 0; margin: 0;
padding: .35rem; min-inline-size: 9rem; list-style: none; background: #fff;
border: 1px solid #EFE7DA; border-radius: .6rem; box-shadow: 0 10px 30px -12px rgba(0,0,0,.25); }
.smf-lang li { padding: .4rem .6rem; font-size: .8rem; border-radius: .4rem; cursor: pointer; list-style: none; }
.smf-lang li:hover { background: #FDF6EC; }
.smf-lang li[aria-selected='true'] { font-weight: 700; }
@media (max-width: 720px) { .smf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
`}</style>
<footer className="smf-foot">
<nav className="smf-grid" aria-label="Site map">
{COLUMNS.map((c) => (
<div key={c.head}>
<h4>{c.head}</h4>
{c.links.map((l) => (
<a key={l.label} href="#">
{l.label}
{/* The dot carries the link's state: amber new, green stable, red sunsetting. */}
{l.status && <i className="smf-dot" data-status={l.status} aria-label={l.status} />}
</a>
))}
</div>
))}
</nav>
<div className="smf-bottom">
<small>© 2026 Meridian</small>
<div className="smf-legal">
<a href="#">Privacy</a> · <a href="#">Terms</a> · <a href="#">Cookies</a>
</div>
<div className="smf-lang" ref={menu}>
<button type="button" aria-haspopup="listbox" aria-expanded={open}
onClick={() => setOpen(!open)}>🌐 {LANGS[lang]} ▾</button>
{open && (
<ul role="listbox">
{Object.entries(LANGS).map(([code, label]) => (
<li key={code} role="option" aria-selected={lang === code}
onClick={() => { setLang(code); setOpen(false); }}>{label}</li>
))}
</ul>
)}
</div>
</div>
</footer>
</>
);
}
<!-- SitemapFooter.vue — dense sitemap, status icons, language menu -->
<script setup lang="ts">
import { ref } from 'vue';
import '@nabuxai/ui-core/css';
const columns = [
{ head: 'Product', links: [
{ label: 'Feature flags', status: 'new' },
{ label: 'Observability', status: 'stable' },
{ label: 'Release automation' },
]},
{ head: 'Developers', links: [
{ label: 'Documentation', status: 'stable' },
{ label: 'Legacy API', status: 'sunsetting' },
]},
{ head: 'Company', links: [{ label: 'About' }, { label: 'Careers', status: 'new' }] },
{ head: 'Resources', links: [{ label: 'Changelog' }, { label: 'Status', status: 'stable' }] },
{ head: 'Legal', links: [{ label: 'Privacy' }, { label: 'Terms' }] },
];
const langs: Record<string, string> = { en: 'English', de: 'Deutsch', fr: 'Français', ja: '日本語' };
const lang = ref('en');
const open = ref(false);
</script>
<template>
<footer class="smf-foot">
<nav class="smf-grid" aria-label="Site map">
<div v-for="c in columns" :key="c.head">
<h4>{{ c.head }}</h4>
<a v-for="l in c.links" :key="l.label" href="#">
{{ l.label }}
<!-- The dot carries the link's state: amber new, green stable, red sunsetting. -->
<i v-if="l.status" class="smf-dot" :data-status="l.status" :aria-label="l.status"></i>
</a>
</div>
</nav>
<div class="smf-bottom">
<small>© 2026 Meridian</small>
<div class="smf-legal">
<a href="#">Privacy</a> · <a href="#">Terms</a> · <a href="#">Cookies</a>
</div>
<div class="smf-lang" @click.outside="open = false" @keydown.escape="open = false">
<button type="button" aria-haspopup="listbox" :aria-expanded="open" @click="open = !open">
🌐 {{ langs[lang] }} ▾
</button>
<ul v-show="open" role="listbox">
<li v-for="(label, code) in langs" :key="code" role="option" :aria-selected="lang === code"
@click="lang = code; open = false">{{ label }}</li>
</ul>
</div>
</div>
</footer>
</template>
<style scoped>
.smf-foot { padding: 3rem 1.5rem 1.25rem; background: #FFFBF5; color: #292524; font-family: 'Inter', sans-serif; }
.smf-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; }
.smf-grid h4 { margin: 0 0 .6rem; font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; color: #A8A29E; }
.smf-grid a { display: flex; align-items: center; gap: .35rem; padding-block: .18rem;
font-size: .8rem; line-height: 1.9; color: #57534E; text-decoration: none; }
.smf-grid a:hover { color: #B45309; text-decoration: underline; }
.smf-dot { inline-size: .55rem; aspect-ratio: 1; border-radius: 50%; flex: none; }
.smf-dot[data-status='new'] { background: #F59E0B; }
.smf-dot[data-status='stable'] { background: #059669; }
.smf-dot[data-status='sunsetting'] { background: #DC2626; border-radius: 2px; }
.smf-bottom { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between;
margin-block-start: 2.5rem; padding-block-start: 1rem; border-block-start: 1px solid #EFE7DA; }
.smf-legal { display: flex; gap: .5rem; font-size: .75rem; color: #A8A29E; }
.smf-lang { position: relative; }
.smf-lang button { display: inline-flex; gap: .4rem; align-items: center; padding: .35rem .8rem;
font-size: .78rem; color: #57534E; background: #fff; border: 1px solid #EFE7DA;
border-radius: .55rem; cursor: pointer; }
.smf-lang ul { position: absolute; inset-block-end: calc(100% + .4rem); inset-inline-end: 0; margin: 0;
padding: .35rem; min-inline-size: 9rem; list-style: none; background: #fff;
border: 1px solid #EFE7DA; border-radius: .6rem; box-shadow: 0 10px 30px -12px rgba(0,0,0,.25); }
.smf-lang li { padding: .4rem .6rem; font-size: .8rem; border-radius: .4rem; cursor: pointer; }
.smf-lang li:hover { background: #FDF6EC; }
.smf-lang li[aria-selected='true'] { font-weight: 700; }
@media (max-width: 720px) { .smf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
</style>
<!-- SitemapFooter.svelte — dense sitemap, status icons, language menu -->
<script lang="ts">
import '@nabuxai/ui-core/css';
const columns = [
{ head: 'Product', links: [
{ label: 'Feature flags', status: 'new' },
{ label: 'Observability', status: 'stable' },
{ label: 'Release automation' },
]},
{ head: 'Developers', links: [
{ label: 'Documentation', status: 'stable' },
{ label: 'Legacy API', status: 'sunsetting' },
]},
{ head: 'Company', links: [{ label: 'About' }, { label: 'Careers', status: 'new' }] },
{ head: 'Resources', links: [{ label: 'Changelog' }, { label: 'Status', status: 'stable' }] },
{ head: 'Legal', links: [{ label: 'Privacy' }, { label: 'Terms' }] },
];
const langs: Record<string, string> = { en: 'English', de: 'Deutsch', fr: 'Français', ja: '日本語' };
const entries = Object.entries(langs);
let lang = $state('en');
let open = $state(false);
</script>
<footer class="smf-foot">
<nav class="smf-grid" aria-label="Site map">
{#each columns as c (c.head)}
<div>
<h4>{c.head}</h4>
{#each c.links as l (l.label)}
<a href="#">
{l.label}
<!-- The dot carries the link's state: amber new, green stable, red sunsetting. -->
{#if l.status}<i class="smf-dot" data-status={l.status} aria-label={l.status}></i>{/if}
</a>
{/each}
</div>
{/each}
</nav>
<div class="smf-bottom">
<small>© 2026 Meridian</small>
<div class="smf-legal">
<a href="#">Privacy</a> · <a href="#">Terms</a> · <a href="#">Cookies</a>
</div>
<div class="smf-lang">
<button type="button" aria-haspopup="listbox" aria-expanded={open}
onclick={() => (open = !open)}>🌐 {langs[lang]} ▾</button>
{#if open}
<ul role="listbox">
{#each entries as [code, label] (code)}
<li role="option" aria-selected={lang === code}
onclick={() => { lang = code; open = false; }}>{label}</li>
{/each}
</ul>
{/if}
<svelte:window onkeydown={(e) => e.key === 'Escape' && (open = false)} />
</div>
</div>
</footer>
<style>
.smf-foot { padding: 3rem 1.5rem 1.25rem; background: #FFFBF5; color: #292524; font-family: 'Inter', sans-serif; }
.smf-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; }
.smf-grid h4 { margin: 0 0 .6rem; font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; color: #A8A29E; }
.smf-grid a { display: flex; align-items: center; gap: .35rem; padding-block: .18rem;
font-size: .8rem; line-height: 1.9; color: #57534E; text-decoration: none; }
.smf-grid a:hover { color: #B45309; text-decoration: underline; }
.smf-dot { inline-size: .55rem; aspect-ratio: 1; border-radius: 50%; flex: none; }
.smf-dot[data-status='new'] { background: #F59E0B; }
.smf-dot[data-status='stable'] { background: #059669; }
.smf-dot[data-status='sunsetting'] { background: #DC2626; border-radius: 2px; }
.smf-bottom { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between;
margin-block-start: 2.5rem; padding-block-start: 1rem; border-block-start: 1px solid #EFE7DA; }
.smf-legal { display: flex; gap: .5rem; font-size: .75rem; color: #A8A29E; }
.smf-lang { position: relative; }
.smf-lang button { display: inline-flex; gap: .4rem; align-items: center; padding: .35rem .8rem;
font-size: .78rem; color: #57534E; background: #fff; border: 1px solid #EFE7DA;
border-radius: .55rem; cursor: pointer; }
.smf-lang ul { position: absolute; inset-block-end: calc(100% + .4rem); inset-inline-end: 0; margin: 0;
padding: .35rem; min-inline-size: 9rem; list-style: none; background: #fff;
border: 1px solid #EFE7DA; border-radius: .6rem; box-shadow: 0 10px 30px -12px rgba(0,0,0,.25); }
.smf-lang li { padding: .4rem .6rem; font-size: .8rem; border-radius: .4rem; cursor: pointer; }
.smf-lang li:hover { background: #FDF6EC; }
.smf-lang li[aria-selected='true'] { font-weight: 700; }
@media (max-width: 720px) { .smf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
</style>