Class NumberedListBlockSettings
Represents settings specific to a numbered list block used in the SfBlockEditor.
Inherited Members
Namespace: Syncfusion.Blazor.BlockEditor
Assembly: Syncfusion.Blazor.dll
Syntax
public class NumberedListBlockSettings : BlockSettings
Remarks
Assign an instance of this settings class to BlockModel.Properties when BlockModel.BlockType is
NumberedList.
This type currently acts as a marker for numbered list configuration. You can extend it with additional properties
such as a starting index (for example, StartIndex) or numbering style (for example, an enum like
NumberingStyle that could support Arabic, Roman, or Alphabetic formats) to meet application needs.
Performance: Rendering numbered lists is lightweight and scales with the number of BlockModel instances. Updates should be performed on the UI thread for thread safety.
Examples
Demonstrates creating a numbered list block and attaching NumberedListBlockSettings within an SfBlockEditor component.
<SfBlockEditor @bind-Blocks="Blocks" />
@code {
private List<BlockModel> Blocks = new()
{
new BlockModel
{
ID = "numbered-list",
BlockType = BlockType.NumberedList,
Properties = new NumberedListBlockSettings(),
Content = new List<ContentModel>
{
new ContentModel { ID = "n1", ContentType = ContentType.Text, Content = "Step one" },
new ContentModel { ID = "n2", ContentType = ContentType.Text, Content = "Step two" }
}
}
};
}
Constructors
NumberedListBlockSettings()
Declaration
public NumberedListBlockSettings()
Properties
Placeholder
Gets or sets the placeholder text displayed when a NumberedList item has no content in the SfBlockEditor.
Declaration
public string Placeholder { get; set; }
Property Value
| Type | Description |
|---|---|
| string | A string representing the placeholder text for an empty numbered list item.
The default value is |
Remarks
Use this property to guide users on what to enter (for example, "Add a step..."). The placeholder is shown
only while the item's content is empty and is hidden once the user provides text.
If the value is null or empty, no placeholder text is rendered.
For localization, provide region-specific placeholder text via resource files to ensure a consistent experience across locales.