A tree whose nodes are table rows. Expand and collapse, sort, filter and choose columns; the keyboard follows the WAI-ARIA treegrid pattern.
Example
Parameters
API
Parameter
Type
Description
ChildrenSelector
Func<TItem, IEnumerable<TItem>>
Returns the children of an item. Items without children are leaves.
Class
string
Extra CSS classes added to the root element.
Columns
RenderFragment
Column definitions: DataGridColumn elements.
Dense
bool
Uses tighter cell padding.
ExpandAll
bool
Expands every node when the tree first appears.
ExportFileName
string
File name of the CSV export, without the extension.
Height
string
Maximum height of the grid body, for example 24rem (default 28rem with VirtualScroll).
Items
IEnumerable<TItem>
The options to choose from.
Label
string
Visible label text (charts: accessible name; IconButton: accessible name and tooltip).
RowEditing
bool
Edits a whole row at once with edit, save and cancel buttons.
RowHeight
int
Row height in pixels when VirtualScroll is on (default 44).
SelectedItem
TItem
Selected node. Use with @bind-SelectedItem.
ShowExport
bool
Adds buttons that save the chart as a PNG or SVG image.
ShowFilters
bool
Shows a filter box under each filterable column header.
ShowToolbar
bool
Shows the toolbar with the column chooser and CSV export.
Style
string
Inline style added to the root element.
VirtualScroll
bool
Draws only the visible rows (rows must have the fixed RowHeight).
TreeListColumn
Parameter
Type
Description
Align
TextAlign
Left (default), Center or Right.
Editable
bool
Lets users edit the cells of the column by clicking them.
Filterable
bool
Shows a filter box for this column (default true).
Format
string
Format string for numbers and dates, e.g. N0 or d.
Hidden
bool
Hides the column at first; users can show it from the toolbar.
Sortable
bool
Allows sorting by this column (default true).
Template
RenderFragment<TItem>
Title
string
Title text (drawer header, tab caption, column header, step caption).
Value
Func<TItem, Object>
Current value. Use with @bind-Value.
Width
string
Skeleton: any CSS length. Charts: drawing width in SVG units (the chart still scales to its container).
Events
API
Event
Type
Description
OnRowEdited
EventCallback<TItem>
Raised after a row was saved, with the item.
SelectedItemChanged
EventCallback<TItem>
Raised when another node is selected.
TreeListColumn
Event
Type
Description
Edited
EventCallback<TreeListEdit<TItem>>
Raised with the item and the new text when an edit is confirmed.
Package
TreeList is part of RayCraft Complete. Package: RayCraft.Blazor.Complete. It comes from the private RayCraft feed and needs an active license. See Getting started.