Class RowStylePattern
- Namespace
- BlazOrbit.Components
- Assembly
- BlazOrbit.dll
Defines a styling pattern for rows (DataGrid) or cards (DataCards). CSS-expressible patterns set container-level variables once; custom patterns compute per-item.
public abstract class RowStylePattern
- Inheritance
-
objectRowStylePattern
Constructors
RowStylePattern()
protected RowStylePattern()
Methods
All(string)
Creates a pattern that applies a background color to all rows.
public static RowStylePattern All(string backgroundColor)
Parameters
backgroundColorstringThe background color for all rows.
Returns
- RowStylePattern
A RowStylePattern that applies to all rows.
Alternating(string?, string?)
Creates an alternating row style pattern.
public static RowStylePattern Alternating(string? evenBackground = null, string? oddBackground = null)
Parameters
evenBackgroundstringThe background color for even rows.
oddBackgroundstringThe background color for odd rows.
Returns
- RowStylePattern
A RowStylePattern that alternates row backgrounds.
Custom(Func<int, RowStyle?>)
Creates a custom row style pattern using the specified selector function.
public static RowStylePattern Custom(Func<int, RowStyle?> selector)
Parameters
Returns
- RowStylePattern
A RowStylePattern that uses custom logic.
EveryNth(int, string)
Creates a pattern that highlights every Nth row.
public static RowStylePattern EveryNth(int n, string backgroundColor)
Parameters
nintThe interval at which rows are highlighted.
backgroundColorstringThe background color for highlighted rows.
Returns
- RowStylePattern
A RowStylePattern that highlights every Nth row.