Class
TelerikMenu<TItem>

The class for the Telerik Menu Component.

Definition

Namespace:Telerik.Blazor.Components

Assembly:Telerik.Blazor.dll

Type Parameters:

TItem

Syntax:

cs-api-definition
public class TelerikMenu<TItem> : HierarchicalBindingComponentBase, IComponent, IHandleEvent, IHandleAfterRender, IDisposable, IMenuPopupContainer

Inheritance: objectComponentBaseBaseComponentBindingComponentBaseHierarchicalBindingComponentBaseTelerikMenu<TItem>

Implements: IComponentIDisposableIHandleAfterRenderIHandleEventIMenuPopupContainer

Inherited Members HierarchicalBindingComponentBase.IdFieldHierarchicalBindingComponentBase.ParentIdFieldHierarchicalBindingComponentBase.HasChildrenFieldHierarchicalBindingComponentBase.ItemsFieldBindingComponentBase.TextFieldBindingComponentBase.IconFieldBindingComponentBase.UrlFieldBaseComponent.ShouldRender()BaseComponent.OnInitializedAsync()BaseComponent.OnAfterRenderAsync(bool)BaseComponent.Dispose()BaseComponent.InitLocalizer()BaseComponent.ThrowIfParameterIsNull(object, string)BaseComponent.HaveOptionsChanged(IDictionary<string, object>, IDictionary<string, object>)BaseComponent.GetClassString(params string[])BaseComponent.InvokeAsync<T>(string, params object[])BaseComponent.InvokeAsync<T>(string, CancellationToken, params object[])BaseComponent.InvokeVoidAsync(string, params object[])BaseComponent.InvokeComponentMethodAsync<T>(string, params object[])BaseComponent.InvokeComponentMethodAsync<T>(string, CancellationToken, params object[])BaseComponent.InvokeVoidComponentMethodAsync(string, params object[])BaseComponent.InvokeComponentVoidMethodAsync(string, object)BaseComponent.InvokeDisposeAsync()BaseComponent.StateHasChanged()BaseComponent.RootComponentBaseComponent.ClassComponentBase.OnInitialized()ComponentBase.OnParametersSet()ComponentBase.OnAfterRender(bool)ComponentBase.InvokeAsync(Action)ComponentBase.InvokeAsync(Func<Task>)ComponentBase.SetParametersAsync(ParameterView)

Constructors

TelerikMenu()

Declaration

cs-api-definition
public TelerikMenu()

Properties

CloseOnClick

Determines whether the menu popups should close on click.

Declaration

cs-api-definition
[Parameter]
public bool CloseOnClick { get; set; }

Property Value

bool

Data

Defines the Menu's Data.

Declaration

cs-api-definition
[Parameter]
public IEnumerable<TItem> Data { get; set; }

Property Value

IEnumerable<TItem>

DisabledField

Defines the Disabled DataField of the DataSource.

Declaration

cs-api-definition
[Parameter]
public string DisabledField { get; set; }

Property Value

string

HideOn

Define the event that triggers closing the popup that contains the menu items.

Declaration

cs-api-definition
[Parameter]
public MenuHideEvent HideOn { get; set; }

Property Value

MenuHideEvent

ItemTemplate

Defines the template for the items.

Declaration

cs-api-definition
[Parameter]
public RenderFragment<TItem> ItemTemplate { get; set; }

Property Value

RenderFragment<TItem>

MenuSettings

Specifies the menu settings.

Declaration

cs-api-definition
[Parameter]
public RenderFragment MenuSettings { get; set; }

Property Value

RenderFragment

OnClick

Defines the OnClick Event which is fired when clicking on a menu item.

Declaration

cs-api-definition
[Parameter]
public EventCallback<TItem> OnClick { get; set; }

Property Value

EventCallback<TItem>

OnItemRender

Fires when a Menu item is being rendered. Can be used to provide custom styling for the Menu's items.

Declaration

cs-api-definition
[Parameter]
public Action<MenuItemRenderEventArgs> OnItemRender { get; set; }

Property Value

Action<MenuItemRenderEventArgs>

Orientation

Defines the Orientation of Menu - vertical or horizontal.

Declaration

cs-api-definition
[Parameter]
public MenuOrientation Orientation { get; set; }

Property Value

MenuOrientation

SeparatorField

Defines the Separator DataField of the DataSource.

Declaration

cs-api-definition
[Parameter]
public string SeparatorField { get; set; }

Property Value

string

ShowOn

Define the event that triggers the opening of the menu.

Declaration

cs-api-definition
[Parameter]
public MenuShowEvent ShowOn { get; set; }

Property Value

MenuShowEvent

Methods

BuildRenderTree(RenderTreeBuilder)

Declaration

cs-api-definition
protected override void BuildRenderTree(RenderTreeBuilder __builder)

Parameters

__builder

RenderTreeBuilder

Overrides ComponentBase.BuildRenderTree(RenderTreeBuilder)

OnParametersSetAsync()

Declaration

cs-api-definition
protected override Task OnParametersSetAsync()

Returns

Task

Overrides ComponentBase.OnParametersSetAsync()