Class DialogButtons
Represents a collection of DialogButton.
Inheritance
System.Object
DialogButtons
Namespace: Syncfusion.Blazor.Popups
Assembly: Syncfusion.Blazor.dll
Syntax
public class DialogButtons : OwningComponentBase
Remarks
To generate dynamic DialogButton based on collection, use @foreach
within DialogButtons tag directive.
Examples
In the following code example, a basic has been rendered using the tag directive.
@using Syncfusion.Blazor.Popups
<SfDialog Width="500px" @bind-Visible="Visibility">
<DialogTemplates>
<Content>
<p>
Dialog content
</p>
</Content>
</DialogTemplates>
<DialogButtons>
<DialogButton IsPrimary="true" Content="Ok" OnClick="@OnBtnClick" />
<DialogButton Content="Cancel" OnClick="@OnBtnClick" />
</DialogButtons>
</SfDialog>
@code {
private bool Visibility { get; set; } = true;
private void OnBtnClick()
{
this.Visibility = false;
}
}
Constructors
DialogButtons()
Declaration
public DialogButtons()
Methods
BuildRenderTree(RenderTreeBuilder)
Declaration
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
Type | Name | Description |
---|---|---|
Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder | __builder |
Dispose()
Dispose the unmanaged resources.
Declaration
public virtual void Dispose()
Dispose(Boolean)
Dispose the unmanaged resources.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | Boolean value to dispose the object. |