I want to modify the BPMN: usertask default shape

I want to change its height。

It turned out to be 80px.

I hope it’s 50px


The 80px in this element, I want to know where I can set it. How to set up


The default sizes for each element are set here.

1 Like

Thank you very much. This helped me. Do you know how to modify the default value conveniently?

Create a custom ElementFactory and override the _getDefaultSize method, so something like that:

import ElementFactory from 'bpmn-js/lib/features/modeling/ElementFactory';

export default class CustomElementFactory extends ElementFactory {

   constructor(bpmnFactory, moddle, translate) {
      super(bpmnFactory, moddle, translate);

   _getDefaultSize(semantic) {

      if (is(semantic, 'bpmn:UserTask')) {
           return { width: 100, height: 50 };

     return super._getDefaultSize(semantic);



ElementFactory.$inject = [
1 Like

Thank you very much. It’s a timely help.

1 Like