Class
EditorCustomTool

Enables creation of custom tools for the Editor toolbar with application-specific functionality. Use to add custom buttons, dropdowns, or other UI elements that integrate seamlessly with the Editor. Custom tools are referenced by name in the Editor's Tools collection to position them in the toolbar.

Definition

Constructors

EditorCustomTool()

Declaration

cs-api-definition
public EditorCustomTool()

Properties

ChildContent

Contains the custom UI content that will be rendered in the Editor toolbar. Use this to define buttons, dropdowns, or other interactive elements with custom styling and behavior. Content has access to the parent Editor context for implementing tool functionality. Should follow Editor toolbar styling conventions for consistent appearance. Children: Custom UI elements like buttons, dropdowns, or other controls.

Declaration

cs-api-definition
[Parameter]
public RenderFragment ChildContent { get; set; }

Property Value

RenderFragment

Implements IEditorCustomToolRendering.ChildContent

Name

Sets the unique identifier name for this custom tool that links it to the toolbar position. Use this name in the Editor's Tools collection to include the custom tool. Example: "MyCustomButton" can be referenced in Tools as new CustomTool { Name = "MyCustomButton" }. Must be unique within the Editor's custom tools collection. Required parameter.

Declaration

cs-api-definition
[Parameter]
public string Name { get; set; }

Property Value

string

Implements IEditorCustomToolRendering.Name

Methods

BuildRenderTree(RenderTreeBuilder)

Declaration

cs-api-definition
protected override void BuildRenderTree(RenderTreeBuilder __builder)

Parameters

__builder

RenderTreeBuilder

Overrides ComponentBase.BuildRenderTree(RenderTreeBuilder)

Dispose()

Declaration

cs-api-definition
public void Dispose()

Implements IDisposable.Dispose()

OnInitializedAsync()

Declaration

cs-api-definition
protected override Task OnInitializedAsync()

Returns

Task

Overrides ComponentBase.OnInitializedAsync()