Back link

Page chrome: one step back to the index.

The "back to the index" affordance at the top of a detail page. Pagechrome, not a content band — and that distinction is the entire reason it is its own component.

Inside the old detail blocks it was the first child of a flex column with a section-sized gap, so it inherited spacing it had no business carrying, and both pages corrected for it the same way:margin-block-end: calc(var(--space-l) - var(--space-2xl)). That reads as arithmetic against a value the element cannot see. Hoisted above the section flow there is no gap to fight and no correction to make — the host sets the space it wants, like any other chrome (ADR 0012).

It renders a <nav> named by its own label, so the link is findable as a landmark rather than being one stray anchor above the content. The anchor declares text-decoration: none, which is how it opts out of the base layer's underline swell — chrome does, prose does not (ADR 0034). It is also the smallest worked example of the:global() rule, because Link is style-less.

Above a page

Tone

Props

packages/primitives/src/BackLink.astro
PropTypeRequired
hrefstringyes
labelstringyes
classstring