ChartLegendTitle
Configures the title displayed above or below legend items in ChartLegend. Use this component to provide descriptive text that explains what the legend represents, such as "Data Series", "Categories", or "Metrics". Legend titles improve chart accessibility and comprehension by clearly labeling the legend content and establishing visual hierarchy within the chart layout. Children: ChartLegendTitleBorder, ChartLegendTitleMargin, ChartLegendTitlePadding.
Definition
Namespace:Telerik.Blazor.Components
Assembly:Telerik.Blazor.dll
Syntax:
public class ChartLegendTitle : DataVizChildComponent, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
Inheritance: objectComponentBaseDataVizChildComponentChartLegendTitle
Implements:
Inherited Members
Constructors
public ChartLegendTitle()
Methods
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Overrides:
protected override void OnInitialized()
Overrides:
protected override void OnParametersSet()
Overrides:
Properties
Controls the horizontal alignment of the legend title using ChartLegendTitleAlign values. Choose Left to align the title to the left edge of the legend, Right to align it to the right edge, or Center to center it within the legend. This affects the overall legend layout and visual balance.
[Parameter]
public ChartLegendTitleAlign? Align { get; set; }
Sets the background color behind the legend title. Accepts any valid CSS color including hex codes (#F8F9FA), RGB values (rgb(248,249,250)), named colors (whitesmoke), or HSL values. Use background colors to improve title readability against complex legend backgrounds or to create visual emphasis for important legend information.
[Parameter]
public string Background { get; set; }
[Parameter]
public RenderFragment ChildContent { get; set; }
Sets the text color of the legend title. Accepts any valid CSS color including hex codes (#212529), RGB values (rgb(33,37,41)), named colors (darkslategray), or HSL values. Choose colors that provide good contrast with the Background and legend theme for optimal readability and professional appearance.
[Parameter]
public string Color { get; set; }
Defines the font styling for the legend title using CSS font notation. Specify properties like size, weight, and family in a single string, for example: "bold 16px Arial", "italic 14px 'Times New Roman'", or "normal 18px sans-serif". Title fonts are typically larger and bolder than legend labels to establish clear visual hierarchy.
[Parameter]
public string Font { get; set; }
Controls the positioning of the legend title relative to legend items using ChartLegendTitlePosition values. Determines whether the title appears above (Top) or below (Bottom) the legend items. This affects the legend's visual hierarchy and reading flow for users.
[Parameter]
public ChartLegendTitlePosition? Position { get; set; }
Specifies the text content displayed as the legend title. Use descriptive text that explains what the legend represents, such as "Data Series", "Categories", "Metrics", or any contextual information that helps users understand the legend content. Clear, informative titles improve chart accessibility and comprehension.
[Parameter]
public string Text { get; set; }
Controls whether the legend title is displayed. Set to true (default) to show the title with its descriptive text, or false to hide it for cleaner legend appearance. Visible titles improve legend comprehension by providing context about what the legend items represent.
[Parameter]
public bool? Visible { get; set; }