Hello,
would anybody know how to delete entries from the replace menu of connections?
I have added custom entries and want to remove the default ones (default flow and conditional flow):
Here you can find the related post to that: How to add custom replace menu entries
My code ruthly looks like this:
class ReplaceProvider {
constructor(popupMenu) {
this.modeling = modeling;
popupMenu.registerProvider("bpmn-replace", this);
}
getPopupMenuEntries(element) {
if (!is(element, "bpmn:SequenceFlow")) {
return;
}
return {
"entry-1": {
className: "bpmn-icon-connection",
label: "Blue Sequence Flow",
action: () => {
this.modeling.setColor(element, {stroke: 'blue'});
}
},
"entry-2": {
...
}, ...
};
}
}
Thanks in advance!