The Almanack Markdown Guide
A reference and tutorial for composing articles in Almanack’s extended markdown dialect. We use standard Pandoc markdown with a few house extensions for margin notes, figures, and other periodical niceties.
Article Structure
Every article lives in its own directory under editorial/articles/, with the
main content in article.md and any images in an assets/ subdirectory.
Frontmatter
Articles begin with YAML frontmatter:
---
title: "Your Magnificent Title"
author: "Horace Greeley"
almanac-day: "2026-01-15"
status: published
frontpage:
- "2026-01-15"
tags:
- astronomy
- philosophy
---
Required Fields
- title: The article title, in quotes
- author: Your name or pen name
- almanac-day: The calendar date in ISO format (YYYY-MM-DD). This determines
the article’s volume number and URL. Negative years work:
-4000-01-01is Vol. 1. - status: Either
draftorpublished. Only published articles appear on the site.
Optional Fields
- frontpage: An array of dates (ISO format) when this article should appear
on the front page. Typically matches
almanac-day, but can include multiple dates for recurring features or later highlights. - tags: An array of topic tags for categorization and discovery.
- author_path: A URL path for the author’s page (e.g.,
/~horace/). - path: Override the default URL path. Useful for pages with custom routes.
- byline_prefix: Custom text before the date in the byline (e.g., “Last compiled in” instead of “From”).
Basic Markdown
We support standard Pandoc markdown: *italics*, **bold**, [links](url),
headers with ##, and so forth. If you know markdown, you know most of what
you need.
Footnotes and Sidenotes
Footnotes are the soul of Almanack. On wide screens, they appear as sidenotes in the margins, adorned with manicules (☞☜). On narrow screens, they collapse to traditional footnotes.
Creating Footnotes
Mark the reference point with [^name] and define the content elsewhere:
The moon appears different depending on your latitude.[^latitude]
[^latitude]: This phenomenon has been documented since antiquity. See
Eratosthenes, "On Looking Up," *Almnck.*{.pub} Vol. 3780, iii.12.
Footnote content can span multiple paragraphs if indented:
[^longfoot]: The first paragraph of the footnote.
A second paragraph, indented with four spaces.
Even a third, if you're feeling expansive.
Citing the Archive
When referring to Almanack’s (fictional) back-catalog, use the .pub class to
render “Almnck.” in the house style:
*Almnck.*{.pub} Vol. 5765, iv.23
This renders with Fell English typography, befitting our antiquarian pretensions.
Figures
Images with captions use HTML figure blocks. This gives you proper plate-style presentation with borders, click-to-enlarge lightboxes, and numbered captions.
<figure class="figure" markdown>

