DxDrawer.CloseOnTargetContentClick Property
Specifies whether the drawer panel should be closed when a user clicks the target content area (for Overlap
mode only).
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.2.dll
NuGet Package: DevExpress.Blazor
Declaration
[DefaultValue(true)]
[Parameter]
public bool CloseOnTargetContentClick { get; set; }
Property Value
Type | Default | Description |
---|---|---|
Boolean | true |
|
Remarks
When the Mode property is set to Overlap
and the ApplyBackgroundShading is set to true
, a user click on the shaded target content area closes the drawer panel.
Set the CloseOnTargetContentClick
property to false
to disable this behavior.
<DxDrawer IsOpen="IsOpen" PanelWidth="20%" Mode="DrawerMode.Overlap" CloseOnTargetContentClick="false">
<BodyTemplate>
<DxMenu Orientation="Orientation.Vertical">
<Items>
<DxMenuItem Text="Home" IconCssClass="menu-icon-home menu-icon" />
<DxMenuItem Text="Components" IconCssClass="menu-icon-products menu-icon" />
<DxMenuItem Text="Support" IconCssClass="menu-icon-support menu-icon" />
<DxMenuItem Text="Contacts" IconCssClass="menu-icon-contacts menu-icon" />
<DxMenuItem Text="About" IconCssClass="menu-icon-about menu-icon" />
</Items>
</DxMenu>
</BodyTemplate>
<TargetContent>
@* ... *@
</TargetContent>
</DxDrawer>
See Also