Skip to content

Commit

Permalink
fix broken copy/paste
Browse files Browse the repository at this point in the history
  • Loading branch information
hofstef committed Jan 3, 2025
1 parent 5758662 commit 21ec51d
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@ export default function DomainStoryElementFactory() {
assign(attrs.businessObject, { $type: "Element" });
}

// even though we don't use these attributes they are needed for the copy/paste functionality of bpmn-js
assign(attrs.businessObject, { di: {} });
if (!attrs.businessObject.$descriptor) {
assign(attrs.businessObject, { $descriptor: {} });
}

// add width and height if shape
if (
(!/:activity$/.test(type) || !/:connection$/.test(type)) &&
Expand Down

0 comments on commit 21ec51d

Please sign in to comment.