Skip to main content

useToolbarItemPress

Listen to the press event of a toolbar item.

Syntax

useToolbarItemPress(id, callback);

Parameters

NameTypeDescription
idstringThe ID of the toolbar item
toolbarIdstringThe ID of the toolbar

Example

useToolbarItemPress('toolbar-item-id', (id, toolbarId) => {
console.log('Toolbar item pressed:', id, 'on toolbar:', toolbarId);
});

Available on: Client