Skip to content

Configuration Guide ​

Put deck-wide settings in the first YAML block of slides.md (headmatter). Later YAML blocks belong to individual slides. Appearance presets go under themeConfig; fields such as authors, bibFile, fontsize, and themeColors stay at the top level:

yaml
---
theme: scholarly
lang: en
footerMiddle: Conference Name 2026
authors:
  - name: Jane Smith
    institution: MIT
    email: [email protected]
  - name: John Doe
    institution: Stanford
    email: [email protected]
themeConfig:
  colorTheme: classic-blue
  fontTheme: classic
  chromeMode: dark
  sectionMode: dark
---

Essential Options ​

OptionPurposeExample
themeEnable the themescholarly
langTheorem and proof labelsen, zh
aspectRatioSlide dimensions16/9, 4/3 (default: 4/3)
bibFileBibTeX source./references.bib
bibStyleBibliography styleapa, ieee, chicago-author-date

Use author for a single name, or authors for structured multi-author decks:

yaml
authors:
  - name: Jane Smith
    institution: MIT
    email: [email protected]
  - name: John Doe
    institution: Stanford

Footer defaults:

PositionDefault
LeftAuthor name(s)
MiddleEmpty unless footerMiddle is set
RightPage number

Override text with footerLeft, footerMiddle, or footerRight. Use the structured authors array to show names and affiliations on the cover.

Theme Config ​

Use themeConfig to control the deck's appearance and player behavior:

yaml
themeConfig:
  colorTheme: oxford-burgundy
  fontTheme: traditional
  chromeMode: dark
  sectionMode: dark
  beamerNav: false
  outlineToc: true
  outlineTocOpen: false
OptionPurposeDefault
fontThemeFont preset idclassic
beamerNavFooter navigation buttons in play modetrue
outlineTocFooter TOC button and outline panelfalse
outlineTocOpenOpen the outline panel on loadfalse
footnoteDisplayLegacy location; prefer the top-level field described belowboth

Color and surface controls:

OptionControlsDefault
colorThemeBrand palette: primary, accent, paper tone, and base text colorclassic-blue
contentModeSlide background, text, code, tables, and content componentsFollows colorMode, then Slidev dark state
chromeModeHeader, footer, page numbers, navigation, outline, and toolbarsdark
sectionModeDefault appearance for layout: section slidesdark
colorModeLegacy alias for contentModeDeprecated

Notes:

  • Navigation buttons are hidden in overview, embedded, and print/export views.
  • The footer TOC groups slides by layout: section.
  • Long decks switch the TOC to a compact section-first view.
  • Slides with hideInToc: true are hidden from the TOC.
  • Legacy outlineSidebar and outlineSidebarOpen still work; prefer outlineToc and outlineTocOpen for new decks.

Color Surface Modes ​

Use contentMode for body content, chromeMode for headers and controls, and sectionMode for chapter dividers. If contentMode is unset, content follows Slidev's light/dark state, subject to the legacy colorMode fallback.

yaml
colorSchema: both
themeConfig:
  colorTheme: high-contrast
  contentMode: light
  chromeMode: dark
  sectionMode: dark

See Theme Mode and Contrast for supported values, precedence, and per-slide section overrides. For custom palette values, use top-level themeColors.

Theorem Numbering ​

Customize automatic theorem numbers:

yaml
theoremNumberFormat: '({number})'

Choose one format:

FormatOutput
'{number}'1, 2, 3
'({number})'(1), (2), (3)
'[{number}]'[1], [2], [3]
'{number}.'1., 2., 3.

Use the number prop for one manual number, or :autoNumber="false" for an unnumbered statement.

Font Sizes ​

Set global font sizes:

yaml
fontsize:
  body: 18px
  h1: 48px
  h2: 36px
  h3: 28px

Override on one slide:

markdown
---
fontsize:
  body: 20px
  h1: 50px
---

# Custom Sized Slide

Values can use px, rem, or em; plain numbers are treated as pixels. Per-slide settings take precedence over the global settings.

For cover-only typography, use scoped CSS on the cover slide:

markdown
<style>
.slidev-layout.cover h1 {
  font-size: 64px;
}
</style>

Footnotes ​

Set a global footnote display mode:

yaml
footnoteDisplay: hover-only

Override one slide:

markdown
---
footnoteDisplay: notes-only
---

Priority order:

  1. Per-slide footnoteDisplay
  2. Global headmatter footnoteDisplay
  3. Legacy themeConfig.footnoteDisplay
  4. Default both

Modes:

ModeBehavior
bothBottom notes plus inline hover/click preview
hover-onlyInline preview only
notes-onlyBottom notes only

Per-Slide Metadata ​

Set title, subtitle, layout options, or local overrides in slide frontmatter:

markdown
---
layout: figure
title: Model Overview
subtitle: Encoder and adapter path
hideInToc: true
---

Use Layouts and Components for page-specific props and examples.