Basic Usage
Use two-way binding @bind-Toggle="..."
to update a value in the parent component.
Alarm is Off
<MudToggleIconButton @bind-Toggled="AlarmOn" Icon="@Icons.Material.Filled.AlarmOff" Color="@Color.Error" ToggledIcon="@Icons.Material.Filled.AlarmOn" ToggledColor="@Color.Success" title="@(AlarmOn ? "On" : "Off")" /> <span>Alarm is @(AlarmOn ? "On" : "Off")</span>
@code { public bool AlarmOn { get; set; } }