Library Blazor Components ProportionalBar Reference ProportionalBar Items

Items

List of values in form of tuples. A Color (any html color) and Value should be provided as a list of items.

razor
[Parameter]
public List<(string Color, double Value)>? Items { get; set; }

Example

razor
<ProportionalBar Items="_colors" />

@code {
    private List<(string Color, double Value)> _colors = [
        ("green", 15),
        ("blue", 13),
        ("gold", 12),
        ("red", 17)
    ];
}

Sign in