This site provides a machine-readable index at /llms.txt.

Skip to main content Skip to navigation

NamedColorScheme Pennington.MonorailCss

A color scheme that uses named Tailwind colors.

Properties

AccentColorName Pennington.MonorailCss.ColorName
required
Gets or sets the color name to map to "accent".
AdditionalMappings System.Collections.Generic.Dictionary<string, Pennington.MonorailCss.ColorName>
Default: []
Gets or sets additional color mappings beyond the core slots. Key is the target slot name (e.g., "info", "warning"), value is the source color.
BaseColorName Pennington.MonorailCss.ColorName
required
Gets or sets the color name to map to "base".
PrimaryColorName Pennington.MonorailCss.ColorName
required
Gets or sets the color name to map to "primary".

Methods

ApplyToTheme

#
public Theme ApplyToTheme(Theme theme);

Applies the color scheme to the given theme.

Parameters

theme Theme
The theme to apply colors to

Returns

Theme

Pennington.MonorailCss.NamedColorScheme

namespace Pennington.MonorailCss;

/// A color scheme that uses named Tailwind colors.
public class NamedColorScheme
{
    /// Gets or sets the color name to map to "accent".
    
public required ColorName AccentColorName { get; init; }
/// Gets or sets additional color mappings beyond the core slots. Key is the target slot name (e.g., "info", "warning"), value is the source color.
public Dictionary<string, ColorName> AdditionalMappings { get; init; } = [];
/// Applies the color scheme to the given theme.
public Theme ApplyToTheme(Theme theme);
/// Gets or sets the color name to map to "base".
public required ColorName BaseColorName { get; init; }
/// Gets or sets the color name to map to "primary".
public required ColorName PrimaryColorName { get; init; }
}