Home > @i2analyze/notebook-sdk > app > IElementEditorBase > setBadge
app.IElementEditorBase.setBadge() method
Sets a badge icon in the given slot on the element.
Signature:
setBadge(slot: visual.BadgeSlot, href: string, description?: string): this;
Introduced: version 1.10
Parameters
| Parameter | Type | Description |
|---|---|---|
| slot | visual.BadgeSlot | The slot position (0 to 5). Slots 0 to 2 are trailing; slots 3 to 5 are leading. |
| href | string | The URL of the badge icon image. |
| description | string | (Optional) A description of the badge, used as alternative text and in tooltips. |
Returns:
this
The element, with the badge icon in the specified slot set to the specified value.