feat: add custom context menu rendering (#7409)

This commit is contained in:
Beka Westberg
2023-08-17 14:50:41 -07:00
committed by GitHub
parent 60aa99af53
commit cb0f7032fd

View File

@@ -137,7 +137,7 @@ export namespace ContextMenuRegistry {
export interface RegistryItem {
callback: (p1: Scope) => void;
scopeType: ScopeType;
displayText: ((p1: Scope) => string) | string;
displayText: ((p1: Scope) => string | HTMLElement) | string | HTMLElement;
preconditionFn: (p1: Scope) => string;
weight: number;
id: string;
@@ -147,7 +147,7 @@ export namespace ContextMenuRegistry {
* A menu item as presented to contextmenu.js.
*/
export interface ContextMenuOption {
text: string;
text: string | HTMLElement;
enabled: boolean;
callback: (p1: Scope) => void;
scope: Scope;