@eclipse-glsp-examples/workflow-server-bundled 2.2.0-next.91 → 2.2.0-next.93
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/package.json +2 -2
- package/wf-glsp-server-node.js +122 -32
- package/wf-glsp-server-node.js.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eclipse-glsp-examples/workflow-server-bundled",
|
|
3
|
-
"version": "2.2.0-next.
|
|
3
|
+
"version": "2.2.0-next.93+f3f5d02",
|
|
4
4
|
"description": "GLSP node server for the workflow example (bundled)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eclipse",
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"publishConfig": {
|
|
50
50
|
"access": "public"
|
|
51
51
|
},
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "f3f5d02d9ec73d6b0338ecc71b0c118f468267f6"
|
|
53
53
|
}
|
package/wf-glsp-server-node.js
CHANGED
|
@@ -312,6 +312,22 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
312
312
|
};
|
|
313
313
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
314
314
|
exports.CreateDecisionNodeHandler = void 0;
|
|
315
|
+
/********************************************************************************
|
|
316
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
317
|
+
*
|
|
318
|
+
* This program and the accompanying materials are made available under the
|
|
319
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
320
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
321
|
+
*
|
|
322
|
+
* This Source Code may also be made available under the following Secondary
|
|
323
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
324
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
325
|
+
* with the GNU Classpath Exception which is available at
|
|
326
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
327
|
+
*
|
|
328
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
329
|
+
********************************************************************************/
|
|
330
|
+
const server_1 = __webpack_require__(/*! @eclipse-glsp/server */ "../../packages/server/lib/node/index.js");
|
|
315
331
|
const inversify_1 = __webpack_require__(/*! inversify */ "../../node_modules/inversify/es/inversify.js");
|
|
316
332
|
const model_types_1 = __webpack_require__(/*! ../util/model-types */ "./lib/common/util/model-types.js");
|
|
317
333
|
const create_activity_node_handler_1 = __webpack_require__(/*! ./create-activity-node-handler */ "./lib/common/handler/create-activity-node-handler.js");
|
|
@@ -322,7 +338,7 @@ let CreateDecisionNodeHandler = class CreateDecisionNodeHandler extends create_a
|
|
|
322
338
|
this.label = 'Decision Node';
|
|
323
339
|
}
|
|
324
340
|
builder(point) {
|
|
325
|
-
return super.builder(point).addCssClass('decision');
|
|
341
|
+
return super.builder(point).addCssClass('decision').resizeLocations(server_1.GResizeLocation.CROSS);
|
|
326
342
|
}
|
|
327
343
|
};
|
|
328
344
|
exports.CreateDecisionNodeHandler = CreateDecisionNodeHandler;
|
|
@@ -556,6 +572,22 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
556
572
|
};
|
|
557
573
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
558
574
|
exports.CreateMergeNodeHandler = void 0;
|
|
575
|
+
/********************************************************************************
|
|
576
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
577
|
+
*
|
|
578
|
+
* This program and the accompanying materials are made available under the
|
|
579
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
580
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
581
|
+
*
|
|
582
|
+
* This Source Code may also be made available under the following Secondary
|
|
583
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
584
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
585
|
+
* with the GNU Classpath Exception which is available at
|
|
586
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
587
|
+
*
|
|
588
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
589
|
+
********************************************************************************/
|
|
590
|
+
const server_1 = __webpack_require__(/*! @eclipse-glsp/server */ "../../packages/server/lib/node/index.js");
|
|
559
591
|
const inversify_1 = __webpack_require__(/*! inversify */ "../../node_modules/inversify/es/inversify.js");
|
|
560
592
|
const model_types_1 = __webpack_require__(/*! ../util/model-types */ "./lib/common/util/model-types.js");
|
|
561
593
|
const create_activity_node_handler_1 = __webpack_require__(/*! ./create-activity-node-handler */ "./lib/common/handler/create-activity-node-handler.js");
|
|
@@ -566,7 +598,7 @@ let CreateMergeNodeHandler = class CreateMergeNodeHandler extends create_activit
|
|
|
566
598
|
this.label = 'Merge Node';
|
|
567
599
|
}
|
|
568
600
|
builder(point) {
|
|
569
|
-
return super.builder(point).addCssClass('merge');
|
|
601
|
+
return super.builder(point).addCssClass('merge').resizeLocations(server_1.GResizeLocation.CROSS);
|
|
570
602
|
}
|
|
571
603
|
};
|
|
572
604
|
exports.CreateMergeNodeHandler = CreateMergeNodeHandler;
|
|
@@ -1913,32 +1945,25 @@ let WorkflowDiagramConfiguration = class WorkflowDiagramConfiguration {
|
|
|
1913
1945
|
return [
|
|
1914
1946
|
createDefaultShapeTypeHint(model_types_1.ModelTypes.MANUAL_TASK),
|
|
1915
1947
|
createDefaultShapeTypeHint(model_types_1.ModelTypes.AUTOMATED_TASK),
|
|
1916
|
-
createDefaultShapeTypeHint(model_types_1.ModelTypes.FORK_NODE),
|
|
1917
|
-
createDefaultShapeTypeHint(model_types_1.ModelTypes.JOIN_NODE),
|
|
1948
|
+
createDefaultShapeTypeHint({ elementTypeId: model_types_1.ModelTypes.FORK_NODE, resizable: false }),
|
|
1949
|
+
createDefaultShapeTypeHint({ elementTypeId: model_types_1.ModelTypes.JOIN_NODE, resizable: false }),
|
|
1918
1950
|
createDefaultShapeTypeHint(model_types_1.ModelTypes.DECISION_NODE),
|
|
1919
1951
|
createDefaultShapeTypeHint(model_types_1.ModelTypes.MERGE_NODE),
|
|
1920
|
-
{
|
|
1952
|
+
createDefaultShapeTypeHint({
|
|
1921
1953
|
elementTypeId: model_types_1.ModelTypes.CATEGORY,
|
|
1922
|
-
repositionable: true,
|
|
1923
|
-
deletable: true,
|
|
1924
|
-
resizable: true,
|
|
1925
|
-
reparentable: true,
|
|
1926
1954
|
containableElementTypeIds: [model_types_1.ModelTypes.TASK, model_types_1.ModelTypes.ACTIVITY_NODE, model_types_1.ModelTypes.CATEGORY]
|
|
1927
|
-
}
|
|
1955
|
+
})
|
|
1928
1956
|
];
|
|
1929
1957
|
}
|
|
1930
1958
|
get edgeTypeHints() {
|
|
1931
1959
|
return [
|
|
1932
1960
|
createDefaultEdgeTypeHint(protocol_1.DefaultTypes.EDGE),
|
|
1933
|
-
{
|
|
1934
|
-
elementTypeId:
|
|
1935
|
-
repositionable: true,
|
|
1936
|
-
deletable: true,
|
|
1937
|
-
routable: true,
|
|
1961
|
+
createDefaultEdgeTypeHint({
|
|
1962
|
+
elementTypeId: protocol_1.DefaultTypes.EDGE,
|
|
1938
1963
|
dynamic: true,
|
|
1939
1964
|
sourceElementTypeIds: [model_types_1.ModelTypes.ACTIVITY_NODE],
|
|
1940
1965
|
targetElementTypeIds: [model_types_1.ModelTypes.TASK, model_types_1.ModelTypes.ACTIVITY_NODE]
|
|
1941
|
-
}
|
|
1966
|
+
})
|
|
1942
1967
|
];
|
|
1943
1968
|
}
|
|
1944
1969
|
};
|
|
@@ -1946,17 +1971,14 @@ exports.WorkflowDiagramConfiguration = WorkflowDiagramConfiguration;
|
|
|
1946
1971
|
exports.WorkflowDiagramConfiguration = WorkflowDiagramConfiguration = __decorate([
|
|
1947
1972
|
(0, inversify_1.injectable)()
|
|
1948
1973
|
], WorkflowDiagramConfiguration);
|
|
1949
|
-
function createDefaultShapeTypeHint(
|
|
1950
|
-
|
|
1974
|
+
function createDefaultShapeTypeHint(elementIdOrTemplate) {
|
|
1975
|
+
const template = typeof elementIdOrTemplate === 'string' ? { elementTypeId: elementIdOrTemplate } : elementIdOrTemplate;
|
|
1976
|
+
return Object.assign({ repositionable: true, deletable: true, resizable: true, reparentable: true }, template);
|
|
1951
1977
|
}
|
|
1952
1978
|
exports.createDefaultShapeTypeHint = createDefaultShapeTypeHint;
|
|
1953
|
-
function createDefaultEdgeTypeHint(
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
repositionable: true,
|
|
1957
|
-
deletable: true,
|
|
1958
|
-
routable: true,
|
|
1959
|
-
sourceElementTypeIds: [
|
|
1979
|
+
function createDefaultEdgeTypeHint(elementIdOrTemplate) {
|
|
1980
|
+
const template = typeof elementIdOrTemplate === 'string' ? { elementTypeId: elementIdOrTemplate } : elementIdOrTemplate;
|
|
1981
|
+
return Object.assign({ repositionable: true, deletable: true, routable: true, sourceElementTypeIds: [
|
|
1960
1982
|
model_types_1.ModelTypes.MANUAL_TASK,
|
|
1961
1983
|
model_types_1.ModelTypes.AUTOMATED_TASK,
|
|
1962
1984
|
model_types_1.ModelTypes.DECISION_NODE,
|
|
@@ -1964,8 +1986,7 @@ function createDefaultEdgeTypeHint(elementId) {
|
|
|
1964
1986
|
model_types_1.ModelTypes.FORK_NODE,
|
|
1965
1987
|
model_types_1.ModelTypes.JOIN_NODE,
|
|
1966
1988
|
model_types_1.ModelTypes.CATEGORY
|
|
1967
|
-
],
|
|
1968
|
-
targetElementTypeIds: [
|
|
1989
|
+
], targetElementTypeIds: [
|
|
1969
1990
|
model_types_1.ModelTypes.MANUAL_TASK,
|
|
1970
1991
|
model_types_1.ModelTypes.AUTOMATED_TASK,
|
|
1971
1992
|
model_types_1.ModelTypes.DECISION_NODE,
|
|
@@ -1973,8 +1994,7 @@ function createDefaultEdgeTypeHint(elementId) {
|
|
|
1973
1994
|
model_types_1.ModelTypes.FORK_NODE,
|
|
1974
1995
|
model_types_1.ModelTypes.JOIN_NODE,
|
|
1975
1996
|
model_types_1.ModelTypes.CATEGORY
|
|
1976
|
-
]
|
|
1977
|
-
};
|
|
1997
|
+
] }, template);
|
|
1978
1998
|
}
|
|
1979
1999
|
exports.createDefaultEdgeTypeHint = createDefaultEdgeTypeHint;
|
|
1980
2000
|
|
|
@@ -2140,7 +2160,7 @@ const graph_extension_1 = __webpack_require__(/*! ./graph-extension */ "./lib/co
|
|
|
2140
2160
|
const model_types_1 = __webpack_require__(/*! ./util/model-types */ "./lib/common/util/model-types.js");
|
|
2141
2161
|
let WorkflowEdgeCreationChecker = class WorkflowEdgeCreationChecker {
|
|
2142
2162
|
isValidSource(edgeType, sourceElement) {
|
|
2143
|
-
return edgeType !== model_types_1.ModelTypes.WEIGHTED_EDGE
|
|
2163
|
+
return edgeType !== model_types_1.ModelTypes.WEIGHTED_EDGE && sourceElement.type === model_types_1.ModelTypes.DECISION_NODE;
|
|
2144
2164
|
}
|
|
2145
2165
|
isValidTarget(edgeType, sourceElement, targetElement) {
|
|
2146
2166
|
return (targetElement instanceof graph_extension_1.TaskNode || targetElement.type === model_types_1.ModelTypes.FORK_NODE || targetElement.type === model_types_1.ModelTypes.JOIN_NODE);
|
|
@@ -45051,6 +45071,70 @@ class GPreRenderedElementBuilder extends gmodel_element_1.GModelElementBuilder {
|
|
|
45051
45071
|
exports.GPreRenderedElementBuilder = GPreRenderedElementBuilder;
|
|
45052
45072
|
|
|
45053
45073
|
|
|
45074
|
+
/***/ }),
|
|
45075
|
+
|
|
45076
|
+
/***/ "../../packages/graph/lib/gresizable.js":
|
|
45077
|
+
/*!**********************************************!*\
|
|
45078
|
+
!*** ../../packages/graph/lib/gresizable.js ***!
|
|
45079
|
+
\**********************************************/
|
|
45080
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
45081
|
+
|
|
45082
|
+
"use strict";
|
|
45083
|
+
|
|
45084
|
+
/********************************************************************************
|
|
45085
|
+
* Copyright (c) 2024 EclipseSource and others.
|
|
45086
|
+
*
|
|
45087
|
+
* This program and the accompanying materials are made available under the
|
|
45088
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
45089
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
45090
|
+
*
|
|
45091
|
+
* This Source Code may also be made available under the following Secondary
|
|
45092
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
45093
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
45094
|
+
* with the GNU Classpath Exception which is available at
|
|
45095
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
45096
|
+
*
|
|
45097
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
45098
|
+
********************************************************************************/
|
|
45099
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
45100
|
+
exports.GResizeLocation = exports.GResizableBuilder = exports.isGResizable = exports.GResizable = void 0;
|
|
45101
|
+
exports.GResizable = Symbol('GResizable');
|
|
45102
|
+
function isGResizable(element) {
|
|
45103
|
+
return exports.GResizable in element && element[exports.GResizable] === true;
|
|
45104
|
+
}
|
|
45105
|
+
exports.isGResizable = isGResizable;
|
|
45106
|
+
var GResizableBuilder;
|
|
45107
|
+
(function (GResizableBuilder) {
|
|
45108
|
+
function resizeLocations(builder, resizeLocations) {
|
|
45109
|
+
const proxy = builder['proxy'];
|
|
45110
|
+
proxy.resizeLocations = resizeLocations;
|
|
45111
|
+
return builder;
|
|
45112
|
+
}
|
|
45113
|
+
GResizableBuilder.resizeLocations = resizeLocations;
|
|
45114
|
+
})(GResizableBuilder || (exports.GResizableBuilder = GResizableBuilder = {}));
|
|
45115
|
+
var GResizeLocation;
|
|
45116
|
+
(function (GResizeLocation) {
|
|
45117
|
+
GResizeLocation["TopLeft"] = "top-left";
|
|
45118
|
+
GResizeLocation["Top"] = "top";
|
|
45119
|
+
GResizeLocation["TopRight"] = "top-right";
|
|
45120
|
+
GResizeLocation["Right"] = "right";
|
|
45121
|
+
GResizeLocation["BottomRight"] = "bottom-right";
|
|
45122
|
+
GResizeLocation["Bottom"] = "bottom";
|
|
45123
|
+
GResizeLocation["BottomLeft"] = "bottom-left";
|
|
45124
|
+
GResizeLocation["Left"] = "left";
|
|
45125
|
+
})(GResizeLocation || (exports.GResizeLocation = GResizeLocation = {}));
|
|
45126
|
+
(function (GResizeLocation) {
|
|
45127
|
+
GResizeLocation.CORNERS = [
|
|
45128
|
+
GResizeLocation.TopLeft,
|
|
45129
|
+
GResizeLocation.TopRight,
|
|
45130
|
+
GResizeLocation.BottomRight,
|
|
45131
|
+
GResizeLocation.BottomLeft
|
|
45132
|
+
];
|
|
45133
|
+
GResizeLocation.CROSS = [GResizeLocation.Top, GResizeLocation.Right, GResizeLocation.Bottom, GResizeLocation.Left];
|
|
45134
|
+
GResizeLocation.ALL = [...GResizeLocation.CORNERS, ...GResizeLocation.CROSS];
|
|
45135
|
+
})(GResizeLocation || (exports.GResizeLocation = GResizeLocation = {}));
|
|
45136
|
+
|
|
45137
|
+
|
|
45054
45138
|
/***/ }),
|
|
45055
45139
|
|
|
45056
45140
|
/***/ "../../packages/graph/lib/gshape-element.js":
|
|
@@ -45061,21 +45145,23 @@ exports.GPreRenderedElementBuilder = GPreRenderedElementBuilder;
|
|
|
45061
45145
|
|
|
45062
45146
|
"use strict";
|
|
45063
45147
|
|
|
45064
|
-
var _a, _b;
|
|
45148
|
+
var _a, _b, _c;
|
|
45065
45149
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
45066
45150
|
exports.GShapeElementBuilder = exports.GShapeElement = void 0;
|
|
45067
45151
|
const gbounds_aware_1 = __webpack_require__(/*! ./gbounds-aware */ "../../packages/graph/lib/gbounds-aware.js");
|
|
45068
45152
|
const glayoutable_1 = __webpack_require__(/*! ./glayoutable */ "../../packages/graph/lib/glayoutable.js");
|
|
45069
45153
|
const gmodel_element_1 = __webpack_require__(/*! ./gmodel-element */ "../../packages/graph/lib/gmodel-element.js");
|
|
45154
|
+
const gresizable_1 = __webpack_require__(/*! ./gresizable */ "../../packages/graph/lib/gresizable.js");
|
|
45070
45155
|
class GShapeElement extends gmodel_element_1.GModelElement {
|
|
45071
45156
|
constructor() {
|
|
45072
45157
|
super(...arguments);
|
|
45073
45158
|
this[_a] = true;
|
|
45074
45159
|
this[_b] = true;
|
|
45160
|
+
this[_c] = true;
|
|
45075
45161
|
}
|
|
45076
45162
|
}
|
|
45077
45163
|
exports.GShapeElement = GShapeElement;
|
|
45078
|
-
_a = gbounds_aware_1.GBoundsAware, _b = glayoutable_1.GLayoutable;
|
|
45164
|
+
_a = gbounds_aware_1.GBoundsAware, _b = glayoutable_1.GLayoutable, _c = gresizable_1.GResizable;
|
|
45079
45165
|
class GShapeElementBuilder extends gmodel_element_1.GModelElementBuilder {
|
|
45080
45166
|
position(pointOrX, y) {
|
|
45081
45167
|
return gbounds_aware_1.GBoundsAwareBuilder.position(this, pointOrX, y);
|
|
@@ -45089,6 +45175,9 @@ class GShapeElementBuilder extends gmodel_element_1.GModelElementBuilder {
|
|
|
45089
45175
|
addLayoutOptions(layoutOptions) {
|
|
45090
45176
|
return glayoutable_1.GLayoutableBuilder.addLayoutOptions(this, layoutOptions);
|
|
45091
45177
|
}
|
|
45178
|
+
resizeLocations(resizeLocations) {
|
|
45179
|
+
return gresizable_1.GResizableBuilder.resizeLocations(this, resizeLocations);
|
|
45180
|
+
}
|
|
45092
45181
|
}
|
|
45093
45182
|
exports.GShapeElementBuilder = GShapeElementBuilder;
|
|
45094
45183
|
|
|
@@ -45218,6 +45307,7 @@ __exportStar(__webpack_require__(/*! ./gmodel-util */ "../../packages/graph/lib/
|
|
|
45218
45307
|
__exportStar(__webpack_require__(/*! ./gnode */ "../../packages/graph/lib/gnode.js"), exports);
|
|
45219
45308
|
__exportStar(__webpack_require__(/*! ./gport */ "../../packages/graph/lib/gport.js"), exports);
|
|
45220
45309
|
__exportStar(__webpack_require__(/*! ./gpre-rendered-element */ "../../packages/graph/lib/gpre-rendered-element.js"), exports);
|
|
45310
|
+
__exportStar(__webpack_require__(/*! ./gresizable */ "../../packages/graph/lib/gresizable.js"), exports);
|
|
45221
45311
|
__exportStar(__webpack_require__(/*! ./gshape-element */ "../../packages/graph/lib/gshape-element.js"), exports);
|
|
45222
45312
|
__exportStar(__webpack_require__(/*! ./gshaped-prerendered-element */ "../../packages/graph/lib/gshaped-prerendered-element.js"), exports);
|
|
45223
45313
|
|