i am a bpmn.io noop and do some experimental stuff with the bpmn-navigated-viewer.js. My wish is to highlight a specific element. Like the screenshot below.
What is the correct way to realize stuff like this. Unfortunately i wasn’t able to find some example project in your github.
My simple approach is:
var canvasElement = angular.element('#bpmn g[data-element-id="foo"] g rect');
if (canvasElement) {
canvasElement.attr('style', 'stroke: red; stroke-width: 4px');
}
yes!!! your second example of camunda tasklist to add some class definitions via canvas.addMarker(taskDefinitionKey, 'highlight'); is also very helpful.