Class TelerikDropDownList<TItem, TValue>
The class for the DropDownList component.
Inheritance
Inherited Members
Namespace: Telerik.Blazor.Components
Assembly: Telerik.Blazor.dll
Syntax
public class TelerikDropDownList<TItem, TValue> : TelerikSelectBase<TItem, TValue>, IDisposable, IPopupContainer, ILabelableInput
Type Parameters
TItem
Type of the model if you cannot provide a Value. |
TValue
Type of the Value if you cannot provide a reference to it. |
Constructors
TelerikDropDownList()
Declaration
public TelerikDropDownList()
Properties
DefaultText
Creates a default item to be shown when no value is selected. The value is set to default(TValue).
Declaration
public string DefaultText { get; set; }
Property Value
System.String
|
DropDownListSettings
Defines a renderfragment that contains all settings for the autocomplete. DropDownListPopupSettings.
Declaration
public RenderFragment DropDownListSettings { get; set; }
Property Value
Microsoft.AspNetCore.Components.RenderFragment
|
FilterDebounceDelay
Time in ms between the last typed symbol and the firing of the internal filter oninput event. Default is 150ms.
Declaration
public int FilterDebounceDelay { get; set; }
Property Value
System.Int32
|
FilterOperator
Defines the filter operator. Default value is StringFilterOperator.StartsWith.
Declaration
public StringFilterOperator FilterOperator { get; set; }
Property Value
StringFilterOperator
|
FilterPlaceholder
The hint that is displayed in the filter input.
Declaration
public string FilterPlaceholder { get; set; }
Property Value
System.String
|
ItemTemplate
Defines the item template of the list items.
Declaration
public RenderFragment<TItem> ItemTemplate { get; set; }
Property Value
Microsoft.AspNetCore.Components.RenderFragment<TItem>
|
OnClose
Defines the OnClose Event which is fired before the suggestion list of the DropDownList is closed.
Declaration
public EventCallback<DropDownListCloseEventArgs> OnClose { get; set; }
Property Value
Microsoft.AspNetCore.Components.EventCallback<DropDownListCloseEventArgs>
|
OnItemRender
Fires each time an item in dropdown renders. Use the event to add a custom CSS class to each dropdown item based on its value.
Declaration
public Action<DropDownListItemRenderEventArgs<TItem>> OnItemRender { get; set; }
Property Value
System.Action<DropDownListItemRenderEventArgs<TItem>>
|
OnOpen
Defines the OnOpen Event which is fired before the suggestion list of the DropDownList is opened.
Declaration
public EventCallback<DropDownListOpenEventArgs> OnOpen { get; set; }
Property Value
Microsoft.AspNetCore.Components.EventCallback<DropDownListOpenEventArgs>
|
OnRead
Fires when the data source is read. Use this to attach your own filtering logic. Once attached, you must implement all such data source operations here, the Component will no longer perform them for you.
Declaration
public EventCallback<DropDownListReadEventArgs> OnRead { get; set; }
Property Value
Microsoft.AspNetCore.Components.EventCallback<DropDownListReadEventArgs>
|
SelectedDataItem
Declaration
protected ListDataItem SelectedDataItem { get; set; }
Property Value
Telerik.Blazor.Components.Common.Dropdowns.ListDataItem
|
TextField
Defines the TextField of the Data. Default value: "Text".
Declaration
public override string TextField { get; set; }
Property Value
System.String
|
Overrides
ValueMapper
A callback function that returns an item that corresponds to the argument value. Used in virtual scrolling combined with OnRead to facilitate pre-selection of items that are not currently loaded.
Declaration
public Func<TValue, Task<TItem>> ValueMapper { get; set; }
Property Value
System.Func<TValue, System.Threading.Tasks.Task<TItem>>
|
ValueTemplate
Defines the value template of the DropDownList.
Declaration
public RenderFragment<TItem> ValueTemplate { get; set; }
Property Value
Microsoft.AspNetCore.Components.RenderFragment<TItem>
|
Methods
BuildRenderTree(RenderTreeBuilder)
Declaration
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder
__builder
|
Dispose()
Declaration
public override void Dispose()
Overrides
OnAfterRenderAsync(Boolean)
Declaration
protected override Task OnAfterRenderAsync(bool firstRender)
Parameters
System.Boolean
firstRender
|
Returns
System.Threading.Tasks.Task
|
Overrides
OnParametersSetAsync()
Declaration
protected override Task OnParametersSetAsync()
Returns
System.Threading.Tasks.Task
|
Overrides
SetParametersAsync(ParameterView)
Declaration
public override Task SetParametersAsync(ParameterView parameters)
Parameters
Microsoft.AspNetCore.Components.ParameterView
parameters
|
Returns
System.Threading.Tasks.Task
|