Javascript example to demonstrate how to add stylized overlay on BPMN elements.
- ⏩ live environment
- to run locally, open the index.html directly in a Web Browser
First, create a BpmnVisualization
instance (named bpmnVisualization
) prior being able to add stylized overlays to BPMN elements.
const overlayConfig = {
style: {
font: {
color: '#ffaacc',
size: 12,
},
fill: {
color: '#ffaacc',
},
stroke: {
color: '#ffaacc',
}
}
};
const overlay = { position: 'top-left', label: '456', ...overlayConfig };
bpmnVisualization.bpmnElementsRegistry.addOverlays('exclusive_gateway_id', overlay);