camunda-bpmn-js 0.16.1 → 0.17.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.
- package/dist/assets/properties-panel.css +4 -10
- package/dist/base-modeler.development.js +2080 -1271
- package/dist/base-modeler.production.min.js +4 -4
- package/dist/base-navigated-viewer.development.js +976 -440
- package/dist/base-navigated-viewer.production.min.js +2 -2
- package/dist/base-viewer.development.js +950 -434
- package/dist/base-viewer.production.min.js +2 -2
- package/dist/camunda-cloud-modeler.development.js +2986 -1512
- package/dist/camunda-cloud-modeler.production.min.js +4 -4
- package/dist/camunda-cloud-navigated-viewer.development.js +1017 -432
- package/dist/camunda-cloud-navigated-viewer.production.min.js +2 -2
- package/dist/camunda-cloud-viewer.development.js +1002 -437
- package/dist/camunda-cloud-viewer.production.min.js +2 -2
- package/dist/camunda-platform-modeler.development.js +2915 -2137
- package/dist/camunda-platform-modeler.production.min.js +4 -4
- package/dist/camunda-platform-navigated-viewer.development.js +980 -444
- package/dist/camunda-platform-navigated-viewer.production.min.js +2 -2
- package/dist/camunda-platform-viewer.development.js +954 -438
- package/dist/camunda-platform-viewer.production.min.js +2 -2
- package/lib/camunda-cloud/Modeler.js +1 -4
- package/lib/camunda-platform/Modeler.js +0 -3
- package/package.json +15 -13
- package/CHANGELOG.md +0 -331
|
@@ -108,6 +108,26 @@
|
|
|
108
108
|
});
|
|
109
109
|
return match;
|
|
110
110
|
}
|
|
111
|
+
/**
|
|
112
|
+
* Find element index in collection.
|
|
113
|
+
*
|
|
114
|
+
* @param {Array|Object} collection
|
|
115
|
+
* @param {Function} matcher
|
|
116
|
+
*
|
|
117
|
+
* @return {Object}
|
|
118
|
+
*/
|
|
119
|
+
|
|
120
|
+
function findIndex(collection, matcher) {
|
|
121
|
+
matcher = toMatcher(matcher);
|
|
122
|
+
var idx = isArray(collection) ? -1 : undefined;
|
|
123
|
+
forEach(collection, function (val, key) {
|
|
124
|
+
if (matcher(val, key)) {
|
|
125
|
+
idx = key;
|
|
126
|
+
return false;
|
|
127
|
+
}
|
|
128
|
+
});
|
|
129
|
+
return idx;
|
|
130
|
+
}
|
|
111
131
|
/**
|
|
112
132
|
* Find element in collection.
|
|
113
133
|
*
|
|
@@ -1170,149 +1190,6 @@
|
|
|
1170
1190
|
}
|
|
1171
1191
|
}
|
|
1172
1192
|
|
|
1173
|
-
/**
|
|
1174
|
-
* Serialization util
|
|
1175
|
-
*/
|
|
1176
|
-
|
|
1177
|
-
var TEXT_ENTITIES = /([&<>]{1})/g;
|
|
1178
|
-
var ATTR_ENTITIES = /([\n\r"]{1})/g;
|
|
1179
|
-
|
|
1180
|
-
var ENTITY_REPLACEMENT = {
|
|
1181
|
-
'&': '&',
|
|
1182
|
-
'<': '<',
|
|
1183
|
-
'>': '>',
|
|
1184
|
-
'"': '\''
|
|
1185
|
-
};
|
|
1186
|
-
|
|
1187
|
-
function escape(str, pattern) {
|
|
1188
|
-
|
|
1189
|
-
function replaceFn(match, entity) {
|
|
1190
|
-
return ENTITY_REPLACEMENT[entity] || entity;
|
|
1191
|
-
}
|
|
1192
|
-
|
|
1193
|
-
return str.replace(pattern, replaceFn);
|
|
1194
|
-
}
|
|
1195
|
-
|
|
1196
|
-
function serialize(node, output) {
|
|
1197
|
-
|
|
1198
|
-
var i, len, attrMap, attrNode, childNodes;
|
|
1199
|
-
|
|
1200
|
-
switch (node.nodeType) {
|
|
1201
|
-
// TEXT
|
|
1202
|
-
case 3:
|
|
1203
|
-
// replace special XML characters
|
|
1204
|
-
output.push(escape(node.textContent, TEXT_ENTITIES));
|
|
1205
|
-
break;
|
|
1206
|
-
|
|
1207
|
-
// ELEMENT
|
|
1208
|
-
case 1:
|
|
1209
|
-
output.push('<', node.tagName);
|
|
1210
|
-
|
|
1211
|
-
if (node.hasAttributes()) {
|
|
1212
|
-
attrMap = node.attributes;
|
|
1213
|
-
for (i = 0, len = attrMap.length; i < len; ++i) {
|
|
1214
|
-
attrNode = attrMap.item(i);
|
|
1215
|
-
output.push(' ', attrNode.name, '="', escape(attrNode.value, ATTR_ENTITIES), '"');
|
|
1216
|
-
}
|
|
1217
|
-
}
|
|
1218
|
-
|
|
1219
|
-
if (node.hasChildNodes()) {
|
|
1220
|
-
output.push('>');
|
|
1221
|
-
childNodes = node.childNodes;
|
|
1222
|
-
for (i = 0, len = childNodes.length; i < len; ++i) {
|
|
1223
|
-
serialize(childNodes.item(i), output);
|
|
1224
|
-
}
|
|
1225
|
-
output.push('</', node.tagName, '>');
|
|
1226
|
-
} else {
|
|
1227
|
-
output.push('/>');
|
|
1228
|
-
}
|
|
1229
|
-
break;
|
|
1230
|
-
|
|
1231
|
-
// COMMENT
|
|
1232
|
-
case 8:
|
|
1233
|
-
output.push('<!--', escape(node.nodeValue, TEXT_ENTITIES), '-->');
|
|
1234
|
-
break;
|
|
1235
|
-
|
|
1236
|
-
// CDATA
|
|
1237
|
-
case 4:
|
|
1238
|
-
output.push('<![CDATA[', node.nodeValue, ']]>');
|
|
1239
|
-
break;
|
|
1240
|
-
|
|
1241
|
-
default:
|
|
1242
|
-
throw new Error('unable to handle node ' + node.nodeType);
|
|
1243
|
-
}
|
|
1244
|
-
|
|
1245
|
-
return output;
|
|
1246
|
-
}
|
|
1247
|
-
|
|
1248
|
-
/**
|
|
1249
|
-
* innerHTML like functionality for SVG elements.
|
|
1250
|
-
* based on innerSVG (https://code.google.com/p/innersvg)
|
|
1251
|
-
*/
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
function set(element, svg) {
|
|
1255
|
-
|
|
1256
|
-
var parsed = parse(svg);
|
|
1257
|
-
|
|
1258
|
-
// clear element contents
|
|
1259
|
-
clear(element);
|
|
1260
|
-
|
|
1261
|
-
if (!svg) {
|
|
1262
|
-
return;
|
|
1263
|
-
}
|
|
1264
|
-
|
|
1265
|
-
if (!isFragment(parsed)) {
|
|
1266
|
-
// extract <svg> from parsed document
|
|
1267
|
-
parsed = parsed.documentElement;
|
|
1268
|
-
}
|
|
1269
|
-
|
|
1270
|
-
var nodes = slice(parsed.childNodes);
|
|
1271
|
-
|
|
1272
|
-
// import + append each node
|
|
1273
|
-
for (var i = 0; i < nodes.length; i++) {
|
|
1274
|
-
appendTo(nodes[i], element);
|
|
1275
|
-
}
|
|
1276
|
-
|
|
1277
|
-
}
|
|
1278
|
-
|
|
1279
|
-
function get(element) {
|
|
1280
|
-
var child = element.firstChild,
|
|
1281
|
-
output = [];
|
|
1282
|
-
|
|
1283
|
-
while (child) {
|
|
1284
|
-
serialize(child, output);
|
|
1285
|
-
child = child.nextSibling;
|
|
1286
|
-
}
|
|
1287
|
-
|
|
1288
|
-
return output.join('');
|
|
1289
|
-
}
|
|
1290
|
-
|
|
1291
|
-
function isFragment(node) {
|
|
1292
|
-
return node.nodeName === '#document-fragment';
|
|
1293
|
-
}
|
|
1294
|
-
|
|
1295
|
-
function innerSVG(element, svg) {
|
|
1296
|
-
|
|
1297
|
-
if (svg !== undefined) {
|
|
1298
|
-
|
|
1299
|
-
try {
|
|
1300
|
-
set(element, svg);
|
|
1301
|
-
} catch (e) {
|
|
1302
|
-
throw new Error('error parsing SVG: ' + e.message);
|
|
1303
|
-
}
|
|
1304
|
-
|
|
1305
|
-
return element;
|
|
1306
|
-
} else {
|
|
1307
|
-
return get(element);
|
|
1308
|
-
}
|
|
1309
|
-
}
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
function slice(arr) {
|
|
1313
|
-
return Array.prototype.slice.call(arr);
|
|
1314
|
-
}
|
|
1315
|
-
|
|
1316
1193
|
/**
|
|
1317
1194
|
* transform accessor utility
|
|
1318
1195
|
*/
|
|
@@ -1463,11 +1340,11 @@
|
|
|
1463
1340
|
radius = shape.width / 2;
|
|
1464
1341
|
|
|
1465
1342
|
var circlePath = [
|
|
1466
|
-
['M', cx, cy],
|
|
1467
|
-
['m', 0, -radius],
|
|
1468
|
-
['a', radius, radius, 0, 1, 1, 0, 2 * radius],
|
|
1469
|
-
['a', radius, radius, 0, 1, 1, 0, -2 * radius],
|
|
1470
|
-
['z']
|
|
1343
|
+
[ 'M', cx, cy ],
|
|
1344
|
+
[ 'm', 0, -radius ],
|
|
1345
|
+
[ 'a', radius, radius, 0, 1, 1, 0, 2 * radius ],
|
|
1346
|
+
[ 'a', radius, radius, 0, 1, 1, 0, -2 * radius ],
|
|
1347
|
+
[ 'z' ]
|
|
1471
1348
|
];
|
|
1472
1349
|
|
|
1473
1350
|
return componentsToPath(circlePath);
|
|
@@ -1481,16 +1358,16 @@
|
|
|
1481
1358
|
height = shape.height;
|
|
1482
1359
|
|
|
1483
1360
|
var roundRectPath = [
|
|
1484
|
-
['M', x + borderRadius, y],
|
|
1485
|
-
['l', width - borderRadius * 2, 0],
|
|
1486
|
-
['a', borderRadius, borderRadius, 0, 0, 1, borderRadius, borderRadius],
|
|
1487
|
-
['l', 0, height - borderRadius * 2],
|
|
1488
|
-
['a', borderRadius, borderRadius, 0, 0, 1, -borderRadius, borderRadius],
|
|
1489
|
-
['l', borderRadius * 2 - width, 0],
|
|
1490
|
-
['a', borderRadius, borderRadius, 0, 0, 1, -borderRadius, -borderRadius],
|
|
1491
|
-
['l', 0, borderRadius * 2 - height],
|
|
1492
|
-
['a', borderRadius, borderRadius, 0, 0, 1, borderRadius, -borderRadius],
|
|
1493
|
-
['z']
|
|
1361
|
+
[ 'M', x + borderRadius, y ],
|
|
1362
|
+
[ 'l', width - borderRadius * 2, 0 ],
|
|
1363
|
+
[ 'a', borderRadius, borderRadius, 0, 0, 1, borderRadius, borderRadius ],
|
|
1364
|
+
[ 'l', 0, height - borderRadius * 2 ],
|
|
1365
|
+
[ 'a', borderRadius, borderRadius, 0, 0, 1, -borderRadius, borderRadius ],
|
|
1366
|
+
[ 'l', borderRadius * 2 - width, 0 ],
|
|
1367
|
+
[ 'a', borderRadius, borderRadius, 0, 0, 1, -borderRadius, -borderRadius ],
|
|
1368
|
+
[ 'l', 0, borderRadius * 2 - height ],
|
|
1369
|
+
[ 'a', borderRadius, borderRadius, 0, 0, 1, borderRadius, -borderRadius ],
|
|
1370
|
+
[ 'z' ]
|
|
1494
1371
|
];
|
|
1495
1372
|
|
|
1496
1373
|
return componentsToPath(roundRectPath);
|
|
@@ -1506,11 +1383,11 @@
|
|
|
1506
1383
|
halfHeight = height / 2;
|
|
1507
1384
|
|
|
1508
1385
|
var diamondPath = [
|
|
1509
|
-
['M', x + halfWidth, y],
|
|
1510
|
-
['l', halfWidth, halfHeight],
|
|
1511
|
-
['l', -halfWidth, halfHeight],
|
|
1512
|
-
['l', -halfWidth, -halfHeight],
|
|
1513
|
-
['z']
|
|
1386
|
+
[ 'M', x + halfWidth, y ],
|
|
1387
|
+
[ 'l', halfWidth, halfHeight ],
|
|
1388
|
+
[ 'l', -halfWidth, halfHeight ],
|
|
1389
|
+
[ 'l', -halfWidth, -halfHeight ],
|
|
1390
|
+
[ 'z' ]
|
|
1514
1391
|
];
|
|
1515
1392
|
|
|
1516
1393
|
return componentsToPath(diamondPath);
|
|
@@ -1523,11 +1400,11 @@
|
|
|
1523
1400
|
height = shape.height;
|
|
1524
1401
|
|
|
1525
1402
|
var rectPath = [
|
|
1526
|
-
['M', x, y],
|
|
1527
|
-
['l', width, 0],
|
|
1528
|
-
['l', 0, height],
|
|
1529
|
-
['l', -width, 0],
|
|
1530
|
-
['z']
|
|
1403
|
+
[ 'M', x, y ],
|
|
1404
|
+
[ 'l', width, 0 ],
|
|
1405
|
+
[ 'l', 0, height ],
|
|
1406
|
+
[ 'l', -width, 0 ],
|
|
1407
|
+
[ 'z' ]
|
|
1531
1408
|
];
|
|
1532
1409
|
|
|
1533
1410
|
return componentsToPath(rectPath);
|
|
@@ -2093,52 +1970,688 @@
|
|
|
2093
1970
|
|
|
2094
1971
|
html = html.replace(/^\s+|\s+$/g, ''); // Remove leading/trailing whitespace
|
|
2095
1972
|
|
|
2096
|
-
var tag = m[1];
|
|
1973
|
+
var tag = m[1];
|
|
1974
|
+
|
|
1975
|
+
// body support
|
|
1976
|
+
if (tag == 'body') {
|
|
1977
|
+
var el = doc.createElement('html');
|
|
1978
|
+
el.innerHTML = html;
|
|
1979
|
+
return el.removeChild(el.lastChild);
|
|
1980
|
+
}
|
|
1981
|
+
|
|
1982
|
+
// wrap map
|
|
1983
|
+
var wrap = map$1[tag] || map$1._default;
|
|
1984
|
+
var depth = wrap[0];
|
|
1985
|
+
var prefix = wrap[1];
|
|
1986
|
+
var suffix = wrap[2];
|
|
1987
|
+
var el = doc.createElement('div');
|
|
1988
|
+
el.innerHTML = prefix + html + suffix;
|
|
1989
|
+
while (depth--) el = el.lastChild;
|
|
1990
|
+
|
|
1991
|
+
// one element
|
|
1992
|
+
if (el.firstChild == el.lastChild) {
|
|
1993
|
+
return el.removeChild(el.firstChild);
|
|
1994
|
+
}
|
|
1995
|
+
|
|
1996
|
+
// several elements
|
|
1997
|
+
var fragment = doc.createDocumentFragment();
|
|
1998
|
+
while (el.firstChild) {
|
|
1999
|
+
fragment.appendChild(el.removeChild(el.firstChild));
|
|
2000
|
+
}
|
|
2001
|
+
|
|
2002
|
+
return fragment;
|
|
2003
|
+
}
|
|
2004
|
+
|
|
2005
|
+
function query(selector, el) {
|
|
2006
|
+
el = el || document;
|
|
2007
|
+
|
|
2008
|
+
return el.querySelector(selector);
|
|
2009
|
+
}
|
|
2010
|
+
|
|
2011
|
+
function all(selector, el) {
|
|
2012
|
+
el = el || document;
|
|
2013
|
+
|
|
2014
|
+
return el.querySelectorAll(selector);
|
|
2015
|
+
}
|
|
2016
|
+
|
|
2017
|
+
function remove$1(el) {
|
|
2018
|
+
el.parentNode && el.parentNode.removeChild(el);
|
|
2019
|
+
}
|
|
2020
|
+
|
|
2021
|
+
function ensureImported$1(element, target) {
|
|
2022
|
+
|
|
2023
|
+
if (element.ownerDocument !== target.ownerDocument) {
|
|
2024
|
+
try {
|
|
2025
|
+
// may fail on webkit
|
|
2026
|
+
return target.ownerDocument.importNode(element, true);
|
|
2027
|
+
} catch (e) {
|
|
2028
|
+
// ignore
|
|
2029
|
+
}
|
|
2030
|
+
}
|
|
2031
|
+
|
|
2032
|
+
return element;
|
|
2033
|
+
}
|
|
2034
|
+
|
|
2035
|
+
/**
|
|
2036
|
+
* appendTo utility
|
|
2037
|
+
*/
|
|
2038
|
+
|
|
2039
|
+
/**
|
|
2040
|
+
* Append a node to a target element and return the appended node.
|
|
2041
|
+
*
|
|
2042
|
+
* @param {SVGElement} element
|
|
2043
|
+
* @param {SVGElement} target
|
|
2044
|
+
*
|
|
2045
|
+
* @return {SVGElement} the appended node
|
|
2046
|
+
*/
|
|
2047
|
+
function appendTo$1(element, target) {
|
|
2048
|
+
return target.appendChild(ensureImported$1(element, target));
|
|
2049
|
+
}
|
|
2050
|
+
|
|
2051
|
+
/**
|
|
2052
|
+
* append utility
|
|
2053
|
+
*/
|
|
2054
|
+
|
|
2055
|
+
/**
|
|
2056
|
+
* Append a node to an element
|
|
2057
|
+
*
|
|
2058
|
+
* @param {SVGElement} element
|
|
2059
|
+
* @param {SVGElement} node
|
|
2060
|
+
*
|
|
2061
|
+
* @return {SVGElement} the element
|
|
2062
|
+
*/
|
|
2063
|
+
function append$1(target, node) {
|
|
2064
|
+
appendTo$1(node, target);
|
|
2065
|
+
return target;
|
|
2066
|
+
}
|
|
2067
|
+
|
|
2068
|
+
/**
|
|
2069
|
+
* attribute accessor utility
|
|
2070
|
+
*/
|
|
2071
|
+
|
|
2072
|
+
var LENGTH_ATTR$1 = 2;
|
|
2073
|
+
|
|
2074
|
+
var CSS_PROPERTIES$1 = {
|
|
2075
|
+
'alignment-baseline': 1,
|
|
2076
|
+
'baseline-shift': 1,
|
|
2077
|
+
'clip': 1,
|
|
2078
|
+
'clip-path': 1,
|
|
2079
|
+
'clip-rule': 1,
|
|
2080
|
+
'color': 1,
|
|
2081
|
+
'color-interpolation': 1,
|
|
2082
|
+
'color-interpolation-filters': 1,
|
|
2083
|
+
'color-profile': 1,
|
|
2084
|
+
'color-rendering': 1,
|
|
2085
|
+
'cursor': 1,
|
|
2086
|
+
'direction': 1,
|
|
2087
|
+
'display': 1,
|
|
2088
|
+
'dominant-baseline': 1,
|
|
2089
|
+
'enable-background': 1,
|
|
2090
|
+
'fill': 1,
|
|
2091
|
+
'fill-opacity': 1,
|
|
2092
|
+
'fill-rule': 1,
|
|
2093
|
+
'filter': 1,
|
|
2094
|
+
'flood-color': 1,
|
|
2095
|
+
'flood-opacity': 1,
|
|
2096
|
+
'font': 1,
|
|
2097
|
+
'font-family': 1,
|
|
2098
|
+
'font-size': LENGTH_ATTR$1,
|
|
2099
|
+
'font-size-adjust': 1,
|
|
2100
|
+
'font-stretch': 1,
|
|
2101
|
+
'font-style': 1,
|
|
2102
|
+
'font-variant': 1,
|
|
2103
|
+
'font-weight': 1,
|
|
2104
|
+
'glyph-orientation-horizontal': 1,
|
|
2105
|
+
'glyph-orientation-vertical': 1,
|
|
2106
|
+
'image-rendering': 1,
|
|
2107
|
+
'kerning': 1,
|
|
2108
|
+
'letter-spacing': 1,
|
|
2109
|
+
'lighting-color': 1,
|
|
2110
|
+
'marker': 1,
|
|
2111
|
+
'marker-end': 1,
|
|
2112
|
+
'marker-mid': 1,
|
|
2113
|
+
'marker-start': 1,
|
|
2114
|
+
'mask': 1,
|
|
2115
|
+
'opacity': 1,
|
|
2116
|
+
'overflow': 1,
|
|
2117
|
+
'pointer-events': 1,
|
|
2118
|
+
'shape-rendering': 1,
|
|
2119
|
+
'stop-color': 1,
|
|
2120
|
+
'stop-opacity': 1,
|
|
2121
|
+
'stroke': 1,
|
|
2122
|
+
'stroke-dasharray': 1,
|
|
2123
|
+
'stroke-dashoffset': 1,
|
|
2124
|
+
'stroke-linecap': 1,
|
|
2125
|
+
'stroke-linejoin': 1,
|
|
2126
|
+
'stroke-miterlimit': 1,
|
|
2127
|
+
'stroke-opacity': 1,
|
|
2128
|
+
'stroke-width': LENGTH_ATTR$1,
|
|
2129
|
+
'text-anchor': 1,
|
|
2130
|
+
'text-decoration': 1,
|
|
2131
|
+
'text-rendering': 1,
|
|
2132
|
+
'unicode-bidi': 1,
|
|
2133
|
+
'visibility': 1,
|
|
2134
|
+
'word-spacing': 1,
|
|
2135
|
+
'writing-mode': 1
|
|
2136
|
+
};
|
|
2137
|
+
|
|
2138
|
+
|
|
2139
|
+
function getAttribute$1(node, name) {
|
|
2140
|
+
if (CSS_PROPERTIES$1[name]) {
|
|
2141
|
+
return node.style[name];
|
|
2142
|
+
} else {
|
|
2143
|
+
return node.getAttributeNS(null, name);
|
|
2144
|
+
}
|
|
2145
|
+
}
|
|
2146
|
+
|
|
2147
|
+
function setAttribute$1(node, name, value) {
|
|
2148
|
+
var hyphenated = name.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
|
|
2149
|
+
|
|
2150
|
+
var type = CSS_PROPERTIES$1[hyphenated];
|
|
2151
|
+
|
|
2152
|
+
if (type) {
|
|
2153
|
+
// append pixel unit, unless present
|
|
2154
|
+
if (type === LENGTH_ATTR$1 && typeof value === 'number') {
|
|
2155
|
+
value = String(value) + 'px';
|
|
2156
|
+
}
|
|
2157
|
+
|
|
2158
|
+
node.style[hyphenated] = value;
|
|
2159
|
+
} else {
|
|
2160
|
+
node.setAttributeNS(null, name, value);
|
|
2161
|
+
}
|
|
2162
|
+
}
|
|
2163
|
+
|
|
2164
|
+
function setAttributes$1(node, attrs) {
|
|
2165
|
+
|
|
2166
|
+
var names = Object.keys(attrs), i, name;
|
|
2167
|
+
|
|
2168
|
+
for (i = 0, name; (name = names[i]); i++) {
|
|
2169
|
+
setAttribute$1(node, name, attrs[name]);
|
|
2170
|
+
}
|
|
2171
|
+
}
|
|
2172
|
+
|
|
2173
|
+
/**
|
|
2174
|
+
* Gets or sets raw attributes on a node.
|
|
2175
|
+
*
|
|
2176
|
+
* @param {SVGElement} node
|
|
2177
|
+
* @param {Object} [attrs]
|
|
2178
|
+
* @param {String} [name]
|
|
2179
|
+
* @param {String} [value]
|
|
2180
|
+
*
|
|
2181
|
+
* @return {String}
|
|
2182
|
+
*/
|
|
2183
|
+
function attr$2(node, name, value) {
|
|
2184
|
+
if (typeof name === 'string') {
|
|
2185
|
+
if (value !== undefined) {
|
|
2186
|
+
setAttribute$1(node, name, value);
|
|
2187
|
+
} else {
|
|
2188
|
+
return getAttribute$1(node, name);
|
|
2189
|
+
}
|
|
2190
|
+
} else {
|
|
2191
|
+
setAttributes$1(node, name);
|
|
2192
|
+
}
|
|
2193
|
+
|
|
2194
|
+
return node;
|
|
2195
|
+
}
|
|
2196
|
+
|
|
2197
|
+
/**
|
|
2198
|
+
* Clear utility
|
|
2199
|
+
*/
|
|
2200
|
+
function index$1(arr, obj) {
|
|
2201
|
+
if (arr.indexOf) {
|
|
2202
|
+
return arr.indexOf(obj);
|
|
2203
|
+
}
|
|
2204
|
+
|
|
2205
|
+
|
|
2206
|
+
for (var i = 0; i < arr.length; ++i) {
|
|
2207
|
+
if (arr[i] === obj) {
|
|
2208
|
+
return i;
|
|
2209
|
+
}
|
|
2210
|
+
}
|
|
2211
|
+
|
|
2212
|
+
return -1;
|
|
2213
|
+
}
|
|
2214
|
+
|
|
2215
|
+
var re$2 = /\s+/;
|
|
2216
|
+
|
|
2217
|
+
var toString$2 = Object.prototype.toString;
|
|
2218
|
+
|
|
2219
|
+
function defined$1(o) {
|
|
2220
|
+
return typeof o !== 'undefined';
|
|
2221
|
+
}
|
|
2222
|
+
|
|
2223
|
+
/**
|
|
2224
|
+
* Wrap `el` in a `ClassList`.
|
|
2225
|
+
*
|
|
2226
|
+
* @param {Element} el
|
|
2227
|
+
* @return {ClassList}
|
|
2228
|
+
* @api public
|
|
2229
|
+
*/
|
|
2230
|
+
|
|
2231
|
+
function classes$2(el) {
|
|
2232
|
+
return new ClassList$2(el);
|
|
2233
|
+
}
|
|
2234
|
+
|
|
2235
|
+
function ClassList$2(el) {
|
|
2236
|
+
if (!el || !el.nodeType) {
|
|
2237
|
+
throw new Error('A DOM element reference is required');
|
|
2238
|
+
}
|
|
2239
|
+
this.el = el;
|
|
2240
|
+
this.list = el.classList;
|
|
2241
|
+
}
|
|
2242
|
+
|
|
2243
|
+
/**
|
|
2244
|
+
* Add class `name` if not already present.
|
|
2245
|
+
*
|
|
2246
|
+
* @param {String} name
|
|
2247
|
+
* @return {ClassList}
|
|
2248
|
+
* @api public
|
|
2249
|
+
*/
|
|
2250
|
+
|
|
2251
|
+
ClassList$2.prototype.add = function(name) {
|
|
2252
|
+
|
|
2253
|
+
// classList
|
|
2254
|
+
if (this.list) {
|
|
2255
|
+
this.list.add(name);
|
|
2256
|
+
return this;
|
|
2257
|
+
}
|
|
2258
|
+
|
|
2259
|
+
// fallback
|
|
2260
|
+
var arr = this.array();
|
|
2261
|
+
var i = index$1(arr, name);
|
|
2262
|
+
if (!~i) {
|
|
2263
|
+
arr.push(name);
|
|
2264
|
+
}
|
|
2265
|
+
|
|
2266
|
+
if (defined$1(this.el.className.baseVal)) {
|
|
2267
|
+
this.el.className.baseVal = arr.join(' ');
|
|
2268
|
+
} else {
|
|
2269
|
+
this.el.className = arr.join(' ');
|
|
2270
|
+
}
|
|
2271
|
+
|
|
2272
|
+
return this;
|
|
2273
|
+
};
|
|
2274
|
+
|
|
2275
|
+
/**
|
|
2276
|
+
* Remove class `name` when present, or
|
|
2277
|
+
* pass a regular expression to remove
|
|
2278
|
+
* any which match.
|
|
2279
|
+
*
|
|
2280
|
+
* @param {String|RegExp} name
|
|
2281
|
+
* @return {ClassList}
|
|
2282
|
+
* @api public
|
|
2283
|
+
*/
|
|
2284
|
+
|
|
2285
|
+
ClassList$2.prototype.remove = function(name) {
|
|
2286
|
+
if ('[object RegExp]' === toString$2.call(name)) {
|
|
2287
|
+
return this.removeMatching(name);
|
|
2288
|
+
}
|
|
2289
|
+
|
|
2290
|
+
// classList
|
|
2291
|
+
if (this.list) {
|
|
2292
|
+
this.list.remove(name);
|
|
2293
|
+
return this;
|
|
2294
|
+
}
|
|
2295
|
+
|
|
2296
|
+
// fallback
|
|
2297
|
+
var arr = this.array();
|
|
2298
|
+
var i = index$1(arr, name);
|
|
2299
|
+
if (~i) {
|
|
2300
|
+
arr.splice(i, 1);
|
|
2301
|
+
}
|
|
2302
|
+
this.el.className.baseVal = arr.join(' ');
|
|
2303
|
+
return this;
|
|
2304
|
+
};
|
|
2305
|
+
|
|
2306
|
+
/**
|
|
2307
|
+
* Remove all classes matching `re`.
|
|
2308
|
+
*
|
|
2309
|
+
* @param {RegExp} re
|
|
2310
|
+
* @return {ClassList}
|
|
2311
|
+
* @api private
|
|
2312
|
+
*/
|
|
2313
|
+
|
|
2314
|
+
ClassList$2.prototype.removeMatching = function(re) {
|
|
2315
|
+
var arr = this.array();
|
|
2316
|
+
for (var i = 0; i < arr.length; i++) {
|
|
2317
|
+
if (re.test(arr[i])) {
|
|
2318
|
+
this.remove(arr[i]);
|
|
2319
|
+
}
|
|
2320
|
+
}
|
|
2321
|
+
return this;
|
|
2322
|
+
};
|
|
2323
|
+
|
|
2324
|
+
/**
|
|
2325
|
+
* Toggle class `name`, can force state via `force`.
|
|
2326
|
+
*
|
|
2327
|
+
* For browsers that support classList, but do not support `force` yet,
|
|
2328
|
+
* the mistake will be detected and corrected.
|
|
2329
|
+
*
|
|
2330
|
+
* @param {String} name
|
|
2331
|
+
* @param {Boolean} force
|
|
2332
|
+
* @return {ClassList}
|
|
2333
|
+
* @api public
|
|
2334
|
+
*/
|
|
2335
|
+
|
|
2336
|
+
ClassList$2.prototype.toggle = function(name, force) {
|
|
2337
|
+
// classList
|
|
2338
|
+
if (this.list) {
|
|
2339
|
+
if (defined$1(force)) {
|
|
2340
|
+
if (force !== this.list.toggle(name, force)) {
|
|
2341
|
+
this.list.toggle(name); // toggle again to correct
|
|
2342
|
+
}
|
|
2343
|
+
} else {
|
|
2344
|
+
this.list.toggle(name);
|
|
2345
|
+
}
|
|
2346
|
+
return this;
|
|
2347
|
+
}
|
|
2348
|
+
|
|
2349
|
+
// fallback
|
|
2350
|
+
if (defined$1(force)) {
|
|
2351
|
+
if (!force) {
|
|
2352
|
+
this.remove(name);
|
|
2353
|
+
} else {
|
|
2354
|
+
this.add(name);
|
|
2355
|
+
}
|
|
2356
|
+
} else {
|
|
2357
|
+
if (this.has(name)) {
|
|
2358
|
+
this.remove(name);
|
|
2359
|
+
} else {
|
|
2360
|
+
this.add(name);
|
|
2361
|
+
}
|
|
2362
|
+
}
|
|
2363
|
+
|
|
2364
|
+
return this;
|
|
2365
|
+
};
|
|
2366
|
+
|
|
2367
|
+
/**
|
|
2368
|
+
* Return an array of classes.
|
|
2369
|
+
*
|
|
2370
|
+
* @return {Array}
|
|
2371
|
+
* @api public
|
|
2372
|
+
*/
|
|
2373
|
+
|
|
2374
|
+
ClassList$2.prototype.array = function() {
|
|
2375
|
+
var className = this.el.getAttribute('class') || '';
|
|
2376
|
+
var str = className.replace(/^\s+|\s+$/g, '');
|
|
2377
|
+
var arr = str.split(re$2);
|
|
2378
|
+
if ('' === arr[0]) {
|
|
2379
|
+
arr.shift();
|
|
2380
|
+
}
|
|
2381
|
+
return arr;
|
|
2382
|
+
};
|
|
2383
|
+
|
|
2384
|
+
/**
|
|
2385
|
+
* Check if class `name` is present.
|
|
2386
|
+
*
|
|
2387
|
+
* @param {String} name
|
|
2388
|
+
* @return {ClassList}
|
|
2389
|
+
* @api public
|
|
2390
|
+
*/
|
|
2391
|
+
|
|
2392
|
+
ClassList$2.prototype.has =
|
|
2393
|
+
ClassList$2.prototype.contains = function(name) {
|
|
2394
|
+
return (
|
|
2395
|
+
this.list ?
|
|
2396
|
+
this.list.contains(name) :
|
|
2397
|
+
!! ~index$1(this.array(), name)
|
|
2398
|
+
);
|
|
2399
|
+
};
|
|
2400
|
+
|
|
2401
|
+
function remove$2(element) {
|
|
2402
|
+
var parent = element.parentNode;
|
|
2403
|
+
|
|
2404
|
+
if (parent) {
|
|
2405
|
+
parent.removeChild(element);
|
|
2406
|
+
}
|
|
2407
|
+
|
|
2408
|
+
return element;
|
|
2409
|
+
}
|
|
2410
|
+
|
|
2411
|
+
/**
|
|
2412
|
+
* Clear utility
|
|
2413
|
+
*/
|
|
2414
|
+
|
|
2415
|
+
/**
|
|
2416
|
+
* Removes all children from the given element
|
|
2417
|
+
*
|
|
2418
|
+
* @param {DOMElement} element
|
|
2419
|
+
* @return {DOMElement} the element (for chaining)
|
|
2420
|
+
*/
|
|
2421
|
+
function clear$2(element) {
|
|
2422
|
+
var child;
|
|
2423
|
+
|
|
2424
|
+
while ((child = element.firstChild)) {
|
|
2425
|
+
remove$2(child);
|
|
2426
|
+
}
|
|
2427
|
+
|
|
2428
|
+
return element;
|
|
2429
|
+
}
|
|
2430
|
+
|
|
2431
|
+
var ns$1 = {
|
|
2432
|
+
svg: 'http://www.w3.org/2000/svg'
|
|
2433
|
+
};
|
|
2434
|
+
|
|
2435
|
+
/**
|
|
2436
|
+
* DOM parsing utility
|
|
2437
|
+
*/
|
|
2438
|
+
|
|
2439
|
+
var SVG_START$1 = '<svg xmlns="' + ns$1.svg + '"';
|
|
2440
|
+
|
|
2441
|
+
function parse$2(svg) {
|
|
2442
|
+
|
|
2443
|
+
var unwrap = false;
|
|
2444
|
+
|
|
2445
|
+
// ensure we import a valid svg document
|
|
2446
|
+
if (svg.substring(0, 4) === '<svg') {
|
|
2447
|
+
if (svg.indexOf(ns$1.svg) === -1) {
|
|
2448
|
+
svg = SVG_START$1 + svg.substring(4);
|
|
2449
|
+
}
|
|
2450
|
+
} else {
|
|
2451
|
+
// namespace svg
|
|
2452
|
+
svg = SVG_START$1 + '>' + svg + '</svg>';
|
|
2453
|
+
unwrap = true;
|
|
2454
|
+
}
|
|
2455
|
+
|
|
2456
|
+
var parsed = parseDocument$1(svg);
|
|
2457
|
+
|
|
2458
|
+
if (!unwrap) {
|
|
2459
|
+
return parsed;
|
|
2460
|
+
}
|
|
2461
|
+
|
|
2462
|
+
var fragment = document.createDocumentFragment();
|
|
2463
|
+
|
|
2464
|
+
var parent = parsed.firstChild;
|
|
2465
|
+
|
|
2466
|
+
while (parent.firstChild) {
|
|
2467
|
+
fragment.appendChild(parent.firstChild);
|
|
2468
|
+
}
|
|
2469
|
+
|
|
2470
|
+
return fragment;
|
|
2471
|
+
}
|
|
2472
|
+
|
|
2473
|
+
function parseDocument$1(svg) {
|
|
2474
|
+
|
|
2475
|
+
var parser;
|
|
2476
|
+
|
|
2477
|
+
// parse
|
|
2478
|
+
parser = new DOMParser();
|
|
2479
|
+
parser.async = false;
|
|
2480
|
+
|
|
2481
|
+
return parser.parseFromString(svg, 'text/xml');
|
|
2482
|
+
}
|
|
2483
|
+
|
|
2484
|
+
/**
|
|
2485
|
+
* Create utility for SVG elements
|
|
2486
|
+
*/
|
|
2487
|
+
|
|
2488
|
+
|
|
2489
|
+
/**
|
|
2490
|
+
* Create a specific type from name or SVG markup.
|
|
2491
|
+
*
|
|
2492
|
+
* @param {String} name the name or markup of the element
|
|
2493
|
+
* @param {Object} [attrs] attributes to set on the element
|
|
2494
|
+
*
|
|
2495
|
+
* @returns {SVGElement}
|
|
2496
|
+
*/
|
|
2497
|
+
function create$1(name, attrs) {
|
|
2498
|
+
var element;
|
|
2499
|
+
|
|
2500
|
+
if (name.charAt(0) === '<') {
|
|
2501
|
+
element = parse$2(name).firstChild;
|
|
2502
|
+
element = document.importNode(element, true);
|
|
2503
|
+
} else {
|
|
2504
|
+
element = document.createElementNS(ns$1.svg, name);
|
|
2505
|
+
}
|
|
2506
|
+
|
|
2507
|
+
if (attrs) {
|
|
2508
|
+
attr$2(element, attrs);
|
|
2509
|
+
}
|
|
2510
|
+
|
|
2511
|
+
return element;
|
|
2512
|
+
}
|
|
2513
|
+
|
|
2514
|
+
/**
|
|
2515
|
+
* Serialization util
|
|
2516
|
+
*/
|
|
2517
|
+
|
|
2518
|
+
var TEXT_ENTITIES = /([&<>]{1})/g;
|
|
2519
|
+
var ATTR_ENTITIES = /([\n\r"]{1})/g;
|
|
2520
|
+
|
|
2521
|
+
var ENTITY_REPLACEMENT = {
|
|
2522
|
+
'&': '&',
|
|
2523
|
+
'<': '<',
|
|
2524
|
+
'>': '>',
|
|
2525
|
+
'"': '\''
|
|
2526
|
+
};
|
|
2527
|
+
|
|
2528
|
+
function escape(str, pattern) {
|
|
2529
|
+
|
|
2530
|
+
function replaceFn(match, entity) {
|
|
2531
|
+
return ENTITY_REPLACEMENT[entity] || entity;
|
|
2532
|
+
}
|
|
2533
|
+
|
|
2534
|
+
return str.replace(pattern, replaceFn);
|
|
2535
|
+
}
|
|
2536
|
+
|
|
2537
|
+
function serialize(node, output) {
|
|
2538
|
+
|
|
2539
|
+
var i, len, attrMap, attrNode, childNodes;
|
|
2540
|
+
|
|
2541
|
+
switch (node.nodeType) {
|
|
2542
|
+
// TEXT
|
|
2543
|
+
case 3:
|
|
2544
|
+
// replace special XML characters
|
|
2545
|
+
output.push(escape(node.textContent, TEXT_ENTITIES));
|
|
2546
|
+
break;
|
|
2547
|
+
|
|
2548
|
+
// ELEMENT
|
|
2549
|
+
case 1:
|
|
2550
|
+
output.push('<', node.tagName);
|
|
2551
|
+
|
|
2552
|
+
if (node.hasAttributes()) {
|
|
2553
|
+
attrMap = node.attributes;
|
|
2554
|
+
for (i = 0, len = attrMap.length; i < len; ++i) {
|
|
2555
|
+
attrNode = attrMap.item(i);
|
|
2556
|
+
output.push(' ', attrNode.name, '="', escape(attrNode.value, ATTR_ENTITIES), '"');
|
|
2557
|
+
}
|
|
2558
|
+
}
|
|
2559
|
+
|
|
2560
|
+
if (node.hasChildNodes()) {
|
|
2561
|
+
output.push('>');
|
|
2562
|
+
childNodes = node.childNodes;
|
|
2563
|
+
for (i = 0, len = childNodes.length; i < len; ++i) {
|
|
2564
|
+
serialize(childNodes.item(i), output);
|
|
2565
|
+
}
|
|
2566
|
+
output.push('</', node.tagName, '>');
|
|
2567
|
+
} else {
|
|
2568
|
+
output.push('/>');
|
|
2569
|
+
}
|
|
2570
|
+
break;
|
|
2571
|
+
|
|
2572
|
+
// COMMENT
|
|
2573
|
+
case 8:
|
|
2574
|
+
output.push('<!--', escape(node.nodeValue, TEXT_ENTITIES), '-->');
|
|
2575
|
+
break;
|
|
2576
|
+
|
|
2577
|
+
// CDATA
|
|
2578
|
+
case 4:
|
|
2579
|
+
output.push('<![CDATA[', node.nodeValue, ']]>');
|
|
2580
|
+
break;
|
|
2581
|
+
|
|
2582
|
+
default:
|
|
2583
|
+
throw new Error('unable to handle node ' + node.nodeType);
|
|
2584
|
+
}
|
|
2585
|
+
|
|
2586
|
+
return output;
|
|
2587
|
+
}
|
|
2588
|
+
|
|
2589
|
+
/**
|
|
2590
|
+
* innerHTML like functionality for SVG elements.
|
|
2591
|
+
* based on innerSVG (https://code.google.com/p/innersvg)
|
|
2592
|
+
*/
|
|
2593
|
+
|
|
2594
|
+
|
|
2595
|
+
function set(element, svg) {
|
|
2596
|
+
|
|
2597
|
+
var parsed = parse$2(svg);
|
|
2598
|
+
|
|
2599
|
+
// clear element contents
|
|
2600
|
+
clear$2(element);
|
|
2601
|
+
|
|
2602
|
+
if (!svg) {
|
|
2603
|
+
return;
|
|
2604
|
+
}
|
|
2605
|
+
|
|
2606
|
+
if (!isFragment(parsed)) {
|
|
2607
|
+
// extract <svg> from parsed document
|
|
2608
|
+
parsed = parsed.documentElement;
|
|
2609
|
+
}
|
|
2610
|
+
|
|
2611
|
+
var nodes = slice(parsed.childNodes);
|
|
2097
2612
|
|
|
2098
|
-
//
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
el.innerHTML = html;
|
|
2102
|
-
return el.removeChild(el.lastChild);
|
|
2613
|
+
// import + append each node
|
|
2614
|
+
for (var i = 0; i < nodes.length; i++) {
|
|
2615
|
+
appendTo$1(nodes[i], element);
|
|
2103
2616
|
}
|
|
2104
2617
|
|
|
2105
|
-
|
|
2106
|
-
var wrap = map$1[tag] || map$1._default;
|
|
2107
|
-
var depth = wrap[0];
|
|
2108
|
-
var prefix = wrap[1];
|
|
2109
|
-
var suffix = wrap[2];
|
|
2110
|
-
var el = doc.createElement('div');
|
|
2111
|
-
el.innerHTML = prefix + html + suffix;
|
|
2112
|
-
while (depth--) el = el.lastChild;
|
|
2618
|
+
}
|
|
2113
2619
|
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
}
|
|
2620
|
+
function get(element) {
|
|
2621
|
+
var child = element.firstChild,
|
|
2622
|
+
output = [];
|
|
2118
2623
|
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
fragment.appendChild(el.removeChild(el.firstChild));
|
|
2624
|
+
while (child) {
|
|
2625
|
+
serialize(child, output);
|
|
2626
|
+
child = child.nextSibling;
|
|
2123
2627
|
}
|
|
2124
2628
|
|
|
2125
|
-
return
|
|
2629
|
+
return output.join('');
|
|
2126
2630
|
}
|
|
2127
2631
|
|
|
2128
|
-
function
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
return el.querySelector(selector);
|
|
2632
|
+
function isFragment(node) {
|
|
2633
|
+
return node.nodeName === '#document-fragment';
|
|
2132
2634
|
}
|
|
2133
2635
|
|
|
2134
|
-
function
|
|
2135
|
-
el = el || document;
|
|
2636
|
+
function innerSVG(element, svg) {
|
|
2136
2637
|
|
|
2137
|
-
|
|
2638
|
+
if (svg !== undefined) {
|
|
2639
|
+
|
|
2640
|
+
try {
|
|
2641
|
+
set(element, svg);
|
|
2642
|
+
} catch (e) {
|
|
2643
|
+
throw new Error('error parsing SVG: ' + e.message);
|
|
2644
|
+
}
|
|
2645
|
+
|
|
2646
|
+
return element;
|
|
2647
|
+
} else {
|
|
2648
|
+
return get(element);
|
|
2649
|
+
}
|
|
2138
2650
|
}
|
|
2139
2651
|
|
|
2140
|
-
|
|
2141
|
-
|
|
2652
|
+
|
|
2653
|
+
function slice(arr) {
|
|
2654
|
+
return Array.prototype.slice.call(arr);
|
|
2142
2655
|
}
|
|
2143
2656
|
|
|
2144
2657
|
/**
|
|
@@ -2390,16 +2903,16 @@
|
|
|
2390
2903
|
// fix for safari / chrome / firefox bug not correctly
|
|
2391
2904
|
// resetting stroke dash array
|
|
2392
2905
|
if (attrs.strokeDasharray === 'none') {
|
|
2393
|
-
attrs.strokeDasharray = [10000, 1];
|
|
2906
|
+
attrs.strokeDasharray = [ 10000, 1 ];
|
|
2394
2907
|
}
|
|
2395
2908
|
|
|
2396
|
-
var marker = create('marker');
|
|
2909
|
+
var marker = create$1('marker');
|
|
2397
2910
|
|
|
2398
|
-
attr(options.element, attrs);
|
|
2911
|
+
attr$2(options.element, attrs);
|
|
2399
2912
|
|
|
2400
|
-
append(marker, options.element);
|
|
2913
|
+
append$1(marker, options.element);
|
|
2401
2914
|
|
|
2402
|
-
attr(marker, {
|
|
2915
|
+
attr$2(marker, {
|
|
2403
2916
|
id: id,
|
|
2404
2917
|
viewBox: '0 0 20 20',
|
|
2405
2918
|
refX: ref.x,
|
|
@@ -2412,12 +2925,12 @@
|
|
|
2412
2925
|
var defs = query('defs', canvas._svg);
|
|
2413
2926
|
|
|
2414
2927
|
if (!defs) {
|
|
2415
|
-
defs = create('defs');
|
|
2928
|
+
defs = create$1('defs');
|
|
2416
2929
|
|
|
2417
|
-
append(canvas._svg, defs);
|
|
2930
|
+
append$1(canvas._svg, defs);
|
|
2418
2931
|
}
|
|
2419
2932
|
|
|
2420
|
-
append(defs, marker);
|
|
2933
|
+
append$1(defs, marker);
|
|
2421
2934
|
|
|
2422
2935
|
markers[id] = marker;
|
|
2423
2936
|
}
|
|
@@ -2441,8 +2954,8 @@
|
|
|
2441
2954
|
function createMarker(id, type, fill, stroke) {
|
|
2442
2955
|
|
|
2443
2956
|
if (type === 'sequenceflow-end') {
|
|
2444
|
-
var sequenceflowEnd = create('path');
|
|
2445
|
-
attr(sequenceflowEnd, { d: 'M 1 5 L 11 10 L 1 15 Z' });
|
|
2957
|
+
var sequenceflowEnd = create$1('path');
|
|
2958
|
+
attr$2(sequenceflowEnd, { d: 'M 1 5 L 11 10 L 1 15 Z' });
|
|
2446
2959
|
|
|
2447
2960
|
addMarker(id, {
|
|
2448
2961
|
element: sequenceflowEnd,
|
|
@@ -2456,8 +2969,8 @@
|
|
|
2456
2969
|
}
|
|
2457
2970
|
|
|
2458
2971
|
if (type === 'messageflow-start') {
|
|
2459
|
-
var messageflowStart = create('circle');
|
|
2460
|
-
attr(messageflowStart, { cx: 6, cy: 6, r: 3.5 });
|
|
2972
|
+
var messageflowStart = create$1('circle');
|
|
2973
|
+
attr$2(messageflowStart, { cx: 6, cy: 6, r: 3.5 });
|
|
2461
2974
|
|
|
2462
2975
|
addMarker(id, {
|
|
2463
2976
|
element: messageflowStart,
|
|
@@ -2470,8 +2983,8 @@
|
|
|
2470
2983
|
}
|
|
2471
2984
|
|
|
2472
2985
|
if (type === 'messageflow-end') {
|
|
2473
|
-
var messageflowEnd = create('path');
|
|
2474
|
-
attr(messageflowEnd, { d: 'm 1 5 l 0 -3 l 7 3 l -7 3 z' });
|
|
2986
|
+
var messageflowEnd = create$1('path');
|
|
2987
|
+
attr$2(messageflowEnd, { d: 'm 1 5 l 0 -3 l 7 3 l -7 3 z' });
|
|
2475
2988
|
|
|
2476
2989
|
addMarker(id, {
|
|
2477
2990
|
element: messageflowEnd,
|
|
@@ -2485,8 +2998,8 @@
|
|
|
2485
2998
|
}
|
|
2486
2999
|
|
|
2487
3000
|
if (type === 'association-start') {
|
|
2488
|
-
var associationStart = create('path');
|
|
2489
|
-
attr(associationStart, { d: 'M 11 5 L 1 10 L 11 15' });
|
|
3001
|
+
var associationStart = create$1('path');
|
|
3002
|
+
attr$2(associationStart, { d: 'M 11 5 L 1 10 L 11 15' });
|
|
2490
3003
|
|
|
2491
3004
|
addMarker(id, {
|
|
2492
3005
|
element: associationStart,
|
|
@@ -2501,8 +3014,8 @@
|
|
|
2501
3014
|
}
|
|
2502
3015
|
|
|
2503
3016
|
if (type === 'association-end') {
|
|
2504
|
-
var associationEnd = create('path');
|
|
2505
|
-
attr(associationEnd, { d: 'M 1 5 L 11 10 L 1 15' });
|
|
3017
|
+
var associationEnd = create$1('path');
|
|
3018
|
+
attr$2(associationEnd, { d: 'M 1 5 L 11 10 L 1 15' });
|
|
2506
3019
|
|
|
2507
3020
|
addMarker(id, {
|
|
2508
3021
|
element: associationEnd,
|
|
@@ -2517,8 +3030,8 @@
|
|
|
2517
3030
|
}
|
|
2518
3031
|
|
|
2519
3032
|
if (type === 'conditional-flow-marker') {
|
|
2520
|
-
var conditionalflowMarker = create('path');
|
|
2521
|
-
attr(conditionalflowMarker, { d: 'M 0 10 L 8 6 L 16 10 L 8 14 Z' });
|
|
3033
|
+
var conditionalflowMarker = create$1('path');
|
|
3034
|
+
attr$2(conditionalflowMarker, { d: 'M 0 10 L 8 6 L 16 10 L 8 14 Z' });
|
|
2522
3035
|
|
|
2523
3036
|
addMarker(id, {
|
|
2524
3037
|
element: conditionalflowMarker,
|
|
@@ -2532,8 +3045,8 @@
|
|
|
2532
3045
|
}
|
|
2533
3046
|
|
|
2534
3047
|
if (type === 'conditional-default-flow-marker') {
|
|
2535
|
-
var conditionaldefaultflowMarker = create('path');
|
|
2536
|
-
attr(conditionaldefaultflowMarker, { d: 'M 6 4 L 10 16' });
|
|
3048
|
+
var conditionaldefaultflowMarker = create$1('path');
|
|
3049
|
+
attr$2(conditionaldefaultflowMarker, { d: 'M 6 4 L 10 16' });
|
|
2537
3050
|
|
|
2538
3051
|
addMarker(id, {
|
|
2539
3052
|
element: conditionaldefaultflowMarker,
|
|
@@ -2568,15 +3081,15 @@
|
|
|
2568
3081
|
var cx = width / 2,
|
|
2569
3082
|
cy = height / 2;
|
|
2570
3083
|
|
|
2571
|
-
var circle = create('circle');
|
|
2572
|
-
attr(circle, {
|
|
3084
|
+
var circle = create$1('circle');
|
|
3085
|
+
attr$2(circle, {
|
|
2573
3086
|
cx: cx,
|
|
2574
3087
|
cy: cy,
|
|
2575
3088
|
r: Math.round((width + height) / 4 - offset)
|
|
2576
3089
|
});
|
|
2577
|
-
attr(circle, attrs);
|
|
3090
|
+
attr$2(circle, attrs);
|
|
2578
3091
|
|
|
2579
|
-
append(parentGfx, circle);
|
|
3092
|
+
append$1(parentGfx, circle);
|
|
2580
3093
|
|
|
2581
3094
|
return circle;
|
|
2582
3095
|
}
|
|
@@ -2596,8 +3109,8 @@
|
|
|
2596
3109
|
fill: 'white'
|
|
2597
3110
|
});
|
|
2598
3111
|
|
|
2599
|
-
var rect = create('rect');
|
|
2600
|
-
attr(rect, {
|
|
3112
|
+
var rect = create$1('rect');
|
|
3113
|
+
attr$2(rect, {
|
|
2601
3114
|
x: offset,
|
|
2602
3115
|
y: offset,
|
|
2603
3116
|
width: width - offset * 2,
|
|
@@ -2605,9 +3118,9 @@
|
|
|
2605
3118
|
rx: r,
|
|
2606
3119
|
ry: r
|
|
2607
3120
|
});
|
|
2608
|
-
attr(rect, attrs);
|
|
3121
|
+
attr$2(rect, attrs);
|
|
2609
3122
|
|
|
2610
|
-
append(parentGfx, rect);
|
|
3123
|
+
append$1(parentGfx, rect);
|
|
2611
3124
|
|
|
2612
3125
|
return rect;
|
|
2613
3126
|
}
|
|
@@ -2617,7 +3130,7 @@
|
|
|
2617
3130
|
var x_2 = width / 2;
|
|
2618
3131
|
var y_2 = height / 2;
|
|
2619
3132
|
|
|
2620
|
-
var points = [{ x: x_2, y: 0 }, { x: width, y: y_2 }, { x: x_2, y: height }, { x: 0, y: y_2 }];
|
|
3133
|
+
var points = [ { x: x_2, y: 0 }, { x: width, y: y_2 }, { x: x_2, y: height }, { x: 0, y: y_2 } ];
|
|
2621
3134
|
|
|
2622
3135
|
var pointsString = points.map(function(point) {
|
|
2623
3136
|
return point.x + ',' + point.y;
|
|
@@ -2629,13 +3142,13 @@
|
|
|
2629
3142
|
fill: 'white'
|
|
2630
3143
|
});
|
|
2631
3144
|
|
|
2632
|
-
var polygon = create('polygon');
|
|
2633
|
-
attr(polygon, {
|
|
3145
|
+
var polygon = create$1('polygon');
|
|
3146
|
+
attr$2(polygon, {
|
|
2634
3147
|
points: pointsString
|
|
2635
3148
|
});
|
|
2636
|
-
attr(polygon, attrs);
|
|
3149
|
+
attr$2(polygon, attrs);
|
|
2637
3150
|
|
|
2638
|
-
append(parentGfx, polygon);
|
|
3151
|
+
append$1(parentGfx, polygon);
|
|
2639
3152
|
|
|
2640
3153
|
return polygon;
|
|
2641
3154
|
}
|
|
@@ -2649,7 +3162,7 @@
|
|
|
2649
3162
|
|
|
2650
3163
|
var line = createLine(waypoints, attrs);
|
|
2651
3164
|
|
|
2652
|
-
append(parentGfx, line);
|
|
3165
|
+
append$1(parentGfx, line);
|
|
2653
3166
|
|
|
2654
3167
|
return line;
|
|
2655
3168
|
}
|
|
@@ -2661,11 +3174,11 @@
|
|
|
2661
3174
|
stroke: black
|
|
2662
3175
|
});
|
|
2663
3176
|
|
|
2664
|
-
var path = create('path');
|
|
2665
|
-
attr(path, { d: d });
|
|
2666
|
-
attr(path, attrs);
|
|
3177
|
+
var path = create$1('path');
|
|
3178
|
+
attr$2(path, { d: d });
|
|
3179
|
+
attr$2(path, attrs);
|
|
2667
3180
|
|
|
2668
|
-
append(parentGfx, path);
|
|
3181
|
+
append$1(parentGfx, path);
|
|
2669
3182
|
|
|
2670
3183
|
return path;
|
|
2671
3184
|
}
|
|
@@ -2689,7 +3202,7 @@
|
|
|
2689
3202
|
var event = getSemantic(element);
|
|
2690
3203
|
var isThrowing = isThrowEvent(event);
|
|
2691
3204
|
|
|
2692
|
-
if (event.eventDefinitions && event.eventDefinitions.length>1) {
|
|
3205
|
+
if (event.eventDefinitions && event.eventDefinitions.length > 1) {
|
|
2693
3206
|
if (event.parallelMultiple) {
|
|
2694
3207
|
return renderer('bpmn:ParallelMultipleEventDefinition')(parentGfx, element, isThrowing);
|
|
2695
3208
|
}
|
|
@@ -2751,9 +3264,9 @@
|
|
|
2751
3264
|
|
|
2752
3265
|
var text = textRenderer.createText(label || '', options);
|
|
2753
3266
|
|
|
2754
|
-
classes(text).add('djs-label');
|
|
3267
|
+
classes$2(text).add('djs-label');
|
|
2755
3268
|
|
|
2756
|
-
append(parentGfx, text);
|
|
3269
|
+
append$1(parentGfx, text);
|
|
2757
3270
|
|
|
2758
3271
|
return text;
|
|
2759
3272
|
}
|
|
@@ -3363,7 +3876,7 @@
|
|
|
3363
3876
|
});
|
|
3364
3877
|
|
|
3365
3878
|
var businessHeaderPath = drawPath(parentGfx, headerPathData);
|
|
3366
|
-
attr(businessHeaderPath, {
|
|
3879
|
+
attr$2(businessHeaderPath, {
|
|
3367
3880
|
strokeWidth: 1,
|
|
3368
3881
|
fill: getFillColor(element, '#aaaaaa'),
|
|
3369
3882
|
stroke: getStrokeColor(element, defaultStrokeColor)
|
|
@@ -3377,7 +3890,7 @@
|
|
|
3377
3890
|
});
|
|
3378
3891
|
|
|
3379
3892
|
var businessPath = drawPath(parentGfx, headerData);
|
|
3380
|
-
attr(businessPath, {
|
|
3893
|
+
attr$2(businessPath, {
|
|
3381
3894
|
strokeWidth: 1,
|
|
3382
3895
|
stroke: getStrokeColor(element, defaultStrokeColor)
|
|
3383
3896
|
});
|
|
@@ -3395,7 +3908,7 @@
|
|
|
3395
3908
|
var expanded = isExpanded(element);
|
|
3396
3909
|
|
|
3397
3910
|
if (isEventSubProcess(element)) {
|
|
3398
|
-
attr(rect, {
|
|
3911
|
+
attr$2(rect, {
|
|
3399
3912
|
strokeDasharray: '1,2'
|
|
3400
3913
|
});
|
|
3401
3914
|
}
|
|
@@ -3405,7 +3918,7 @@
|
|
|
3405
3918
|
if (expanded) {
|
|
3406
3919
|
attachTaskMarkers(parentGfx, element);
|
|
3407
3920
|
} else {
|
|
3408
|
-
attachTaskMarkers(parentGfx, element, ['SubProcessMarker']);
|
|
3921
|
+
attachTaskMarkers(parentGfx, element, [ 'SubProcessMarker' ]);
|
|
3409
3922
|
}
|
|
3410
3923
|
|
|
3411
3924
|
return rect;
|
|
@@ -3617,7 +4130,7 @@
|
|
|
3617
4130
|
});
|
|
3618
4131
|
|
|
3619
4132
|
var parallelPath = drawPath(parentGfx, pathData);
|
|
3620
|
-
attr(parallelPath, {
|
|
4133
|
+
attr$2(parallelPath, {
|
|
3621
4134
|
strokeWidth: 1,
|
|
3622
4135
|
fill: 'none'
|
|
3623
4136
|
});
|
|
@@ -3625,7 +4138,7 @@
|
|
|
3625
4138
|
|
|
3626
4139
|
if (!instantiate) {
|
|
3627
4140
|
var innerCircle = drawCircle(parentGfx, element.width, element.height, element.height * 0.26);
|
|
3628
|
-
attr(innerCircle, {
|
|
4141
|
+
attr$2(innerCircle, {
|
|
3629
4142
|
strokeWidth: 1,
|
|
3630
4143
|
fill: 'none',
|
|
3631
4144
|
stroke: getStrokeColor(element, defaultStrokeColor)
|
|
@@ -3670,7 +4183,7 @@
|
|
|
3670
4183
|
|
|
3671
4184
|
// conditional flow marker
|
|
3672
4185
|
if (sequenceFlow.conditionExpression && source.$instanceOf('bpmn:Activity')) {
|
|
3673
|
-
attr(path, {
|
|
4186
|
+
attr$2(path, {
|
|
3674
4187
|
markerStart: marker('conditional-flow-marker', fill, stroke)
|
|
3675
4188
|
});
|
|
3676
4189
|
}
|
|
@@ -3678,7 +4191,7 @@
|
|
|
3678
4191
|
// default marker
|
|
3679
4192
|
if (source.default && (source.$instanceOf('bpmn:Gateway') || source.$instanceOf('bpmn:Activity')) &&
|
|
3680
4193
|
source.default === sequenceFlow) {
|
|
3681
|
-
attr(path, {
|
|
4194
|
+
attr$2(path, {
|
|
3682
4195
|
markerStart: marker('conditional-default-flow-marker', fill, stroke)
|
|
3683
4196
|
});
|
|
3684
4197
|
}
|
|
@@ -4739,22 +5252,22 @@
|
|
|
4739
5252
|
d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',
|
|
4740
5253
|
height: 36,
|
|
4741
5254
|
width: 36,
|
|
4742
|
-
heightElements: [6, 14],
|
|
4743
|
-
widthElements: [10.5, 21]
|
|
5255
|
+
heightElements: [ 6, 14 ],
|
|
5256
|
+
widthElements: [ 10.5, 21 ]
|
|
4744
5257
|
},
|
|
4745
5258
|
'EVENT_SIGNAL': {
|
|
4746
5259
|
d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x1},0 Z',
|
|
4747
5260
|
height: 36,
|
|
4748
5261
|
width: 36,
|
|
4749
|
-
heightElements: [18],
|
|
4750
|
-
widthElements: [10, 20]
|
|
5262
|
+
heightElements: [ 18 ],
|
|
5263
|
+
widthElements: [ 10, 20 ]
|
|
4751
5264
|
},
|
|
4752
5265
|
'EVENT_ESCALATION': {
|
|
4753
5266
|
d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x0},-{e.y1} l -{e.x0},{e.y1} Z',
|
|
4754
5267
|
height: 36,
|
|
4755
5268
|
width: 36,
|
|
4756
|
-
heightElements: [20, 7],
|
|
4757
|
-
widthElements: [8]
|
|
5269
|
+
heightElements: [ 20, 7 ],
|
|
5270
|
+
widthElements: [ 8 ]
|
|
4758
5271
|
},
|
|
4759
5272
|
'EVENT_CONDITIONAL': {
|
|
4760
5273
|
d: 'M {e.x0},{e.y0} l {e.x1},0 l 0,{e.y2} l -{e.x1},0 Z ' +
|
|
@@ -4766,67 +5279,67 @@
|
|
|
4766
5279
|
'M {e.x2},{e.y8} l {e.x0},0 ',
|
|
4767
5280
|
height: 36,
|
|
4768
5281
|
width: 36,
|
|
4769
|
-
heightElements: [8.5, 14.5, 18, 11.5, 14.5, 17.5, 20.5, 23.5, 26.5],
|
|
4770
|
-
widthElements: [10.5, 14.5, 12.5]
|
|
5282
|
+
heightElements: [ 8.5, 14.5, 18, 11.5, 14.5, 17.5, 20.5, 23.5, 26.5 ],
|
|
5283
|
+
widthElements: [ 10.5, 14.5, 12.5 ]
|
|
4771
5284
|
},
|
|
4772
5285
|
'EVENT_LINK': {
|
|
4773
5286
|
d: 'm {mx},{my} 0,{e.y0} -{e.x1},0 0,{e.y1} {e.x1},0 0,{e.y0} {e.x0},-{e.y2} -{e.x0},-{e.y2} z',
|
|
4774
5287
|
height: 36,
|
|
4775
5288
|
width: 36,
|
|
4776
|
-
heightElements: [4.4375, 6.75, 7.8125],
|
|
4777
|
-
widthElements: [9.84375, 13.5]
|
|
5289
|
+
heightElements: [ 4.4375, 6.75, 7.8125 ],
|
|
5290
|
+
widthElements: [ 9.84375, 13.5 ]
|
|
4778
5291
|
},
|
|
4779
5292
|
'EVENT_ERROR': {
|
|
4780
5293
|
d: 'm {mx},{my} {e.x0},-{e.y0} {e.x1},-{e.y1} {e.x2},{e.y2} {e.x3},-{e.y3} -{e.x4},{e.y4} -{e.x5},-{e.y5} z',
|
|
4781
5294
|
height: 36,
|
|
4782
5295
|
width: 36,
|
|
4783
|
-
heightElements: [0.023, 8.737, 8.151, 16.564, 10.591, 8.714],
|
|
4784
|
-
widthElements: [0.085, 6.672, 6.97, 4.273, 5.337, 6.636]
|
|
5296
|
+
heightElements: [ 0.023, 8.737, 8.151, 16.564, 10.591, 8.714 ],
|
|
5297
|
+
widthElements: [ 0.085, 6.672, 6.97, 4.273, 5.337, 6.636 ]
|
|
4785
5298
|
},
|
|
4786
5299
|
'EVENT_CANCEL_45': {
|
|
4787
5300
|
d: 'm {mx},{my} -{e.x1},0 0,{e.x0} {e.x1},0 0,{e.y1} {e.x0},0 ' +
|
|
4788
5301
|
'0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',
|
|
4789
5302
|
height: 36,
|
|
4790
5303
|
width: 36,
|
|
4791
|
-
heightElements: [4.75, 8.5],
|
|
4792
|
-
widthElements: [4.75, 8.5]
|
|
5304
|
+
heightElements: [ 4.75, 8.5 ],
|
|
5305
|
+
widthElements: [ 4.75, 8.5 ]
|
|
4793
5306
|
},
|
|
4794
5307
|
'EVENT_COMPENSATION': {
|
|
4795
5308
|
d: 'm {mx},{my} {e.x0},-{e.y0} 0,{e.y1} z m {e.x1},-{e.y2} {e.x2},-{e.y3} 0,{e.y1} -{e.x2},-{e.y3} z',
|
|
4796
5309
|
height: 36,
|
|
4797
5310
|
width: 36,
|
|
4798
|
-
heightElements: [6.5, 13, 0.4, 6.1],
|
|
4799
|
-
widthElements: [9, 9.3, 8.7]
|
|
5311
|
+
heightElements: [ 6.5, 13, 0.4, 6.1 ],
|
|
5312
|
+
widthElements: [ 9, 9.3, 8.7 ]
|
|
4800
5313
|
},
|
|
4801
5314
|
'EVENT_TIMER_WH': {
|
|
4802
5315
|
d: 'M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ',
|
|
4803
5316
|
height: 36,
|
|
4804
5317
|
width: 36,
|
|
4805
|
-
heightElements: [10, 2],
|
|
4806
|
-
widthElements: [3, 7]
|
|
5318
|
+
heightElements: [ 10, 2 ],
|
|
5319
|
+
widthElements: [ 3, 7 ]
|
|
4807
5320
|
},
|
|
4808
5321
|
'EVENT_TIMER_LINE': {
|
|
4809
5322
|
d: 'M {mx},{my} ' +
|
|
4810
5323
|
'm {e.x0},{e.y0} l -{e.x1},{e.y1} ',
|
|
4811
5324
|
height: 36,
|
|
4812
5325
|
width: 36,
|
|
4813
|
-
heightElements: [10, 3],
|
|
4814
|
-
widthElements: [0, 0]
|
|
5326
|
+
heightElements: [ 10, 3 ],
|
|
5327
|
+
widthElements: [ 0, 0 ]
|
|
4815
5328
|
},
|
|
4816
5329
|
'EVENT_MULTIPLE': {
|
|
4817
5330
|
d:'m {mx},{my} {e.x1},-{e.y0} {e.x1},{e.y0} -{e.x0},{e.y1} -{e.x2},0 z',
|
|
4818
5331
|
height: 36,
|
|
4819
5332
|
width: 36,
|
|
4820
|
-
heightElements: [6.28099, 12.56199],
|
|
4821
|
-
widthElements: [3.1405, 9.42149, 12.56198]
|
|
5333
|
+
heightElements: [ 6.28099, 12.56199 ],
|
|
5334
|
+
widthElements: [ 3.1405, 9.42149, 12.56198 ]
|
|
4822
5335
|
},
|
|
4823
5336
|
'EVENT_PARALLEL_MULTIPLE': {
|
|
4824
5337
|
d:'m {mx},{my} {e.x0},0 0,{e.y1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +
|
|
4825
5338
|
'-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',
|
|
4826
5339
|
height: 36,
|
|
4827
5340
|
width: 36,
|
|
4828
|
-
heightElements: [2.56228, 7.68683],
|
|
4829
|
-
widthElements: [2.56228, 7.68683]
|
|
5341
|
+
heightElements: [ 2.56228, 7.68683 ],
|
|
5342
|
+
widthElements: [ 2.56228, 7.68683 ]
|
|
4830
5343
|
},
|
|
4831
5344
|
'GATEWAY_EXCLUSIVE': {
|
|
4832
5345
|
d:'m {mx},{my} {e.x0},{e.y0} {e.x1},{e.y0} {e.x2},0 {e.x4},{e.y2} ' +
|
|
@@ -4834,23 +5347,23 @@
|
|
|
4834
5347
|
'{e.x3},0 {e.x5},{e.y1} {e.x5},{e.y2} {e.x3},0 z',
|
|
4835
5348
|
height: 17.5,
|
|
4836
5349
|
width: 17.5,
|
|
4837
|
-
heightElements: [8.5, 6.5312, -6.5312, -8.5],
|
|
4838
|
-
widthElements: [6.5, -6.5, 3, -3, 5, -5]
|
|
5350
|
+
heightElements: [ 8.5, 6.5312, -6.5312, -8.5 ],
|
|
5351
|
+
widthElements: [ 6.5, -6.5, 3, -3, 5, -5 ]
|
|
4839
5352
|
},
|
|
4840
5353
|
'GATEWAY_PARALLEL': {
|
|
4841
5354
|
d:'m {mx},{my} 0,{e.y1} -{e.x1},0 0,{e.y0} {e.x1},0 0,{e.y1} {e.x0},0 ' +
|
|
4842
5355
|
'0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',
|
|
4843
5356
|
height: 30,
|
|
4844
5357
|
width: 30,
|
|
4845
|
-
heightElements: [5, 12.5],
|
|
4846
|
-
widthElements: [5, 12.5]
|
|
5358
|
+
heightElements: [ 5, 12.5 ],
|
|
5359
|
+
widthElements: [ 5, 12.5 ]
|
|
4847
5360
|
},
|
|
4848
5361
|
'GATEWAY_EVENT_BASED': {
|
|
4849
5362
|
d:'m {mx},{my} {e.x0},{e.y0} {e.x0},{e.y1} {e.x1},{e.y2} {e.x2},0 z',
|
|
4850
5363
|
height: 11,
|
|
4851
5364
|
width: 11,
|
|
4852
|
-
heightElements: [-6, 6, 12, -12],
|
|
4853
|
-
widthElements: [9, -3, -12]
|
|
5365
|
+
heightElements: [ -6, 6, 12, -12 ],
|
|
5366
|
+
widthElements: [ 9, -3, -12 ]
|
|
4854
5367
|
},
|
|
4855
5368
|
'GATEWAY_COMPLEX': {
|
|
4856
5369
|
d:'m {mx},{my} 0,{e.y0} -{e.x0},-{e.y1} -{e.x1},{e.y2} {e.x0},{e.y1} -{e.x2},0 0,{e.y3} ' +
|
|
@@ -4859,15 +5372,15 @@
|
|
|
4859
5372
|
'-{e.x0},{e.y1} 0,-{e.y0} -{e.x3},0 z',
|
|
4860
5373
|
height: 17.125,
|
|
4861
5374
|
width: 17.125,
|
|
4862
|
-
heightElements: [4.875, 3.4375, 2.125, 3],
|
|
4863
|
-
widthElements: [3.4375, 2.125, 4.875, 3]
|
|
5375
|
+
heightElements: [ 4.875, 3.4375, 2.125, 3 ],
|
|
5376
|
+
widthElements: [ 3.4375, 2.125, 4.875, 3 ]
|
|
4864
5377
|
},
|
|
4865
5378
|
'DATA_OBJECT_PATH': {
|
|
4866
5379
|
d:'m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0',
|
|
4867
5380
|
height: 61,
|
|
4868
5381
|
width: 51,
|
|
4869
|
-
heightElements: [10, 50, 60],
|
|
4870
|
-
widthElements: [10, 40, 50, 60]
|
|
5382
|
+
heightElements: [ 10, 50, 60 ],
|
|
5383
|
+
widthElements: [ 10, 40, 50, 60 ]
|
|
4871
5384
|
},
|
|
4872
5385
|
'DATA_OBJECT_COLLECTION_PATH': {
|
|
4873
5386
|
d: 'm{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10',
|
|
@@ -4896,15 +5409,15 @@
|
|
|
4896
5409
|
'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0',
|
|
4897
5410
|
height: 61,
|
|
4898
5411
|
width: 61,
|
|
4899
|
-
heightElements: [7, 10, 45],
|
|
4900
|
-
widthElements: [2, 58, 60]
|
|
5412
|
+
heightElements: [ 7, 10, 45 ],
|
|
5413
|
+
widthElements: [ 2, 58, 60 ]
|
|
4901
5414
|
},
|
|
4902
5415
|
'TEXT_ANNOTATION': {
|
|
4903
5416
|
d: 'm {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0',
|
|
4904
5417
|
height: 30,
|
|
4905
5418
|
width: 10,
|
|
4906
|
-
heightElements: [30],
|
|
4907
|
-
widthElements: [10]
|
|
5419
|
+
heightElements: [ 30 ],
|
|
5420
|
+
widthElements: [ 10 ]
|
|
4908
5421
|
},
|
|
4909
5422
|
'MARKER_SUB_PROCESS': {
|
|
4910
5423
|
d: 'm{mx},{my} m 7,2 l 0,10 m -5,-5 l 10,0',
|
|
@@ -4959,8 +5472,8 @@
|
|
|
4959
5472
|
d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',
|
|
4960
5473
|
height: 14,
|
|
4961
5474
|
width: 21,
|
|
4962
|
-
heightElements: [6, 14],
|
|
4963
|
-
widthElements: [10.5, 21]
|
|
5475
|
+
heightElements: [ 6, 14 ],
|
|
5476
|
+
widthElements: [ 10.5, 21 ]
|
|
4964
5477
|
},
|
|
4965
5478
|
'TASK_TYPE_SCRIPT': {
|
|
4966
5479
|
d: 'm {mx},{my} c 9.966553,-6.27276 -8.000926,-7.91932 2.968968,-14.938 l -8.802728,0 ' +
|
|
@@ -4971,8 +5484,8 @@
|
|
|
4971
5484
|
'm -4,3 l 5,0',
|
|
4972
5485
|
height: 15,
|
|
4973
5486
|
width: 12.6,
|
|
4974
|
-
heightElements: [6, 14],
|
|
4975
|
-
widthElements: [10.5, 21]
|
|
5487
|
+
heightElements: [ 6, 14 ],
|
|
5488
|
+
widthElements: [ 10.5, 21 ]
|
|
4976
5489
|
},
|
|
4977
5490
|
'TASK_TYPE_USER_1': {
|
|
4978
5491
|
d: 'm {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 ' +
|
|
@@ -5657,11 +6170,6 @@
|
|
|
5657
6170
|
parentElement = this._canvas.findRoot(parentElement);
|
|
5658
6171
|
}
|
|
5659
6172
|
|
|
5660
|
-
// insert sequence flows behind other flow nodes (cf. #727)
|
|
5661
|
-
if (is(semantic, 'bpmn:SequenceFlow')) {
|
|
5662
|
-
parentIndex = 0;
|
|
5663
|
-
}
|
|
5664
|
-
|
|
5665
6173
|
this._canvas.addConnection(element, parentElement, parentIndex);
|
|
5666
6174
|
} else {
|
|
5667
6175
|
throw new Error(translate('unknown di {di} for element {semantic}', {
|
|
@@ -8406,7 +8914,7 @@
|
|
|
8406
8914
|
|
|
8407
8915
|
// dataAssociations are children of the subprocess but rendered on process level
|
|
8408
8916
|
// cf. https://github.com/bpmn-io/bpmn-js/issues/1619
|
|
8409
|
-
if (isAny(bo, ['bpmn:DataInputAssociation', 'bpmn:DataOutputAssociation'])) {
|
|
8917
|
+
if (isAny(bo, [ 'bpmn:DataInputAssociation', 'bpmn:DataOutputAssociation' ])) {
|
|
8410
8918
|
return false;
|
|
8411
8919
|
}
|
|
8412
8920
|
|
|
@@ -8454,7 +8962,7 @@
|
|
|
8454
8962
|
}, true);
|
|
8455
8963
|
|
|
8456
8964
|
|
|
8457
|
-
this.executed(['shape.create', 'shape.move', 'shape.delete'], LOW_PRIORITY$3,
|
|
8965
|
+
this.executed([ 'shape.create', 'shape.move', 'shape.delete' ], LOW_PRIORITY$3,
|
|
8458
8966
|
function(context) {
|
|
8459
8967
|
var oldParent = context.oldParent,
|
|
8460
8968
|
newParent = context.newParent || context.parent,
|
|
@@ -8471,7 +8979,7 @@
|
|
|
8471
8979
|
}, true);
|
|
8472
8980
|
|
|
8473
8981
|
|
|
8474
|
-
this.reverted(['shape.create', 'shape.move', 'shape.delete'], LOW_PRIORITY$3,
|
|
8982
|
+
this.reverted([ 'shape.create', 'shape.move', 'shape.delete' ], LOW_PRIORITY$3,
|
|
8475
8983
|
function(context) {
|
|
8476
8984
|
var oldParent = context.oldParent,
|
|
8477
8985
|
newParent = context.newParent || context.parent,
|
|
@@ -8590,7 +9098,7 @@
|
|
|
8590
9098
|
|
|
8591
9099
|
var DrilldownModdule = {
|
|
8592
9100
|
__depends__: [ OverlaysModule, ChangeSupportModule, RootElementsModule ],
|
|
8593
|
-
__init__: [ 'drilldownBreadcrumbs', 'drilldownOverlayBehavior', 'drilldownCentering', 'subprocessCompatibility'],
|
|
9101
|
+
__init__: [ 'drilldownBreadcrumbs', 'drilldownOverlayBehavior', 'drilldownCentering', 'subprocessCompatibility' ],
|
|
8594
9102
|
drilldownBreadcrumbs: [ 'type', DrilldownBreadcrumbs ],
|
|
8595
9103
|
drilldownCentering: [ 'type', DrilldownCentering ],
|
|
8596
9104
|
drilldownOverlayBehavior: [ 'type', DrilldownOverlayBehavior ],
|
|
@@ -8918,20 +9426,11 @@
|
|
|
8918
9426
|
return function() {
|
|
8919
9427
|
initializers.forEach(function(initializer) {
|
|
8920
9428
|
|
|
8921
|
-
|
|
8922
|
-
|
|
8923
|
-
|
|
8924
|
-
|
|
8925
|
-
|
|
8926
|
-
} else {
|
|
8927
|
-
injector.invoke(initializer);
|
|
8928
|
-
}
|
|
8929
|
-
} catch (error) {
|
|
8930
|
-
if (typeof AggregateError !== 'undefined') {
|
|
8931
|
-
throw new AggregateError([ error ], 'Failed to initialize!');
|
|
8932
|
-
}
|
|
8933
|
-
|
|
8934
|
-
throw new Error('Failed to initialize! ' + error.message);
|
|
9429
|
+
// eagerly resolve component (fn or string)
|
|
9430
|
+
if (typeof initializer === 'string') {
|
|
9431
|
+
injector.get(initializer);
|
|
9432
|
+
} else {
|
|
9433
|
+
injector.invoke(initializer);
|
|
8935
9434
|
}
|
|
8936
9435
|
});
|
|
8937
9436
|
};
|
|
@@ -9247,7 +9746,7 @@
|
|
|
9247
9746
|
*
|
|
9248
9747
|
* @return {number} the previous index of the element
|
|
9249
9748
|
*/
|
|
9250
|
-
function remove$
|
|
9749
|
+
function remove$3(collection, element) {
|
|
9251
9750
|
|
|
9252
9751
|
if (!collection || !element) {
|
|
9253
9752
|
return -1;
|
|
@@ -10199,7 +10698,7 @@
|
|
|
10199
10698
|
graphicsFactory.remove(element);
|
|
10200
10699
|
|
|
10201
10700
|
// unset parent <-> child relationship
|
|
10202
|
-
remove$
|
|
10701
|
+
remove$3(element.parent && element.parent.children, element);
|
|
10203
10702
|
element.parent = null;
|
|
10204
10703
|
|
|
10205
10704
|
eventBus.fire(type + '.removed', { element: element });
|
|
@@ -11523,7 +12022,7 @@
|
|
|
11523
12022
|
*
|
|
11524
12023
|
* @return {Base} the new model instance
|
|
11525
12024
|
*/
|
|
11526
|
-
function create$
|
|
12025
|
+
function create$2(type, attrs) {
|
|
11527
12026
|
var Type = types[type];
|
|
11528
12027
|
if (!Type) {
|
|
11529
12028
|
throw new Error('unknown type: <' + type + '>');
|
|
@@ -11571,7 +12070,7 @@
|
|
|
11571
12070
|
attrs.id = type + '_' + (this._uid++);
|
|
11572
12071
|
}
|
|
11573
12072
|
|
|
11574
|
-
return create$
|
|
12073
|
+
return create$2(type, attrs);
|
|
11575
12074
|
};
|
|
11576
12075
|
|
|
11577
12076
|
var FN_REF = '__fn';
|
|
@@ -16092,7 +16591,23 @@
|
|
|
16092
16591
|
value = escapeAttr(value);
|
|
16093
16592
|
}
|
|
16094
16593
|
|
|
16095
|
-
|
|
16594
|
+
// de-duplicate attributes
|
|
16595
|
+
// https://github.com/bpmn-io/moddle-xml/issues/66
|
|
16596
|
+
var idx = findIndex(attrs, function(element) {
|
|
16597
|
+
return (
|
|
16598
|
+
element.name.localName === name.localName &&
|
|
16599
|
+
element.name.uri === name.uri &&
|
|
16600
|
+
element.name.prefix === name.prefix
|
|
16601
|
+
);
|
|
16602
|
+
});
|
|
16603
|
+
|
|
16604
|
+
var attr = { name: name, value: value };
|
|
16605
|
+
|
|
16606
|
+
if (idx !== -1) {
|
|
16607
|
+
attrs.splice(idx, 1, attr);
|
|
16608
|
+
} else {
|
|
16609
|
+
attrs.push(attr);
|
|
16610
|
+
}
|
|
16096
16611
|
};
|
|
16097
16612
|
|
|
16098
16613
|
ElementSerializer.prototype.serializeAttributes = function(writer) {
|
|
@@ -16352,12 +16867,12 @@
|
|
|
16352
16867
|
});
|
|
16353
16868
|
};
|
|
16354
16869
|
|
|
16355
|
-
var name = "BPMN20";
|
|
16356
|
-
var uri = "http://www.omg.org/spec/BPMN/20100524/MODEL";
|
|
16357
|
-
var prefix$
|
|
16358
|
-
var associations = [
|
|
16870
|
+
var name$5 = "BPMN20";
|
|
16871
|
+
var uri$5 = "http://www.omg.org/spec/BPMN/20100524/MODEL";
|
|
16872
|
+
var prefix$5 = "bpmn";
|
|
16873
|
+
var associations$5 = [
|
|
16359
16874
|
];
|
|
16360
|
-
var types$
|
|
16875
|
+
var types$5 = [
|
|
16361
16876
|
{
|
|
16362
16877
|
name: "Interface",
|
|
16363
16878
|
superClass: [
|
|
@@ -19175,7 +19690,7 @@
|
|
|
19175
19690
|
]
|
|
19176
19691
|
}
|
|
19177
19692
|
];
|
|
19178
|
-
var enumerations = [
|
|
19693
|
+
var enumerations$3 = [
|
|
19179
19694
|
{
|
|
19180
19695
|
name: "ProcessType",
|
|
19181
19696
|
literalValues: [
|
|
@@ -19306,24 +19821,24 @@
|
|
|
19306
19821
|
]
|
|
19307
19822
|
}
|
|
19308
19823
|
];
|
|
19309
|
-
var xml = {
|
|
19824
|
+
var xml$1 = {
|
|
19310
19825
|
tagAlias: "lowerCase",
|
|
19311
19826
|
typePrefix: "t"
|
|
19312
19827
|
};
|
|
19313
19828
|
var BpmnPackage = {
|
|
19314
|
-
name: name,
|
|
19315
|
-
uri: uri,
|
|
19316
|
-
prefix: prefix$
|
|
19317
|
-
associations: associations,
|
|
19318
|
-
types: types$
|
|
19319
|
-
enumerations: enumerations,
|
|
19320
|
-
xml: xml
|
|
19829
|
+
name: name$5,
|
|
19830
|
+
uri: uri$5,
|
|
19831
|
+
prefix: prefix$5,
|
|
19832
|
+
associations: associations$5,
|
|
19833
|
+
types: types$5,
|
|
19834
|
+
enumerations: enumerations$3,
|
|
19835
|
+
xml: xml$1
|
|
19321
19836
|
};
|
|
19322
19837
|
|
|
19323
|
-
var name$
|
|
19324
|
-
var uri$
|
|
19325
|
-
var prefix$
|
|
19326
|
-
var types$
|
|
19838
|
+
var name$4 = "BPMNDI";
|
|
19839
|
+
var uri$4 = "http://www.omg.org/spec/BPMN/20100524/DI";
|
|
19840
|
+
var prefix$4 = "bpmndi";
|
|
19841
|
+
var types$4 = [
|
|
19327
19842
|
{
|
|
19328
19843
|
name: "BPMNDiagram",
|
|
19329
19844
|
properties: [
|
|
@@ -19474,7 +19989,7 @@
|
|
|
19474
19989
|
]
|
|
19475
19990
|
}
|
|
19476
19991
|
];
|
|
19477
|
-
var enumerations$
|
|
19992
|
+
var enumerations$2 = [
|
|
19478
19993
|
{
|
|
19479
19994
|
name: "ParticipantBandKind",
|
|
19480
19995
|
literalValues: [
|
|
@@ -19510,21 +20025,21 @@
|
|
|
19510
20025
|
]
|
|
19511
20026
|
}
|
|
19512
20027
|
];
|
|
19513
|
-
var associations$
|
|
20028
|
+
var associations$4 = [
|
|
19514
20029
|
];
|
|
19515
20030
|
var BpmnDiPackage = {
|
|
19516
|
-
name: name$
|
|
19517
|
-
uri: uri$
|
|
19518
|
-
prefix: prefix$
|
|
19519
|
-
types: types$
|
|
19520
|
-
enumerations: enumerations$
|
|
19521
|
-
associations: associations$
|
|
20031
|
+
name: name$4,
|
|
20032
|
+
uri: uri$4,
|
|
20033
|
+
prefix: prefix$4,
|
|
20034
|
+
types: types$4,
|
|
20035
|
+
enumerations: enumerations$2,
|
|
20036
|
+
associations: associations$4
|
|
19522
20037
|
};
|
|
19523
20038
|
|
|
19524
|
-
var name$
|
|
19525
|
-
var uri$
|
|
19526
|
-
var prefix$
|
|
19527
|
-
var types$
|
|
20039
|
+
var name$3 = "DC";
|
|
20040
|
+
var uri$3 = "http://www.omg.org/spec/DD/20100524/DC";
|
|
20041
|
+
var prefix$3 = "dc";
|
|
20042
|
+
var types$3 = [
|
|
19528
20043
|
{
|
|
19529
20044
|
name: "Boolean"
|
|
19530
20045
|
},
|
|
@@ -19617,20 +20132,20 @@
|
|
|
19617
20132
|
]
|
|
19618
20133
|
}
|
|
19619
20134
|
];
|
|
19620
|
-
var associations$
|
|
20135
|
+
var associations$3 = [
|
|
19621
20136
|
];
|
|
19622
20137
|
var DcPackage = {
|
|
19623
|
-
name: name$
|
|
19624
|
-
uri: uri$
|
|
19625
|
-
prefix: prefix$
|
|
19626
|
-
types: types$
|
|
19627
|
-
associations: associations$
|
|
20138
|
+
name: name$3,
|
|
20139
|
+
uri: uri$3,
|
|
20140
|
+
prefix: prefix$3,
|
|
20141
|
+
types: types$3,
|
|
20142
|
+
associations: associations$3
|
|
19628
20143
|
};
|
|
19629
20144
|
|
|
19630
|
-
var name$
|
|
19631
|
-
var uri$
|
|
19632
|
-
var prefix$
|
|
19633
|
-
var types$
|
|
20145
|
+
var name$2 = "DI";
|
|
20146
|
+
var uri$2 = "http://www.omg.org/spec/DD/20100524/DI";
|
|
20147
|
+
var prefix$2 = "di";
|
|
20148
|
+
var types$2 = [
|
|
19634
20149
|
{
|
|
19635
20150
|
name: "DiagramElement",
|
|
19636
20151
|
isAbstract: true,
|
|
@@ -19859,24 +20374,24 @@
|
|
|
19859
20374
|
]
|
|
19860
20375
|
}
|
|
19861
20376
|
];
|
|
19862
|
-
var associations$
|
|
20377
|
+
var associations$2 = [
|
|
19863
20378
|
];
|
|
19864
|
-
var xml
|
|
20379
|
+
var xml = {
|
|
19865
20380
|
tagAlias: "lowerCase"
|
|
19866
20381
|
};
|
|
19867
20382
|
var DiPackage = {
|
|
19868
|
-
name: name$
|
|
19869
|
-
uri: uri$
|
|
19870
|
-
prefix: prefix$
|
|
19871
|
-
types: types$
|
|
19872
|
-
associations: associations$
|
|
19873
|
-
xml: xml
|
|
20383
|
+
name: name$2,
|
|
20384
|
+
uri: uri$2,
|
|
20385
|
+
prefix: prefix$2,
|
|
20386
|
+
types: types$2,
|
|
20387
|
+
associations: associations$2,
|
|
20388
|
+
xml: xml
|
|
19874
20389
|
};
|
|
19875
20390
|
|
|
19876
|
-
var name$
|
|
19877
|
-
var uri$
|
|
19878
|
-
var prefix$
|
|
19879
|
-
var types$
|
|
20391
|
+
var name$1 = "bpmn.io colors for BPMN";
|
|
20392
|
+
var uri$1 = "http://bpmn.io/schema/bpmn/biocolor/1.0";
|
|
20393
|
+
var prefix$1 = "bioc";
|
|
20394
|
+
var types$1 = [
|
|
19880
20395
|
{
|
|
19881
20396
|
name: "ColoredShape",
|
|
19882
20397
|
"extends": [
|
|
@@ -19914,23 +20429,23 @@
|
|
|
19914
20429
|
]
|
|
19915
20430
|
}
|
|
19916
20431
|
];
|
|
19917
|
-
var enumerations$
|
|
20432
|
+
var enumerations$1 = [
|
|
19918
20433
|
];
|
|
19919
|
-
var associations$
|
|
20434
|
+
var associations$1 = [
|
|
19920
20435
|
];
|
|
19921
20436
|
var BiocPackage = {
|
|
19922
|
-
name: name$
|
|
19923
|
-
uri: uri$
|
|
19924
|
-
prefix: prefix$
|
|
19925
|
-
types: types$
|
|
19926
|
-
enumerations: enumerations$
|
|
19927
|
-
associations: associations$
|
|
20437
|
+
name: name$1,
|
|
20438
|
+
uri: uri$1,
|
|
20439
|
+
prefix: prefix$1,
|
|
20440
|
+
types: types$1,
|
|
20441
|
+
enumerations: enumerations$1,
|
|
20442
|
+
associations: associations$1
|
|
19928
20443
|
};
|
|
19929
20444
|
|
|
19930
|
-
var name
|
|
19931
|
-
var uri
|
|
19932
|
-
var prefix$
|
|
19933
|
-
var types$
|
|
20445
|
+
var name = "BPMN in Color";
|
|
20446
|
+
var uri = "http://www.omg.org/spec/BPMN/non-normative/color/1.0";
|
|
20447
|
+
var prefix$6 = "color";
|
|
20448
|
+
var types$6 = [
|
|
19934
20449
|
{
|
|
19935
20450
|
name: "ColoredLabel",
|
|
19936
20451
|
"extends": [
|
|
@@ -19976,17 +20491,17 @@
|
|
|
19976
20491
|
]
|
|
19977
20492
|
}
|
|
19978
20493
|
];
|
|
19979
|
-
var enumerations
|
|
20494
|
+
var enumerations = [
|
|
19980
20495
|
];
|
|
19981
|
-
var associations
|
|
20496
|
+
var associations = [
|
|
19982
20497
|
];
|
|
19983
20498
|
var BpmnInColorPackage = {
|
|
19984
|
-
name: name
|
|
19985
|
-
uri: uri
|
|
19986
|
-
prefix: prefix$
|
|
19987
|
-
types: types$
|
|
19988
|
-
enumerations: enumerations
|
|
19989
|
-
associations: associations
|
|
20499
|
+
name: name,
|
|
20500
|
+
uri: uri,
|
|
20501
|
+
prefix: prefix$6,
|
|
20502
|
+
types: types$6,
|
|
20503
|
+
enumerations: enumerations,
|
|
20504
|
+
associations: associations
|
|
19990
20505
|
};
|
|
19991
20506
|
|
|
19992
20507
|
var packages = {
|
|
@@ -20066,6 +20581,7 @@
|
|
|
20066
20581
|
// bpmnElement can have multiple independent DIs
|
|
20067
20582
|
if (!has(businessObject, 'di')) {
|
|
20068
20583
|
Object.defineProperty(businessObject, 'di', {
|
|
20584
|
+
enumerable: false,
|
|
20069
20585
|
get: function() {
|
|
20070
20586
|
throw new Error(DI_ERROR_MESSAGE);
|
|
20071
20587
|
}
|
|
@@ -21635,7 +22151,7 @@
|
|
|
21635
22151
|
// default moddle extensions the viewer is composed of
|
|
21636
22152
|
Viewer.prototype._moddleExtensions = {};
|
|
21637
22153
|
|
|
21638
|
-
function ensureImported$
|
|
22154
|
+
function ensureImported$2(element, target) {
|
|
21639
22155
|
|
|
21640
22156
|
if (element.ownerDocument !== target.ownerDocument) {
|
|
21641
22157
|
try {
|
|
@@ -21661,8 +22177,8 @@
|
|
|
21661
22177
|
*
|
|
21662
22178
|
* @return {SVGElement} the appended node
|
|
21663
22179
|
*/
|
|
21664
|
-
function appendTo$
|
|
21665
|
-
return target.appendChild(ensureImported$
|
|
22180
|
+
function appendTo$2(element, target) {
|
|
22181
|
+
return target.appendChild(ensureImported$2(element, target));
|
|
21666
22182
|
}
|
|
21667
22183
|
|
|
21668
22184
|
/**
|
|
@@ -21677,8 +22193,8 @@
|
|
|
21677
22193
|
*
|
|
21678
22194
|
* @return {SVGElement} the element
|
|
21679
22195
|
*/
|
|
21680
|
-
function append$
|
|
21681
|
-
appendTo$
|
|
22196
|
+
function append$2(target, node) {
|
|
22197
|
+
appendTo$2(node, target);
|
|
21682
22198
|
return target;
|
|
21683
22199
|
}
|
|
21684
22200
|
|
|
@@ -21686,9 +22202,9 @@
|
|
|
21686
22202
|
* attribute accessor utility
|
|
21687
22203
|
*/
|
|
21688
22204
|
|
|
21689
|
-
var LENGTH_ATTR$
|
|
22205
|
+
var LENGTH_ATTR$2 = 2;
|
|
21690
22206
|
|
|
21691
|
-
var CSS_PROPERTIES$
|
|
22207
|
+
var CSS_PROPERTIES$2 = {
|
|
21692
22208
|
'alignment-baseline': 1,
|
|
21693
22209
|
'baseline-shift': 1,
|
|
21694
22210
|
'clip': 1,
|
|
@@ -21712,7 +22228,7 @@
|
|
|
21712
22228
|
'flood-opacity': 1,
|
|
21713
22229
|
'font': 1,
|
|
21714
22230
|
'font-family': 1,
|
|
21715
|
-
'font-size': LENGTH_ATTR$
|
|
22231
|
+
'font-size': LENGTH_ATTR$2,
|
|
21716
22232
|
'font-size-adjust': 1,
|
|
21717
22233
|
'font-stretch': 1,
|
|
21718
22234
|
'font-style': 1,
|
|
@@ -21742,7 +22258,7 @@
|
|
|
21742
22258
|
'stroke-linejoin': 1,
|
|
21743
22259
|
'stroke-miterlimit': 1,
|
|
21744
22260
|
'stroke-opacity': 1,
|
|
21745
|
-
'stroke-width': LENGTH_ATTR$
|
|
22261
|
+
'stroke-width': LENGTH_ATTR$2,
|
|
21746
22262
|
'text-anchor': 1,
|
|
21747
22263
|
'text-decoration': 1,
|
|
21748
22264
|
'text-rendering': 1,
|
|
@@ -21753,22 +22269,22 @@
|
|
|
21753
22269
|
};
|
|
21754
22270
|
|
|
21755
22271
|
|
|
21756
|
-
function getAttribute$
|
|
21757
|
-
if (CSS_PROPERTIES$
|
|
22272
|
+
function getAttribute$2(node, name) {
|
|
22273
|
+
if (CSS_PROPERTIES$2[name]) {
|
|
21758
22274
|
return node.style[name];
|
|
21759
22275
|
} else {
|
|
21760
22276
|
return node.getAttributeNS(null, name);
|
|
21761
22277
|
}
|
|
21762
22278
|
}
|
|
21763
22279
|
|
|
21764
|
-
function setAttribute$
|
|
22280
|
+
function setAttribute$2(node, name, value) {
|
|
21765
22281
|
var hyphenated = name.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
|
|
21766
22282
|
|
|
21767
|
-
var type = CSS_PROPERTIES$
|
|
22283
|
+
var type = CSS_PROPERTIES$2[hyphenated];
|
|
21768
22284
|
|
|
21769
22285
|
if (type) {
|
|
21770
22286
|
// append pixel unit, unless present
|
|
21771
|
-
if (type === LENGTH_ATTR$
|
|
22287
|
+
if (type === LENGTH_ATTR$2 && typeof value === 'number') {
|
|
21772
22288
|
value = String(value) + 'px';
|
|
21773
22289
|
}
|
|
21774
22290
|
|
|
@@ -21778,12 +22294,12 @@
|
|
|
21778
22294
|
}
|
|
21779
22295
|
}
|
|
21780
22296
|
|
|
21781
|
-
function setAttributes$
|
|
22297
|
+
function setAttributes$2(node, attrs) {
|
|
21782
22298
|
|
|
21783
22299
|
var names = Object.keys(attrs), i, name;
|
|
21784
22300
|
|
|
21785
22301
|
for (i = 0, name; (name = names[i]); i++) {
|
|
21786
|
-
setAttribute$
|
|
22302
|
+
setAttribute$2(node, name, attrs[name]);
|
|
21787
22303
|
}
|
|
21788
22304
|
}
|
|
21789
22305
|
|
|
@@ -21797,21 +22313,21 @@
|
|
|
21797
22313
|
*
|
|
21798
22314
|
* @return {String}
|
|
21799
22315
|
*/
|
|
21800
|
-
function attr$
|
|
22316
|
+
function attr$3(node, name, value) {
|
|
21801
22317
|
if (typeof name === 'string') {
|
|
21802
22318
|
if (value !== undefined) {
|
|
21803
|
-
setAttribute$
|
|
22319
|
+
setAttribute$2(node, name, value);
|
|
21804
22320
|
} else {
|
|
21805
|
-
return getAttribute$
|
|
22321
|
+
return getAttribute$2(node, name);
|
|
21806
22322
|
}
|
|
21807
22323
|
} else {
|
|
21808
|
-
setAttributes$
|
|
22324
|
+
setAttributes$2(node, name);
|
|
21809
22325
|
}
|
|
21810
22326
|
|
|
21811
22327
|
return node;
|
|
21812
22328
|
}
|
|
21813
22329
|
|
|
21814
|
-
var ns$
|
|
22330
|
+
var ns$2 = {
|
|
21815
22331
|
svg: 'http://www.w3.org/2000/svg'
|
|
21816
22332
|
};
|
|
21817
22333
|
|
|
@@ -21819,24 +22335,24 @@
|
|
|
21819
22335
|
* DOM parsing utility
|
|
21820
22336
|
*/
|
|
21821
22337
|
|
|
21822
|
-
var SVG_START$
|
|
22338
|
+
var SVG_START$2 = '<svg xmlns="' + ns$2.svg + '"';
|
|
21823
22339
|
|
|
21824
|
-
function parse$
|
|
22340
|
+
function parse$3(svg) {
|
|
21825
22341
|
|
|
21826
22342
|
var unwrap = false;
|
|
21827
22343
|
|
|
21828
22344
|
// ensure we import a valid svg document
|
|
21829
22345
|
if (svg.substring(0, 4) === '<svg') {
|
|
21830
|
-
if (svg.indexOf(ns$
|
|
21831
|
-
svg = SVG_START$
|
|
22346
|
+
if (svg.indexOf(ns$2.svg) === -1) {
|
|
22347
|
+
svg = SVG_START$2 + svg.substring(4);
|
|
21832
22348
|
}
|
|
21833
22349
|
} else {
|
|
21834
22350
|
// namespace svg
|
|
21835
|
-
svg = SVG_START$
|
|
22351
|
+
svg = SVG_START$2 + '>' + svg + '</svg>';
|
|
21836
22352
|
unwrap = true;
|
|
21837
22353
|
}
|
|
21838
22354
|
|
|
21839
|
-
var parsed = parseDocument$
|
|
22355
|
+
var parsed = parseDocument$2(svg);
|
|
21840
22356
|
|
|
21841
22357
|
if (!unwrap) {
|
|
21842
22358
|
return parsed;
|
|
@@ -21853,7 +22369,7 @@
|
|
|
21853
22369
|
return fragment;
|
|
21854
22370
|
}
|
|
21855
22371
|
|
|
21856
|
-
function parseDocument$
|
|
22372
|
+
function parseDocument$2(svg) {
|
|
21857
22373
|
|
|
21858
22374
|
var parser;
|
|
21859
22375
|
|
|
@@ -21877,18 +22393,18 @@
|
|
|
21877
22393
|
*
|
|
21878
22394
|
* @returns {SVGElement}
|
|
21879
22395
|
*/
|
|
21880
|
-
function create$
|
|
22396
|
+
function create$3(name, attrs) {
|
|
21881
22397
|
var element;
|
|
21882
22398
|
|
|
21883
22399
|
if (name.charAt(0) === '<') {
|
|
21884
|
-
element = parse$
|
|
22400
|
+
element = parse$3(name).firstChild;
|
|
21885
22401
|
element = document.importNode(element, true);
|
|
21886
22402
|
} else {
|
|
21887
|
-
element = document.createElementNS(ns$
|
|
22403
|
+
element = document.createElementNS(ns$2.svg, name);
|
|
21888
22404
|
}
|
|
21889
22405
|
|
|
21890
22406
|
if (attrs) {
|
|
21891
|
-
attr$
|
|
22407
|
+
attr$3(element, attrs);
|
|
21892
22408
|
}
|
|
21893
22409
|
|
|
21894
22410
|
return element;
|
|
@@ -21899,7 +22415,7 @@
|
|
|
21899
22415
|
*/
|
|
21900
22416
|
|
|
21901
22417
|
// fake node used to instantiate svg geometry elements
|
|
21902
|
-
create$
|
|
22418
|
+
create$3('svg');
|
|
21903
22419
|
|
|
21904
22420
|
function getModelerTemplateIcon(element) {
|
|
21905
22421
|
var modelerTemplateIcon = getBusinessObject(element).get('zeebe:modelerTemplateIcon');
|
|
@@ -21940,8 +22456,8 @@
|
|
|
21940
22456
|
|
|
21941
22457
|
var modelerTemplateIcon = getModelerTemplateIcon(element);
|
|
21942
22458
|
|
|
21943
|
-
var icon = create$
|
|
21944
|
-
attr$
|
|
22459
|
+
var icon = create$3('image');
|
|
22460
|
+
attr$3(icon, {
|
|
21945
22461
|
href: modelerTemplateIcon,
|
|
21946
22462
|
x: 5,
|
|
21947
22463
|
y: 5,
|
|
@@ -21949,7 +22465,7 @@
|
|
|
21949
22465
|
height: 18
|
|
21950
22466
|
});
|
|
21951
22467
|
|
|
21952
|
-
append$
|
|
22468
|
+
append$2(parentGfx, icon);
|
|
21953
22469
|
|
|
21954
22470
|
return gfx;
|
|
21955
22471
|
};
|
|
@@ -21969,14 +22485,14 @@
|
|
|
21969
22485
|
};
|
|
21970
22486
|
|
|
21971
22487
|
var name$6 = "zeebe";
|
|
21972
|
-
var prefix$
|
|
22488
|
+
var prefix$7 = "zeebe";
|
|
21973
22489
|
var uri$6 = "http://camunda.org/schema/zeebe/1.0";
|
|
21974
22490
|
var xml$2 = {
|
|
21975
22491
|
tagAlias: "lowerCase"
|
|
21976
22492
|
};
|
|
21977
22493
|
var associations$6 = [
|
|
21978
22494
|
];
|
|
21979
|
-
var types$
|
|
22495
|
+
var types$7 = [
|
|
21980
22496
|
{
|
|
21981
22497
|
name: "ZeebeServiceTask",
|
|
21982
22498
|
"extends": [
|
|
@@ -22022,7 +22538,8 @@
|
|
|
22022
22538
|
"bpmn:Event",
|
|
22023
22539
|
"bpmn:ReceiveTask",
|
|
22024
22540
|
"zeebe:ZeebeServiceTask",
|
|
22025
|
-
"bpmn:SubProcess"
|
|
22541
|
+
"bpmn:SubProcess",
|
|
22542
|
+
"bpmn:UserTask"
|
|
22026
22543
|
]
|
|
22027
22544
|
}
|
|
22028
22545
|
},
|
|
@@ -22063,7 +22580,8 @@
|
|
|
22063
22580
|
allowedIn: [
|
|
22064
22581
|
"bpmn:CallActivity",
|
|
22065
22582
|
"zeebe:ZeebeServiceTask",
|
|
22066
|
-
"bpmn:SubProcess"
|
|
22583
|
+
"bpmn:SubProcess",
|
|
22584
|
+
"bpmn:UserTask"
|
|
22067
22585
|
]
|
|
22068
22586
|
}
|
|
22069
22587
|
},
|
|
@@ -22078,7 +22596,8 @@
|
|
|
22078
22596
|
"bpmn:Event",
|
|
22079
22597
|
"bpmn:ReceiveTask",
|
|
22080
22598
|
"zeebe:ZeebeServiceTask",
|
|
22081
|
-
"bpmn:SubProcess"
|
|
22599
|
+
"bpmn:SubProcess",
|
|
22600
|
+
"bpmn:UserTask"
|
|
22082
22601
|
]
|
|
22083
22602
|
}
|
|
22084
22603
|
},
|
|
@@ -22089,7 +22608,8 @@
|
|
|
22089
22608
|
],
|
|
22090
22609
|
meta: {
|
|
22091
22610
|
allowedIn: [
|
|
22092
|
-
"zeebe:ZeebeServiceTask"
|
|
22611
|
+
"zeebe:ZeebeServiceTask",
|
|
22612
|
+
"bpmn:UserTask"
|
|
22093
22613
|
]
|
|
22094
22614
|
},
|
|
22095
22615
|
properties: [
|
|
@@ -22296,6 +22816,51 @@
|
|
|
22296
22816
|
}
|
|
22297
22817
|
]
|
|
22298
22818
|
},
|
|
22819
|
+
{
|
|
22820
|
+
name: "Properties",
|
|
22821
|
+
superClass: [
|
|
22822
|
+
"Element"
|
|
22823
|
+
],
|
|
22824
|
+
properties: [
|
|
22825
|
+
{
|
|
22826
|
+
name: "properties",
|
|
22827
|
+
type: "Property",
|
|
22828
|
+
isMany: true
|
|
22829
|
+
}
|
|
22830
|
+
],
|
|
22831
|
+
meta: {
|
|
22832
|
+
allowedIn: [
|
|
22833
|
+
"zeebe:PropertiesHolder"
|
|
22834
|
+
]
|
|
22835
|
+
}
|
|
22836
|
+
},
|
|
22837
|
+
{
|
|
22838
|
+
name: "Property",
|
|
22839
|
+
properties: [
|
|
22840
|
+
{
|
|
22841
|
+
name: "name",
|
|
22842
|
+
type: "String",
|
|
22843
|
+
isAttr: true
|
|
22844
|
+
},
|
|
22845
|
+
{
|
|
22846
|
+
name: "value",
|
|
22847
|
+
type: "String",
|
|
22848
|
+
isAttr: true
|
|
22849
|
+
}
|
|
22850
|
+
],
|
|
22851
|
+
meta: {
|
|
22852
|
+
allowedIn: [
|
|
22853
|
+
"zeebe:PropertiesHolder"
|
|
22854
|
+
]
|
|
22855
|
+
}
|
|
22856
|
+
},
|
|
22857
|
+
{
|
|
22858
|
+
name: "PropertiesHolder",
|
|
22859
|
+
isAbstract: true,
|
|
22860
|
+
"extends": [
|
|
22861
|
+
"bpmn:FlowNode"
|
|
22862
|
+
]
|
|
22863
|
+
},
|
|
22299
22864
|
{
|
|
22300
22865
|
name: "TemplateSupported",
|
|
22301
22866
|
isAbstract: true,
|
|
@@ -22325,11 +22890,11 @@
|
|
|
22325
22890
|
];
|
|
22326
22891
|
var zeebeModdle = {
|
|
22327
22892
|
name: name$6,
|
|
22328
|
-
prefix: prefix$
|
|
22893
|
+
prefix: prefix$7,
|
|
22329
22894
|
uri: uri$6,
|
|
22330
22895
|
xml: xml$2,
|
|
22331
22896
|
associations: associations$6,
|
|
22332
|
-
types: types$
|
|
22897
|
+
types: types$7
|
|
22333
22898
|
};
|
|
22334
22899
|
|
|
22335
22900
|
const commonModules = [
|