This documentation is also published as Markdown for efficient machine reading: the whole site is indexed at /llms.txt, and every page has a clean Markdown copy under /_llms/. These are generated from the same source and cost far fewer tokens to read than this rendered HTML.

Skip to main content Skip to navigation

DocSiteOptions Pennington.DocSite

Options record passed to AddDocSite that configures the DocSite template: site chrome, typography, color scheme, content areas, and escape-hatch callbacks for the underlying PenningtonOptions and MonorailCssOptions.

Properties

AdditionalHtmlHeadContent string
Additional raw HTML appended to the document <head> (for analytics, meta tags, etc.).
AdditionalRoutingAssemblies Assembly[]
Additional assemblies scanned for Razor components so out-of-project pages participate in routing.
Areas IReadOnlyList<ContentArea>
Content areas for the documentation site. When empty or containing a single area, no area selector is shown. Each area's slug must match a top-level directory name under ContentRootPath.
BodyFontFamily string
CSS font-family stack used for body copy.
CanonicalBaseUrl string
Absolute base URL used when emitting canonical links, sitemap entries, and absolute feed URLs.
ColorScheme IColorScheme
Color scheme driving the MonorailCSS theme. Defaults to the built-in DocSite palette when null.
ConfigureLocalization Action<LocalizationOptions>
Configure localization options (locales, default locale).
ConfigurePennington Action<PenningtonOptions>
Escape hatch for additional content wiring: callback invoked against the underlying PenningtonOptions after DocSite's own defaults are applied. Use to register extra AddMarkdownContent sources, add highlighters, register islands, etc., without dropping to bare AddPennington.
ContentRootPath FilePath
Root folder (relative to the content project) that holds the markdown and razor content tree.
ContentSelector string
Override the CSS selector used to scope the shared site projection to a page region. The same selector drives the search index, llms.txt sidecars, and build-time link audit, so chrome (navigation, footers) is stripped once. Default is #main-content — the element wrapping the article in the stock DocSite layout. Set to an empty string to project the whole page body, or to a custom selector when you've replaced the layout.
CustomCssFrameworkSettings Func<CssFrameworkSettings, CssFrameworkSettings>
Callback to further customize the MonorailCSS framework settings after the DocSite theme has been applied. Mirrors CustomCssFrameworkSettings.
DisplayFontFamily string
CSS font-family stack used for display type (headings and hero copy).
ExtendProseCustomization Func<ProseCustomization, ProseCustomization>
Wraps the baseline ProseCustomization. Forwarded to ExtendProseCustomization.
ExtraStyles string
Additional CSS appended to the generated stylesheet.
Favicons FaviconOptions
Favicon / icon links. Forwarded to Favicons.
FontPreloads FontPreload[]
Fonts to preload via <link rel="preload"> for faster first paint.
FooterContent MarkupContent?
Content rendered in the site footer. Assign a raw HTML string or a RenderFragment — both convert implicitly. Strings are emitted as raw HTML, not markdown.
GitHubUrl string
URL to the project's GitHub repository. When set, a GitHub link is shown in the header.
HeaderContent MarkupContent?
The header brand area (logo + title). Assign a raw HTML string or a RenderFragment — both convert implicitly. When set, it replaces the default icon and SiteTitle link outright, giving total control over that region; when null, the default document icon and title link render. Strings are emitted as raw HTML, not markdown.
MonoFontFamily string
CSS font-family stack used for monospaced contexts (code blocks, inline code, kbd).
SiteDescription string
required
Short description used in the meta description tag and default OpenGraph description.
SiteTitle string
required
Title displayed in the site chrome and used as a default for OpenGraph tags.
SocialCards SocialCardOptions
Enables generated per-page social cards. When set, each page emits an og:image/ twitter:image pointing at an on-demand-rendered card (and the site-wide SocialImageUrl default steps aside). The host supplies the drawing via Render.
SocialImageUrl string
Default social-share image URL used when a page does not specify its own.
StandardSite StandardSiteOptions
Standard Site (AT Protocol) integration. Forwarded to StandardSite.
Styles Dictionary<string, string>
Per-slot CSS class overrides keyed by StyleKeys constants. Each value is Tailwind-merged over the template's default for that slot — conflicting utilities are replaced, non-conflicting ones kept (dark: variants only conflict with other dark: classes, so override them explicitly). Unknown keys throw at startup. Write values as compile-time string literals — MonorailCSS class discovery scans IL string literals and cannot see runtime-built strings.
SyntaxTheme SyntaxTheme
Syntax-highlight color palette used by .hljs-* token classes. Defaults to Default when null. Values may reference custom palette names registered via ColorScheme.

Pennington.DocSite.DocSiteOptions

namespace Pennington.DocSite;

