Back to Devexpress

MenuHamburgerButtonPosition Enum

blazor-devexpress-dot-blazor-51890ccf.md

latest3.2 KB
Original Source

MenuHamburgerButtonPosition Enum

Lists values that specify the hamburger button’s position.

Namespace : DevExpress.Blazor

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
public enum MenuHamburgerButtonPosition

Members

NameDescription
Default

Mobile and tablet devices display this button at the right edge of the menu panel.
Other device types display the button at the left edge of the menu panel.
Depends on the DisplayMode property value.

| | Left |

The button is placed at the left edge of the menu panel.

| | Right |

The button is placed closer to the right edge of the menu panel.

| | Reverse |

Mobile and tablet devices display this button at the left edge of the menu panel.
Other devices display the button at the right edge of the menu panel.
Depends on the DisplayMode property value.

|

The following properties accept/return MenuHamburgerButtonPosition values:

Remarks

Menu items can be displayed in a hamburger menu in two cases:

  • If you set the DisplayMode to Mobile and set the Orientation to Horizontal.

  • If you set the DisplayMode to Desktop and set the CollapseItemsToHamburgerMenu property to true, menu items are collapsed into a hamburger menu when the width of the browser window changes and there is not enough space to display the items in the menu panel.

You can use the HamburgerButtonPosition and HamburgerIconCssClass properties to change the hamburger button’s position and icon.

razor
<div class="card w-auto">
    <DxMenu Title="DevExpress"
            CollapseItemToIconMode="MenuCollapseItemToIconMode.Sequentially"
            CollapseItemsToHamburgerMenu="true"
            HamburgerButtonPosition="MenuHamburgerButtonPosition.Right"
            HamburgerIconCssClass="oi oi-menu">
        <Items>
            <DxMenuItem Text="Products" IconCssClass="oi oi-layers" />
            <DxMenuItem Text="Support" IconCssClass="oi oi-person" />
            <DxMenuItem Text="Documentation" IconCssClass="oi oi-book" />
            <DxMenuItem Text="Demos" IconCssClass="oi oi-monitor" />
            <DxMenuItem Text="Blogs" IconCssClass="oi oi-bell" />
            <DxMenuItem Text="Search" IconCssClass="oi oi-magnifying-glass" />
        </Items>
    </DxMenu>
</div>

YouTube video

See Also

DevExpress.Blazor Namespace