feat(config): add global nav.toc setting with frontmatter override
- Add toc: bool to [nav] config section (default: false) - Frontmatter toc: true/false overrides global config - If frontmatter toc is not specified, falls back to config.nav.toc - Enable nav.toc = true in docs/site.toml for global TOC
This commit is contained in:
@@ -28,6 +28,9 @@ pub struct SiteConfig {
|
||||
pub struct NavConfig {
|
||||
/// Whether to display nested navigation (default: false).
|
||||
pub nested: bool,
|
||||
/// Enable table of contents (anchor nav) globally (default: false).
|
||||
/// Can be overridden per-page via frontmatter toc field.
|
||||
pub toc: bool,
|
||||
}
|
||||
|
||||
/// Path configuration with sensible defaults.
|
||||
|
||||
Reference in New Issue
Block a user