Class ContextMenuModule
Represents the context menu module in DocumentEditor.
Inheritance
System.Object
ContextMenuModule
Namespace: Syncfusion.Blazor.DocumentEditor
Assembly: Syncfusion.Blazor.dll
Syntax
public class ContextMenuModule : Object
Constructors
ContextMenuModule(BaseComponent)
Default constructor for ContextMenu.
Declaration
public ContextMenuModule(BaseComponent baseComponent)
Parameters
Type | Name | Description |
---|---|---|
BaseComponent | baseComponent | An DocumentEdiorComponent instance. |
Properties
DocumentEditorComponent
DocumentEdiorComponent instance.
Declaration
protected BaseComponent DocumentEditorComponent { get; set; }
Property Value
Type | Description |
---|---|
BaseComponent |
Methods
AddCustomMenu(List<MenuItemModel>, Boolean, Boolean)
Add and customize custom context menu items.
Declaration
public Task AddCustomMenu(List<MenuItemModel> items, bool isEnable, bool isBottom)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.List<MenuItemModel> | items | Custom context menu items |
System.Boolean | isEnable | Hide existing menu items and show custom menu item alone. |
System.Boolean | isBottom | Place the new items at the bottom of existing items. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task | Returns an asynchronous operation. |
HideSpellContextItems()
Hide spelling context menu items.
Declaration
public Task HideSpellContextItems()
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task | Returns an asynchronous operation. |
Examples
//SfDocumentEditor Component.
SfDocumentEditor sfDocumentEditor = new SfDocumentEditor();
await sfDocumentEditor.GetContextMenu().HideSpellContextItems();
//SfDocumentEditorContainer Component.
SfDocumentEditorContainer sfDocumentEditorContainer = new SfDocumentEditorContainer();
await sfDocumentEditorContainer.GetDocumentEditor().GetContextMenu().HideSpellContextItems();