Skip to content

MatSelectItem does not update selected value #860

@vankampenp

Description

@vankampenp

Describe the bug
When an item is selected in MatSelectItem, it is shown in the mdc-select__selected-text span. When clicking the selected item or the dropdown icon, the dropdown list with all items is displayed.
I have an input field that allows me to change the name of the selected item. This state is changed in a separate span, and in the dropdownlist, but not the in the mdc-select__selected-text span.

To Reproduce
see fiddle

In the fiddle this works properly.
But using .NET 5.0 (latest version) and MatBlazor v2.8.0 it does not update the changed selected value. See the screenshot.
After changing the name to "vegateblesss" it is reflected everywhere, but not in the selected text span. When I click on the dropdown, the new name is shown there.

Blazorfiddle link
https://blazorfiddle.com/s/1ku2nt01

Expected behavior
The fiddle shows the expected behavior.

Screenshots
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    invalidThis doesn't seem right

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions