Class HeaderCell<T>
- Namespace
- MudBlazor
- Assembly
- MudBlazor.dll
Represents a cell displayed at the top of a MudDataGrid<T> column.
public class HeaderCell<T> : MudComponentBase, IComponent, IHandleEvent, IHandleAfterRender, IMudStateHasChanged, IDisposable
Type Parameters
T
The kind of item managed by the grid.
- Inheritance
-
HeaderCell<T>
- Implements
- Inherited Members
- Extension Methods
Constructors
HeaderCell()
public HeaderCell()
Properties
ChildContent
The content within this header cell.
[Parameter]
public RenderFragment ChildContent { get; set; }
Property Value
Column
The column associated with this header cell.
[Parameter]
public Column<T> Column { get; set; }
Property Value
- Column<T>
DataGrid
The MudDataGrid<T> which contains this header cell.
[CascadingParameter]
public MudDataGrid<T> DataGrid { get; set; }
Property Value
- MudDataGrid<T>
IsOnlyHeader
Shows this cell only in the header area.
[CascadingParameter(Name = "IsOnlyHeader")]
public bool IsOnlyHeader { get; set; }
Property Value
Remarks
Defaults to false
. When true
, the header cell display in the header area and will not display cells with data like a normal column. This property is set automatically when adding a header to the grid manually.
SortDirection
The direction to sort values in this column.
[Parameter]
public SortDirection SortDirection { get; set; }
Property Value
Remarks
Defaults to None.
Width
The width for this header cell, in pixels.
public double? Width { get; }
Property Value
Remarks
Defaults to null
.
Methods
BuildRenderTree(RenderTreeBuilder)
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
__builder
RenderTreeBuilder
Dispose()
Releases resources used by this header cell.
public void Dispose()
OnInitializedAsync()
protected override Task OnInitializedAsync()
Returns
OnParametersSetAsync()
protected override Task OnParametersSetAsync()
Returns
See Also
MudDataGrid<T>