Skip to content

bug(Select): Select with IsVirtualize defaults display text to .Value parameter #6503

@EliasIsmail

Description

@EliasIsmail

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

I am using the Select component like this:

<Select IsVirtualize="true" ShowSearch="true" IsPopover="true" Items="Items" @bind-Value="_selectedItem"

I just updated from version 9.3.0 to 9.8.2. In 9.3.0, the selected value in the Select component (before clicking it so the Popover appears), was showing the .Text parameter of the selected item. Now, the .Value parameter is showing instead. This seems to only be the case for when "IsVirtualize" is set to true.

Example:

<Select IsVirtualize="true" ShowSearch="true" IsPopover="true" Items="Items" @bind-Value="_selectedItem"

var Items= new List<SelectedItem>() { new() { Text = "Display Text", Value = "Value"}}

Image

Expected Behavior

That the Select component, when not toggled, also shows the .Text parameter of the selected item, and not the .Value parameter

Interactive render mode

Interactive Server (Interactive server-side rendering (interactive SSR) using Blazor Server)

Steps To Reproduce

  1. Create Select component with IsVirtualize = "true", and 1+ items
  2. Select an item
  3. View the default value shown in the Select

Exceptions (if any)

No response

.NET Version

NET9.0

Anything else?

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions