bpmn-io / bpmn-js-properties-panel

A properties panel for bpmn-js.
MIT License
295 stars 197 forks source link

Render HTML in element template descriptions #626

Open pinussilvestrus opened 2 years ago

pinussilvestrus commented 2 years ago

Is your feature request related to a problem? Please describe

In element templates, it is possible to add HTML to property descriptions.

{
  "label": "Hostname",
  "description": "Specify the email server (SMTP) host name. Find some documentation <a href='https://docs.camunda.io'>here</a>",
  "type": "String",
  "binding": {
    "type": "zeebe:input",
    "name": "HOST_NAME"
  }
}

image

However, this is not possible for the general elementTemplate.description

{
  "$schema": "https://unpkg.com/@camunda/zeebe-element-templates-json-schema/resources/schema.json",
  "name": "Email Connector",
  "id": "EmailConnector",
  "description": "Find some documentation <a href='https://docs.camunda.io'>here</a>",
  "appliesTo": [
    "bpmn:Task"
  ],
  "properties": []
}

image

Describe the solution you'd like

Make it possible to also provide HTML in element template descriptions.

Describe alternatives you've considered

/

Additional context

This does not solve that documentation URLs should be more visible on the properties panel header (cf. #616).

Cf. https://github.com/bpmn-io/bpmn-js-properties-panel/pull/549

pinussilvestrus commented 2 years ago

Also to consider: render these descriptions properly in the Catalog Modal

image

nikku commented 2 years ago

Also consider: If we go that route we need to support it everywhere, i.e. also in element template chooser as well as the connectors extension.

nikku commented 2 years ago

I'd personally not go down this route, given that it is easy to link documentation via documentationRef (https://github.com/bpmn-io/bpmn-js-properties-panel/issues/616). This is not the case for property descriptions.

We could also feature the documentation link in the Template section, to have description + name + link to documentation closer to each other.

MaxTru commented 2 years ago

cc @andreasgeier