Typeahead
Typeahead copied to clipboard
[Question] Is there a way to programmatically select multiple items?
I search for a Solution to programmatically select multiple items with an parameter eg. in AfterRender.
Change the IList
<BlazoredTypeahead SearchMethod="SearchEvents"
@bind-Values="SelectedPeople"
EnableDropDown="true"
placeholder="Suche Mail oder Name...">
<SelectedTemplate Context="EmailsUsers">
📧 @EmailsUsers.emailAdd
</SelectedTemplate>
<HelpTemplate>
Mindestens 2 Zeichen zur Suche eingeben.
</HelpTemplate>
<ResultTemplate Context="EmailsUsers">
<div style="font-weight: 300;"> 📧 @EmailsUsers.emailAdd</div>
<div style="font-size: xx-small;">@EmailsUsers.name </div>
</ResultTemplate>
</BlazoredTypeahead>
I do this with TypeAhead, by maintaining a separate List that's added to in the "ValueChanged" event, I then render these items below the TypeAhead as the selected items, with a option to remove from the list
So ends up looking like this
