Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: remove legacy check #1089

Merged
merged 1 commit into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/render/BpmnPropertiesPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -250,9 +250,7 @@ export default function BpmnPropertiesPanel(props) {
// helpers //////////////////////////

function isImplicitRoot(element) {

// Backwards compatibility for diagram-js<7.4.0, see https://github.com/bpmn-io/bpmn-properties-panel/pull/102
return element && (element.isImplicit || element.id === '__implicitroot');
return element && element.isImplicit;
}

function findElement(elements, element) {
Expand Down
4 changes: 1 addition & 3 deletions src/render/BpmnPropertiesPanelRenderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,7 @@ BpmnPropertiesPanelRenderer.$inject = [ 'config.propertiesPanel', 'injector', 'e
// helpers ///////////////////////

function isImplicitRoot(element) {

// Backwards compatibility for diagram-js<7.4.0, see https://github.com/bpmn-io/bpmn-properties-panel/pull/102
return element && (element.isImplicit || element.id === '__implicitroot');
return element && element.isImplicit;
}

/**
Expand Down
26 changes: 0 additions & 26 deletions test/spec/BpmnPropertiesPanelRenderer.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -401,32 +401,6 @@ describe('<BpmnPropertiesPanelRenderer>', function() {
});


it('should ignore implicit root - legacy', async function() {

// given
const diagramXml = require('test/fixtures/simple.bpmn').default;

// when
const { modeler } = await createModeler(diagramXml, {
shouldImport: false,
propertiesPanel: {}
});

const implicitRootElement = {
id: '__implicitroot',
children: []
};

// when
const propertiesPanel = modeler.get('propertiesPanel');
propertiesPanel.attachTo(propertiesContainer);
propertiesPanel._render(implicitRootElement);

// then
expect(domQuery('.bio-properties-panel', propertiesContainer)).to.not.exist;
});


describe('providers', function() {

const diagramXML = require('test/fixtures/simple.bpmn').default;
Expand Down