This commit is contained in:
Beatriz Mendes 2022-04-27 15:18:29 +02:00
parent b708a4d7af
commit 7a705a5a54
3 changed files with 10 additions and 5 deletions

View File

@ -482,8 +482,8 @@ export default function BpmnRenderer(
function renderExternalLabel(parentGfx, element) { function renderExternalLabel(parentGfx, element) {
var box = { var box = {
width: 90, width: element.width,
height: 30, height: element.height,
x: element.width / 2 + element.x, x: element.width / 2 + element.x,
y: element.height / 2 + element.y y: element.height / 2 + element.y
}; };

View File

@ -171,7 +171,8 @@ LabelEditingProvider.prototype.activate = function(element) {
// external labels // external labels
if (isLabelExternal(element)) { if (isLabelExternal(element)) {
assign(options, { assign(options, {
autoResize: true resizable: true,
autoResize: true,
}); });
} }
@ -291,7 +292,7 @@ LabelEditingProvider.prototype.getEditingBBox = function(element) {
}); });
} }
var width = 90 * zoom, var width = Math.max(90 * zoom, bbox.width),
paddingTop = 7 * zoom, paddingTop = 7 * zoom,
paddingBottom = 4 * zoom; paddingBottom = 4 * zoom;

View File

@ -18,7 +18,7 @@ import {
} from '../modeling/util/ModelingUtil'; } from '../modeling/util/ModelingUtil';
import { import {
isLabel isLabel, isLabelExternal
} from '../../util/LabelUtil'; } from '../../util/LabelUtil';
import { import {
@ -798,6 +798,10 @@ function canResize(shape, newBounds) {
return true; return true;
} }
if (isLabelExternal(shape)) {
return true;
}
return false; return false;
} }