<figcaption>Figure 1. Your witty caption here.</figcaption>
</figure>
Key points:
- The
markdownattribute allows markdown processing inside the HTML - Alt text goes in the
![brackets]— describe the image for accessibility - Number your figures manually (Figure 1, Figure i, etc.)
- Readers can click images to see them enlarged in a lightbox
Figures work especially well inside footnotes, where they appear in the margins alongside the relevant text.
Blockquotes with Attribution
For quoted passages with citations — especially epigraphs at the start of an
article — use the figure.quote structure:
<figure class="quote">
<blockquote>"[Tarski] once confided to me that he considered himself
'the greatest living sane logician'," thus not so subtly avoiding
the problem of comparison with Kurt Gödel.</blockquote>
<figcaption>— <cite>Alfred Tarski, Life and Logic</cite>, p.5</figcaption>
</figure>
This renders the quote indented on both sides (20% padding), left-aligned, with
the attribution right-aligned below in a subtle style. The book title inside
<cite> appears in italics.
Epigraphs
When a figure.quote appears as the first element of an article, the following
paragraph automatically receives the small-caps first-line treatment — making it
ideal for opening epigraphs:
---
title: "Your Title"
...
---
<figure class="quote">
<blockquote>An inspiring or provocative quote.</blockquote>
<figcaption>— <cite>Source</cite></figcaption>
</figure>
Your opening paragraph starts here and will have small-caps styling
on its first line.
Quotes appearing later in the article don’t trigger this effect — only the opening epigraph.
Headnotes
An article set in an earlier volume (a reprint, a translation, a recovered
tablet) opens with a headnote: a short introduction from the present-day
editors saying who wrote the piece, where it comes from, and where it was
later republished. Write it as the first paragraph of the article, and put
{: .headnote} on the line after it:
Noted anarchist Emma Goldman was Almanack's government relations correspondent
from 1920 to 1921. This extract from her reports was later republished in *My
Further Disillusionment in Russia* (1924).
{: .headnote}
The headnote is set in italics in the main column, smaller than the body
text and indented on both sides (on a phone it fills the column), with a short
hairline beneath it. A headnote of one paragraph is centred. It also appears
when the article is on the front page. It can carry footnotes. Emphasis inside
it (*My Further Disillusionment in Russia*) is set upright, as a title is in
any italic passage.
A headnote of several paragraphs is justified rather than centred, because
centred lines are tiring to read at length. End each paragraph with its own
{: .headnote} line, or put them in a block:
<div class="headnote" markdown="1">
A𒀭 is a series of perforated tokens from near Tello, ancient Girsu.
The translation here includes the accepted notion for the individual tokens.
</div>
A headnote never has a drop cap. The initial belongs to the first letter of the body text that follows.
Drop Caps (Initials)
For a distinguished opening, use the .initial class on an image:
{.initial}
This floats a decorative capital at the start of your article. The image should be roughly square and work well at about 4 lines of text height.
The initial stands for the first letter of the body text. If the article has a headnote, the initial comes after it.
Until the artwork exists, a typographic initial will do. Put the letter in a
text-initial block before the paragraph, and repeat it, hidden, at the start
of the paragraph so screen readers hear the whole word:
<div class="text-initial" aria-hidden="true">W</div>
<span class="visually-hidden">W</span>hen kings had learnt to borrow against the unborn,
The first line of the paragraph is set in vermilion small capitals.
To open a verse section with initialism artwork, put the image in a
verse-initial block, and keep the hidden letter at the start of the first
line:
<div class="verse-initial" markdown="span">
{.initial}
</div>
<span class="visually-hidden">W</span>hen kings had learnt to borrow against the unborn,<br>
The artwork must follow the white-line convention below, on a transparent ground: the block inverts it to a dark engraving.
Verse
Wrap a poem in a verse section and end each line with <br>:
<section class="verse" markdown>
They had kneaded one loaf.<br>
They had lifted one child from the water.<br>
They had washed in one basin;<br>
each accused the other of making it dirty.
</section>
A blank line separates stanzas. Verse is never justified, and a line too long
for the column hangs its overflow under the first word, so readers can tell a
wrapped line from a new one. Keep emphasis within a single line: *italics*
that cross a <br> won’t get the hanging indent.
Use <br> rather than Pandoc’s trailing backslash, which the website’s
renderer ignores.
Disputations
For a debate poem, give each speech its own section with an ## heading
naming the speaker. disputation-left speaks in vermilion (☜) and
disputation-right in ultramarine (☞); disputation-scribe sets narrative
interludes in italics, and disputation-judgment frames the verdict:
<section class="verse disputation-speech disputation-left" markdown>
## The Left Hand
O Right, little landlord of five fingers!<br>
...
</section>
See The Disputation of the Left Hand and the Right Hand, Almnck. Vol. 1941, x·30, for the full set.
Margin Boxes
Beyond sidenotes (which derive from footnotes), you can place standalone
content in the margins using margin boxes. These are <aside> elements with
the margin-box class and a data-type attribute.
Poems
For verse in the margins, framed with floral ornaments:
<aside class="margin-box" data-type="poem" markdown>
*Poem Title*
First line of verse
Second line of verse
Third line, and so on
-- Attribution
</aside>
The title (first *italic* element) displays prominently. Use markdown line
breaks (two trailing spaces or <br>) to preserve line structure. The poem
is bracketed by ❦ above and ❧ below.
Quotes
For quotations with attribution:
<aside class="margin-box" data-type="quote" markdown>
The important thing is not to stop questioning.
<cite>Albert Einstein, probably</cite>
</aside>
Renders in italics with a left border.
Aphorisms
Short, pithy statements in display typography:
<aside class="margin-box" data-type="aphorism" markdown>
Everything should be made as simple as possible, but not simpler.
</aside>
Centered, in Fell English.
Advertisements
For period-appropriate notices:
<aside class="margin-box" data-type="ad" markdown>
**ACME MOON CHEESE**
Now available in three flavours!
</aside>
Boxed and centered.
Placement Preferences
By default, margin boxes appear near their position in the document, alternating
between left and right margins. You can control placement more precisely with
the data-margin attribute:
<aside class="margin-box" data-margin="top-right-high" data-type="ad" markdown>
**PREMIUM SPONSOR**
</aside>
The attribute accepts hyphen-separated tokens (order doesn’t matter):
| Token | Effect |
|---|---|
top |
Place at the top of the margin, filling downward |
bottom |
Place at the bottom of the body text, filling upward |
near |
Stay close to the definition point (default for inline boxes) |
left |
Prefer the left margin |
right |
Prefer the right margin |
high |
Place first, position is locked |
low |
Place last, most flexible for redistribution |
Examples:
data-margin="top-right-high"— Premium ad pinned to top-rightdata-margin="bottom-low"— Decorative closer at the end, flexibledata-margin="near"— Stay close to where it’s defined (the default)data-margin="left"— Prefer left margin, normal priority
High-priority boxes get first pick of positions and won’t be moved during redistribution. Normal and low-priority boxes may shift slightly to even out spacing in the margins.
When no data-margin is specified, inline boxes (those defined within the
article body) default to near, while boxes injected from elsewhere default
to filling the largest available gaps.
Centering
For centered content (dingbats, decorative breaks, etc.):
<center markdown="1">
{width=50%}
</center>
The markdown="1" attribute enables markdown processing inside the HTML.
Artwork Conventions: Initialisms, Dingbats, and Section Breaks
All monochrome ornamental artwork (initialisms/drop caps, dingbats, tailpieces, section breaks) must be white-on-black: light/white lines on a solid black background, saved as grayscale PNG.
The CSS inverts the image and applies a sepia tint, producing warm dark engravings on the cream page.
AI art prompt guidance
When generating initialisms or dingbats with an AI image generator, include these specifications in the prompt:
- Style: white lines on a solid black background; woodcut, engraving, or linocut aesthetic
- Colour: strictly monochrome grayscale — no colour, no sepia, no warm tones (the CSS applies tinting)
- Background: solid pure black (
#000000), no gradients, no vignetting - Detail: white/light lines for all artwork detail, dark/black for negative space
- Border: if using a decorative border, the border lines should also be white/light on the black ground
- Format: PNG, grayscale colour mode, no transparency
Example prompt fragment:
…in the style of a white-line woodcut engraving, white lines on solid black background, monochrome grayscale, no colour tinting…
Converting existing artwork
If you have dark-on-light artwork that needs converting, composite it onto a white background, convert to grayscale, and invert:
from PIL import Image, ImageOps
img = Image.open("source.png").convert("RGBA")
white = Image.new("RGBA", img.size, (255, 255, 255, 255))
flat = Image.alpha_composite(white, img).convert("L")
ImageOps.invert(flat).save("output.png")
Links
Standard markdown links work as expected:
[visible text](https://example.com)
For internal links to other Almanack articles, use relative paths:
[previous article](/6024/1/1/look-back-up/)
Deep Links (Fragment IDs)
Every paragraph, sidenote, margin box, and figure gets an ID that readers can
link to directly. When someone follows a fragment link, the element highlights
briefly to draw the eye. On desktop, hovering over any of these elements for a
moment reveals a small purple # you can click to copy its URL. The Subject
Index uses these IDs to link each citation to the passage it refers to.
How IDs Are Constructed
| Element | ID Format | Example |
|---|---|---|
| Paragraphs (and list items) | p- + five characters |
#p-k3f9q |
| Footnotes / Sidenotes | fn:name |
#fn:latitude |
| Margin boxes with slug | mb:slug |
#mb:seneca-time |
| Margin boxes in an article, without slug | mb: + five characters |
#mb:4fbts |
| Margin boxes injected by the site, without slug | mb:N |
#mb:1 |
Figures with data-interactive |
fig:name |
#fig:latitude-picker |
| Figures with manual ID | whatever you set | #fig:earth-map |
| Figures without either | fig:N |
#fig:1 |
| Video time | t=time |
#t=1m30s |
| Headings | auto from text | #best-practices |
Footnote IDs come from the footnote name you choose in markdown — [^latitude]
produces #fn:latitude. This works identically whether the reader has
JavaScript (sidenotes in the margin) or not (footnotes at the bottom).
Paragraph IDs
Paragraph IDs are made automatically, and they survive small edits: fixing a typo or rewording a sentence leaves a paragraph’s ID alone, so links to it keep working. Only a new or heavily rewritten paragraph gets a new ID.
To manage this, make sync keeps a file next to each article,
_anchors.yaml, that remembers which ID belongs to which paragraph (as
hashed word fingerprints, so it holds none of the article’s text). Commit
it along with the article; make ed-commit does this for you, and
make verify fails if a regenerated _anchors.yaml hasn’t been committed.
To give a paragraph a permanent ID of your choosing, put it on the line after the paragraph:
The coffin was carried through the snow by the released prisoners.
{: #coffin}
Setting Your Own IDs
Footnotes — choose a descriptive name rather than a number:
The regolith varies by latitude.[^regolith-depth]
[^regolith-depth]: Measurements from the Lunar Reconnaissance Orbiter...
This creates linkable ID #fn:regolith-depth.
Figures — add an id attribute directly, or use data-interactive:
<figure class="figure" id="fig:earth-map" markdown>

<figcaption>Figure 1. The Earth, as seen from above.</figcaption>
</figure>
Or, for interactive figures:
<figure class="figure" data-interactive="latitude-picker" markdown>
...
</figure>
This gets #fig:latitude-picker automatically.
Margin boxes — add a data-slug attribute:
<aside class="margin-box" data-type="poem" data-slug="moon-poem" markdown>
*Moon, looking back*
trepid explorers trundling...
</aside>
This creates #mb:moon-poem. Without a slug, a margin box written in an
article gets an automatic ID like a paragraph’s, which survives small edits.
Linking to Fragments
Link to a specific element within an article:
See the [latitude picker](/6026/1/3/regolith-with-latitude/#fig:latitude-picker)
in our lunar regolith article.
Or within the same article:
As shown in [Figure 1](#fig:earth-map)...
Finding Available IDs
To discover what IDs exist on a page, hover over paragraphs, sidenotes,
margin boxes, and figures — the purple # that appears links to that
element. On touch
devices, long-press to reveal it. You can also inspect the page source or
use your browser’s developer tools.
The Subject Index
The Subject Index (editorial/pages/index/page.md) is compiled by
bin/update-index, which asks a language model to index each article.
The model finds the passage for each citation with a locate tool, so
every citation links to a paragraph, footnote or margin box that exists.
Cross-references (“see: Tcheka”, “see also: Goldman, Emma; Kropotkin,
Peter”) become links to the entry they name when the page is built;
separate targets with semicolons, and name entries exactly.
make idx-status # which articles need indexing
make idx-new # index new and changed articles
bin/update-index --reanchor SLUG # re-point an article's citations
bin/update-index --check # report links that point nowhere
--check also runs as a unit test. If it fails after an article is
heavily rewritten, run --reanchor for that article.
Video Figures
Video figures use the interactive figures runtime. The <figure> gets a
data-interactive="video-player" attribute, and companion elements for
annotations and scenes are placed after it. Three figure modules
(video-player.js, video-annotations.js, video-scenes.js) communicate
via pub/sub capability topics.
Basic Video Figure
<figure data-interactive="video-player" class="figure">
<video controls playsinline preload="none" poster="assets/poster.jpg">
<source src="assets/video-360p.mp4" type="video/mp4" data-label="Standard (360p)" default>
<source src="assets/video-full.mp4" type="video/mp4" data-label="Full Quality" data-size="409MB">
<track kind="metadata" src="assets/annotations.vtt">
<track kind="chapters" src="assets/chapters.vtt">
</video>
<figcaption>Caption text here.</figcaption>
</figure>
<span data-interactive="video-annotations" hidden></span>
<span data-interactive="video-scenes" hidden></span>
<script type="module">
const base = location.origin + '/VOLUME/MONTH/DAY/SLUG/assets/figures';
const { initFigures } = await import('/static/js/figures/runtime.js');
initFigures({ base });
</script>
- Quality switching: Add multiple
<source>elements withdata-labelattributes. A dropdown appears below the video. Mark the default source withdefault. Optionally adddata-sizeto show file sizes. - Poster: Set
poster=to a still frame so the page doesn’t load the video until the reader presses play. - Annotations: Add a
<track kind="metadata">pointing to a WebVTT file. Annotations appear in the margins on desktop or as an overlay on mobile.
Annotation Format (WebVTT)
Annotations are WebVTT files where each cue’s text is a JSON object:
WEBVTT
00:00:25.000 --> 00:00:40.000
{"text": "Banners carried at the head of the procession", "shape": {"type": "rect", "x": 0.3, "y": 0.1, "w": 0.4, "h": 0.6}}
00:01:00.000 --> 00:01:20.000
{"text": "Thousands of mourners follow the coffin"}
Each cue object supports:
| Field | Required | Description |
|---|---|---|
text |
Yes | Annotation text displayed in the margin |
short |
No | Shorter text for mobile overlay (falls back to text) |
shape |
No | SVG overlay shape highlighting a region of the video |
Shape types
Shapes use normalized coordinates (0–1), where (0,0) is the top-left corner of the video and (1,1) is the bottom-right.
| Type | Fields | Example |
|---|---|---|
rect |
x, y, w, h |
{"type": "rect", "x": 0.3, "y": 0.1, "w": 0.4, "h": 0.6} |
circle |
cx, cy, r |
{"type": "circle", "cx": 0.5, "cy": 0.5, "r": 0.2} |
ellipse |
cx, cy, rx, ry |
{"type": "ellipse", "cx": 0.5, "cy": 0.3, "rx": 0.3, "ry": 0.15} |
When a shape is present, a translucent highlight appears over the video and a dashed connector line links it to the annotation in the margin. Clicking either the shape or the annotation text seeks the video to the cue’s start time.
Margin placement
Annotations are injected into the left or right margin depending on the shape’s horizontal position: shapes whose center is in the left half of the video go to the left margin, and vice versa. Cues without shapes alternate between left and right. Each annotation is vertically aligned with its shape’s center (or at roughly 80% of the video height for text-only cues, near where subtitles sit).
Multiple cues can overlap in time — they’ll appear simultaneously.
Time Fragment Links
You can link to a specific moment in a video using the #t= fragment:
https://almanack.blog/6026/2/13/kropotkins-funeral/#t=1m30s
Supported formats:
| Fragment | Meaning |
|---|---|
#t=1m30s |
1 minute, 30 seconds |
#t=30s |
30 seconds |
#t=1m |
1 minute |
#t=1m30.5s |
1 minute, 30.5 seconds |
#t=90 |
90 seconds |
When a reader follows a #t= link, the page scrolls to the video and seeks
to that time. The permalink affordance on video annotations (the purple #)
generates #t= links using the current playback time, so readers can share
links to the exact moment they’re watching.
Within an article, you can link to a video moment like this:
The banners are visible at [1:30 into the film](#t=1m30s).
Code and Preformatted Text
For code or ASCII art, use fenced code blocks:
```
◉◉ △△△△△ △△△△△ △△△△△ △△△△△
◑ ╱╱╱╱╱ ╱╱╱╱╱ ╱╱╱╱╱ △△△△△
```
Best Practices
Density Over Explanation
Assume smart readers. Link to external resources rather than explaining everything.
Footnotes as Escape Valves
When you feel the urge to qualify, defend, or digress — that’s a footnote. Keep the main text flowing; let the margins handle the complexity.
The Archive Gambit
Controversial claim? Feel the urge to throat-clear before you can get to the meat of your article? Attribute what will slow you down to the Archive:
This has been established beyond doubt.[^settled]
[^settled]: See the seventeen-volume *Comprehensive Settlement of This
Exact Question*, R. Buckminster Fuller et al., *Almnck.*{.pub} Vols.
5765–5781.
The Archive has already covered every possible argument. You merely report its conclusions.
Image Placement
Figures work well inside footnotes — they appear in the margins near the relevant text. For images that need more prominence, place them in the main body.
Line Breaks in Verse
For poems and other line-sensitive content, end lines with explicit <br>
tags (see Verse). The margin-box poem type does not preserve
whitespace automatically.
File Organization
editorial/articles/your-article/
├── article.md # Your content
├── assets/
│ ├── figure-1.jpg # Images referenced in the article
│ ├── initial-a.png # Drop cap, if used
│ ├── dingbat.png # Decorative elements
│ ├── _summary.md # RSS summary (not published)
│ └── _source/ # Source files (not published)
│ ├── original-sketch.psd
│ └── reference.pdf
└── editorial/ # Editorial notes (optional)
├── STYLE.md
└── FACT.md
Private Assets
Files and directories in assets/ starting with underscore (_) are not
copied to the website. Use this for:
_summary.md— the chapbook-style RSS summary_source/— original artwork, PSDs, research PDFs, earlier drafts_notes.md— working notes that shouldn’t be published
This keeps source materials version-controlled alongside the article without bloating the published site.
Keep editorial notes separate from the article itself — the primary document should evolve cleanly toward publication.