bpmn-io / dmn-js

View and edit DMN diagrams in the browser.
https://bpmn.io/toolkit/dmn-js/
Other
289 stars 137 forks source link

Allow merging of table cells #836

Open michaelglasson opened 5 months ago

michaelglasson commented 5 months ago

Need to put the same contents into multiple cells in a column - inconvenient and error-prone

Allow adjacent cells in a column to be merged

The DMN Specification shows that it is valid to merge adjacent cells so that multiple cells can have the same content which needs to be entered only once.

Describe alternatives you've considered

Putting the same data into adjacent cells - as is the case now.

Additional context

There are many examples in the DMN specification that show merged cells.

barmac commented 5 months ago

Thanks for creating this issue. How do you imagine such solution could work from the user's point of view? What actions should I take to merge the table cells?

michaelglasson commented 5 months ago

Thanks for your response, @barmac. I would follow the approach used in word processor tables. Allow the user to select multiple cells by dragging, or by click, shift-click or by click, ctrl-click. A right-button context menu then allows 'merge cells'. The image below shows the same complex expression in two vertically adjacent cells.

Screenshot 2024-03-19 064432
barmac commented 5 months ago

Makes sense. So the hidden requirement of this feature request is the ability to select multiple cells. This could unlock even more actions, e.g. clear multiple cells at once. Anyway, for now this lands in backlog so that we can pick it up later.