MarkUP GitHub

Component reference

Every component below is available in any MarkUP document. Plugins can add more.

Callouts

note

Note callout — useful information that readers should know, even when skimming.

Syntax: :::note

Label (optional): Custom title. Defaults to “Note”.

AttributeTypeDefaultDescription
collapsibleboolean—Render the callout collapsed behind its title.
:::note
The body is regular **MarkUP**.
:::

tip

Tip callout — helpful advice for doing things better or more easily.

Syntax: :::tip

Label (optional): Custom title. Defaults to “Tip”.

AttributeTypeDefaultDescription
collapsibleboolean—Render the callout collapsed behind its title.
:::tip
The body is regular **MarkUP**.
:::

important

Important callout — key information readers need to achieve their goal.

Syntax: :::important

Label (optional): Custom title. Defaults to “Important”.

AttributeTypeDefaultDescription
collapsibleboolean—Render the callout collapsed behind its title.
:::important
The body is regular **MarkUP**.
:::

warning

Warning callout — urgent information that needs immediate attention to avoid problems.

Syntax: :::warning

Label (optional): Custom title. Defaults to “Warning”.

AttributeTypeDefaultDescription
collapsibleboolean—Render the callout collapsed behind its title.
:::warning
The body is regular **MarkUP**.
:::

caution

Caution callout — advises about risks or negative outcomes of certain actions.

Syntax: :::caution

Label (optional): Custom title. Defaults to “Caution”.

AttributeTypeDefaultDescription
collapsibleboolean—Render the callout collapsed behind its title.
:::caution
The body is regular **MarkUP**.
:::

Layout

card

A bordered surface that groups related content. Several cards in a row inside columns make a grid.

Syntax: :::card

Label (optional): Card title.

AttributeTypeDefaultDescription
hrefstring—Makes the title a link.
iconstring—A short symbol shown before the title.
:::card[Installation]{href=installation.md}
MarkUP needs Node.js 22.12 or newer.
:::

Installation

MarkUP needs Node.js 22.12 or newer.

columns

Lays out its column children side by side. Columns stack on narrow screens.

Syntax: :::columns

AttributeTypeDefaultDescription
gap"none" | "small" | "medium" | "large"mediumSpace between columns.
align"start" | "center" | "end" | "stretch"stretchVertical alignment of the columns.

May only contain column.

::::columns
:::column
Left
:::
:::column
Right
:::
::::

Left

Right

column

One column of a columns layout.

Syntax: :::column

AttributeTypeDefaultDescription
spaninteger (1–12)1Relative width compared to sibling columns.

Must be placed directly inside columns.

tabs

A set of tabbed panels. Each panel is a tab child; works without JavaScript.

Syntax: :::tabs

May only contain tab.

::::tabs
:::tab[Command]
```sh
markup build docs --out site
```
:::
:::tab[Configuration]
```json
{ "out": "site" }
```
:::
::::
markup build docs --out site
{ "out": "site" }

tab

One panel of a tabs group. The label is the tab title.

Syntax: :::tab

Label (required): Tab title.

AttributeTypeDefaultDescription
selectedboolean—Select this tab initially instead of the first one.

Must be placed directly inside tabs.

Content

details

A collapsible section. The label is the always-visible summary.

Syntax: :::details

Label (optional): Summary text. Defaults to “Details”.

AttributeTypeDefaultDescription
openboolean—Start expanded.
:::details[How does it work?]
The body is hidden until the reader expands it.
:::
How does it work?

The body is hidden until the reader expands it.

figure

Self-contained content — usually an image, diagram or code — with an optional caption.

Syntax: :::figure

Label (optional): Caption.

AttributeTypeDefaultDescription
align"left" | "center" | "right"centerHorizontal alignment.
:::figure[Building a folder]
```sh
markup build docs --out site
```
:::
markup build docs --out site
Building a folder

progress

A progress bar. Use it as a block (::progress) or inline (:progress).

Syntax: ::progress, :progress

Label (optional): Text shown next to the bar.

AttributeTypeDefaultDescription
valuenumberrequiredCurrent value.
maxnumber (≥ 0)100Value that represents completion.
variant"default" | "success" | "warning" | "danger"defaultColour.
::progress[Translation]{value=72}
Translation72%

Data

chart

A chart rendered to static SVG. The body is MarkUP Data: either data (one series of label: value pairs) or labels plus series.

Syntax: :::chart · body: MarkUP Data

Label (optional): Chart title (same as the title key).

AttributeTypeDefaultDescription
type"bar" | "line" | "area" | "pie" | "donut"barKind of chart.
titlestring—Title shown above the chart.
unitstring—Unit appended to values, e.g. % or ms.
heightnumber (120–1200)280Height in pixels.
stackedboolean—Stack series instead of grouping them (bar and area).
legendboolean—Show the legend. Defaults to true when there are several series.

Single series

:::chart
type: bar
title: Favourite languages
data:
  Python: 80
  JavaScript: 60
  Rust: 40
:::
Favourite languages
Favourite languages020406080PythonJavaScriptRustPython — Favourite languages: 80JavaScript — Favourite languages: 60Rust — Favourite languages: 40
Favourite languages
Python80
JavaScript60
Rust40

Several series

:::chart{type=line unit=k}
labels: [Q1, Q2, Q3, Q4]
series:
  - name: 2025
    values: [12, 18, 15, 24]
  - name: 2026
    values: [16, 22, 27, 31]
:::
line chart0k10k20k30k40kQ1Q2Q3Q4Q1 — 2025: 12kQ2 — 2025: 18kQ3 — 2025: 15kQ4 — 2025: 24kQ1 — 2026: 16kQ2 — 2026: 22kQ3 — 2026: 27kQ4 — 2026: 31k
  • 2025
  • 2026
20252026
Q112k16k
Q218k22k
Q315k27k
Q424k31k

Pie chart

:::chart{type=pie}
title: Time spent
data:
  Writing: 50
  Review: 30
  Meetings: 20
:::
Time spent
Time spentWriting: 50 (50.0%)Review: 30 (30.0%)Meetings: 20 (20.0%)
  • Writing
  • Review
  • Meetings
Time spent
Writing50
Review30
Meetings20

toc

A table of contents generated from the document’s headings.

Syntax: ::toc

Label (optional): Title shown above the list.

AttributeTypeDefaultDescription
depthinteger (1–6)3Deepest heading level to include.
frominteger (1–6)2Shallowest heading level to include.
::toc[On this page]{depth=3}

Inline

badge

A small status label.

Syntax: :badge

Label (required): Badge text.

AttributeTypeDefaultDescription
variant"neutral" | "info" | "success" | "warning" | "danger"neutralColour.
Status: :badge[stable]{variant=success}

Status: stable

kbd

A keyboard shortcut. Keys separated by + are rendered individually.

Syntax: :kbd

Label (required): Keys, e.g. Ctrl+Shift+P.

Press :kbd[Ctrl+S] to save.

Press Ctrl+S to save.

abbr

An abbreviation with its expansion shown on hover.

Syntax: :abbr

Label (required): The abbreviation.

AttributeTypeDefaultDescription
titlestringrequiredThe expanded form.
:abbr[AST]{title="Abstract syntax tree"}

AST

u

Underlined text. Markdown has no underline syntax, so it is a component. The label can contain other formatting, e.g. :u[**bold**].

Syntax: :u

Label (required): The text to underline.

Sign the form :u[before] Friday.

Sign the form before Friday.