parent
cc06e84cce
commit
8b5572d3c4
|
@ -291,11 +291,6 @@ function BpmnRenderer(eventBus, styles, pathMap, priority) {
|
|||
|
||||
function renderExternalLabel(p, element, align) {
|
||||
var semantic = getSemantic(element);
|
||||
|
||||
if (!semantic.name) {
|
||||
element.hidden = true;
|
||||
}
|
||||
|
||||
return renderLabel(p, semantic.name, { box: element, align: align, style: { fontSize: '11px' } });
|
||||
}
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ UpdatePropertiesHandler.prototype.execute = function(context) {
|
|||
changed.push(element.label);
|
||||
|
||||
// show the label
|
||||
element.label.hidden = false;
|
||||
element.label.hidden = !properties[NAME];
|
||||
}
|
||||
|
||||
// update properties
|
||||
|
|
|
@ -171,7 +171,7 @@ BpmnImporter.prototype.addLabel = function(semantic, element) {
|
|||
id: semantic.id + '_label',
|
||||
labelTarget: element,
|
||||
type: 'label',
|
||||
hidden: element.hidden,
|
||||
hidden: element.hidden || !semantic.name,
|
||||
x: Math.round(bounds.x),
|
||||
y: Math.round(bounds.y),
|
||||
width: Math.round(bounds.width),
|
||||
|
|
|
@ -52,7 +52,7 @@ describe('import - collapsed container', function() {
|
|||
}));
|
||||
|
||||
|
||||
it('should import collapsed with nested elements', inject(function(elementRegistry) {
|
||||
it('should import collapsed with nested hidden labels', inject(function(elementRegistry) {
|
||||
var hiddenEventShape = elementRegistry.get('StartEvent_2');
|
||||
expect(hiddenEventShape.label.hidden).to.be.true;
|
||||
|
||||
|
|
Loading…
Reference in New Issue