WorkspaceRibbon.addRibbonItemButton method
WorkspaceRibbon › addRibbonItemButton
Unofficial
Adds a ribbon item button.Signature:
addRibbonItemButton(id: string, icon: string, title: string, callback: (evt: MouseEvent) => unknown): HTMLElementParameters:
| Parameter | Type | Description |
|---|---|---|
| id | string | The unique identifier of the item. |
| icon | string | The lucide icon name. |
| title | string | The tooltip title. |
| callback | (evt: MouseEvent) => unknown | The click handler. |
Returns: HTMLElement — The created button element.