/// Options record passed to AddDocSite that configures the DocSite template: site chrome, typography, color scheme, content areas, and escape-hatch callbacks for the underlying PenningtonOptions and MonorailCssOptions.
public record DocSiteOptions
{
    /// Additional raw HTML appended to the document <head> (for analytics, meta tags, etc.).
    
public string AdditionalHtmlHeadContent { get; set; }
/// Additional assemblies scanned for Razor components so out-of-project pages participate in routing.
public Assembly[] AdditionalRoutingAssemblies { get; set; }
/// Content areas for the documentation site. When empty or containing a single area, no area selector is shown. Each area's slug must match a top-level directory name under ContentRootPath.
public IReadOnlyList<ContentArea> Areas { get; set; }
/// CSS font-family stack used for body copy.
public string BodyFontFamily { get; set; }
/// Absolute base URL used when emitting canonical links, sitemap entries, and absolute feed URLs.
public string CanonicalBaseUrl { get; set; }
/// Color scheme driving the MonorailCSS theme. Defaults to the built-in DocSite palette when null.
public IColorScheme ColorScheme { get; set; }
/// Configure localization options (locales, default locale).
public Action<LocalizationOptions> ConfigureLocalization { get; set; }
/// Escape hatch for additional content wiring: callback invoked against the underlying PenningtonOptions after DocSite's own defaults are applied. Use to register extra AddMarkdownContent sources, add highlighters, register islands, etc., without dropping to bare AddPennington.
public Action<PenningtonOptions> ConfigurePennington { get; set; }
/// Root folder (relative to the content project) that holds the markdown and razor content tree.
public FilePath ContentRootPath { get; set; }
/// Override the CSS selector used to scope the shared site projection to a page region. The same selector drives the search index, llms.txt sidecars, and build-time link audit, so chrome (navigation, footers) is stripped once. Default is #main-content — the element wrapping the article in the stock DocSite layout. Set to an empty string to project the whole page body, or to a custom selector when you've replaced the layout.
public string ContentSelector { get; set; }
/// Callback to further customize the MonorailCSS framework settings after the DocSite theme has been applied. Mirrors CustomCssFrameworkSettings.
public Func<CssFrameworkSettings, CssFrameworkSettings> CustomCssFrameworkSettings { get; set; }
/// CSS font-family stack used for display type (headings and hero copy).
public string DisplayFontFamily { get; set; }
/// Wraps the baseline ProseCustomization. Forwarded to ExtendProseCustomization.
public Func<ProseCustomization, ProseCustomization> ExtendProseCustomization { get; set; }
/// Additional CSS appended to the generated stylesheet.
public string ExtraStyles { get; set; }
/// Favicon / icon links. Forwarded to Favicons.
public FaviconOptions Favicons { get; set; }
/// Fonts to preload via <link rel="preload"> for faster first paint.
public FontPreload[] FontPreloads { get; set; }
/// Content rendered in the site footer. Assign a raw HTML string or a RenderFragment — both convert implicitly. Strings are emitted as raw HTML, not markdown.
public MarkupContent? FooterContent { get; set; }
/// URL to the project's GitHub repository. When set, a GitHub link is shown in the header.
public string GitHubUrl { get; set; }
/// The header brand area (logo + title). Assign a raw HTML string or a RenderFragment — both convert implicitly. When set, it replaces the default icon and SiteTitle link outright, giving total control over that region; when null, the default document icon and title link render. Strings are emitted as raw HTML, not markdown.
public MarkupContent? HeaderContent { get; set; }
/// CSS font-family stack used for monospaced contexts (code blocks, inline code, kbd).
public string MonoFontFamily { get; set; }
/// Short description used in the meta description tag and default OpenGraph description.
public string SiteDescription { get; set; }
/// Title displayed in the site chrome and used as a default for OpenGraph tags.
public string SiteTitle { get; set; }
/// Enables generated per-page social cards. When set, each page emits an og:image/ twitter:image pointing at an on-demand-rendered card (and the site-wide SocialImageUrl default steps aside). The host supplies the drawing via Render.
public SocialCardOptions SocialCards { get; set; }
/// Default social-share image URL used when a page does not specify its own.
public string SocialImageUrl { get; set; }
/// Standard Site (AT Protocol) integration. Forwarded to StandardSite.
public StandardSiteOptions StandardSite { get; set; }
/// Per-slot CSS class overrides keyed by StyleKeys constants. Each value is Tailwind-merged over the template's default for that slot — conflicting utilities are replaced, non-conflicting ones kept (dark: variants only conflict with other dark: classes, so override them explicitly). Unknown keys throw at startup. Write values as compile-time string literals — MonorailCSS class discovery scans IL string literals and cannot see runtime-built strings.
public Dictionary<string, string> Styles { get; set; }
/// Syntax-highlight color palette used by .hljs-* token classes. Defaults to Default when null. Values may reference custom palette names registered via ColorScheme.
public SyntaxTheme SyntaxTheme { get; set; }
}