@camunda/element-templates-json-schema 0.3.1 → 0.7.0

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.
@@ -5,674 +5,781 @@
5
5
  "description": "A single element template configuration or an array of element template configurations",
6
6
  "definitions": {
7
7
  "properties": {
8
- "type": "array",
9
- "title": "element template properties",
10
- "description": "The properties of the element template",
11
- "default": [],
12
- "items": {
13
- "$id": "#/properties/property",
14
- "type": "object",
15
- "title": "element template property",
16
- "description": "A property defined for the element template",
17
- "default": {},
18
- "required": [
19
- "binding"
20
- ],
21
- "errorMessage": {
22
- "required": {
23
- "binding": "missing binding for property \"${0#}\""
24
- }
25
- },
26
- "allOf": [
27
- {
28
- "if": {
29
- "properties": {
30
- "type": {
31
- "const": "Dropdown"
32
- }
33
- },
34
- "required": [
35
- "type"
36
- ]
37
- },
38
- "then": {
39
- "required": [
40
- "choices"
41
- ],
42
- "errorMessage": "must provide choices=[] with \"Dropdown\" type"
43
- }
44
- },
45
- {
46
- "if": {
47
- "properties": {
48
- "binding": {
8
+ "allOf": [
9
+ {
10
+ "type": "array",
11
+ "title": "element template properties",
12
+ "description": "The properties of the element template",
13
+ "default": [],
14
+ "items": {
15
+ "type": "object",
16
+ "title": "element template property",
17
+ "description": "A property defined for the element template",
18
+ "default": {},
19
+ "allOf": [
20
+ {
21
+ "if": {
49
22
  "properties": {
50
23
  "type": {
51
- "const": "property"
24
+ "const": "Dropdown"
52
25
  }
53
26
  },
54
27
  "required": [
55
28
  "type"
56
29
  ]
57
- }
58
- },
59
- "required": [
60
- "binding"
61
- ]
62
- },
63
- "then": {
64
- "properties": {
65
- "type": {
66
- "enum": [
67
- "String",
68
- "Text",
69
- "Hidden",
70
- "Dropdown",
71
- "Boolean"
72
- ],
73
- "errorMessage": "invalid property type ${0} for binding type \"property\"; must be any of { String, Text, Hidden, Dropdown, Boolean }"
74
- }
75
- }
76
- }
77
- },
78
- {
79
- "if": {
80
- "properties": {
81
- "binding": {
82
- "properties": {
83
- "type": {
84
- "const": "camunda:executionListener"
85
- }
86
- },
30
+ },
31
+ "then": {
87
32
  "required": [
88
- "type"
89
- ]
90
- }
91
- },
92
- "required": [
93
- "binding"
94
- ]
95
- },
96
- "then": {
97
- "properties": {
98
- "type": {
99
- "enum": [
100
- "Hidden"
33
+ "choices"
101
34
  ],
102
- "errorMessage": "invalid property type ${1/type} for binding type \"camunda:executionListener\"; must be \"Hidden\""
35
+ "errorMessage": "must provide choices=[] with \"Dropdown\" type"
103
36
  }
104
37
  }
105
- }
106
- },
107
- {
108
- "if": {
109
- "properties": {
110
- "binding": {
38
+ ],
39
+ "properties": {
40
+ "value": {
41
+ "$id": "#/properties/property/value",
42
+ "type": [
43
+ "string",
44
+ "boolean"
45
+ ],
46
+ "title": "property value",
47
+ "description": "The value of the control field for the property"
48
+ },
49
+ "description": {
50
+ "$id": "#/properties/property/description",
51
+ "type": "string",
52
+ "title": "property description",
53
+ "description": "The description of the control field"
54
+ },
55
+ "label": {
56
+ "$id": "#/properties/property/label",
57
+ "type": "string",
58
+ "title": "property label",
59
+ "description": "The label of the control field for the property"
60
+ },
61
+ "type": {
62
+ "$id": "#/properties/property/type",
63
+ "type": "string",
64
+ "title": "property type",
65
+ "description": "The type of the control field"
66
+ },
67
+ "editable": {
68
+ "$id": "#/properties/property/editable",
69
+ "type": "boolean",
70
+ "title": "property editable",
71
+ "description": "Indicates whether the property is editable or not"
72
+ },
73
+ "choices": {
74
+ "$id": "#/properties/property/choices",
75
+ "type": "array",
76
+ "title": "property choices",
77
+ "description": "The choices for dropdown properties",
78
+ "items": {
79
+ "$id": "#/properties/property/choices/item",
80
+ "type": "object",
111
81
  "properties": {
112
- "type": {
113
- "enum": [
114
- "camunda:property",
115
- "camunda:outputParameter",
116
- "camunda:in",
117
- "camunda:in:businessKey",
118
- "camunda:out",
119
- "camunda:errorEventDefinition"
120
- ]
82
+ "name": {
83
+ "$id": "#/properties/property/choices/item/name",
84
+ "type": "string",
85
+ "title": "choice name",
86
+ "description": "The name of the choice"
87
+ },
88
+ "value": {
89
+ "$id": "#/properties/property/choices/item/value",
90
+ "type": "string",
91
+ "title": "choice value",
92
+ "description": "The value of the choice"
121
93
  }
122
94
  },
123
95
  "required": [
124
- "type"
125
- ]
126
- }
127
- },
128
- "required": [
129
- "binding"
130
- ]
131
- },
132
- "then": {
133
- "properties": {
134
- "type": {
135
- "enum": [
136
- "String",
137
- "Hidden",
138
- "Dropdown"
96
+ "value",
97
+ "name"
139
98
  ],
140
- "errorMessage": "invalid property type ${0} for binding type ${1/binding/type}; must be any of { String, Hidden, Dropdown }"
99
+ "errorMessage": "{ name, value } must be specified for \"Dropdown\" choices"
141
100
  }
142
- }
143
- }
144
- },
145
- {
146
- "if": {
147
- "properties": {
148
- "binding": {
149
- "properties": {
150
- "type": {
151
- "enum": [
152
- "camunda:inputParameter",
153
- "camunda:field"
154
- ]
155
- }
101
+ },
102
+ "constraints": {
103
+ "$id": "#/properties/property/constraints",
104
+ "type": "object",
105
+ "title": "property constraints",
106
+ "description": "The validation constraints",
107
+ "properties": {
108
+ "notEmpty": {
109
+ "$id": "#/properties/property/constraints/notEmpty",
110
+ "type": "boolean",
111
+ "title": "property constraints not empty",
112
+ "description": "The control field must not be empty"
156
113
  },
157
- "required": [
158
- "type"
159
- ]
114
+ "minLength": {
115
+ "$id": "#/properties/property/constraints/minLength",
116
+ "type": "number",
117
+ "title": "property constraints min length",
118
+ "description": "The minimal length for the control field value"
119
+ },
120
+ "maxLength": {
121
+ "$id": "#/properties/property/constraints/maxLength",
122
+ "type": "number",
123
+ "title": "property constraints max length",
124
+ "description": "The maximal length for the control field value"
125
+ },
126
+ "pattern": {
127
+ "$id": "#/properties/property/constraints/pattern",
128
+ "title": "property constraints pattern",
129
+ "description": "A regular expression pattern for the constraints",
130
+ "oneOf": [
131
+ {
132
+ "type": "object",
133
+ "properties": {
134
+ "value": {
135
+ "$id": "#/properties/property/constraints/pattern/value",
136
+ "type": "string",
137
+ "title": "property constraints pattern value",
138
+ "description": "The regular expression of the pattern constraint"
139
+ },
140
+ "message": {
141
+ "$id": "#/properties/property/constraints/pattern/message",
142
+ "type": "string",
143
+ "title": "property constraints pattern message",
144
+ "description": "The validation message of the pattern constraint"
145
+ }
146
+ }
147
+ },
148
+ {
149
+ "type": "string"
150
+ }
151
+ ]
152
+ }
160
153
  }
161
154
  },
162
- "required": [
163
- "binding"
164
- ]
165
- },
166
- "then": {
167
- "properties": {
168
- "type": {
169
- "enum": [
170
- "String",
171
- "Text",
172
- "Hidden",
173
- "Dropdown"
174
- ],
175
- "errorMessage": "invalid property type ${0} for binding type ${1/binding/type}; must be any of { String, Text, Hidden, Dropdown }"
176
- }
155
+ "group": {
156
+ "$id": "#/properties/property/group",
157
+ "type": "string",
158
+ "title": "property group",
159
+ "description": "The custom group of the control field for the property"
177
160
  }
178
161
  }
179
162
  }
180
- ],
181
- "properties": {
182
- "value": {
183
- "$id": "#/properties/property/value",
184
- "type": [
185
- "string",
186
- "boolean"
187
- ],
188
- "title": "property value",
189
- "description": "The value of the control field for the property"
190
- },
191
- "description": {
192
- "$id": "#/properties/property/description",
193
- "type": "string",
194
- "title": "property description",
195
- "description": "The description of the control field"
196
- },
197
- "label": {
198
- "$id": "#/properties/property/label",
199
- "type": "string",
200
- "title": "property label",
201
- "description": "The label of the control field for the property"
202
- },
203
- "type": {
204
- "$id": "#/properties/property/type",
205
- "type": "string",
206
- "title": "property type",
207
- "description": "The type of the control field"
208
- },
209
- "editable": {
210
- "$id": "#/properties/property/editable",
211
- "type": "boolean",
212
- "title": "property editable",
213
- "description": "Indicates whether the property is editable or not"
214
- },
215
- "choices": {
216
- "$id": "#/properties/property/choices",
217
- "type": "array",
218
- "title": "property choices",
219
- "description": "The choices for dropdown properties",
220
- "items": {
221
- "$id": "#/properties/property/choices/item",
222
- "type": "object",
223
- "properties": {
224
- "name": {
225
- "$id": "#/properties/property/choices/item/name",
226
- "type": "string",
227
- "title": "choice name",
228
- "description": "The name of the choice"
229
- },
230
- "value": {
231
- "$id": "#/properties/property/choices/item/value",
232
- "type": "string",
233
- "title": "choice value",
234
- "description": "The value of the choice"
235
- }
236
- },
237
- "required": [
238
- "value",
239
- "name"
240
- ],
241
- "errorMessage": "{ name, value } must be specified for \"Dropdown\" choices"
242
- }
243
- },
244
- "binding": {
245
- "$id": "#/properties/property/binding",
163
+ },
164
+ {
165
+ "$schema": "http://json-schema.org/draft-07/schema",
166
+ "type": "array",
167
+ "title": "element template properties",
168
+ "description": "The properties of the element template",
169
+ "default": [],
170
+ "items": {
246
171
  "type": "object",
247
- "title": "property binding",
248
- "description": "A binding to a BPMN 2.0 property",
172
+ "title": "element template property",
173
+ "description": "A property defined for the element template",
174
+ "default": {},
249
175
  "required": [
250
- "type"
176
+ "binding"
251
177
  ],
178
+ "errorMessage": {
179
+ "required": {
180
+ "binding": "missing binding for property \"${0#}\""
181
+ }
182
+ },
252
183
  "allOf": [
253
184
  {
254
185
  "if": {
255
186
  "properties": {
256
- "type": {
257
- "enum": [
258
- "property",
259
- "camunda:property",
260
- "camunda:inputParameter",
261
- "camunda:field"
187
+ "binding": {
188
+ "properties": {
189
+ "type": {
190
+ "const": "property"
191
+ }
192
+ },
193
+ "required": [
194
+ "type"
262
195
  ]
263
196
  }
264
197
  },
265
198
  "required": [
266
- "type"
199
+ "binding"
267
200
  ]
268
201
  },
269
202
  "then": {
270
- "required": [
271
- "name"
272
- ],
273
- "errorMessage": "property.binding ${0/type} requires name"
203
+ "properties": {
204
+ "type": {
205
+ "enum": [
206
+ "String",
207
+ "Text",
208
+ "Hidden",
209
+ "Dropdown",
210
+ "Boolean"
211
+ ],
212
+ "errorMessage": "invalid property type ${0} for binding type \"property\"; must be any of { String, Text, Hidden, Dropdown, Boolean }"
213
+ }
214
+ }
274
215
  }
275
216
  },
276
217
  {
277
218
  "if": {
278
219
  "properties": {
279
- "type": {
280
- "const": "camunda:outputParameter"
220
+ "binding": {
221
+ "properties": {
222
+ "type": {
223
+ "const": "camunda:executionListener"
224
+ }
225
+ },
226
+ "required": [
227
+ "type"
228
+ ]
281
229
  }
282
230
  },
283
231
  "required": [
284
- "type"
232
+ "binding"
285
233
  ]
286
234
  },
287
235
  "then": {
288
- "required": [
289
- "source"
290
- ],
291
- "errorMessage": "property.binding ${0/type} requires source"
236
+ "properties": {
237
+ "type": {
238
+ "enum": [
239
+ "Hidden"
240
+ ],
241
+ "errorMessage": "invalid property type ${1/type} for binding type \"camunda:executionListener\"; must be \"Hidden\""
242
+ }
243
+ }
292
244
  }
293
245
  },
294
246
  {
295
247
  "if": {
296
248
  "properties": {
297
- "type": {
298
- "const": "camunda:in"
249
+ "binding": {
250
+ "properties": {
251
+ "type": {
252
+ "enum": [
253
+ "camunda:property",
254
+ "camunda:outputParameter",
255
+ "camunda:in",
256
+ "camunda:in:businessKey",
257
+ "camunda:out",
258
+ "camunda:errorEventDefinition"
259
+ ]
260
+ }
261
+ },
262
+ "required": [
263
+ "type"
264
+ ]
299
265
  }
300
266
  },
301
267
  "required": [
302
- "type"
268
+ "binding"
303
269
  ]
304
270
  },
305
271
  "then": {
306
- "oneOf": [
307
- {
308
- "required": [
309
- "variables"
310
- ]
311
- },
312
- {
313
- "required": [
314
- "target"
315
- ]
272
+ "properties": {
273
+ "type": {
274
+ "enum": [
275
+ "String",
276
+ "Hidden",
277
+ "Dropdown"
278
+ ],
279
+ "errorMessage": "invalid property type ${0} for binding type ${1/binding/type}; must be any of { String, Hidden, Dropdown }"
316
280
  }
317
- ],
318
- "errorMessage": "property.binding ${0/type} requires variables or target"
281
+ }
319
282
  }
320
283
  },
321
284
  {
322
285
  "if": {
323
286
  "properties": {
324
- "type": {
325
- "const": "camunda:out"
287
+ "binding": {
288
+ "properties": {
289
+ "type": {
290
+ "enum": [
291
+ "camunda:inputParameter",
292
+ "camunda:field"
293
+ ]
294
+ }
295
+ },
296
+ "required": [
297
+ "type"
298
+ ]
326
299
  }
327
300
  },
328
301
  "required": [
329
- "type"
302
+ "binding"
330
303
  ]
331
304
  },
332
305
  "then": {
333
- "oneOf": [
334
- {
306
+ "properties": {
307
+ "type": {
308
+ "enum": [
309
+ "String",
310
+ "Text",
311
+ "Hidden",
312
+ "Dropdown"
313
+ ],
314
+ "errorMessage": "invalid property type ${0} for binding type ${1/binding/type}; must be any of { String, Text, Hidden, Dropdown }"
315
+ }
316
+ }
317
+ }
318
+ }
319
+ ],
320
+ "properties": {
321
+ "binding": {
322
+ "$id": "#/properties/property/binding",
323
+ "type": "object",
324
+ "title": "property binding",
325
+ "description": "A binding to a BPMN 2.0 property",
326
+ "required": [
327
+ "type"
328
+ ],
329
+ "allOf": [
330
+ {
331
+ "if": {
332
+ "properties": {
333
+ "type": {
334
+ "enum": [
335
+ "property",
336
+ "camunda:property",
337
+ "camunda:inputParameter",
338
+ "camunda:field"
339
+ ]
340
+ }
341
+ },
335
342
  "required": [
336
- "variables"
343
+ "type"
337
344
  ]
338
345
  },
339
- {
346
+ "then": {
340
347
  "required": [
341
- "source"
348
+ "name"
349
+ ],
350
+ "errorMessage": "property.binding ${0/type} requires name"
351
+ }
352
+ },
353
+ {
354
+ "if": {
355
+ "properties": {
356
+ "type": {
357
+ "const": "camunda:outputParameter"
358
+ }
359
+ },
360
+ "required": [
361
+ "type"
342
362
  ]
343
363
  },
344
- {
364
+ "then": {
345
365
  "required": [
346
- "sourceExpression"
347
- ]
348
- }
349
- ],
350
- "errorMessage": "property.binding ${0/type} requires variables, sourceExpression or source"
351
- }
352
- },
353
- {
354
- "if": {
355
- "properties": {
356
- "type": {
357
- "const": "camunda:errorEventDefinition"
366
+ "source"
367
+ ],
368
+ "errorMessage": "property.binding ${0/type} requires source"
358
369
  }
359
370
  },
360
- "required": [
361
- "type"
362
- ]
363
- },
364
- "then": {
365
- "oneOf": [
366
- {
371
+ {
372
+ "if": {
373
+ "properties": {
374
+ "type": {
375
+ "const": "camunda:in"
376
+ }
377
+ },
367
378
  "required": [
368
- "errorRef"
379
+ "type"
369
380
  ]
381
+ },
382
+ "then": {
383
+ "anyOf": [
384
+ {
385
+ "required": [
386
+ "variables"
387
+ ]
388
+ },
389
+ {
390
+ "required": [
391
+ "target"
392
+ ]
393
+ }
394
+ ],
395
+ "errorMessage": "property.binding ${0/type} requires variables, target, or both"
370
396
  }
371
- ],
372
- "errorMessage": "property.binding ${0/type} requires errorRef"
373
- }
374
- }
375
- ],
376
- "properties": {
377
- "type": {
378
- "$id": "#/properties/property/binding/type",
379
- "type": "string",
380
- "title": "property binding type",
381
- "enum": [
382
- "property",
383
- "camunda:property",
384
- "camunda:inputParameter",
385
- "camunda:outputParameter",
386
- "camunda:in",
387
- "camunda:out",
388
- "camunda:in:businessKey",
389
- "camunda:executionListener",
390
- "camunda:field",
391
- "camunda:errorEventDefinition"
392
- ],
393
- "errorMessage": "invalid property.binding type ${0}; must be any of { property, camunda:property, camunda:inputParameter, camunda:outputParameter, camunda:in, camunda:out, camunda:in:businessKey, camunda:executionListener, camunda:field, camunda:errorEventDefinition }",
394
- "description": "The type of the property binding"
395
- },
396
- "name": {
397
- "$id": "#/properties/property/binding/name",
398
- "type": "string",
399
- "title": "property binding name",
400
- "description": "The name of binding xml property"
401
- },
402
- "event": {
403
- "$id": "#/properties/property/binding/event",
404
- "type": "string",
405
- "title": "property binding event",
406
- "description": "The event type of an execution listener binding"
407
- },
408
- "scriptFormat": {
409
- "$id": "#/properties/property/binding/scriptFormat",
410
- "type": "string",
411
- "title": "property binding script format",
412
- "description": "The format of a script property binding (camunda:outputParameter, camunda:inputParameter)"
413
- },
414
- "source": {
415
- "$id": "#/properties/property/binding/source",
416
- "type": "string",
417
- "title": "property binding source",
418
- "description": "The source value of a property binding (camunda:outputParameter, camunda:out)"
419
- },
420
- "target": {
421
- "$id": "#/properties/property/binding/target",
422
- "type": "string",
423
- "title": "property binding target",
424
- "description": "The target value to be mapped to (camunda:in)"
425
- },
426
- "expression": {
427
- "$id": "#/properties/property/binding/expression",
428
- "type": "boolean",
429
- "title": "property binding expression",
430
- "description": "True indicates that the control field value is an expression (camunda:in, camunda:field)"
431
- },
432
- "variables": {
433
- "$id": "#/properties/property/binding/variables",
434
- "type": "string",
435
- "title": "property binding variables",
436
- "enum": [
437
- "all",
438
- "local"
439
- ],
440
- "description": "Either all or local indicating the variable mapping (camunda:in)"
441
- },
442
- "sourceExpression": {
443
- "$id": "#/properties/property/binding/sourceExpression",
444
- "type": "string",
445
- "title": "property binding source expression",
446
- "description": "The string containing the expression for the source attribute (camunda:out)"
447
- }
448
- }
449
- },
450
- "constraints": {
451
- "$id": "#/properties/property/constraints",
452
- "type": "object",
453
- "title": "property constraints",
454
- "description": "The validation constraints",
455
- "properties": {
456
- "notEmpty": {
457
- "$id": "#/properties/property/constraints/notEmpty",
458
- "type": "boolean",
459
- "title": "property constraints not empty",
460
- "description": "The control field must not be empty"
461
- },
462
- "minLength": {
463
- "$id": "#/properties/property/constraints/minLength",
464
- "type": "number",
465
- "title": "property constraints min length",
466
- "description": "The minimal length for the control field value"
467
- },
468
- "maxLength": {
469
- "$id": "#/properties/property/constraints/maxLength",
470
- "type": "number",
471
- "title": "property constraints max length",
472
- "description": "The maximal length for the control field value"
473
- },
474
- "pattern": {
475
- "$id": "#/properties/property/constraints/pattern",
476
-
477
- "title": "property constraints pattern",
478
- "description": "A regular expression pattern for the constraints",
479
- "oneOf": [
397
+ },
480
398
  {
481
- "type": "object",
482
- "properties": {
483
- "value": {
484
- "$id": "#/properties/property/constraints/pattern/value",
485
- "type": "string",
486
- "title": "property constraints pattern value",
487
- "description": "The regular expression of the pattern constraint"
399
+ "if": {
400
+ "properties": {
401
+ "type": {
402
+ "const": "camunda:out"
403
+ }
488
404
  },
489
- "message": {
490
- "$id": "#/properties/property/constraints/pattern/message",
491
- "type": "string",
492
- "title": "property constraints pattern message",
493
- "description": "The validation message of the pattern constraint"
494
- }
405
+ "required": [
406
+ "type"
407
+ ]
408
+ },
409
+ "then": {
410
+ "oneOf": [
411
+ {
412
+ "required": [
413
+ "variables"
414
+ ],
415
+ "not": {
416
+ "anyOf": [
417
+ {
418
+ "required": [
419
+ "source"
420
+ ]
421
+ },
422
+ {
423
+ "required": [
424
+ "sourceExpression"
425
+ ]
426
+ }
427
+ ]
428
+ }
429
+ },
430
+ {
431
+ "required": [
432
+ "source"
433
+ ],
434
+ "not": {
435
+ "anyOf": [
436
+ {
437
+ "required": [
438
+ "variables"
439
+ ]
440
+ },
441
+ {
442
+ "required": [
443
+ "sourceExpression"
444
+ ]
445
+ }
446
+ ]
447
+ }
448
+ },
449
+ {
450
+ "required": [
451
+ "sourceExpression"
452
+ ],
453
+ "not": {
454
+ "anyOf": [
455
+ {
456
+ "required": [
457
+ "variables"
458
+ ]
459
+ },
460
+ {
461
+ "required": [
462
+ "source"
463
+ ]
464
+ }
465
+ ]
466
+ }
467
+ },
468
+ {
469
+ "required": [
470
+ "variables",
471
+ "sourceExpression"
472
+ ],
473
+ "not": {
474
+ "required": [
475
+ "source"
476
+ ]
477
+ }
478
+ },
479
+ {
480
+ "required": [
481
+ "variables",
482
+ "source"
483
+ ],
484
+ "not": {
485
+ "required": [
486
+ "sourceExpression"
487
+ ]
488
+ }
489
+ }
490
+ ],
491
+ "errorMessage": "property.binding ${0/type} requires one of the following: variables, sourceExpression, source, (sourceExpression and variables), or (source and variables)"
495
492
  }
496
493
  },
497
494
  {
498
- "type": "string"
495
+ "if": {
496
+ "properties": {
497
+ "type": {
498
+ "const": "camunda:errorEventDefinition"
499
+ }
500
+ },
501
+ "required": [
502
+ "type"
503
+ ]
504
+ },
505
+ "then": {
506
+ "oneOf": [
507
+ {
508
+ "required": [
509
+ "errorRef"
510
+ ]
511
+ }
512
+ ],
513
+ "errorMessage": "property.binding ${0/type} requires errorRef"
514
+ }
499
515
  }
500
- ]
516
+ ],
517
+ "properties": {
518
+ "type": {
519
+ "$id": "#/properties/property/binding/type",
520
+ "type": "string",
521
+ "title": "property binding type",
522
+ "enum": [
523
+ "property",
524
+ "camunda:property",
525
+ "camunda:inputParameter",
526
+ "camunda:outputParameter",
527
+ "camunda:in",
528
+ "camunda:out",
529
+ "camunda:in:businessKey",
530
+ "camunda:executionListener",
531
+ "camunda:field",
532
+ "camunda:errorEventDefinition"
533
+ ],
534
+ "errorMessage": "invalid property.binding type ${0}; must be any of { property, camunda:property, camunda:inputParameter, camunda:outputParameter, camunda:in, camunda:out, camunda:in:businessKey, camunda:executionListener, camunda:field, camunda:errorEventDefinition }",
535
+ "description": "The type of the property binding"
536
+ },
537
+ "name": {
538
+ "$id": "#/properties/property/binding/name",
539
+ "type": "string",
540
+ "title": "property binding name",
541
+ "description": "The name of binding xml property"
542
+ },
543
+ "event": {
544
+ "$id": "#/properties/property/binding/event",
545
+ "type": "string",
546
+ "title": "property binding event",
547
+ "description": "The event type of an execution listener binding"
548
+ },
549
+ "scriptFormat": {
550
+ "$id": "#/properties/property/binding/scriptFormat",
551
+ "type": "string",
552
+ "title": "property binding script format",
553
+ "description": "The format of a script property binding (camunda:outputParameter, camunda:inputParameter)"
554
+ },
555
+ "source": {
556
+ "$id": "#/properties/property/binding/source",
557
+ "type": "string",
558
+ "title": "property binding source",
559
+ "description": "The source value of a property binding (camunda:outputParameter, camunda:out)"
560
+ },
561
+ "target": {
562
+ "$id": "#/properties/property/binding/target",
563
+ "type": "string",
564
+ "title": "property binding target",
565
+ "description": "The target value to be mapped to (camunda:in)"
566
+ },
567
+ "expression": {
568
+ "$id": "#/properties/property/binding/expression",
569
+ "type": "boolean",
570
+ "title": "property binding expression",
571
+ "description": "True indicates that the control field value is an expression (camunda:in, camunda:field)"
572
+ },
573
+ "variables": {
574
+ "$id": "#/properties/property/binding/variables",
575
+ "type": "string",
576
+ "title": "property binding variables",
577
+ "enum": [
578
+ "all",
579
+ "local"
580
+ ],
581
+ "description": "Either all or local indicating the variable mapping (camunda:in)"
582
+ },
583
+ "sourceExpression": {
584
+ "$id": "#/properties/property/binding/sourceExpression",
585
+ "type": "string",
586
+ "title": "property binding source expression",
587
+ "description": "The string containing the expression for the source attribute (camunda:out)"
588
+ }
589
+ }
501
590
  }
502
591
  }
503
592
  }
504
593
  }
505
- }
594
+ ]
506
595
  },
507
- "scopes_old": {
508
- "$id": "#/definitions/scopes_old",
596
+ "template": {
509
597
  "type": "object",
510
- "title": "element template scope",
511
- "deprecated": true,
512
- "description": "@Deprecated - Special scoped bindings that allow you to configure nested elements",
513
- "additionalProperties": {
514
- "not": true,
515
- "errorMessage": "invalid scope ${0#}, object descriptor is only supported for \"camunda:Connector\""
516
- },
517
- "properties": {
518
- "camunda:Connector": {
519
- "type": "object",
520
- "title": "element template scoped connector binding",
521
- "description": "A scoped binding for a camunda connector inside the element",
522
- "properties": {
523
- "properties": {
524
- "$ref": "#/definitions/properties"
525
- }
526
- }
527
- }
528
- }
529
- },
530
- "scopes": {
531
- "$id": "#/definitions/scopes",
532
- "type": "array",
533
- "title": "element template scope",
534
- "description": "Special scoped bindings that allow you to configure nested elements",
535
- "items": {
536
- "$id": "#/scopes/item",
537
- "type": "object",
538
- "title": "element template scope item",
539
- "description": "Scoped binding to configure nested elements",
540
- "properties": {
541
- "type": {
542
- "$id": "#scopes/item/type",
543
- "type": "string",
544
- "enum": [
545
- "camunda:Connector",
546
- "bpmn:Error"
547
- ],
548
- "errorMessage": "invalid scope type ${0}; must be any of { camunda:Connector, bpmn:Error }"
549
- },
598
+ "allOf": [
599
+ {
600
+ "required": [
601
+ "name",
602
+ "id",
603
+ "appliesTo",
604
+ "properties"
605
+ ],
550
606
  "properties": {
551
- "$ref": "#/definitions/properties"
552
- }
553
- },
554
- "required": [
555
- "type",
556
- "properties"
557
- ],
558
- "errorMessage": {
559
- "required": {
560
- "type": "invalid scope, missing type",
561
- "properties": "invalid scope ${0/type}, missing properties=[]"
562
- }
563
- },
564
- "allOf": [
565
- {
566
- "if": {
567
- "properties": {
568
- "type": {
569
- "enum": [
570
- "bpmn:Error"
571
- ]
607
+ "name": {
608
+ "$id": "#/name",
609
+ "type": "string",
610
+ "title": "element template name",
611
+ "description": "The name of the element template"
612
+ },
613
+ "id": {
614
+ "$id": "#/id",
615
+ "type": "string",
616
+ "title": "element template id",
617
+ "description": "The identifier of the element template"
618
+ },
619
+ "description": {
620
+ "$id": "#/description",
621
+ "type": "string",
622
+ "title": "element template description",
623
+ "description": "The description of the element template"
624
+ },
625
+ "version": {
626
+ "$id": "#/version",
627
+ "type": "number",
628
+ "title": "element template version",
629
+ "description": "The version of the element template"
630
+ },
631
+ "isDefault": {
632
+ "$id": "#/isDefault",
633
+ "type": "boolean",
634
+ "title": "element template is default",
635
+ "description": "Indicates whether the element template is a default template"
636
+ },
637
+ "appliesTo": {
638
+ "$id": "#/appliesTo",
639
+ "type": "array",
640
+ "title": "element template applies to",
641
+ "description": "The definition for which element types the element template can be applied",
642
+ "default": [],
643
+ "items": {
644
+ "$id": "#/appliesTo/items",
645
+ "type": "string",
646
+ "pattern": "^(.*?:)",
647
+ "errorMessage": {
648
+ "pattern": "invalid item for \"appliesTo\", should contain namespaced property, example: \"bpmn:Task\""
572
649
  }
573
- },
574
- "required": [
575
- "type"
576
- ]
650
+ }
651
+ },
652
+ "metadata": {
653
+ "$id": "#/metadata",
654
+ "type": "object",
655
+ "title": "element template metadata",
656
+ "description": "Some metadata for further configuration"
577
657
  },
578
- "then": {
579
- "required": [
580
- "id"
581
- ],
582
- "errorMessage": "invalid scope ${0/type}, missing id"
658
+ "entriesVisible": {
659
+ "$id": "#/entriesVisible",
660
+ "type": "boolean",
661
+ "title": "element template entries visible",
662
+ "description": "Select whether non-template entries are visible in the properties panel"
663
+ },
664
+ "groups": {
665
+ "$id": "#/groups",
666
+ "type": "array",
667
+ "title": "element template properties groups",
668
+ "description": "The custom defined groups of the element template",
669
+ "default": [],
670
+ "items": {
671
+ "$id": "#/groups/group",
672
+ "type": "object",
673
+ "title": "element template group",
674
+ "description": "A custom defined group for the element template",
675
+ "default": {},
676
+ "required": [
677
+ "id",
678
+ "label"
679
+ ],
680
+ "errorMessage": {
681
+ "required": {
682
+ "id": "missing id for group \"${0#}\"",
683
+ "label": "missing label for group \"${0#}\""
684
+ }
685
+ },
686
+ "properties": {
687
+ "id": {
688
+ "$id": "#/groups/group/id",
689
+ "type": "string",
690
+ "title": "group id",
691
+ "description": "The id of the custom group"
692
+ },
693
+ "label": {
694
+ "$id": "#/groups/group/label",
695
+ "type": "string",
696
+ "title": "group label",
697
+ "description": "The label of the custom group"
698
+ }
699
+ }
700
+ }
701
+ }
702
+ },
703
+ "errorMessage": {
704
+ "required": {
705
+ "name": "missing template name",
706
+ "id": "missing template id",
707
+ "appliesTo": "missing appliesTo=[]",
708
+ "properties": "missing properties=[]"
583
709
  }
584
710
  }
585
- ]
586
- }
587
- },
588
- "template": {
589
- "type": "object",
590
- "required": [
591
- "name",
592
- "id",
593
- "appliesTo",
594
- "properties"
711
+ }
595
712
  ],
596
713
  "properties": {
597
- "name": {
598
- "$id": "#/name",
599
- "type": "string",
600
- "title": "element template name",
601
- "description": "The name of the element template"
602
- },
603
- "id": {
604
- "$id": "#/id",
605
- "type": "string",
606
- "title": "element template id",
607
- "description": "The identifier of the element template"
608
- },
609
- "description": {
610
- "$id": "#/description",
611
- "type": "string",
612
- "title": "element template description",
613
- "description": "The description of the element template"
614
- },
615
- "version": {
616
- "$id": "#/version",
617
- "type": "number",
618
- "title": "element template version",
619
- "description": "The version of the element template"
620
- },
621
- "isDefault": {
622
- "$id": "#/isDefault",
623
- "type": "boolean",
624
- "title": "element template is default",
625
- "description": "Indicates whether the element template is a default template"
626
- },
627
- "appliesTo": {
628
- "$id": "#/appliesTo",
629
- "type": "array",
630
- "title": "element template applies to",
631
- "description": "The definition for which element types the element template can be applied",
632
- "default": [],
633
- "items": {
634
- "$id": "#/appliesTo/items",
635
- "type": "string",
636
- "pattern": "^(.*?:)",
637
- "errorMessage": {
638
- "pattern": "invalid item for \"appliesTo\", should contain namespaced property, example: \"bpmn:Task\""
639
- }
640
- }
641
- },
642
714
  "properties": {
643
715
  "$ref": "#/definitions/properties",
644
716
  "$id": "#/properties"
645
717
  },
646
- "metadata": {
647
- "$id": "#/metadata",
648
- "type": "object",
649
- "title": "element template metadata",
650
- "description": "Some metadata for further configuration"
651
- },
652
718
  "scopes": {
653
- "oneOf": [
654
- {
655
- "$ref": "#/definitions/scopes_old"
719
+ "$id": "#/scopes",
720
+ "type": "array",
721
+ "title": "element template scope",
722
+ "description": "Special scoped bindings that allow you to configure nested elements",
723
+ "items": {
724
+ "$id": "#/scopes/item",
725
+ "type": "object",
726
+ "title": "element template scope item",
727
+ "description": "Scoped binding to configure nested elements",
728
+ "properties": {
729
+ "type": {
730
+ "$id": "#scopes/item/type",
731
+ "type": "string",
732
+ "enum": [
733
+ "camunda:Connector",
734
+ "bpmn:Error"
735
+ ],
736
+ "errorMessage": "invalid scope type ${0}; must be any of { camunda:Connector, bpmn:Error }"
737
+ },
738
+ "properties": {
739
+ "$id": "#/scopes/properties",
740
+ "allOf": [
741
+ {
742
+ "$ref": "#/definitions/properties/allOf/0"
743
+ },
744
+ {
745
+ "$ref": "#/definitions/properties/allOf/1"
746
+ }
747
+ ]
748
+ }
656
749
  },
657
- {
658
- "$ref": "#/definitions/scopes"
659
- }
660
- ]
661
- },
662
- "entriesVisible": {
663
- "$id": "#/entriesVisible",
664
- "deprecated": true,
665
- "type": [ "object", "boolean" ],
666
- "title": "element template entries visible",
667
- "description": "@Deprecated - Select which entries are visible in the properties panel"
668
- }
669
- },
670
- "errorMessage": {
671
- "required": {
672
- "name": "missing template name",
673
- "id": "missing template id",
674
- "appliesTo": "missing appliesTo=[]",
675
- "properties": "missing properties=[]"
750
+ "required": [
751
+ "type",
752
+ "properties"
753
+ ],
754
+ "errorMessage": {
755
+ "required": {
756
+ "type": "invalid scope, missing type",
757
+ "properties": "invalid scope ${0/type}, missing properties=[]"
758
+ }
759
+ },
760
+ "allOf": [
761
+ {
762
+ "if": {
763
+ "properties": {
764
+ "type": {
765
+ "enum": [
766
+ "bpmn:Error"
767
+ ]
768
+ }
769
+ },
770
+ "required": [
771
+ "type"
772
+ ]
773
+ },
774
+ "then": {
775
+ "required": [
776
+ "id"
777
+ ],
778
+ "errorMessage": "invalid scope ${0/type}, missing id"
779
+ }
780
+ }
781
+ ]
782
+ }
676
783
  }
677
784
  }
678
785
  }
@@ -688,4 +795,4 @@
688
795
  }
689
796
  }
690
797
  ]
691
- }
798
+ }