Use the strict mode to allow only valid selections

This commit is contained in:
Thorsten Sommer 2024-07-27 12:19:59 +02:00
parent eb31759f67
commit 1d5e4542c8
Signed by: tsommer
GPG Key ID: 371BBA77A02C0108

View File

@ -1,7 +1,7 @@
@inherits ConfigurationBase @inherits ConfigurationBase
@typeparam T @typeparam T
<MudSelect T="T" Value="@this.SelectedValue()" Margin="Margin.Dense" Label="@this.OptionDescription" Class="@GetClass" Variant="Variant.Outlined" HelperText="@this.OptionHelp" ValueChanged="selectedValue => this.OptionChanged(selectedValue)"> <MudSelect T="T" Value="@this.SelectedValue()" Strict="@true" Margin="Margin.Dense" Label="@this.OptionDescription" Class="@GetClass" Variant="Variant.Outlined" HelperText="@this.OptionHelp" ValueChanged="selectedValue => this.OptionChanged(selectedValue)">
@foreach (var data in this.Data) @foreach (var data in this.Data)
{ {
<MudSelectItem Value="@data.Value"> <MudSelectItem Value="@data.Value">