Skip to content

WorkspaceRibbon.addRibbonItemButton method

WorkspaceRibbon › addRibbonItemButton

Unofficial

Adds a ribbon item button.

Signature:

addRibbonItemButton(id: string, icon: string, title: string, callback: (evt: MouseEvent) => unknown): HTMLElement

Parameters:

ParameterTypeDescription
idstringThe unique identifier of the item.
iconstringThe lucide icon name.
titlestringThe tooltip title.
callback(evt: MouseEvent) => unknownThe click handler.

Returns: HTMLElementThe created button element.