I have Angular Application that implements some functionality of bpmnJS
As for now there’s such diagram:
I am trying to add Event Listener on one of the elements:
ngAfterViewChecked(): void {
//select the end event
var elementRegistry = this.bpmnJS.get("elementRegistry");
if (elementRegistry._elements != null) {
let element = elementRegistry.get('Activity_1iag6z7');
element.addEventListener('click', this.onClick.bind(this));
}
}
Element is successfully found
But when I try to AddEventListener I have error like this
Can you please tell me, what am I doing wrong?