bpmn-js-properties-panel
bpmn-js-properties-panel copied to clipboard
Override an existing properties panel component behaviour
Is your feature request related to a problem? Please describe
I am working on upgrading my plugins to Camunda Modeler 5.0 and I am a bit stuck on a thing. I have to edit the behaviour of an existing field on properties panel (in my case, the MessageRef field) because I need to call one of my specific events on setValue. Is there a simple way to do it without re-writing the component and replacing it on the propertiesProvider#getGroups call?
Describe the solution you'd like
Support to override a field component, possibly without completely rewriting it, but only parts of it (getter, setter, validate, ...).
Describe alternatives you've considered
The only way I considered, as I said, is to re-write the existing behaviour of the field, overriding the setValue and adding my code.
Additional context
Cross-posting my answer from the Camunda forum: https://forum.camunda.io/t/is-there-a-simple-way-to-override-a-properties-panel-component-behaviour/39156/2.
I think this should rather be a feature request in the properties panel project: https://github.com/bpmn-io/bpmn-js-properties-panel/issues/new/choose
I transferred the issue accordingly, thanks for the request 👍
I think that would be an interesting slack time topic.
Slack time (2nd Sep. 2022)
Idea(s):
- Fire event via
eventBus
on setter, getter, validate so others can hook into (cf. https://github.com/bpmn-io/properties-panel/blob/main/src/components/entries/TextField.js#L102). - Make properties panel components extensible (replace setter, getter, validate)
- Make setter, getter and validate configurable via something like
DescriptionProvider
Miro: https://miro.com/app/board/uXjVPaDdxHs=/
Branches:
- https://github.com/bpmn-io/properties-panel/tree/slack-time-niklas-v1
- https://github.com/bpmn-io/bpmn-js-properties-panel/tree/slack-time-niklas-v1
Hi @pinussilvestrus! Any news about this issue?
Unfortunately not. this issue is not on our roadmap currently (cf. backlog
label).