camunda / camunda-bpmn-js

Embeddable Camunda modeling distributions based on bpmn-js
MIT License
104 stars 22 forks source link

Impossible to extend context pad and palette for Camunda Cloud #87

Open nikku opened 2 years ago

nikku commented 2 years ago

Describe the Bug

As a user I'd love to extend the camunda-bpmn-js Camunda Cloud distribution in the same way I'm used to extend bpmn-js (core).

However, I've stumbled over the fact that we do filter context pad entries based on a whitelist (rather than a black list), cf. https://github.com/camunda/camunda-bpmn-js/search?q=availableActions.

This essentially makes it impossible to provide custom context pad entries to the modeler.

Steps to Reproduce

  1. Bootstrap camunda-bpmn-js with a custom context pad/palette provider
  2. See that context pad / palette entries are being removed / filtered out

Expected Behavior

If we filter we should filter based on a blacklist, not whitelist.

Alternatively, we should filter entries with normal, not low priority to allow adding additional extensions after filtering took place.

To work around this issue I need to register my providers with even lower priority; that does sound like a short term hack to me, rather than a proper solution.

Environment

barmac commented 2 years ago

But you can have a context pad provider with a lower priority though :)

nikku commented 2 years ago

You can, you just have to read the source code to figure this out (i.e. at which priority to hook into) :wink:

nikku commented 2 years ago

We fell for this one, again :tada:.