Class MBMenuSurface
This is a general purpose Material Theme menu surface.
public class MBMenuSurface : ComponentFoundation, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
- Inheritance
-
MBMenuSurface
- Implements
- Inherited Members
Constructors
MBMenuSurface()
public MBMenuSurface()
Properties
ChildContent
A render fragement as a set of MBListItems.
[Parameter]
public RenderFragment ChildContent { get; set; }
Property Value
MenuSurfacePositioning
Regular, fullwidth or fixed positioning/width.
[Parameter]
public MBMenuSurfacePositioning MenuSurfacePositioning { get; set; }
Property Value
OnMenuClosed
Called when the menu is closed.
[Parameter]
public Action OnMenuClosed { get; set; }
Property Value
OnMenuOpened
Called when the menu is opened.
[Parameter]
public Action OnMenuOpened { get; set; }
Property Value
Methods
BuildRenderTree(RenderTreeBuilder)
Renders the component to the supplied RenderTreeBuilder.
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
__builder
RenderTreeBuilder
Dispose(bool)
protected override void Dispose(bool disposing)
Parameters
disposing
bool
NotifyClosed()
For Material Theme to notify of menu closure via JS Interop.
[JSInvokable]
public void NotifyClosed()
NotifyOpened()
For Material Theme to notify of menu closure via JS Interop.
[JSInvokable]
public void NotifyOpened()
OnInitializedAsync()
Method invoked when the component is ready to start, having received its initial parameters from its parent in the render tree.
Override this method if you will perform an asynchronous operation and want the component to refresh when that operation is completed.
protected override Task OnInitializedAsync()
Returns
ToggleAsync()
Toggles the menu open and closed.
public Task ToggleAsync()