RayCraftDocs
v1.0.3 raycraft.dev
On this page

DataFilter

Complete

Builds a filter from conditions (field, operator, value) and returns it as a predicate, so it works with any list and with DataGrid items. Operators fit the field kind: text, number, date or boolean.

Example

DataFilter control

Parameters

ParameterTypeDescription
ClassstringExtra CSS classes added to the root element.
ConditionsIReadOnlyList<FilterCondition>The conditions. Use with @bind-Conditions.
FieldsIEnumerable<DataFilterField<TItem>>DataFilterField(id, title, value, kind) items.
LabelstringVisible label text (charts: accessible name; IconButton: accessible name and tooltip).
MatchAllboolTrue when every condition must match, false when one is enough.
StylestringInline style added to the root element.

Events

EventTypeDescription
ConditionsChangedEventCallback<IReadOnlyList<FilterCondition>>Raised when a condition is added, changed or removed.
MatchAllChangedEventCallback<bool>Raised when the combination changes.
PredicateChangedEventCallback<Func<TItem, bool>>Raised with a Func that tests an item against the conditions.

Package

DataFilter is part of RayCraft Complete. Package: RayCraft.Blazor.Complete. It comes from the private RayCraft feed and needs an active license. See Getting started.