Skip to content

Family footer

The one footer of every dustinedwards.info site, with the family strip, profiles and legal links.

<div data-family="purple" id="m-purple" data-origin="" data-site="dustinedwards"></div>

Installation

// package.json: "capsomer": "github:DrDustinEdwards/capsomer#v0.152.2"
import "capsomer/tokens.css";
import "capsomer/base.css";
import "capsomer/family-footer.css";
import { siteLinks, legalLinks, familyLinks } from "capsomer/behavior/family-footer";

Usage

import { familyFooterHtml } from "capsomer/behavior/family-footer";
import "capsomer/manual.css"; // the double stripe and the letterhead
import "capsomer/family-footer.css";

// On another site: its own part, and the family's paths point at https://dustinedwards.info.
footer.innerHTML = familyFooterHtml({ site: "capsid", center });
// On dustinedwards.info itself: its own paths, and the Accessibility link only while that page is published.
familyFooterHtml({ site: "dustinedwards", origin: "", published: PUBLISHED_PAGES });
// A site that serves its own accessibility statement: the Legal group's Accessibility link goes to it.
familyFooterHtml({ site: "capsid", center, statement: "/accessibility" });
<div class="cap-family-footer-center">
  <div><p class="cap-family-footer-center-name">Capsid</p><p class="cap-family-footer-about">What it is.</p></div>
  <div class="cap-family-footer-columns">
    <ul class="cap-family-footer-links"><li><a href="/tools">Tools</a></li></ul>
    <!-- up to three groups, on the letterhead's columns -->
  </div>
  <p class="cap-family-footer-stamp"><span>Data as of 2026-10-26</span></p>
</div>

Examples

On Capsid, in teal, with its own part

<div data-family="teal" id="m-teal" data-site="capsid"></div>

On Capsomer, in magenta, with its own part

<div data-family="magenta" id="m-magenta" data-site="capsomer"></div>

API reference

Functions

FunctionSignatureDoes
siteLinks(published?: readonly string[] | undefined): FamilyLink[]The Site group: Contact, Site map, Features and Colophon. A page link waits for its page; none here does.
legalLinks(published?: readonly string[] | undefined): FamilyLink[]The Legal group: Privacy, Terms and Accessibility (only while its page is published).
familyLinks(published?: readonly string[] | undefined): FamilyLink[]Every link the footer draws, in page order.
familyFooterHtml({ site, center, origin, published, statement, year, }?: FamilyFooterOptions): stringThe footer as HTML: plain string building, so a server, a React page or a static build writes the same markup. Its band is the family's --on, so each site's own color draws it.
copyright(name: string, since?: number | undefined, now?: Date): stringA footer's copyright line, the same everywhere: "© 2024–2026 Example Co", or "© 2026 Example Co" when since is this year or later. The year is the server's (UTC), so a page rendered on New Year's Eve and hydrated after midnight in another zone keeps the server's text: render it once, on the server, and never recompute it in an effect.

CSS variables

VariableDefault
--family-footer-nameminmax(0, 20rem)
--markvar(--family-purple)

Parts and data attributes

ClassIs
.cap-family-footerthe root
.cap-family-footer-abouta part
.cap-family-footer-centera part
.cap-family-footer-center-namea part
.cap-family-footer-columnsa part
.cap-family-footer-heada part
.cap-family-footer-headinga part
.cap-family-footer-icona part
.cap-family-footer-knockouta part
.cap-family-footer-labela part
.cap-family-footer-linksa part
.cap-family-footer-locala part
.cap-family-footer-locka part
.cap-family-footer-logoa part
.cap-family-footer-marka part
.cap-family-footer-notea part
.cap-family-footer-privatea part
.cap-family-footer-site-namea part
.cap-family-footer-site-rolea part
.cap-family-footer-sitesa part
.cap-family-footer-sociala part
.cap-family-footer-social-labela part
.cap-family-footer-social-linka part
.cap-family-footer-stampa part
.cap-goits own class
AttributeValues
data-family-markcerulean magenta olive purple rose teal
data-goout
StateRead from
:focus-visiblethe platform
:hoverthe platform
:visitedthe platform
[aria-current]an attribute

Accessibility

  • The strip of sites, the Workspace, Site and Legal groups are nav landmarks named by their headings; the site you are on is aria-current="page".
  • The site you are on is marked by a heavier border, not by color alone, so it holds in forced colors.
  • Each social link's name is its text, hidden until hover or focus but never display: none.
  • Each login's accessible name begins with its visible word and ends "(requires sign-in)".
  • The stripes and every icon are aria-hidden.