Skip to Content

Themes

A theme decides how a published document is arranged and how it looks: where the navigation, the search field and the light/dark switch sit, and the corners, borders, background and type of every page. You choose one theme, then set what is yours on top of it: brand colour, fonts, and light or dark mode.

Themes do not change your content or your navigation. You can switch at any time.

The seven themes

ThemeArrangementLook
Sequoia (the default)Navigation, search and the light/dark switch in a sidebar. No top barWhite page, rounded corners. The open page is highlighted in the sidebar
CloverA top bar holds the sections of the navigation as tabs, the search field and the light/dark switch. A sidebar lists the pages of the open sectionThe same look as Sequoia
FernAs SequoiaA page lightly tinted with your brand colour, larger rounded corners. The open page is marked as a pill
CedarAs SequoiaSquare corners and firmer borders. The open page is marked by a rule on its left, and group labels are in small capitals
JuniperAs SequoiaMonospaced type everywhere, the navigation included, slightly smaller text, a warm page background. A > marks the open page
BirchA slim top bar holds the site name at the left and, at the right, the sections of the navigation as tabs, your header links and the light/dark switch. The search field is at the top of the sidebar, which lists the pages of the open sectionA soft grey page with the content in a white rounded card. The sidebar sits directly on the grey page, without a border. The open page is marked as a pill. Geist type
AlderA slim top bar holds the site name at the left, the sections of the navigation as pills in the middle and, at the right, search as an icon beside the light/dark switch. A narrow sidebar lists the pages of the open sectionMinimal and quiet: a white page without borders around the sidebar, a narrower reading column, lighter headings. The open page is marked by coloured text alone. Inter type

The same page in the seven themes

Every theme has a light and a dark version, and every theme works on a phone, where the navigation moves into a drawer. In Birch’s dark version the page is darker than the card. On a phone, Birch shows the content without its card.

In Clover, Birch and Alder the top-level entries of your navigation are the tabs, and the sidebar lists the pages of the open one. A long tab name is cut with an ellipsis. When there are more tabs than the bar has room for, the tab row scrolls inside the bar, with an arrow at each end that has tabs out of view; a short top level still reads best. A version without an apigit.json has no tabs: the bar holds the site name and the sidebar lists the files.

Choose a theme

Open Publish Center → API documents → Site Settings, then the Styling panel of the site settings. Under Theme, each theme is a tile with its name, a one-line description and a small sketch of a page. Click a tile and Save.

The Theme picker in the Styling panel

The theme you save applies at once to every published version of the repository.

A different theme for one version

To give one version its own theme, set theme in the apigit.json of the commit it is published from, beside the navigation:

apigit.json
{ "theme": "clover", "nav": [ ... ] }

The value is one of sequoia, clover, fern, cedar, juniper, birch and alder. A version whose apigit.json names a theme uses that one; every other version uses the theme chosen in the Styling panel. A name in the file that is not in the list is ignored, and the version uses the theme of the Styling panel.

A version that follows a branch picks up changes to apigit.json with its next update.

Why do my versions look the same?

A version takes its theme from the apigit.json of the commit it was published from, and only when that file names none from the Styling panel. So versions published from the same commit, or from commits whose apigit.json names the same theme, look the same whatever you choose in the Styling panel: the panel’s theme reaches only the versions whose file names none. To see which theme each version uses, open Publish Center → API documents → All publishes: under every version a line says “Theme: Clover (set in this version’s apigit.json)” or “Theme: Fern (the site’s theme)”.

The list of published versions, each with the theme it uses and where that is set

To let the Styling panel decide for a version, remove theme from apigit.json (in the form editor, Use the site’s theme) and publish that commit. Opened in the repository, an apigit.json that names no theme says which theme the site uses for it.

theme and nav are the only settings read from apigit.json. Everything else on this page is set in the site settings and applies to every version.

Brand colour

Brand colour is used for links, the open item in the navigation, and buttons. Choose it with the picker or type a hex value such as #0f766e; Reset returns to the default blue. In the Fern theme it also tints the page background.

A colour that would be hard to read on the page is darkened until it has enough contrast, and the screen tells you which colour is shown. Text on a button in your colour is black or white, whichever reads better.

Brand colour in dark mode is optional. Without it, your brand colour is used in dark mode too, lightened where needed.

Light and dark

Appearance decides whether readers see a light or a dark page:

AppearanceBehaviour
System (the default)Follows the reader’s device: dark for a reader whose system is in dark mode. Readers get a switch
LightAlways light, without a switch
DarkStarts dark. Readers get a switch

The reader’s switch is at the right of the top bar in the Clover, Birch and Alder themes and at the foot of the sidebar in the other themes. A reader’s choice is remembered in their browser, per site.

If your logo is dark artwork, add a second logo for dark mode in the Branding panel, or set Appearance to Light.

Fonts

In the Typography panel, choose a Heading font and a Body font: Roboto, Inter, Geist, or System, which uses the reader’s own system font. Where you choose none, the theme’s own font is used: Roboto in most themes, Geist in Birch and Inter in Alder. The panel shows which.

The Juniper theme always uses its monospaced type: the two font settings have no effect there.

Preview before publishing

Use the Preview button at the top of the settings screen to see saved settings on a branch.

Working in a clone, apigit preview shows the site on your machine. It applies the theme of apigit.json, and --theme with one of the seven names stands in for the theme chosen in the Styling panel. The settings saved in the screen are not known to the local preview.

Last updated on