MatBlazor - Material Design components for Blazor and Razor Components

MatSelectItem

Selects allow users to select from a single-option menu. It functions as a wrapper around the browser's native select element.

Name Type Description
TValue Generic argument
Attributes Dictionary<String,Object> Gets or sets a collection of additional attributes that will be applied to the created element.
ChildContent RenderFragment Child content of MatSelectItem
Class String Specifies one or more classnames for an DOM element.
Disabled Boolean
Enhanced Boolean
HelperText String
HelperTextPersistent Boolean
HelperTextValidation Boolean
HideDropDownIcon Boolean
Icon String
IconOnClick EventCallback<MouseEventArgs>
Id String
Items IReadOnlyList<TValue>
ItemTemplate RenderFragment<TValue>
Label String
Outlined Boolean
RefBack ForwardRef
Style String Specifies an inline style for an DOM element.
ValidationDisabled Boolean
Value TValue Gets or sets the value of the input. This should be used with two-way binding.
ValueChanged EventCallback<TValue> Gets or sets a callback that updates the bound value.
ValueExpression Expression<Func<TValue>> Gets or sets an expression that identifies the bound value.
Ref ElementReference Returned ElementRef reference for DOM element.
Example MatSelectItem with simple array

  • Grains
  • Vegetables
  • Fruit

Selected value: Grains

Example MatSelectItem with class array and ItemTemplate
  • Grains
  • Vegetables
  • Fruit

Selected value:

Example MatSelectItem with Enum
  • Grains
  • Vegetables
  • Fruit

Selected value: Grains

If you like MatBlazor, please put a star on GitHub.