@eclipse-glsp/graph 1.1.0-next.0f9fe4e.28 → 1.1.0-next.231d53b.69
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/lib/default-types.js +2 -2
- package/lib/default-types.js.map +1 -1
- package/lib/galignable.d.ts +2 -2
- package/lib/galignable.d.ts.map +1 -1
- package/lib/galignable.js +2 -2
- package/lib/galignable.js.map +1 -1
- package/lib/gbounds-aware.d.ts +2 -2
- package/lib/gbounds-aware.d.ts.map +1 -1
- package/lib/gbounds-aware.js +2 -2
- package/lib/gbounds-aware.js.map +1 -1
- package/lib/gedge-layoutable.d.ts +3 -3
- package/lib/gedge-layoutable.d.ts.map +1 -1
- package/lib/gedge-layoutable.js +2 -2
- package/lib/gedge-layoutable.js.map +1 -1
- package/lib/gedge.js +1 -1
- package/lib/gedge.js.map +1 -1
- package/lib/gforeign-object-element.d.ts +35 -0
- package/lib/gforeign-object-element.d.ts.map +1 -0
- package/lib/gforeign-object-element.js +44 -0
- package/lib/gforeign-object-element.js.map +1 -0
- package/lib/{ghtmlroot.d.ts → ghtml-root.d.ts} +1 -1
- package/lib/ghtml-root.d.ts.map +1 -0
- package/lib/{ghtmlroot.js → ghtml-root.js} +1 -1
- package/lib/ghtml-root.js.map +1 -0
- package/lib/gissue-marker.d.ts +1 -1
- package/lib/gissue-marker.d.ts.map +1 -1
- package/lib/glayoutable.d.ts +2 -2
- package/lib/glayoutable.d.ts.map +1 -1
- package/lib/glayoutable.js +2 -2
- package/lib/glayoutable.js.map +1 -1
- package/lib/glayouting.d.ts +2 -2
- package/lib/glayouting.d.ts.map +1 -1
- package/lib/glayouting.js +2 -2
- package/lib/glayouting.js.map +1 -1
- package/lib/gmodel-element.d.ts +3 -16
- package/lib/gmodel-element.d.ts.map +1 -1
- package/lib/gmodel-element.js +1 -10
- package/lib/gmodel-element.js.map +1 -1
- package/lib/gmodel-util.d.ts +3 -3
- package/lib/gmodel-util.d.ts.map +1 -1
- package/lib/gmodel-util.js +1 -1
- package/lib/index.d.ts +2 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +7 -2
- package/lib/index.js.map +1 -1
- package/{src/gmodel-element.spec.ts → lib/index.spec.d.ts} +1 -3
- package/lib/index.spec.d.ts.map +1 -0
- package/lib/index.spec.js +27 -0
- package/lib/index.spec.js.map +1 -0
- package/package.json +21 -21
- package/src/default-types.ts +1 -1
- package/src/galignable.ts +2 -2
- package/src/gbounds-aware.ts +2 -2
- package/src/gedge-layoutable.ts +2 -2
- package/src/gforeign-object-element.ts +44 -0
- package/src/glayoutable.ts +2 -2
- package/src/glayouting.ts +2 -2
- package/src/gmodel-element.ts +4 -19
- package/src/gmodel-util.ts +2 -2
- package/src/index.spec.ts +27 -0
- package/src/index.ts +2 -1
- package/lib/ghtmlroot.d.ts.map +0 -1
- package/lib/ghtmlroot.js.map +0 -1
- /package/src/{ghtmlroot.ts → ghtml-root.ts} +0 -0
package/lib/default-types.js
CHANGED
|
@@ -21,7 +21,7 @@ const gbutton_1 = require("./gbutton");
|
|
|
21
21
|
const gcompartment_1 = require("./gcompartment");
|
|
22
22
|
const gedge_1 = require("./gedge");
|
|
23
23
|
const ggraph_1 = require("./ggraph");
|
|
24
|
-
const
|
|
24
|
+
const ghtml_root_1 = require("./ghtml-root");
|
|
25
25
|
const gissue_marker_1 = require("./gissue-marker");
|
|
26
26
|
const glabel_1 = require("./glabel");
|
|
27
27
|
const gnode_1 = require("./gnode");
|
|
@@ -41,7 +41,7 @@ function getDefaultMapping() {
|
|
|
41
41
|
mapping.set(protocol_1.DefaultTypes.COMPARTMENT, gcompartment_1.GCompartment);
|
|
42
42
|
mapping.set(protocol_1.DefaultTypes.BUTTON, gbutton_1.GButton);
|
|
43
43
|
mapping.set(protocol_1.DefaultTypes.ISSUE_MARKER, gissue_marker_1.GIssueMarker);
|
|
44
|
-
mapping.set(protocol_1.DefaultTypes.HTML,
|
|
44
|
+
mapping.set(protocol_1.DefaultTypes.HTML, ghtml_root_1.GHtmlRoot);
|
|
45
45
|
mapping.set(protocol_1.DefaultTypes.PRE_RENDERED, gpre_rendered_element_1.GPreRenderedElement);
|
|
46
46
|
mapping.set(protocol_1.DefaultTypes.FOREIGN_OBJECT, gshaped_prerendered_element_1.GShapedPreRenderedElement);
|
|
47
47
|
return mapping;
|
package/lib/default-types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"default-types.js","sourceRoot":"","sources":["../src/default-types.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAA+D;AAC/D,uCAAoC;AACpC,iDAA8C;AAC9C,mCAAgC;AAChC,qCAAkC;AAClC,
|
|
1
|
+
{"version":3,"file":"default-types.js","sourceRoot":"","sources":["../src/default-types.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAA+D;AAC/D,uCAAoC;AACpC,iDAA8C;AAC9C,mCAAgC;AAChC,qCAAkC;AAClC,6CAAyC;AACzC,mDAA+C;AAC/C,qCAAkC;AAElC,mCAAgC;AAChC,mCAAgC;AAChC,mEAA8D;AAC9D,+EAA0E;AAE1E,SAAgB,iBAAiB;IAC7B,sFAAsF;IACtF,mCAAmC;IACnC,6GAA6G;IAC7G,MAAM,OAAO,GAAG,IAAI,GAAG,EAAoC,CAAC;IAC5D,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,KAAK,EAAE,eAAM,CAAC,CAAC;IACjC,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,IAAI,EAAE,aAAK,CAAC,CAAC;IAC/B,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,IAAI,EAAE,aAAK,CAAC,CAAC;IAC/B,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,IAAI,EAAE,aAAK,CAAC,CAAC;IAC/B,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,KAAK,EAAE,eAAM,CAAC,CAAC;IACjC,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,WAAW,EAAE,2BAAY,CAAC,CAAC;IAC7C,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,MAAM,EAAE,iBAAO,CAAC,CAAC;IACnC,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,YAAY,EAAE,4BAAY,CAAC,CAAC;IAE9C,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,IAAI,EAAE,sBAAS,CAAC,CAAC;IACnC,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,YAAY,EAAE,2CAAmB,CAAC,CAAC;IACrD,OAAO,CAAC,GAAG,CAAC,uBAAK,CAAC,cAAc,EAAE,uDAAyB,CAAC,CAAC;IAC7D,OAAO,OAAO,CAAC;AACnB,CAAC;AAlBD,8CAkBC"}
|
package/lib/galignable.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -21,7 +21,7 @@ export interface GAlignable {
|
|
|
21
21
|
[GAlignable]: boolean;
|
|
22
22
|
}
|
|
23
23
|
export declare function isGAlignable<G extends GModelElement>(element: G): element is G & GAlignable;
|
|
24
|
-
export
|
|
24
|
+
export type GAlignableBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GAlignable>;
|
|
25
25
|
export declare namespace GAlignableBuilder {
|
|
26
26
|
function alignment<B extends GAlignableBuilder>(builder: B, pointOrX: Point | number, y?: number): B;
|
|
27
27
|
}
|
package/lib/galignable.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"galignable.d.ts","sourceRoot":"","sources":["../src/galignable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,UAAU,eAAuB,CAAC;AAE/C,MAAM,WAAW,UAAU;IACvB,SAAS,EAAE,KAAK,CAAC;IACjB,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,UAAU,CAE3F;AAED,
|
|
1
|
+
{"version":3,"file":"galignable.d.ts","sourceRoot":"","sources":["../src/galignable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,UAAU,eAAuB,CAAC;AAE/C,MAAM,WAAW,UAAU;IACvB,SAAS,EAAE,KAAK,CAAC;IACjB,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,UAAU,CAE3F;AAED,MAAM,MAAM,iBAAiB,CAAC,CAAC,SAAS,aAAa,GAAG,aAAa,IAAI,oBAAoB,CAAC,CAAC,GAAG,UAAU,CAAC,CAAC;AAE9G,yBAAiB,iBAAiB,CAAC;IAC/B,SAAgB,SAAS,CAAC,CAAC,SAAS,iBAAiB,EAAE,OAAO,EAAE,CAAC,EAAE,QAAQ,EAAE,KAAK,GAAG,MAAM,EAAE,CAAC,CAAC,EAAE,MAAM,GAAG,CAAC,CAQ1G;CACJ"}
|
package/lib/galignable.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.GAlignableBuilder = exports.isGAlignable = exports.GAlignable = void 0;
|
|
4
4
|
exports.GAlignable = Symbol('GAlignable');
|
|
5
5
|
function isGAlignable(element) {
|
|
6
|
-
return
|
|
6
|
+
return exports.GAlignable in element && element[exports.GAlignable] === true;
|
|
7
7
|
}
|
|
8
8
|
exports.isGAlignable = isGAlignable;
|
|
9
9
|
var GAlignableBuilder;
|
|
@@ -19,5 +19,5 @@ var GAlignableBuilder;
|
|
|
19
19
|
return builder;
|
|
20
20
|
}
|
|
21
21
|
GAlignableBuilder.alignment = alignment;
|
|
22
|
-
})(GAlignableBuilder
|
|
22
|
+
})(GAlignableBuilder || (exports.GAlignableBuilder = GAlignableBuilder = {}));
|
|
23
23
|
//# sourceMappingURL=galignable.js.map
|
package/lib/galignable.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"galignable.js","sourceRoot":"","sources":["../src/galignable.ts"],"names":[],"mappings":";;;AAkBa,QAAA,UAAU,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC;AAO/C,SAAgB,YAAY,CAA0B,OAAU;IAC5D,OAAO,
|
|
1
|
+
{"version":3,"file":"galignable.js","sourceRoot":"","sources":["../src/galignable.ts"],"names":[],"mappings":";;;AAkBa,QAAA,UAAU,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC;AAO/C,SAAgB,YAAY,CAA0B,OAAU;IAC5D,OAAO,kBAAU,IAAI,OAAO,IAAI,OAAO,CAAC,kBAAU,CAAC,KAAK,IAAI,CAAC;AACjE,CAAC;AAFD,oCAEC;AAID,IAAiB,iBAAiB,CAUjC;AAVD,WAAiB,iBAAiB;IAC9B,SAAgB,SAAS,CAA8B,OAAU,EAAE,QAAwB,EAAE,CAAU;QACnG,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;QAC/B,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE;YAC9B,KAAK,CAAC,SAAS,GAAG,QAAQ,CAAC;SAC9B;aAAM,IAAI,CAAC,EAAE;YACV,KAAK,CAAC,SAAS,GAAG,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;SACxC;QACD,OAAO,OAAO,CAAC;IACnB,CAAC;IARe,2BAAS,YAQxB,CAAA;AACL,CAAC,EAVgB,iBAAiB,iCAAjB,iBAAiB,QAUjC"}
|
package/lib/gbounds-aware.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -22,7 +22,7 @@ export interface GBoundsAware {
|
|
|
22
22
|
[GBoundsAware]: boolean;
|
|
23
23
|
}
|
|
24
24
|
export declare function isGBoundsAware<G extends GModelElement>(element: G): element is G & GBoundsAware;
|
|
25
|
-
export
|
|
25
|
+
export type GBoundsAwareBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GBoundsAware>;
|
|
26
26
|
export declare namespace GBoundsAwareBuilder {
|
|
27
27
|
function position<B extends GBoundsAwareBuilder>(builder: B, pointOrX: Point | number, y?: number): B;
|
|
28
28
|
function size<B extends GBoundsAwareBuilder>(builder: B, sizeOrWidth: Dimension | number, height?: number): B;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gbounds-aware.d.ts","sourceRoot":"","sources":["../src/gbounds-aware.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,YAAY,eAAyB,CAAC;AAEnD,MAAM,WAAW,YAAY;IACzB,QAAQ,CAAC,EA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ounds-aware.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.GBoundsAwareBuilder = exports.isGBoundsAware = exports.GBoundsAware = void 0;
|
|
4
4
|
exports.GBoundsAware = Symbol('GBoundsAware');
|
|
5
5
|
function isGBoundsAware(element) {
|
|
6
|
-
return
|
|
6
|
+
return exports.GBoundsAware in element && element[exports.GBoundsAware] === true;
|
|
7
7
|
}
|
|
8
8
|
exports.isGBoundsAware = isGBoundsAware;
|
|
9
9
|
var GBoundsAwareBuilder;
|
|
@@ -30,5 +30,5 @@ var GBoundsAwareBuilder;
|
|
|
30
30
|
return builder;
|
|
31
31
|
}
|
|
32
32
|
GBoundsAwareBuilder.size = size;
|
|
33
|
-
})(GBoundsAwareBuilder
|
|
33
|
+
})(GBoundsAwareBuilder || (exports.GBoundsAwareBuilder = GBoundsAwareBuilder = {}));
|
|
34
34
|
//# sourceMappingURL=gbounds-aware.js.map
|
package/lib/gbounds-aware.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gbounds-aware.js","sourceRoot":"","sources":["../src/gbounds-aware.ts"],"names":[],"mappings":";;;AAkBa,QAAA,YAAY,GAAG,MAAM,CAAC,cAAc,CAAC,CAAC;AAQnD,SAAgB,cAAc,CAA0B,OAAU;IAC9D,OAAO,
|
|
1
|
+
{"version":3,"file":"gbounds-aware.js","sourceRoot":"","sources":["../src/gbounds-aware.ts"],"names":[],"mappings":";;;AAkBa,QAAA,YAAY,GAAG,MAAM,CAAC,cAAc,CAAC,CAAC;AAQnD,SAAgB,cAAc,CAA0B,OAAU;IAC9D,OAAO,oBAAY,IAAI,OAAO,IAAI,OAAO,CAAC,oBAAY,CAAC,KAAK,IAAI,CAAC;AACrE,CAAC;AAFD,wCAEC;AAID,IAAiB,mBAAmB,CAoBnC;AApBD,WAAiB,mBAAmB;IAChC,SAAgB,QAAQ,CAAgC,OAAU,EAAE,QAAwB,EAAE,CAAU;QACpG,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;QAC/B,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE;YAC9B,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC7B;aAAM,IAAI,CAAC,EAAE;YACV,KAAK,CAAC,QAAQ,GAAG,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;SACvC;QACD,OAAO,OAAO,CAAC;IACnB,CAAC;IARe,4BAAQ,WAQvB,CAAA;IAED,SAAgB,IAAI,CAAgC,OAAU,EAAE,WAA+B,EAAE,MAAe;QAC5G,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;QAC/B,IAAI,OAAO,WAAW,KAAK,QAAQ,EAAE;YACjC,KAAK,CAAC,IAAI,GAAG,WAAW,CAAC;SAC5B;aAAM,IAAI,MAAM,EAAE;YACf,KAAK,CAAC,IAAI,GAAG,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,CAAC;SAC/C;QACD,OAAO,OAAO,CAAC;IACnB,CAAC;IARe,wBAAI,OAQnB,CAAA;AACL,CAAC,EApBgB,mBAAmB,mCAAnB,mBAAmB,QAoBnC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
import { GModelElement, GModelElementBuilder } from './gmodel-element';
|
|
17
|
-
export
|
|
17
|
+
export type EdgeSide = 'left' | 'right' | 'top' | 'bottom' | 'on';
|
|
18
18
|
export interface GEdgePlacement {
|
|
19
19
|
rotate: boolean;
|
|
20
20
|
side: EdgeSide;
|
|
@@ -27,7 +27,7 @@ export interface GEdgeLayoutable {
|
|
|
27
27
|
[GEdgeLayoutable]: boolean;
|
|
28
28
|
}
|
|
29
29
|
export declare function isGEdgeLayoutable<G extends GModelElement>(element: G): element is G & GEdgeLayoutable;
|
|
30
|
-
export
|
|
30
|
+
export type GEdgeLayoutableBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GEdgeLayoutable>;
|
|
31
31
|
export declare namespace GEdgeLayoutableBuilder {
|
|
32
32
|
function edgePlacement<B extends GEdgeLayoutableBuilder>(builder: B, placement?: GEdgePlacement): B;
|
|
33
33
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gedge-layoutable.d.ts","sourceRoot":"","sources":["../src/gedge-layoutable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,
|
|
1
|
+
{"version":3,"file":"gedge-layoutable.d.ts","sourceRoot":"","sources":["../src/gedge-layoutable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,KAAK,GAAG,QAAQ,GAAG,IAAI,CAAC;AAElE,MAAM,WAAW,cAAc;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,eAAe,eAA4B,CAAC;AAEzD,MAAM,WAAW,eAAe;IAC5B,aAAa,CAAC,EAAE,cAAc,CAAC;IAC/B,CAAC,eAAe,CAAC,EAAE,OAAO,CAAC;CAC9B;AAED,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,eAAe,CAErG;AAED,MAAM,MAAM,sBAAsB,CAAC,CAAC,SAAS,aAAa,GAAG,aAAa,IAAI,oBAAoB,CAAC,CAAC,GAAG,eAAe,CAAC,CAAC;AAExH,yBAAiB,sBAAsB,CAAC;IACpC,SAAgB,aAAa,CAAC,CAAC,SAAS,sBAAsB,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,CAAC,EAAE,cAAc,GAAG,CAAC,CAGzG;CACJ"}
|
package/lib/gedge-layoutable.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.GEdgeLayoutableBuilder = exports.isGEdgeLayoutable = exports.GEdgeLayoutable = void 0;
|
|
4
4
|
exports.GEdgeLayoutable = Symbol('GEdgeLayoutable');
|
|
5
5
|
function isGEdgeLayoutable(element) {
|
|
6
|
-
return
|
|
6
|
+
return exports.GEdgeLayoutable in element && element[exports.GEdgeLayoutable] === true;
|
|
7
7
|
}
|
|
8
8
|
exports.isGEdgeLayoutable = isGEdgeLayoutable;
|
|
9
9
|
var GEdgeLayoutableBuilder;
|
|
@@ -13,5 +13,5 @@ var GEdgeLayoutableBuilder;
|
|
|
13
13
|
return builder;
|
|
14
14
|
}
|
|
15
15
|
GEdgeLayoutableBuilder.edgePlacement = edgePlacement;
|
|
16
|
-
})(GEdgeLayoutableBuilder
|
|
16
|
+
})(GEdgeLayoutableBuilder || (exports.GEdgeLayoutableBuilder = GEdgeLayoutableBuilder = {}));
|
|
17
17
|
//# sourceMappingURL=gedge-layoutable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gedge-layoutable.js","sourceRoot":"","sources":["../src/gedge-layoutable.ts"],"names":[],"mappings":";;;AA0Ba,QAAA,eAAe,GAAG,MAAM,CAAC,iBAAiB,CAAC,CAAC;AAOzD,SAAgB,iBAAiB,CAA0B,OAAU;IACjE,OAAO,
|
|
1
|
+
{"version":3,"file":"gedge-layoutable.js","sourceRoot":"","sources":["../src/gedge-layoutable.ts"],"names":[],"mappings":";;;AA0Ba,QAAA,eAAe,GAAG,MAAM,CAAC,iBAAiB,CAAC,CAAC;AAOzD,SAAgB,iBAAiB,CAA0B,OAAU;IACjE,OAAO,uBAAe,IAAI,OAAO,IAAI,OAAO,CAAC,uBAAe,CAAC,KAAK,IAAI,CAAC;AAC3E,CAAC;AAFD,8CAEC;AAID,IAAiB,sBAAsB,CAKtC;AALD,WAAiB,sBAAsB;IACnC,SAAgB,aAAa,CAAmC,OAAU,EAAE,SAA0B;QAClG,OAAO,CAAC,OAAO,CAAC,CAAC,aAAa,GAAG,SAAS,CAAC;QAC3C,OAAO,OAAO,CAAC;IACnB,CAAC;IAHe,oCAAa,gBAG5B,CAAA;AACL,CAAC,EALgB,sBAAsB,sCAAtB,sBAAsB,QAKtC"}
|
package/lib/gedge.js
CHANGED
|
@@ -34,7 +34,7 @@ exports.GEdge = GEdge;
|
|
|
34
34
|
return GEdge.is(object);
|
|
35
35
|
}
|
|
36
36
|
GEdge.is = is;
|
|
37
|
-
})(GEdge
|
|
37
|
+
})(GEdge || (exports.GEdge = GEdge = {}));
|
|
38
38
|
class GEdgeBuilder extends gmodel_element_1.GModelElementBuilder {
|
|
39
39
|
source(source) {
|
|
40
40
|
this.proxy.sourceId = source.id;
|
package/lib/gedge.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gedge.js","sourceRoot":"","sources":["../src/gedge.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAAmF;AACnF,qDAAuE;AAEvE,MAAa,KAAM,SAAQ,8BAAa;IAAxC;;QAKa,SAAI,GAAG,uBAAY,CAAC,IAAI,CAAC;QAClC,kBAAa,GAAY,EAAE,CAAC;IAIhC,CAAC;IATG,MAAM,CAAC,OAAO;QACV,OAAO,I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M,CAAC,EAAE,CAAC;QAChC,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,QAAQ,CAAC,QAAgB;QACrB,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAC/B,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,UAAU,CAAC,UAAkB;QACzB,IAAI,CAAC,KAAK,CAAC,UAAU,GAAG,UAAU,CAAC;QACnC,OAAO,IAAI,CAAC;IAChB,CAAC;IAID,eAAe,CAAC,QAAwB,EAAE,CAAU;QAChD,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE;YAC9B,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;SAC3C;aAAM,IAAI,CAAC,EAAE;YACV,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC,CAAC;SACrD;QACD,OAAO,IAAI,CAAC;IAChB,CAAC;IAID,gBAAgB,CAAC,GAAG,aAAkC;QAClD,IAAA,mBAAQ,EAAC,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,aAAa,CAAC,CAAC;QAClD,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AA3CD,oCA2CC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/********************************************************************************
|
|
2
|
+
* Copyright (c) 2023 EclipseSource and others.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made available under the
|
|
5
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
*
|
|
8
|
+
* This Source Code may also be made available under the following Secondary
|
|
9
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
* with the GNU Classpath Exception which is available at
|
|
12
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
*
|
|
14
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
|
+
********************************************************************************/
|
|
16
|
+
import { GShapePreRenderedElementBuilder, GShapedPreRenderedElement } from './gshaped-prerendered-element';
|
|
17
|
+
/**
|
|
18
|
+
* A `foreignObject` element to be transferred to the DOM within the SVG.
|
|
19
|
+
*
|
|
20
|
+
* This can be useful to to benefit from e.g. HTML rendering features, such as line wrapping, inside of
|
|
21
|
+
* the SVG diagram. Note that `foreignObject` is not supported by all browsers and SVG viewers may not
|
|
22
|
+
* support rendering the `foreignObject` content.
|
|
23
|
+
*
|
|
24
|
+
* If no dimensions are specified in the schema element, this element will obtain the dimension of
|
|
25
|
+
* its parent to fill the entire available room. Thus, this element requires specified bounds itself
|
|
26
|
+
* or bounds to be available for its parent.
|
|
27
|
+
*/
|
|
28
|
+
export declare class GForeignObjectElement extends GShapedPreRenderedElement {
|
|
29
|
+
static builder(): GForeignObjectElementBuilder;
|
|
30
|
+
namespace: string;
|
|
31
|
+
}
|
|
32
|
+
export declare class GForeignObjectElementBuilder<G extends GForeignObjectElement = GForeignObjectElement> extends GShapePreRenderedElementBuilder<G> {
|
|
33
|
+
namespace(namespace: string): this;
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=gforeign-object-element.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gforeign-object-element.d.ts","sourceRoot":"","sources":["../src/gforeign-object-element.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,OAAO,EAAE,+BAA+B,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAC;AAE3G;;;;;;;;;;GAUG;AACH,qBAAa,qBAAsB,SAAQ,yBAAyB;WAChD,OAAO,IAAI,4BAA4B;IAGvD,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,qBAAa,4BAA4B,CACrC,CAAC,SAAS,qBAAqB,GAAG,qBAAqB,CACzD,SAAQ,+BAA+B,CAAC,CAAC,CAAC;IACxC,SAAS,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI;CAIrC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/********************************************************************************
|
|
3
|
+
* Copyright (c) 2023 EclipseSource and others.
|
|
4
|
+
*
|
|
5
|
+
* This program and the accompanying materials are made available under the
|
|
6
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
*
|
|
9
|
+
* This Source Code may also be made available under the following Secondary
|
|
10
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
* with the GNU Classpath Exception which is available at
|
|
13
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
*
|
|
15
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
16
|
+
********************************************************************************/
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.GForeignObjectElementBuilder = exports.GForeignObjectElement = void 0;
|
|
19
|
+
const gshaped_prerendered_element_1 = require("./gshaped-prerendered-element");
|
|
20
|
+
/**
|
|
21
|
+
* A `foreignObject` element to be transferred to the DOM within the SVG.
|
|
22
|
+
*
|
|
23
|
+
* This can be useful to to benefit from e.g. HTML rendering features, such as line wrapping, inside of
|
|
24
|
+
* the SVG diagram. Note that `foreignObject` is not supported by all browsers and SVG viewers may not
|
|
25
|
+
* support rendering the `foreignObject` content.
|
|
26
|
+
*
|
|
27
|
+
* If no dimensions are specified in the schema element, this element will obtain the dimension of
|
|
28
|
+
* its parent to fill the entire available room. Thus, this element requires specified bounds itself
|
|
29
|
+
* or bounds to be available for its parent.
|
|
30
|
+
*/
|
|
31
|
+
class GForeignObjectElement extends gshaped_prerendered_element_1.GShapedPreRenderedElement {
|
|
32
|
+
static builder() {
|
|
33
|
+
return new GForeignObjectElementBuilder(GForeignObjectElement);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
exports.GForeignObjectElement = GForeignObjectElement;
|
|
37
|
+
class GForeignObjectElementBuilder extends gshaped_prerendered_element_1.GShapePreRenderedElementBuilder {
|
|
38
|
+
namespace(namespace) {
|
|
39
|
+
this.proxy.namespace = namespace;
|
|
40
|
+
return this;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
exports.GForeignObjectElementBuilder = GForeignObjectElementBuilder;
|
|
44
|
+
//# sourceMappingURL=gforeign-object-element.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gforeign-object-element.js","sourceRoot":"","sources":["../src/gforeign-object-element.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;;AAElF,+EAA2G;AAE3G;;;;;;;;;;GAUG;AACH,MAAa,qBAAsB,SAAQ,uDAAyB;IAChE,MAAM,CAAU,OAAO;QACnB,OAAO,IAAI,4BAA4B,CAAC,qBAAqB,CAAC,CAAC;IACnE,CAAC;CAEJ;AALD,sDAKC;AAED,MAAa,4BAEX,SAAQ,6DAAkC;IACxC,SAAS,CAAC,SAAiB;QACvB,IAAI,CAAC,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;QACjC,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AAPD,oEAOC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ghtml-root.d.ts","sourceRoot":"","sources":["../src/ghtml-root.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAEjE;;GAEG;AACH,qBAAa,SAAU,SAAQ,UAAU;WACrB,OAAO,IAAI,gBAAgB;IAIlC,IAAI,SAAc;IAC3B,OAAO,EAAE,MAAM,EAAE,CAAM;CAC1B;AAED,qBAAa,gBAAgB,CAAC,CAAC,SAAS,SAAS,GAAG,SAAS,CAAE,SAAQ,iBAAiB,CAAC,CAAC,CAAC;IACvF,UAAU,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI;IACnC,UAAU,CAAC,GAAG,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI;CAKzC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ghtml-root.js","sourceRoot":"","sources":["../src/ghtml-root.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAAqF;AACrF,qDAAiE;AAEjE;;GAEG;AACH,MAAa,SAAU,SAAQ,2BAAU;IAAzC;;QAKa,SAAI,GAAG,uBAAK,CAAC,IAAI,CAAC;QAC3B,YAAO,GAAa,EAAE,CAAC;IAC3B,CAAC;IANG,MAAM,CAAU,OAAO;QACnB,OAAO,IAAI,gBAAgB,CAAC,SAAS,CAAC,CAAC;IAC3C,CAAC;CAIJ;AAPD,8BAOC;AAED,MAAa,gBAAkD,SAAQ,kCAAoB;IAGvF,UAAU,CAAC,GAAG,OAA6B;QACvC,IAAA,mBAAQ,EAAC,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;QACtC,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AAPD,4CAOC"}
|
package/lib/gissue-marker.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GShapeElement, GShapeElementBuilder } from './gshape-element';
|
|
2
|
-
export
|
|
2
|
+
export type GIssueSeverity = 'error' | 'warning' | 'info';
|
|
3
3
|
export declare class GIssue {
|
|
4
4
|
message: string;
|
|
5
5
|
severity: GIssueSeverity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gissue-marker.d.ts","sourceRoot":"","sources":["../src/gissue-marker.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,
|
|
1
|
+
{"version":3,"file":"gissue-marker.d.ts","sourceRoot":"","sources":["../src/gissue-marker.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,GAAG,MAAM,CAAC;AAE1D,qBAAa,MAAM;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,cAAc,CAAC;CAC5B;AAED,qBAAa,YAAa,SAAQ,aAAa;IAC3C,MAAM,CAAC,OAAO,IAAI,mBAAmB;IAI5B,IAAI,SAA6B;IAC1C,MAAM,EAAE,MAAM,EAAE,CAAM;CACzB;AAED,qBAAa,mBAAmB,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,CAAE,SAAQ,oBAAoB,CAAC,CAAC,CAAC;IACnG,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,cAAc,GAAG,IAAI;IAUzD,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI;IACjC,SAAS,CAAC,GAAG,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI;CAKvC"}
|
package/lib/glayoutable.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -21,7 +21,7 @@ export interface GLayoutable {
|
|
|
21
21
|
[GLayoutable]: boolean;
|
|
22
22
|
}
|
|
23
23
|
export declare function isGLayoutable<G extends GModelElement>(element: G): element is G & GLayoutable;
|
|
24
|
-
export
|
|
24
|
+
export type GLayoutableBuilder = GModelElementBuilder<GModelElement & GLayoutable>;
|
|
25
25
|
export declare namespace GLayoutableBuilder {
|
|
26
26
|
function addLayoutOption<B extends GLayoutableBuilder>(builder: B, key: string, value: JsonPrimitive): B;
|
|
27
27
|
function addLayoutOptions<B extends GLayoutableBuilder>(builder: B, layoutOptions: Args | Map<string, JsonPrimitive>): B;
|
package/lib/glayoutable.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glayoutable.d.ts","sourceRoot":"","sources":["../src/glayoutable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,WAAW,eAAwB,CAAC;AAEjD,MAAM,WAAW,WAAW;IACxB,aAAa,CAAC,EAAE,IAAI,CAAC;IACrB,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,wBAAgB,aAAa,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,WAAW,CAE7F;AAED,
|
|
1
|
+
{"version":3,"file":"glayoutable.d.ts","sourceRoot":"","sources":["../src/glayoutable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,WAAW,eAAwB,CAAC;AAEjD,MAAM,WAAW,WAAW;IACxB,aAAa,CAAC,EAAE,IAAI,CAAC;IACrB,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,wBAAgB,aAAa,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,WAAW,CAE7F;AAED,MAAM,MAAM,kBAAkB,GAAG,oBAAoB,CAAC,aAAa,GAAG,WAAW,CAAC,CAAC;AAEnF,yBAAiB,kBAAkB,CAAC;IAChC,SAAgB,eAAe,CAAC,CAAC,SAAS,kBAAkB,EAAE,OAAO,EAAE,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,aAAa,GAAG,CAAC,CAO9G;IAED,SAAgB,gBAAgB,CAAC,CAAC,SAAS,kBAAkB,EAAE,OAAO,EAAE,CAAC,EAAE,aAAa,EAAE,IAAI,GAAG,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,GAAG,CAAC,CAc9H;CACJ"}
|
package/lib/glayoutable.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.GLayoutableBuilder = exports.isGLayoutable = exports.GLayoutable = void 0;
|
|
4
4
|
exports.GLayoutable = Symbol('GLayoutable');
|
|
5
5
|
function isGLayoutable(element) {
|
|
6
|
-
return
|
|
6
|
+
return exports.GLayoutable in element && element[exports.GLayoutable] === true;
|
|
7
7
|
}
|
|
8
8
|
exports.isGLayoutable = isGLayoutable;
|
|
9
9
|
var GLayoutableBuilder;
|
|
@@ -35,5 +35,5 @@ var GLayoutableBuilder;
|
|
|
35
35
|
return builder;
|
|
36
36
|
}
|
|
37
37
|
GLayoutableBuilder.addLayoutOptions = addLayoutOptions;
|
|
38
|
-
})(GLayoutableBuilder
|
|
38
|
+
})(GLayoutableBuilder || (exports.GLayoutableBuilder = GLayoutableBuilder = {}));
|
|
39
39
|
//# sourceMappingURL=glayoutable.js.map
|
package/lib/glayoutable.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glayoutable.js","sourceRoot":"","sources":["../src/glayoutable.ts"],"names":[],"mappings":";;;AAkBa,QAAA,WAAW,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC;AAOjD,SAAgB,aAAa,CAA0B,OAAU;IAC7D,OAAO,
|
|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B,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;SAChD;aAAM;YACH,KAAK,CAAC,aAAa,GAAG,QAAQ,CAAC;SAClC;QACD,OAAO,OAAO,CAAC;IACnB,CAAC;IAde,mCAAgB,mBAc/B,CAAA;AACL,CAAC,EAzBgB,kBAAkB,kCAAlB,kBAAkB,QAyBlC"}
|
package/lib/glayouting.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -20,7 +20,7 @@ export interface GLayouting {
|
|
|
20
20
|
[GLayouting]: boolean;
|
|
21
21
|
}
|
|
22
22
|
export declare function isGLayouting<G extends GModelElement>(element: G): element is G & GLayouting;
|
|
23
|
-
export
|
|
23
|
+
export type GLayoutingBuilder = GModelElementBuilder<GModelElement & GLayouting>;
|
|
24
24
|
export declare namespace GLayoutingBuilder {
|
|
25
25
|
function layout<B extends GLayoutingBuilder>(builder: B, newLayout?: string): B;
|
|
26
26
|
}
|
package/lib/glayouting.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glayouting.d.ts","sourceRoot":"","sources":["../src/glayouting.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,UAAU,eAAuB,CAAC;AAE/C,MAAM,WAAW,UAAU;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,UAAU,CAE3F;AAED,
|
|
1
|
+
{"version":3,"file":"glayouting.d.ts","sourceRoot":"","sources":["../src/glayouting.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,eAAO,MAAM,UAAU,eAAuB,CAAC;AAE/C,MAAM,WAAW,UAAU;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,YAAY,CAAC,CAAC,SAAS,aAAa,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG,UAAU,CAE3F;AAED,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,CAAC,aAAa,GAAG,UAAU,CAAC,CAAC;AAEjF,yBAAiB,iBAAiB,CAAC;IAC/B,SAAgB,MAAM,CAAC,CAAC,SAAS,iBAAiB,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,CAAC,CAGrF;CACJ"}
|
package/lib/glayouting.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.GLayoutingBuilder = exports.isGLayouting = exports.GLayouting = void 0;
|
|
4
4
|
exports.GLayouting = Symbol('GLayouting');
|
|
5
5
|
function isGLayouting(element) {
|
|
6
|
-
return
|
|
6
|
+
return exports.GLayouting in element && element[exports.GLayouting] === true;
|
|
7
7
|
}
|
|
8
8
|
exports.isGLayouting = isGLayouting;
|
|
9
9
|
var GLayoutingBuilder;
|
|
@@ -13,5 +13,5 @@ var GLayoutingBuilder;
|
|
|
13
13
|
return builder;
|
|
14
14
|
}
|
|
15
15
|
GLayoutingBuilder.layout = layout;
|
|
16
|
-
})(GLayoutingBuilder
|
|
16
|
+
})(GLayoutingBuilder || (exports.GLayoutingBuilder = GLayoutingBuilder = {}));
|
|
17
17
|
//# sourceMappingURL=glayouting.js.map
|
package/lib/glayouting.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glayouting.js","sourceRoot":"","sources":["../src/glayouting.ts"],"names":[],"mappings":";;;AAiBa,QAAA,UAAU,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC;AAO/C,SAAgB,YAAY,CAA0B,OAAU;IAC5D,OAAO,
|
|
1
|
+
{"version":3,"file":"glayouting.js","sourceRoot":"","sources":["../src/glayouting.ts"],"names":[],"mappings":";;;AAiBa,QAAA,UAAU,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC;AAO/C,SAAgB,YAAY,CAA0B,OAAU;IAC5D,OAAO,kBAAU,IAAI,OAAO,IAAI,OAAO,CAAC,kBAAU,CAAC,KAAK,IAAI,CAAC;AACjE,CAAC;AAFD,oCAEC;AAID,IAAiB,iBAAiB,CAKjC;AALD,WAAiB,iBAAiB;IAC9B,SAAgB,MAAM,CAA8B,OAAU,EAAE,SAAkB;QAC9E,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,GAAG,SAAS,CAAC;QACpC,OAAO,OAAO,CAAC;IACnB,CAAC;IAHe,wBAAM,SAGrB,CAAA;AACL,CAAC,EALgB,iBAAiB,iCAAjB,iBAAiB,QAKjC"}
|
package/lib/gmodel-element.d.ts
CHANGED
|
@@ -13,20 +13,8 @@
|
|
|
13
13
|
*
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
|
-
import { Args, Bounds, Dimension,
|
|
17
|
-
export
|
|
18
|
-
/**
|
|
19
|
-
* Represents a `GModeElement` serialized as plain JSON object.
|
|
20
|
-
*/
|
|
21
|
-
export declare type GModelElementSchema = SModelElementSchema;
|
|
22
|
-
export declare namespace GModelElementSchema {
|
|
23
|
-
/**
|
|
24
|
-
* Typeguard function to check wether the given object is an {@link GModelElementSchema}.
|
|
25
|
-
* @param object The object to check.
|
|
26
|
-
* @returns A type literal indicating wether the given object is of type {@link GModelElementSchema}.
|
|
27
|
-
*/
|
|
28
|
-
const is: typeof SModelElementSchema.is;
|
|
29
|
-
}
|
|
16
|
+
import { Args, Bounds, Dimension, GModelElementSchema, GModelRootSchema, JsonPrimitive, Point } from '@eclipse-glsp/protocol';
|
|
17
|
+
export type GModelElementConstructor<G extends GModelElement = GModelElement> = new () => G;
|
|
30
18
|
/**
|
|
31
19
|
* Base type for all elements of the graphical model.
|
|
32
20
|
* Each model element must have a unique ID and a type that is used to look up its view.
|
|
@@ -93,8 +81,7 @@ export declare abstract class GModelElementBuilder<G extends GModelElement> {
|
|
|
93
81
|
addArgs(args: Args): this;
|
|
94
82
|
addArgs(args: Map<string, JsonPrimitive>): this;
|
|
95
83
|
}
|
|
96
|
-
export declare
|
|
97
|
-
export declare class GModelRoot extends GModelElement implements SModelRootSchema {
|
|
84
|
+
export declare class GModelRoot extends GModelElement implements GModelRootSchema {
|
|
98
85
|
static builder(): GModelRootBuilder;
|
|
99
86
|
canvasBounds?: Bounds;
|
|
100
87
|
revision?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gmodel-element.d.ts","sourceRoot":"","sources":["../src/gmodel-element.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EACH,IAAI,EACJ,MAAM,EACN,SAAS,
|
|
1
|
+
{"version":3,"file":"gmodel-element.d.ts","sourceRoot":"","sources":["../src/gmodel-element.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EACH,IAAI,EACJ,MAAM,EACN,SAAS,EACT,mBAAmB,EACnB,gBAAgB,EAChB,aAAa,EAEb,KAAK,EAER,MAAM,wBAAwB,CAAC;AAGhC,MAAM,MAAM,wBAAwB,CAAC,CAAC,SAAS,aAAa,GAAG,aAAa,IAAI,UAAU,CAAC,CAAC;AAE5F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EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,GAAG,IAAI;CAelD;AAED,qBAAa,UAAW,SAAQ,aAAc,YAAW,gBAAgB;IACrE,MAAM,CAAC,OAAO,IAAI,iBAAiB;IAInC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,qBAAa,iBAAiB,CAAC,CAAC,SAAS,UAAU,GAAG,UAAU,CAAE,SAAQ,oBAAoB,CAAC,CAAC,CAAC;IAC7F,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI;IAKhC,YAAY,CAAC,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,GAAG,IAAI;IACpD,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;CAWrC"}
|
package/lib/gmodel-element.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.GModelRootBuilder = exports.GModelRoot = exports.GModelElementBuilder = exports.GModelElement =
|
|
3
|
+
exports.GModelRootBuilder = exports.GModelRoot = exports.GModelElementBuilder = exports.GModelElement = void 0;
|
|
4
4
|
/********************************************************************************
|
|
5
5
|
* Copyright (c) 2022 STMicroelectronics and others.
|
|
6
6
|
*
|
|
@@ -18,15 +18,6 @@ exports.GModelRootBuilder = exports.GModelRoot = exports.GModelElementBuilder =
|
|
|
18
18
|
********************************************************************************/
|
|
19
19
|
const protocol_1 = require("@eclipse-glsp/protocol");
|
|
20
20
|
const uuid = require("uuid");
|
|
21
|
-
var GModelElementSchema;
|
|
22
|
-
(function (GModelElementSchema) {
|
|
23
|
-
/**
|
|
24
|
-
* Typeguard function to check wether the given object is an {@link GModelElementSchema}.
|
|
25
|
-
* @param object The object to check.
|
|
26
|
-
* @returns A type literal indicating wether the given object is of type {@link GModelElementSchema}.
|
|
27
|
-
*/
|
|
28
|
-
GModelElementSchema.is = protocol_1.SModelElementSchema.is;
|
|
29
|
-
})(GModelElementSchema = exports.GModelElementSchema || (exports.GModelElementSchema = {}));
|
|
30
21
|
/**
|
|
31
22
|
* Base type for all elements of the graphical model.
|
|
32
23
|
* Each model element must have a unique ID and a type that is used to look up its view.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gmodel-element.js","sourceRoot":"","sources":["../src/gmodel-element.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAUgC;AAChC,6BAA6B;
|
|
1
|
+
{"version":3,"file":"gmodel-element.js","sourceRoot":"","sources":["../src/gmodel-element.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAUgC;AAChC,6BAA6B;AAI7B;;;GAGG;AACH,MAAsB,aAAa;IAAnC;QAcI;;WAEG;QACH,eAAU,GAAa,EAAE,CAAC;QAC1B;;;;WAIG;QACH,aAAQ,GAAoB,EAAE,CAAC;IAqBnC,CAAC;IAVG;;OAEG;IACH,IAAI,IAAI;QACJ,IAAI,OAAO,GAAkB,IAAI,CAAC;QAClC,OAAO,CAAC,CAAC,OAAO,YAAY,UAAU,CAAC,EAAE;YACrC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC;SAC5B;QACD,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ;AA5CD,sCA4CC;AAED;;;;;GAKG;AACH,MAAsB,oBAAoB;IAItC,YAAY,kBAA+C;QACvD,IAAI,CAAC,kBAAkB,GAAG,kBAAkB,CAAC;QAC7C,IAAI,CAAC,KAAK,GAAG,IAAI,kBAAkB,EAAE,CAAC;QACtC,IAAI,CAAC,KAAK,CAAC,UAAU,GAAG,EAAE,CAAC;QAC3B,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,EAAE,CAAC;QACzB,IAAI,CAAC,KAAK,CAAC,EAAE,GAAG,IAAI,CAAC,EAAE,EAAE,CAAC;IAC9B,CAAC;IAED,KAAK;QACD,IAAI,CAAC,K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,CAAC,CAAC;IAC7C,CAAC;CAIJ;AAPD,gCAOC;AAED,MAAa,iBAAqD,SAAQ,oBAAuB;IAC7F,QAAQ,CAAC,QAAgB;QACrB,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAC/B,OAAO,IAAI,CAAC;IAChB,CAAC;IAID,YAAY,CAAC,gBAAgC,EAAE,IAAgB;QAC3D,IAAI,MAAc,CAAC;QACnB,IAAI,IAAI,EAAE;YACN,MAAM,mCAAQ,gBAAgB,GAAK,IAAI,CAAE,CAAC;SAC7C;aAAM;YACH,MAAM,GAAG,gBAA0B,CAAC;SACvC;QACD,IAAI,CAAC,KAAK,CAAC,YAAY,GAAG,MAAM,CAAC;QACjC,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AAlBD,8CAkBC"}
|
package/lib/gmodel-util.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
*
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
|
-
import { GModelElement, GModelElementConstructor } from '
|
|
17
|
-
export
|
|
16
|
+
import { GModelElement, GModelElementConstructor } from './gmodel-element';
|
|
17
|
+
export type Predicate<T> = (element: T) => boolean;
|
|
18
18
|
/**
|
|
19
19
|
* Returns the first element matching the search predicate starting from the given
|
|
20
20
|
* element and walking up the parent hierarchy.
|
package/lib/gmodel-util.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gmodel-util.d.ts","sourceRoot":"","sources":["../src/gmodel-util.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,OAAO,EAAE,aAAa,EAAE,wBAAwB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"gmodel-util.d.ts","sourceRoot":"","sources":["../src/gmodel-util.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,OAAO,EAAE,aAAa,EAAE,wBAAwB,EAAE,MAAM,kBAAkB,CAAC;AAE3E,MAAM,MAAM,SAAS,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,OAAO,CAAC;AAEnD;;;;;;;GAOG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,SAAS,CAAC,aAAa,CAAC,GAAG,aAAa,GAAG,SAAS,CASvH;AAED;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,aAAa,EACrD,OAAO,EAAE,aAAa,EACtB,WAAW,EAAE,wBAAwB,CAAC,CAAC,CAAC,GACzC,CAAC,GAAG,SAAS,CAOf"}
|
package/lib/gmodel-util.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/********************************************************************************
|
|
3
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
3
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
4
4
|
*
|
|
5
5
|
* This program and the accompanying materials are made available under the
|
|
6
6
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
package/lib/index.d.ts
CHANGED
|
@@ -20,8 +20,9 @@ export * from './gbutton';
|
|
|
20
20
|
export * from './gcompartment';
|
|
21
21
|
export * from './gedge';
|
|
22
22
|
export * from './gedge-layoutable';
|
|
23
|
+
export * from './gforeign-object-element';
|
|
23
24
|
export * from './ggraph';
|
|
24
|
-
export * from './
|
|
25
|
+
export * from './ghtml-root';
|
|
25
26
|
export * from './gissue-marker';
|
|
26
27
|
export * from './glabel';
|
|
27
28
|
export * from './glayoutable';
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AACjC,cAAc,+BAA+B,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
|
@@ -32,8 +36,9 @@ __exportStar(require("./gbutton"), exports);
|
|
|
32
36
|
__exportStar(require("./gcompartment"), exports);
|
|
33
37
|
__exportStar(require("./gedge"), exports);
|
|
34
38
|
__exportStar(require("./gedge-layoutable"), exports);
|
|
39
|
+
__exportStar(require("./gforeign-object-element"), exports);
|
|
35
40
|
__exportStar(require("./ggraph"), exports);
|
|
36
|
-
__exportStar(require("./
|
|
41
|
+
__exportStar(require("./ghtml-root"), exports);
|
|
37
42
|
__exportStar(require("./gissue-marker"), exports);
|
|
38
43
|
__exportStar(require("./glabel"), exports);
|
|
39
44
|
__exportStar(require("./glayoutable"), exports);
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,kDAAgC;AAChC,+CAA6B;AAC7B,kDAAgC;AAChC,4CAA0B;AAC1B,iDAA+B;AAC/B,0CAAwB;AACxB,qDAAmC;AACnC,4DAA0C;AAC1C,2CAAyB;AACzB,+CAA6B;AAC7B,kDAAgC;AAChC,2CAAyB;AACzB,gDAA8B;AAC9B,+CAA6B;AAC7B,mDAAiC;AACjC,gDAA8B;AAC9B,0CAAwB;AACxB,0CAAwB;AACxB,0DAAwC;AACxC,mDAAiC;AACjC,gEAA8C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.spec.d.ts","sourceRoot":"","sources":["../src/index.spec.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/********************************************************************************
|
|
3
|
+
* Copyright (c) 2022 STMicroelectronics and others.
|
|
4
|
+
*
|
|
5
|
+
* This program and the accompanying materials are made available under the
|
|
6
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
*
|
|
9
|
+
* This Source Code may also be made available under the following Secondary
|
|
10
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
* with the GNU Classpath Exception which is available at
|
|
13
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
*
|
|
15
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
16
|
+
********************************************************************************/
|
|
17
|
+
/* note: this bogus test file is required so that
|
|
18
|
+
we are able to run mocha unit tests on this
|
|
19
|
+
package, without having any actual unit tests in it.
|
|
20
|
+
This way a coverage report will be generated,
|
|
21
|
+
showing 0% coverage, instead of no report.
|
|
22
|
+
This file can be removed once we have real unit
|
|
23
|
+
tests in place. */
|
|
24
|
+
describe('graph package', () => {
|
|
25
|
+
it('should support code coverage statistics', () => true);
|
|
26
|
+
});
|
|
27
|
+
//# sourceMappingURL=index.spec.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.spec.js","sourceRoot":"","sources":["../src/index.spec.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;AAElF;;;;;;qBAMqB;AAErB,QAAQ,CAAC,eAAe,EAAE,GAAG,EAAE;IAC3B,EAAE,CAAC,yCAAyC,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;AAC9D,CAAC,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eclipse-glsp/graph",
|
|
3
|
-
"version": "1.1.0-next.
|
|
3
|
+
"version": "1.1.0-next.231d53b.69+231d53b",
|
|
4
4
|
"description": "The typescript implementation of the GLSP graphical model (GModel)",
|
|
5
|
-
"license": "(EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0)",
|
|
6
5
|
"keywords": [
|
|
7
6
|
"eclipse",
|
|
8
7
|
"graphics",
|
|
@@ -12,15 +11,16 @@
|
|
|
12
11
|
"glsp",
|
|
13
12
|
"diagram editor"
|
|
14
13
|
],
|
|
15
|
-
"author": {
|
|
16
|
-
"name": "Eclipse GLSP"
|
|
17
|
-
},
|
|
18
14
|
"homepage": "https://www.eclipse.org/glsp/",
|
|
15
|
+
"bugs": "https://github.com/eclipse-glsp/glsp/issues",
|
|
19
16
|
"repository": {
|
|
20
17
|
"type": "git",
|
|
21
18
|
"url": "https://github.com/eclipse-glsp/glsp-server-node.git"
|
|
22
19
|
},
|
|
23
|
-
"
|
|
20
|
+
"license": "(EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0)",
|
|
21
|
+
"author": {
|
|
22
|
+
"name": "Eclipse GLSP"
|
|
23
|
+
},
|
|
24
24
|
"contributors": [
|
|
25
25
|
{
|
|
26
26
|
"name": "STMicroelectronics",
|
|
@@ -32,31 +32,31 @@
|
|
|
32
32
|
"url": "https://projects.eclipse.org/projects/ecd.glsp"
|
|
33
33
|
}
|
|
34
34
|
],
|
|
35
|
+
"main": "lib/index",
|
|
36
|
+
"types": "lib/index",
|
|
35
37
|
"files": [
|
|
36
38
|
"lib",
|
|
37
|
-
"src"
|
|
38
|
-
"css"
|
|
39
|
+
"src"
|
|
39
40
|
],
|
|
41
|
+
"scripts": {
|
|
42
|
+
"build": "tsc -b",
|
|
43
|
+
"clean": "rimraf lib tsconfig.tsbuildinfo coverage .nyc_output",
|
|
44
|
+
"lint": "eslint --ext .ts,.tsx ./src",
|
|
45
|
+
"lint:ci": "yarn lint -o eslint.xml -f checkstyle",
|
|
46
|
+
"prepare": "yarn clean && yarn build",
|
|
47
|
+
"test": "mocha --config ../../.mocharc \"./src/**/*.spec.?(ts|tsx)\"",
|
|
48
|
+
"test:ci": "export JUNIT_REPORT_PATH=./report.xml && yarn test --reporter mocha-jenkins-reporter",
|
|
49
|
+
"test:coverage": "nyc yarn test",
|
|
50
|
+
"watch": "tsc -w"
|
|
51
|
+
},
|
|
40
52
|
"dependencies": {
|
|
41
53
|
"@eclipse-glsp/protocol": "next"
|
|
42
54
|
},
|
|
43
55
|
"devDependencies": {
|
|
44
56
|
"@types/uuid": "8.3.1"
|
|
45
57
|
},
|
|
46
|
-
"scripts": {
|
|
47
|
-
"prepare": "yarn clean && yarn build && yarn lint",
|
|
48
|
-
"clean": "rimraf tsconfig.tsbuildinfo lib",
|
|
49
|
-
"build": "tsc",
|
|
50
|
-
"test": "mocha --config ../../.mocharc.json \"./src/**/*.spec.?(ts|tsx)\"",
|
|
51
|
-
"test:ci": "export JUNIT_REPORT_PATH=./report.xml && yarn test --reporter mocha-jenkins-reporter",
|
|
52
|
-
"lint": "eslint -c ../../.eslintrc.js --ext .ts,.tsx ./src",
|
|
53
|
-
"lint:fix": "eslint --fix -c ../../.eslintrc.js --ext .ts,.tsx ./src",
|
|
54
|
-
"watch": "tsc -w"
|
|
55
|
-
},
|
|
56
58
|
"publishConfig": {
|
|
57
59
|
"access": "public"
|
|
58
60
|
},
|
|
59
|
-
"
|
|
60
|
-
"types": "lib/index",
|
|
61
|
-
"gitHead": "0f9fe4e469e607b7ae2c45c001b5069c9abaf349"
|
|
61
|
+
"gitHead": "231d53bfe5d4720f834dcc68bbdbb5b2a639f243"
|
|
62
62
|
}
|
package/src/default-types.ts
CHANGED
|
@@ -18,7 +18,7 @@ import { GButton } from './gbutton';
|
|
|
18
18
|
import { GCompartment } from './gcompartment';
|
|
19
19
|
import { GEdge } from './gedge';
|
|
20
20
|
import { GGraph } from './ggraph';
|
|
21
|
-
import { GHtmlRoot } from './
|
|
21
|
+
import { GHtmlRoot } from './ghtml-root';
|
|
22
22
|
import { GIssueMarker } from './gissue-marker';
|
|
23
23
|
import { GLabel } from './glabel';
|
|
24
24
|
import { GModelElementConstructor } from './gmodel-element';
|
package/src/galignable.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -24,7 +24,7 @@ export interface GAlignable {
|
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
export function isGAlignable<G extends GModelElement>(element: G): element is G & GAlignable {
|
|
27
|
-
return
|
|
27
|
+
return GAlignable in element && element[GAlignable] === true;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
export type GAlignableBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GAlignable>;
|
package/src/gbounds-aware.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -25,7 +25,7 @@ export interface GBoundsAware {
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
export function isGBoundsAware<G extends GModelElement>(element: G): element is G & GBoundsAware {
|
|
28
|
-
return
|
|
28
|
+
return GBoundsAware in element && element[GBoundsAware] === true;
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
export type GBoundsAwareBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GBoundsAware>;
|
package/src/gedge-layoutable.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -32,7 +32,7 @@ export interface GEdgeLayoutable {
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
export function isGEdgeLayoutable<G extends GModelElement>(element: G): element is G & GEdgeLayoutable {
|
|
35
|
-
return
|
|
35
|
+
return GEdgeLayoutable in element && element[GEdgeLayoutable] === true;
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
export type GEdgeLayoutableBuilder<G extends GModelElement = GModelElement> = GModelElementBuilder<G & GEdgeLayoutable>;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/********************************************************************************
|
|
2
|
+
* Copyright (c) 2023 EclipseSource and others.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made available under the
|
|
5
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
*
|
|
8
|
+
* This Source Code may also be made available under the following Secondary
|
|
9
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
* with the GNU Classpath Exception which is available at
|
|
12
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
*
|
|
14
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
|
+
********************************************************************************/
|
|
16
|
+
|
|
17
|
+
import { GShapePreRenderedElementBuilder, GShapedPreRenderedElement } from './gshaped-prerendered-element';
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* A `foreignObject` element to be transferred to the DOM within the SVG.
|
|
21
|
+
*
|
|
22
|
+
* This can be useful to to benefit from e.g. HTML rendering features, such as line wrapping, inside of
|
|
23
|
+
* the SVG diagram. Note that `foreignObject` is not supported by all browsers and SVG viewers may not
|
|
24
|
+
* support rendering the `foreignObject` content.
|
|
25
|
+
*
|
|
26
|
+
* If no dimensions are specified in the schema element, this element will obtain the dimension of
|
|
27
|
+
* its parent to fill the entire available room. Thus, this element requires specified bounds itself
|
|
28
|
+
* or bounds to be available for its parent.
|
|
29
|
+
*/
|
|
30
|
+
export class GForeignObjectElement extends GShapedPreRenderedElement {
|
|
31
|
+
static override builder(): GForeignObjectElementBuilder {
|
|
32
|
+
return new GForeignObjectElementBuilder(GForeignObjectElement);
|
|
33
|
+
}
|
|
34
|
+
namespace: string;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export class GForeignObjectElementBuilder<
|
|
38
|
+
G extends GForeignObjectElement = GForeignObjectElement
|
|
39
|
+
> extends GShapePreRenderedElementBuilder<G> {
|
|
40
|
+
namespace(namespace: string): this {
|
|
41
|
+
this.proxy.namespace = namespace;
|
|
42
|
+
return this;
|
|
43
|
+
}
|
|
44
|
+
}
|
package/src/glayoutable.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -24,7 +24,7 @@ export interface GLayoutable {
|
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
export function isGLayoutable<G extends GModelElement>(element: G): element is G & GLayoutable {
|
|
27
|
-
return
|
|
27
|
+
return GLayoutable in element && element[GLayoutable] === true;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
export type GLayoutableBuilder = GModelElementBuilder<GModelElement & GLayoutable>;
|
package/src/glayouting.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -23,7 +23,7 @@ export interface GLayouting {
|
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
export function isGLayouting<G extends GModelElement>(element: G): element is G & GLayouting {
|
|
26
|
-
return
|
|
26
|
+
return GLayouting in element && element[GLayouting] === true;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
export type GLayoutingBuilder = GModelElementBuilder<GModelElement & GLayouting>;
|
package/src/gmodel-element.ts
CHANGED
|
@@ -17,29 +17,16 @@ import {
|
|
|
17
17
|
Args,
|
|
18
18
|
Bounds,
|
|
19
19
|
Dimension,
|
|
20
|
-
|
|
20
|
+
GModelElementSchema,
|
|
21
|
+
GModelRootSchema,
|
|
21
22
|
JsonPrimitive,
|
|
22
23
|
MaybeArray,
|
|
23
24
|
Point,
|
|
24
|
-
|
|
25
|
-
SModelRootSchema
|
|
25
|
+
flatPush
|
|
26
26
|
} from '@eclipse-glsp/protocol';
|
|
27
27
|
import * as uuid from 'uuid';
|
|
28
28
|
|
|
29
29
|
export type GModelElementConstructor<G extends GModelElement = GModelElement> = new () => G;
|
|
30
|
-
/**
|
|
31
|
-
* Represents a `GModeElement` serialized as plain JSON object.
|
|
32
|
-
*/
|
|
33
|
-
export type GModelElementSchema = SModelElementSchema;
|
|
34
|
-
|
|
35
|
-
export namespace GModelElementSchema {
|
|
36
|
-
/**
|
|
37
|
-
* Typeguard function to check wether the given object is an {@link GModelElementSchema}.
|
|
38
|
-
* @param object The object to check.
|
|
39
|
-
* @returns A type literal indicating wether the given object is of type {@link GModelElementSchema}.
|
|
40
|
-
*/
|
|
41
|
-
export const is = SModelElementSchema.is;
|
|
42
|
-
}
|
|
43
30
|
|
|
44
31
|
/**
|
|
45
32
|
* Base type for all elements of the graphical model.
|
|
@@ -187,9 +174,7 @@ export abstract class GModelElementBuilder<G extends GModelElement> {
|
|
|
187
174
|
}
|
|
188
175
|
}
|
|
189
176
|
|
|
190
|
-
export
|
|
191
|
-
|
|
192
|
-
export class GModelRoot extends GModelElement implements SModelRootSchema {
|
|
177
|
+
export class GModelRoot extends GModelElement implements GModelRootSchema {
|
|
193
178
|
static builder(): GModelRootBuilder {
|
|
194
179
|
return new GModelRootBuilder(GModelRoot);
|
|
195
180
|
}
|
package/src/gmodel-util.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/********************************************************************************
|
|
2
|
-
* Copyright (c) 2022 STMicroelectronics and others.
|
|
2
|
+
* Copyright (c) 2022-2023 STMicroelectronics and others.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made available under the
|
|
5
5
|
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
|
|
17
|
-
import { GModelElement, GModelElementConstructor } from '
|
|
17
|
+
import { GModelElement, GModelElementConstructor } from './gmodel-element';
|
|
18
18
|
|
|
19
19
|
export type Predicate<T> = (element: T) => boolean;
|
|
20
20
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/********************************************************************************
|
|
2
|
+
* Copyright (c) 2022 STMicroelectronics and others.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made available under the
|
|
5
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
*
|
|
8
|
+
* This Source Code may also be made available under the following Secondary
|
|
9
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
* with the GNU Classpath Exception which is available at
|
|
12
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
*
|
|
14
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
|
+
********************************************************************************/
|
|
16
|
+
|
|
17
|
+
/* note: this bogus test file is required so that
|
|
18
|
+
we are able to run mocha unit tests on this
|
|
19
|
+
package, without having any actual unit tests in it.
|
|
20
|
+
This way a coverage report will be generated,
|
|
21
|
+
showing 0% coverage, instead of no report.
|
|
22
|
+
This file can be removed once we have real unit
|
|
23
|
+
tests in place. */
|
|
24
|
+
|
|
25
|
+
describe('graph package', () => {
|
|
26
|
+
it('should support code coverage statistics', () => true);
|
|
27
|
+
});
|
package/src/index.ts
CHANGED
|
@@ -20,8 +20,9 @@ export * from './gbutton';
|
|
|
20
20
|
export * from './gcompartment';
|
|
21
21
|
export * from './gedge';
|
|
22
22
|
export * from './gedge-layoutable';
|
|
23
|
+
export * from './gforeign-object-element';
|
|
23
24
|
export * from './ggraph';
|
|
24
|
-
export * from './
|
|
25
|
+
export * from './ghtml-root';
|
|
25
26
|
export * from './gissue-marker';
|
|
26
27
|
export * from './glabel';
|
|
27
28
|
export * from './glayoutable';
|
package/lib/ghtmlroot.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ghtmlroot.d.ts","sourceRoot":"","sources":["../src/ghtmlroot.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAEjE;;GAEG;AACH,qBAAa,SAAU,SAAQ,UAAU;WACrB,OAAO,IAAI,gBAAgB;IAIlC,IAAI,SAAc;IAC3B,OAAO,EAAE,MAAM,EAAE,CAAM;CAC1B;AAED,qBAAa,gBAAgB,CAAC,CAAC,SAAS,SAAS,GAAG,SAAS,CAAE,SAAQ,iBAAiB,CAAC,CAAC,CAAC;IACvF,UAAU,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI;IACnC,UAAU,CAAC,GAAG,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI;CAKzC"}
|
package/lib/ghtmlroot.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ghtmlroot.js","sourceRoot":"","sources":["../src/ghtmlroot.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAAqF;AACrF,qDAAiE;AAEjE;;GAEG;AACH,MAAa,SAAU,SAAQ,2BAAU;IAAzC;;QAKa,SAAI,GAAG,uBAAK,CAAC,IAAI,CAAC;QAC3B,YAAO,GAAa,EAAE,CAAC;IAC3B,CAAC;IANG,MAAM,CAAU,OAAO;QACnB,OAAO,IAAI,gBAAgB,CAAC,SAAS,CAAC,CAAC;IAC3C,CAAC;CAIJ;AAPD,8BAOC;AAED,MAAa,gBAAkD,SAAQ,kCAAoB;IAGvF,UAAU,CAAC,GAAG,OAA6B;QACvC,IAAA,mBAAQ,EAAC,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;QACtC,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AAPD,4CAOC"}
|
|
File without changes
|