Files
davidandClaude Opus 5.5 5d7db5c5bf Phase 6 part 5, step 1: a shared site theme
internal/theme embeds a Hugo theme from federated-website's look and the
13 section types both sites share, with the header, footer, colors, font
and logo set per site in hugo.toml, and a README of each type's fields.
The catalogue reader reads themes' sections and READMEs after the site's
own; lead forms know a theme site needs only the Lead Capture address.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 15:14:24 -07:00
..

The Supermarket site theme

A Hugo theme for websites made of sections, from Federated Computer's design system. Supermarket copies it into a site as themes/supermarket/; the site's hugo.toml says theme = "supermarket". Anything in the site's own layouts/ or static/ takes precedence over the theme's, so a site can change any part of it.

How pages are built

Every page's content lives in its front matter as a sections: list. Each section has a type and the fields that type takes. Sections alternate white and grey bands; hero opens the page as a dark band and final-cta closes it as one.

Any section can take id (an anchor for links); without one it's made from kicker or headline. Most take a heading: kicker (a small label above), headline and lede (a sentence below). Buttons are ctas: a list of label, url and style (primary, ghost, or text for a quiet link). Text fields take Markdown inline (bold, links).

Type Fields
hero eyebrow, title, subhead, ctas, compact (shorter). Optional log: lines of tag + text (think: true for a greyed step, done: true to close) typed out in a console beside the copy, titled logTitle; logImage puts a photo behind the band, credited by logCaption
text kicker, headline, body (Markdown), centered, ctas; offer adds a highlighted card below: badge, text, ctas. Without a headline, the body shows as a large statement
features kicker, headline, lede, intro (Markdown), items of label + body
cards kicker, headline, lede, columns (2 or 3), items of label, title, body, image, link, linktext; visual: true draws a panel where there's no image; ctas
steps kicker, headline, lede, items of title + body
checklist kicker, headline, lede, items (Markdown strings)
split kicker, headline, lede, columns of title + items (short lists), ctas
stats kicker, headline, lede, items of value + label (values starting with a number count up), ctas
table A comparison: kicker, headline, lede, headers (one per column of values; the last is yours, highlighted), rows of label + cells (one value per header), ctas
faq kicker, headline, lede, items of q + a, ctas
callout kicker, headline, intro, text
final-cta headline, body, ctas (the dark closing band)
form A lead form: kicker, headline, lede, points (a list beside the form), note, subject (names the lead), submit (the button), success (shown after sending), fields of name, label, type (text, email, number, select, textarea), options, placeholder, hint, required, half: true (two to a row). It posts to [params.leads] action (EspoCRM's Lead Capture, set up by Supermarket); while that's empty it opens an email to [params.leads] email

Settings (hugo.toml)

theme = "supermarket"

[params]
  tagline = "What the company does, in a line."

[params.brand]
  logo = "/images/logo.svg"   # without one, the site's title is shown
  favicon = "/favicon.svg"
  dark = "#001a2b"            # the top bar, hero and closing band
  dark2 = "#052b42"
  primary = "#e0ff4f"         # the main button
  accent = "#614efa"          # links and highlights
  font = "Inter"              # a Google Fonts family

[params.header]
  ctas = [{ label = "Get started", url = "/contact/", style = "primary" }]

[params.footer]
  tagline = "..."
  place = "City, Country"
  copyright = "© 2026 Company, Inc."
  groups = [{ title = "Company", menu = "footer_company" }]

[params.leads]
  action = ""
  email = "hello@example.com"

[params.plausible]
  script = "https://plausible.example.com/js/script.js"
  domain = "example.com"

The top bar shows the main menu ([[menu.main]]); an entry with params.dropdown = "<menu>" opens that menu as a panel. The footer shows the menus its groups name, footer_social and footer_legal.