ToolStripStatusLabel
Description
This component represents a status label within a StatusStrip
in Blazor using the Gap.Blazor.ToolStripStatusLabel
model. It renders a styled label inside a Telerik ToolBarTemplateItem
, supports tooltip display, click interaction, and dynamic layout behavior such as spring and auto size.
Usage
<WMStyleBase model=@toolStripStatusLabel></WMStyleBase>
<ToolBarTemplateItem class="spring-active">
<label class="@(toolStripStatusLabel.GetStringClasses() + " " + toolStripStatusLabel.GetToolTipClass() + " BorderStyle")"
title="@toolStripStatusLabel.ToolTipText"
onclick="@toolStripItemClick">
@toolStripStatusLabel.Text
</label>
</ToolBarTemplateItem>
<WMToolStripStatusLabel3DBorderStyle ToolStripStatusLabel="@this.toolStripStatusLabel" />
Properties
toolStripStatusLabel: Instance of the
Gap.Blazor.ToolStripStatusLabel
model.Text: The label text displayed in the status strip.
ToolTipText: Tooltip shown on hover.
Spring: If
true
, the label expands to fill available space.AutoSize: If
true
, the label width is set to 100%; otherwise, it uses a fixed width.TextAlign: Determines the horizontal alignment of the label content.
Methods
toolStripItemClick(MouseEventArgs): Invokes the
PerformClick()
method on the model when the label is clicked.
Dynamic Rendering
ToolBarTemplateItem: Used to render the label inside a Telerik
ToolBar
.Label Styling: Combines model-based classes with tooltip and border styling.
WMToolStripStatusLabel3DBorderStyle: Renders additional 3D border effects based on the model.
Styles
[email protected]() {
position: relative;
text-align: [based on TextAlign];
width: [100% if AutoSize, else fixed width];
}
[email protected]() .k-toolbar-item {
width: [100% if Spring, else fit-content];
display: contents;
}
Events
Click: Triggered when the label is clicked, invoking the model’s
PerformClick()
method.
Last updated