Class ProgressButtonSpinSettings
Configures the appearance and behavior of the spinner within the SfProgressButton component.
Inheritance
Namespace: Syncfusion.Blazor.SplitButtons
Assembly: Syncfusion.Blazor.dll
Syntax
public class ProgressButtonSpinSettings : OwningComponentBase
Remarks
The ProgressButtonSpinSettings allows you to customize the position, width, and template of the spinner displayed during progress.
Examples
<SfProgressButton Content="Submit">
<ProgressButtonSpinSettings Position="SpinPosition.Right" Width="20">
<SpinTemplate>
<div class="custom-spinner"></div>
</SpinTemplate>
</ProgressButtonSpinSettings>
</SfProgressButton>
Constructors
ProgressButtonSpinSettings()
Declaration
public ProgressButtonSpinSettings()
Properties
Position
Gets or sets a value that indicates the position of the spinner within the SfProgressButton.
Declaration
public SpinPosition Position { get; set; }
Property Value
Type | Description |
---|---|
SpinPosition | One of the SpinPosition enumeration values. The default value is Left. |
Remarks
This property controls the placement of the spinner relative to the button's content. The available positions are:
SpinTemplate
Gets or sets the custom template for the spinner in the SfProgressButton.
Declaration
public RenderFragment SpinTemplate { get; set; }
Property Value
Type | Description |
---|---|
Microsoft.AspNetCore.Components.RenderFragment | A Microsoft.AspNetCore.Components.RenderFragment that defines the custom spinner content. The default value is |
Remarks
This template allows you to replace the default spinner with custom HTML content or components. When a SpinTemplate is provided, it will be rendered as the spinner during the progress state.
Width
Gets or sets the width of the spinner in the SfProgressButton.
Declaration
public string Width { get; set; }
Property Value
Type | Description |
---|---|
System.String | A |
Remarks
This property allows you to control the size of the spinner. For example, you can set it to "20px" or "100%". If only a numeric value is provided, it is treated as pixels.
Methods
Dispose(Boolean)
Releases the unmanaged resources used by the ProgressButtonSpinSettings and optionally releases the managed resources.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing |
|
Remarks
This method cleans up resources by detaching from the parent SfProgressButton.
OnInitializedAsync()
Method invoked when the component is ready to start.
Declaration
protected override Task OnInitializedAsync()
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task | A System.Threading.Tasks.Task representing the asynchronous operation. |
Remarks
This method notifies the parent SfProgressButton about these spin settings.