Page tree
Skip to end of metadata
Go to start of metadata

Legend extends Element

The API model used to edit the Legend.

Methods

remove()

Removes the Element itself.

IF ALL ELEMENTS ARE REMOVED, ERRORS MAY OCCUR IN SUBSEQUENT OPERATIONS.

var legend = editor.getAPIModelById('id');
legend.remove();

replace(html)

  • html <String> The HTML String to replace.

Replaces the element itself with the HTML String passed as an argument.

var legend = editor.getAPIModelById('id');
legend.replace('<span>Legend replaced</span>');
  • No labels