Home

Site Layout Components

Named component definitions for reuse

Define components once and reference them by name in regions. When the key matches a built-in component type (e.g., "nav-tree"), the type field can be omitted.

Example:

# Type inferred from key for built-in types:
[site.layout.components.nav-tree]
collapsible = true
depth = 3

# Custom names require explicit type:
[site.layout.components.main-nav]
type = "nav-tree"
collapsible = true

Available Types

TypeDescription
logoSite logo image with responsive and dark mode variants
titleSite title text
breadcrumbsBreadcrumb navigation trail
nav-treeHierarchical navigation tree
nav-menuTop-level navigation menu bar
nav-groupsFooter-style grouped navigation
toc-treeTable of contents tree from document headings
prev-nextPrevious/next page navigation links
color-modeLight/dark mode toggle
copyrightCopyright notice with auto-updating year
social-linksSocial/external links (GitHub, Discord, LinkedIn, etc.)
edit-sourceEdit source link for GitHub/GitLab/Bitbucket
edit-onEdit on cloud service (Google Docs or Microsoft 365)
copy-markdownCopy page as Markdown button
site-searchSite search

This documentation was generated from layout/components.rs by generate.rs.

© 2026 Stencila