Skip to main content

Sidebar

Namespace: Wisej.Web.Ext.Syncfusion2

Assembly: Wisej.Web.Ext.Syncfusion2 (4.1.0.0)

Sidebar is an expandable or collapsible component that typically act as a side container to place the primary or secondary content alongside of the main content.

public class Sidebar : ej2Base

Constructors​

Constructs a new instance of the Sidebar class.

Example:

The following example creates a sidebar that opens over the content and configures it through the Options object.

var sidebar = new Sidebar();
sidebar.Options.type = "Over";
sidebar.Options.width = "250px";
sidebar.Options.showBackdrop = true;
sidebar.Dock = DockStyle.Left;
this.Controls.Add(sidebar);

Constructs a new instance of the Sidebar class.

NameTypeDescription
optionsObjectInitial set of options.

Example:

The following example creates a sidebar on the right side that can be docked to a narrow strip, and toggles it when the user clicks a button.

var sidebar = new Sidebar(new
{
position = "Right",
enableDock = true,
dockSize = "60px",
width = "220px",
isOpen = false
});
sidebar.Dock = DockStyle.Right;
this.Controls.Add(sidebar);

this.buttonMenu.Click += (s, e) => sidebar.Instance.toggle();

Implements​