camunda-bpmn-js 3.6.0 → 3.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -126887,6 +126887,7 @@
|
|
|
126887
126887
|
}
|
|
126888
126888
|
|
|
126889
126889
|
const LOWER_PRIORITY$1 = 300;
|
|
126890
|
+
const ALWAYS_DISPLAYED_GROUPS = ['general', 'multiInstance'];
|
|
126890
126891
|
let ElementTemplatesPropertiesProvider$1 = class ElementTemplatesPropertiesProvider {
|
|
126891
126892
|
constructor(elementTemplates, propertiesPanel, injector) {
|
|
126892
126893
|
propertiesPanel.registerProvider(LOWER_PRIORITY$1, this);
|
|
@@ -126916,7 +126917,7 @@
|
|
|
126916
126917
|
};
|
|
126917
126918
|
|
|
126918
126919
|
// (1) Add templates group
|
|
126919
|
-
addGroupsAfter$1(
|
|
126920
|
+
addGroupsAfter$1(ALWAYS_DISPLAYED_GROUPS, groups, [templatesGroup]);
|
|
126920
126921
|
let elementTemplate = this._elementTemplates.get(element);
|
|
126921
126922
|
if (elementTemplate) {
|
|
126922
126923
|
elementTemplate = applyConditions(element, elementTemplate);
|
|
@@ -126962,12 +126963,20 @@
|
|
|
126962
126963
|
|
|
126963
126964
|
/**
|
|
126964
126965
|
*
|
|
126965
|
-
* @param {string}
|
|
126966
|
+
* @param {string|string[]} idOrIds
|
|
126966
126967
|
* @param {Array<{ id: string }} groups
|
|
126967
126968
|
* @param {Array<{ id: string }>} groupsToAdd
|
|
126968
126969
|
*/
|
|
126969
|
-
function addGroupsAfter$1(
|
|
126970
|
-
|
|
126970
|
+
function addGroupsAfter$1(idOrIds, groups, groupsToAdd) {
|
|
126971
|
+
let ids = idOrIds;
|
|
126972
|
+
if (!Array.isArray(idOrIds)) {
|
|
126973
|
+
ids = [idOrIds];
|
|
126974
|
+
}
|
|
126975
|
+
|
|
126976
|
+
// find index of last group with provided id
|
|
126977
|
+
const index = groups.reduce((acc, group, index) => {
|
|
126978
|
+
return ids.includes(group.id) ? index : acc;
|
|
126979
|
+
}, -1);
|
|
126971
126980
|
if (index !== -1) {
|
|
126972
126981
|
groups.splice(index + 1, 0, ...groupsToAdd);
|
|
126973
126982
|
} else {
|
|
@@ -126978,7 +126987,7 @@
|
|
|
126978
126987
|
function filterWithEntriesVisible$1(template, groups) {
|
|
126979
126988
|
if (!template.entriesVisible) {
|
|
126980
126989
|
return groups.filter(group => {
|
|
126981
|
-
return group.id
|
|
126990
|
+
return ALWAYS_DISPLAYED_GROUPS.includes(group.id) || group.id.startsWith('ElementTemplates__');
|
|
126982
126991
|
});
|
|
126983
126992
|
}
|
|
126984
126993
|
return groups;
|