BlazorFluentUI
BlazorFluentUI copied to clipboard
Dropdown popup list not shown in correct position when >18 Options added
If you have a Dropdown component with more than 18 DropdownOption items in, the popup window is not placed in the correct position.
Using BlazorServer, and package version 5.5.3
@page "/dropdownissue"
<Stack>
<Dropdown Label="My Dropdown"
ItemsSource=@items
DropdownHeight="300"
@bind-SelectedOption=@selectedItem
Style="width:300px"/>
</Stack>
@code {
List<IDropdownOption>? items;
IDropdownOption? selectedItem;
protected override void OnInitialized()
{
items = new List<IDropdownOption>();
for (int i = 0; i < 19; i++)
{
items.Add(new DropdownOption { Key = i.ToString(), Text = i.ToString() });
};
selectedItem = items.First(i => i.Key == "1");
base.OnInitialized();
}
}