Class ThemeService
- Namespace
- Radzen
- Assembly
- Radzen.Blazor.dll
Service for theme registration and management.
public class ThemeService
- Inheritance
-
ThemeService
- Inherited Members
Constructors
ThemeService()
public ThemeService()
Properties
RightToLeft
Specify if the theme should be right-to-left.
public bool? RightToLeft { get; }
Property Value
- bool?
Theme
Gets the current theme.
public string Theme { get; }
Property Value
Wcag
Specify if the theme colors should meet WCAG contrast requirements.
public bool? Wcag { get; }
Property Value
- bool?
Methods
SetRightToLeft(bool)
Specifies if the theme should be right-to-left.
public void SetRightToLeft(bool rightToLeft)
Parameters
rightToLeft
bool
SetTheme(ThemeOptions)
Changes the current theme with additional options.
public void SetTheme(ThemeOptions options)
Parameters
options
ThemeOptions
SetTheme(string, bool)
Changes the current theme.
public void SetTheme(string theme, bool triggerChange = true)
Parameters
SetWcag(bool)
Enables or disables WCAG contrast requirements.
public void SetWcag(bool wcag)
Parameters
wcag
bool
Events
ThemeChanged
Raised when the theme changes.
public event Action ThemeChanged