Skip to main content
All docs
V25.1
  • DxThemeFluent Class

    Defines a Fluent theme for DevExpress Blazor UI controls.

    Namespace: DevExpress.Blazor

    Assembly: DevExpress.Blazor.v25.1.dll

    NuGet Package: DevExpress.Blazor

    Declaration

    public class DxThemeFluent :
        DxThemeBase<ThemeFluentProperties>

    Remarks

    Use DxThemeFluent API members to obtain information about a Fluent theme. These APIs include:

    Name
    Returns the theme name that serves as a unique theme identifier.
    Mode
    Returns the theme mode (light or dark).
    AccentColor | GetCustomAccentColor()
    Return the built-in or custom accent color applied to the theme.
    GetFilePaths()
    Returns theme stylesheet paths.
    GetStyles()
    Returns <style> element content in HTML format. Required for themes that implement custom accent colors.
    UseBootstrapStyles
    Returns a Boolean value that specifies whether a theme includes Bootstrap stylesheets (v5). Available in v25.1.4+.
    ApplyToPageElements
    Returns a Boolean value that specifies whether a theme includes styles for non-DevExpress elements (hyperlinks, inputs, headings, browser scroll bars, etc.).

    You can also call the DxThemeFluent.Clone() method to clone the built-in Fluent Light Blue theme and modify it as needed.

    The following code snippet creates a Fluent Dark Purple theme using predefined theme mode and accent color. The theme does not include styles for non-DevExpress (page) elements:

    <head>
        @*...*@
        @DxResourceManager.RegisterTheme(Themes.Fluent.Clone(properties => {
            properties.Name = "Fluent Dark Purple";
            properties.Mode = ThemeMode.Dark;
            properties.AccentColor = ThemeFluentAccentColor.Purple;
            properties.ApplyToPageElements = false;
        }))
    </head>
    

    Implements

    Inheritance

    See Also