Add block bar (+ menu).
Access:
app.addbar
app.getModule('addbar')
app.invoke('addbar.method', …)
add#
Registers a dynamic addbar dropdown item config by name.
Parameters:
- name (
string) — identifier name - config (
object) — configuration object
app.addbar.add('callout', { title: 'Callout', template: '…' });
remove#
Marks addbar item names as removed.
Parameters:
- ...names (
Array) — list of names to process
app.addbar.remove('quote');
getItems#
Builds the addbar dropdown item list with block.insert commands assigned.
Parameters:
- block (
Block | HTMLElement) — block instance
Returns: object[]
app.addbar.getItems(block);
open#
Creates and opens the addbar dropdown anchored to a trigger element.
Parameters:
- params (
object) — command or form parameters - button (
HTMLElement | string) — toolbar or UI button element - el (
HTMLElement | string) — DOM element
app.addbar.open({}, { button });