Skip to content

Commit 8a4bdca

Browse files
committed
fix: use default value for cancelRemainingInstances for edit marker
fix: undo breaking change in peer dependencies Related to #1149
1 parent 43673e5 commit 8a4bdca

File tree

6 files changed

+16
-13
lines changed

6 files changed

+16
-13
lines changed

.github/workflows/CI.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
matrix:
99
integration: [ true ]
1010
integration-deps:
11-
- [email protected] bpmn-js@18.6.3
11+
- [email protected] bpmn-js@11.5
1212
- "@bpmn-io/properties-panel@3"
1313
include:
1414
- integration-deps: "" # as defined in package.json

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ All notable changes to [bpmn-js-properties-panel](https://github.com/bpmn-io/bpm
66

77
___Note:__ Yet to be released changes appear here._
88

9+
## 5.42.1
10+
11+
* `FIX`: use default value for `cancelRemainingInstances` for edit marker
12+
* `FIX`: undo breaking change in peer dependencies ([#1149](https://github.com/bpmn-io/bpmn-js-properties-panel/issues/1149))
13+
914
## 5.42.0
1015

1116
* `FEAT`: support multiline feel strings in `camunda` dialect ([@bpmn-io/lezer-feel#2](https://github.com/bpmn-io/lezer-feel/pull/2))

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@
109109
},
110110
"peerDependencies": {
111111
"@bpmn-io/properties-panel": ">= 3.7",
112-
"bpmn-js": ">= 18.6.3",
112+
"bpmn-js": ">= 11.5",
113113
"camunda-bpmn-js-behaviors": ">= 0.4",
114114
"diagram-js": ">= 11.9"
115115
}

src/provider/bpmn/properties/AdHocCompletionProps.js

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@ import { is, getBusinessObject } from 'bpmn-js/lib/util/ModelUtil';
22

33
import {
44
CheckboxEntry,
5-
isCheckboxEntryEdited,
65
isTextFieldEntryEdited,
7-
TextFieldEntry
6+
TextFieldEntry,
87
} from '@bpmn-io/properties-panel';
98

109
import { useService } from '../../../hooks';
@@ -33,9 +32,8 @@ export function AdHocCompletionProps(props) {
3332
{
3433
id: 'cancelRemainingInstances',
3534
component: CancelRemainingInstances,
36-
37-
isEdited: isCheckboxEntryEdited
38-
}
35+
isEdited: (node) => node && !node.checked // the default value is true
36+
},
3937
];
4038
}
4139

test/spec/provider/bpmn/AdHocCompletionProps.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,11 +204,11 @@ describe('provider/bpmn - AdHocCompletion', function() {
204204

205205
describe('#cancelRemainingInstances', function() {
206206

207-
it('should not be checked when not explicitely configured on the process', inject(async function(elementRegistry, selection) {
207+
it('should be checked when not explicitely configured on the process', inject(async function(elementRegistry, selection) {
208208

209209
// given
210210
const subprocess = elementRegistry.get('Subprocess_2');
211-
expect(getCancelRemainingInstancesValue(subprocess)).not.to.exist;
211+
expect(getCancelRemainingInstancesValue(subprocess)).to.be.true;
212212

213213
// when
214214
await act(() => {
@@ -218,7 +218,7 @@ describe('provider/bpmn - AdHocCompletion', function() {
218218
// then
219219
const cancelRemainingInstancesCheckbox = getCancelRemainingInstancesCheckbox(container);
220220
expect(cancelRemainingInstancesCheckbox).to.exist;
221-
expect(cancelRemainingInstancesCheckbox.checked).to.be.false;
221+
expect(cancelRemainingInstancesCheckbox.checked).be.true;
222222
}));
223223

224224

test/spec/provider/zeebe/AdHocCompletionProps.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -264,13 +264,13 @@ describe('provider/zeebe - AdHocCompletion', function() {
264264

265265
describe('#cancelRemainingInstances', function() {
266266

267-
it('should not be checked when not explicitely configured on the process', inject(async function(
267+
it('should be checked when not explicitely configured on the process', inject(async function(
268268
elementRegistry, selection
269269
) {
270270

271271
// given
272272
const subprocess = elementRegistry.get('Subprocess_2');
273-
expect(getCancelRemainingInstancesValue(subprocess)).not.to.exist;
273+
expect(getCancelRemainingInstancesValue(subprocess)).to.be.true;
274274

275275
// when
276276
await act(() => {
@@ -280,7 +280,7 @@ describe('provider/zeebe - AdHocCompletion', function() {
280280
// then
281281
const cancelRemainingInstancesCheckbox = getCancelRemainingInstancesCheckbox(container);
282282
expect(cancelRemainingInstancesCheckbox).to.exist;
283-
expect(cancelRemainingInstancesCheckbox.checked).to.be.false;
283+
expect(cancelRemainingInstancesCheckbox.checked).be.true;
284284
}));
285285

286286

0 commit comments

Comments
 (0)