@focus.matters/diagrams 0.1.2 → 0.2.1
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/{DirectedPoint-BcpEj8ub.js → DirectedPoint-BSGh_PUt.js} +2 -2
- package/dist/DirectedPoint-BSGh_PUt.js.map +1 -0
- package/dist/diagrams.css +1 -1
- package/dist/index-y4Eon_hl.js +16196 -0
- package/dist/{index-hTkL5cDr.js.map → index-y4Eon_hl.js.map} +1 -1
- package/dist/index.es.js +25 -8
- package/dist/index.umd.js +5 -5
- package/dist/index.umd.js.map +1 -1
- package/dist/src/Diagrams/components/objects/RenderEdge/EdgeMidpoints.d.ts +2 -1
- package/dist/src/Diagrams/context-menu/buildDiagramContextMenu.d.ts +1 -0
- package/dist/src/Diagrams/custom/bpmn/config/BPMNLabels.d.ts +1 -1
- package/dist/src/Diagrams/custom/bpmn/extensions/BPMNModelerExtension.d.ts +14 -1
- package/dist/src/Diagrams/custom/bpmn/nodes/BPMNEventDefinition.d.ts +11 -2
- package/dist/src/Diagrams/custom/bpmn/nodes/DocumentNode.d.ts +75 -1
- package/dist/src/Diagrams/custom/bpmn/nodes/GateNode.d.ts +2 -1
- package/dist/src/Diagrams/custom/bpmn/nodes/TaskNode.d.ts +16 -0
- package/dist/src/Diagrams/custom/bpmn/ui/BPMNElementMenu.d.ts +2 -1
- package/dist/src/Diagrams/custom/bpmn/ui/BPMNIcon.d.ts +1 -1
- package/dist/src/Diagrams/custom/bpmn/ui/BPMNPropertiesPanel.d.ts +11 -1
- package/dist/src/Diagrams/custom/bpmnExecution/BPMNExecutionDiagram.d.ts +30 -0
- package/dist/src/Diagrams/custom/bpmnExecution/BPMNExecutionEdge.d.ts +67 -0
- package/dist/src/Diagrams/custom/bpmnExecution/BPMNExecutionExtension.d.ts +9 -0
- package/dist/src/Diagrams/custom/bpmnExecution/BPMNExecutionMarker.d.ts +12 -0
- package/dist/src/Diagrams/custom/bpmnExecution/BPMNNodeExecutionState.d.ts +27 -0
- package/dist/src/Diagrams/custom/bpmnExecution/isBPMNExecutionNode.d.ts +7 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionBlackBoxPoolNode.d.ts +70 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionDataStoreNode.d.ts +70 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionDocumentAnnotationNode.d.ts +70 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionDocumentNode.d.ts +71 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionEventNode.d.ts +81 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionGateNode.d.ts +71 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionLanes.d.ts +14 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionTaskNode.d.ts +76 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionTextAnnotationNode.d.ts +70 -0
- package/dist/src/Diagrams/custom/bpmnExecution/nodes/BPMNExecutionUnknownNode.d.ts +71 -0
- package/dist/src/Diagrams/custom/bpmnExecution/promoteBPMNExecutionEdge.d.ts +3 -0
- package/dist/src/Diagrams/custom/bpmnExecution/promoteBPMNExecutionNode.d.ts +3 -0
- package/dist/src/Diagrams/custom/bpmnExecution/types.d.ts +38 -0
- package/dist/src/Diagrams/custom/bpmnExecution/ui/BPMNExecutionMarkers.d.ts +6 -0
- package/dist/src/Diagrams/custom/bpmnExecution/ui/BPMNExecutionPropertiesPanel.d.ts +6 -0
- package/dist/src/Diagrams/custom/mr/MRDiagram.d.ts +17 -0
- package/dist/src/Diagrams/custom/mr/edges/MRForeignKeyEdge.d.ts +77 -0
- package/dist/src/Diagrams/custom/mr/extensions/MRModelerExtension.d.ts +45 -0
- package/dist/src/Diagrams/custom/mr/extensions/MRPropertyChangeEvent.d.ts +4 -0
- package/dist/src/Diagrams/custom/mr/layout/applyMRAutoLayout.d.ts +3 -0
- package/dist/src/Diagrams/custom/mr/nodes/MRTableNode.d.ts +105 -0
- package/dist/src/Diagrams/custom/mr/types.d.ts +51 -0
- package/dist/src/Diagrams/custom/mr/ui/MRPropertiesPanel.d.ts +6 -0
- package/dist/src/Diagrams/store/elements/Events.d.ts +2 -1
- package/dist/src/index.d.ts +20 -0
- package/package.json +4 -1
- package/dist/DirectedPoint-BcpEj8ub.js.map +0 -1
- package/dist/index-hTkL5cDr.js +0 -12037
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { Edge } from '../../../store/elements/Edge';
|
|
2
3
|
import { Coordinates } from '../../../store/primitives/Coordinates';
|
|
3
4
|
import { Midpoint } from './types';
|
|
4
|
-
import { Edge } from '../../../store/elements/Edge';
|
|
5
5
|
interface EdgeMidpointsProps {
|
|
6
6
|
edge: Edge;
|
|
7
7
|
onMouseDown: (m: Midpoint, ev: React.MouseEvent) => unknown;
|
|
8
8
|
points: Coordinates[];
|
|
9
9
|
}
|
|
10
|
+
/** Renders draggable midpoint handles and edge-debug actions for every visible segment. */
|
|
10
11
|
export declare const EdgeMidpoints: React.FC<EdgeMidpointsProps>;
|
|
11
12
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Diagram } from '../store/Diagram';
|
|
2
2
|
import { ContextMenuElement } from './types';
|
|
3
|
+
/** Builds a context menu whose editing actions respect the diagram's current rules. */
|
|
3
4
|
export declare function buildDiagramContextMenu(diagram: Diagram, target: HTMLElement, cursor: {
|
|
4
5
|
x: number;
|
|
5
6
|
y: number;
|
|
@@ -3,7 +3,7 @@ export type BPMNLabels = {
|
|
|
3
3
|
elements: Record<string, string>;
|
|
4
4
|
eventOptions: Record<"none" | "start" | "intermediate" | "end" | "catch" | "throw", string>;
|
|
5
5
|
actions: Record<"transform" | "connect" | "settings" | "close" | "delete" | "reverseDirection" | "resize" | "resizeElement", string>;
|
|
6
|
-
properties: Record<"title" | "name" | "type" | "condition" | "defaultFlow" | "directed" | "edgeType" | "routingType" | "eventType" | "eventStage" | "eventDirection" | "interrupting" | "subprocessStart" | "eventSubprocessStartType" | "loop" | "multiInstance", string>;
|
|
6
|
+
properties: Record<"title" | "name" | "type" | "condition" | "defaultFlow" | "directed" | "edgeType" | "routingType" | "eventType" | "eventStage" | "eventDirection" | "interrupting" | "subprocessStart" | "eventSubprocessStartType" | "loop" | "multiInstance" | "compensation" | "adHoc" | "transaction", string>;
|
|
7
7
|
edges: Record<string, string>;
|
|
8
8
|
routing: Record<"orthogonal" | "straight" | "curved", string>;
|
|
9
9
|
inputs: Record<"blackBoxPoolName" | "documentAnnotationText" | "elementSearch" | "laneName", string>;
|
|
@@ -15,7 +15,14 @@ export declare class BPMNModelerExtension extends DiagramExtension {
|
|
|
15
15
|
RenderDiagram: (({ diagram, extension }: import('../../../store/extensions/DiagramExtension').TDiagramExtensionRenderProps<BPMNModelerExtension>) => import("react").JSX.Element | null) & {
|
|
16
16
|
displayName: string;
|
|
17
17
|
};
|
|
18
|
-
RenderUI: (({ diagram, extension }: import('../../../store/extensions/DiagramExtension').TDiagramExtensionRenderProps<BPMNModelerExtension>
|
|
18
|
+
RenderUI: (({ diagram, extension, sections }: import('../../../store/extensions/DiagramExtension').TDiagramExtensionRenderProps<BPMNModelerExtension> & {
|
|
19
|
+
sections?: {
|
|
20
|
+
generalTitle: string;
|
|
21
|
+
additionalTitle: string;
|
|
22
|
+
additionalContent: import('react').ReactNode;
|
|
23
|
+
additionalEditable?: boolean;
|
|
24
|
+
};
|
|
25
|
+
}) => import("react").JSX.Element) & {
|
|
19
26
|
displayName: string;
|
|
20
27
|
};
|
|
21
28
|
private labelConfiguration;
|
|
@@ -70,6 +77,12 @@ export declare class BPMNModelerExtension extends DiagramExtension {
|
|
|
70
77
|
changeTaskMultiInstance(node: TaskNode, multiInstance: TaskMultiInstance): boolean;
|
|
71
78
|
/** Toggles a task's standard conditional loop and records the property change. */
|
|
72
79
|
changeTaskLoop(node: TaskNode, loop: boolean): boolean;
|
|
80
|
+
/** Toggles the BPMN compensation marker while recording one property mutation. */
|
|
81
|
+
changeTaskCompensation(node: TaskNode, compensation: boolean): boolean;
|
|
82
|
+
/** Toggles a standard sub-process ad-hoc marker and records one property mutation. */
|
|
83
|
+
changeTaskAdHoc(node: TaskNode, adHoc: boolean): boolean;
|
|
84
|
+
/** Toggles standard BPMN transaction notation and records one editable property mutation. */
|
|
85
|
+
changeTaskTransaction(node: TaskNode, transaction: boolean): boolean;
|
|
73
86
|
/** Updates a selected edge label and records the mutation in diagram history. */
|
|
74
87
|
renameEdge(edge: Edge, label: string): void;
|
|
75
88
|
/** Returns only edge kinds that preserve all endpoint-specific BPMN constraints. */
|
|
@@ -13,10 +13,19 @@ export declare enum EventTypes {
|
|
|
13
13
|
errorCatch = 10,
|
|
14
14
|
errorThrow = 11,
|
|
15
15
|
conditional = 12,
|
|
16
|
-
terminate = 13
|
|
16
|
+
terminate = 13,
|
|
17
|
+
cancelCatch = 14,
|
|
18
|
+
cancelThrow = 15,
|
|
19
|
+
escalationCatch = 16,
|
|
20
|
+
escalationThrow = 17,
|
|
21
|
+
linkCatch = 18,
|
|
22
|
+
linkThrow = 19,
|
|
23
|
+
multipleCatch = 20,
|
|
24
|
+
multipleThrow = 21,
|
|
25
|
+
parallelMultiple = 22
|
|
17
26
|
}
|
|
18
27
|
export type EventStage = "start" | "intermediate" | "end";
|
|
19
|
-
export type EventKind = "none" | "timer" | "message" | "signal" | "compensation" | "error" | "conditional" | "terminate";
|
|
28
|
+
export type EventKind = "none" | "timer" | "message" | "signal" | "compensation" | "error" | "conditional" | "cancel" | "escalation" | "link" | "multiple" | "parallelMultiple" | "terminate";
|
|
20
29
|
export type EventDirection = "catch" | "throw";
|
|
21
30
|
export type EventDefinition = Readonly<{
|
|
22
31
|
stage: EventStage;
|
|
@@ -2,12 +2,86 @@ import { Element } from '../../../store/elements/Element';
|
|
|
2
2
|
import { TNodeConstructorProps } from '../../../store/elements/Node';
|
|
3
3
|
import { Dimensions } from '../../../store/primitives/Dimensions';
|
|
4
4
|
import { BPMNode } from './BPMNode';
|
|
5
|
+
/** Enumerates standard BPMN data-object states while retaining normal documents by default. */
|
|
6
|
+
export declare enum DataObjectTypes {
|
|
7
|
+
normal = 0,
|
|
8
|
+
input = 1,
|
|
9
|
+
output = 2
|
|
10
|
+
}
|
|
11
|
+
type TDocumentNodeState = TNodeConstructorProps & {
|
|
12
|
+
type?: DataObjectTypes;
|
|
13
|
+
};
|
|
5
14
|
/** Models a transient BPMN data document connected through directional associations. */
|
|
6
15
|
export declare class DocumentNode extends BPMNode {
|
|
16
|
+
type: DataObjectTypes;
|
|
7
17
|
requiredEdgePathType: "straight";
|
|
8
|
-
|
|
18
|
+
protected occupiesGridSquare: boolean;
|
|
19
|
+
constructor(parent: Element | null, state: TDocumentNodeState);
|
|
20
|
+
/** Changes the BPMN data-object state while retaining its node geometry and connections. */
|
|
21
|
+
setType(type: DataObjectTypes): boolean;
|
|
22
|
+
/** Serializes the semantic data-object state alongside normal BPMN document state. */
|
|
23
|
+
serialize(): {
|
|
24
|
+
type: DataObjectTypes;
|
|
25
|
+
box: [number, number, number, number];
|
|
26
|
+
id: string;
|
|
27
|
+
label: string;
|
|
28
|
+
movable: boolean | undefined;
|
|
29
|
+
selectable: boolean | undefined;
|
|
30
|
+
selected: boolean | undefined;
|
|
31
|
+
gateways: {
|
|
32
|
+
coordinates: [number, number];
|
|
33
|
+
fill: string | undefined;
|
|
34
|
+
id: string;
|
|
35
|
+
orientation: import('../../../store/types').TOrientation;
|
|
36
|
+
radius: number;
|
|
37
|
+
stroke: string | undefined;
|
|
38
|
+
strokeWidth: number;
|
|
39
|
+
outEdges: {
|
|
40
|
+
arrowHeadEnd: import('../../../store/types').EdgeArrowHead | undefined;
|
|
41
|
+
arrowHeadStart: import('../../../store/types').EdgeArrowHead | undefined;
|
|
42
|
+
displacementEnd: [number, number] | undefined;
|
|
43
|
+
displacementStart: [number, number] | undefined;
|
|
44
|
+
lineStyle: import('../../../store/types').EdgeLineStyle | undefined;
|
|
45
|
+
labels: {
|
|
46
|
+
alignment: "right" | "left" | "center";
|
|
47
|
+
id: string;
|
|
48
|
+
size: {
|
|
49
|
+
height: number;
|
|
50
|
+
width: number;
|
|
51
|
+
};
|
|
52
|
+
text: string;
|
|
53
|
+
position: [number, number];
|
|
54
|
+
}[];
|
|
55
|
+
pathType: import('../../../store/types').EdgePathType;
|
|
56
|
+
startAnchor: {
|
|
57
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
58
|
+
position: [number, number] | undefined;
|
|
59
|
+
};
|
|
60
|
+
endAnchor: {
|
|
61
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
62
|
+
position: [number, number] | undefined;
|
|
63
|
+
};
|
|
64
|
+
steps: import('../../../store/elements/EdgePoint').TSerializedEdgePoint[];
|
|
65
|
+
stroke: string | undefined;
|
|
66
|
+
strokeWidth: number | undefined;
|
|
67
|
+
to: string;
|
|
68
|
+
toParentId: string;
|
|
69
|
+
class: string;
|
|
70
|
+
}[];
|
|
71
|
+
class: string;
|
|
72
|
+
}[];
|
|
73
|
+
fill: string | undefined;
|
|
74
|
+
labelFontSize: number | undefined;
|
|
75
|
+
labelOffset: [number, number] | undefined;
|
|
76
|
+
stroke: string | undefined;
|
|
77
|
+
strokewWidth: number | undefined;
|
|
78
|
+
class: string;
|
|
79
|
+
};
|
|
80
|
+
/** Restores the persisted data-object state while accepting older normal documents. */
|
|
81
|
+
deserialize(o: ReturnType<this["serialize"]>): void;
|
|
9
82
|
protected get screenLabelBox(): Dimensions;
|
|
10
83
|
RenderOverlay: (() => import("react").JSX.Element) & {
|
|
11
84
|
displayName: string;
|
|
12
85
|
};
|
|
13
86
|
}
|
|
87
|
+
export {};
|
|
@@ -6,7 +6,8 @@ export declare enum GateTypes {
|
|
|
6
6
|
inclusive = 0,
|
|
7
7
|
exclusive = 1,
|
|
8
8
|
parallel = 2,
|
|
9
|
-
eventBased = 3
|
|
9
|
+
eventBased = 3,
|
|
10
|
+
complex = 4
|
|
10
11
|
}
|
|
11
12
|
/** Models fixed-grid BPMN gateways and their mutually exclusive marker variants. */
|
|
12
13
|
export declare class GateNode extends BPMNode {
|
|
@@ -22,6 +22,9 @@ type TTaskNodeState = TNodeConstructorProps & {
|
|
|
22
22
|
type?: TaskTypes;
|
|
23
23
|
multiInstance?: TaskMultiInstance;
|
|
24
24
|
loop?: boolean;
|
|
25
|
+
compensation?: boolean;
|
|
26
|
+
adHoc?: boolean;
|
|
27
|
+
transaction?: boolean;
|
|
25
28
|
};
|
|
26
29
|
/** Models BPMN activities with compact default geometry and selectable task variants. */
|
|
27
30
|
export declare class TaskNode extends BPMNode implements BPMNResizableNode {
|
|
@@ -29,6 +32,9 @@ export declare class TaskNode extends BPMNode implements BPMNResizableNode {
|
|
|
29
32
|
readonly minimumResizeSize: Coordinates;
|
|
30
33
|
multiInstance: TaskMultiInstance;
|
|
31
34
|
loop: boolean;
|
|
35
|
+
compensation: boolean;
|
|
36
|
+
adHoc: boolean;
|
|
37
|
+
transaction: boolean;
|
|
32
38
|
edgesAsGateways: boolean;
|
|
33
39
|
constructor(parent: Element | null, state: TTaskNodeState);
|
|
34
40
|
private fitWidthToGrid;
|
|
@@ -41,11 +47,20 @@ export declare class TaskNode extends BPMNode implements BPMNResizableNode {
|
|
|
41
47
|
setMultiInstance(multiInstance: TaskMultiInstance): boolean;
|
|
42
48
|
/** Toggles the standard conditional-loop marker independently of other markers. */
|
|
43
49
|
setLoop(loop: boolean): boolean;
|
|
50
|
+
/** Toggles the BPMN compensation marker independently from loop and multi-instance state. */
|
|
51
|
+
setCompensation(compensation: boolean): boolean;
|
|
52
|
+
/** Toggles the BPMN ad-hoc marker only when this node is a standard sub-process. */
|
|
53
|
+
setAdHoc(adHoc: boolean): boolean;
|
|
54
|
+
/** Toggles transaction notation only for BPMN sub-processes and call activities. */
|
|
55
|
+
setTransaction(transaction: boolean): boolean;
|
|
44
56
|
/** Serializes the task subtype together with the shared editable node state. */
|
|
45
57
|
serialize(): {
|
|
46
58
|
type: TaskTypes;
|
|
47
59
|
multiInstance: TaskMultiInstance;
|
|
48
60
|
loop: boolean;
|
|
61
|
+
compensation: boolean;
|
|
62
|
+
adHoc: boolean;
|
|
63
|
+
transaction: boolean;
|
|
49
64
|
box: [number, number, number, number];
|
|
50
65
|
id: string;
|
|
51
66
|
label: string;
|
|
@@ -104,6 +119,7 @@ export declare class TaskNode extends BPMNode implements BPMNResizableNode {
|
|
|
104
119
|
/** Restores persisted task variants and defaults missing marker state safely. */
|
|
105
120
|
deserialize(o: ReturnType<this["serialize"]>): void;
|
|
106
121
|
protected get screenLabelBox(): Dimensions;
|
|
122
|
+
private refreshTransactionPresentation;
|
|
107
123
|
RenderScreen: (() => import("react").JSX.Element) & {
|
|
108
124
|
displayName: string;
|
|
109
125
|
};
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { BPMNElementDefinition, BPMNElementId } from '../config/BPMNElementCatalog';
|
|
2
2
|
import { BPMNLabels } from '../config/BPMNLabels';
|
|
3
3
|
type BPMNElementMenuProps = {
|
|
4
|
+
autoFocus?: boolean;
|
|
4
5
|
items: BPMNElementDefinition[];
|
|
5
6
|
labels: BPMNLabels;
|
|
6
7
|
onSelect: (item: BPMNElementDefinition) => void;
|
|
7
8
|
selectedId?: BPMNElementId;
|
|
8
9
|
};
|
|
9
10
|
/** Renders the compact catalog list shared by toolbars and transformation menus. */
|
|
10
|
-
export declare function BPMNElementMenu({ items, labels, onSelect, selectedId, }: BPMNElementMenuProps): import("react").JSX.Element;
|
|
11
|
+
export declare function BPMNElementMenu({ autoFocus, items, labels, onSelect, selectedId, }: BPMNElementMenuProps): import("react").JSX.Element;
|
|
11
12
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type BPMNIconId = "task" | "serviceTask" | "sendTask" | "receiveTask" | "scriptTask" | "manualTask" | "businessRuleTask" | "callActivity" | "subprocess" | "eventSubprocess" | "event" | "start" | "intermediate" | "end" | "timer" | "message" | "messageCatch" | "messageThrow" | "signal" | "compensation" | "error" | "conditional" | "terminate" | "exclusive" | "inclusive" | "parallel" | "eventBased" | "lanes" | "blackBoxPool" | "dataStore" | "document" | "documentAnnotation" | "textAnnotation" | "transform" | "connect" | "settings";
|
|
1
|
+
export type BPMNIconId = "task" | "serviceTask" | "sendTask" | "receiveTask" | "scriptTask" | "manualTask" | "businessRuleTask" | "callActivity" | "subprocess" | "eventSubprocess" | "event" | "start" | "intermediate" | "end" | "timer" | "message" | "messageCatch" | "messageThrow" | "signal" | "compensation" | "error" | "conditional" | "cancel" | "escalation" | "link" | "multiple" | "parallelMultiple" | "terminate" | "exclusive" | "inclusive" | "parallel" | "eventBased" | "complex" | "lanes" | "blackBoxPool" | "dataStore" | "document" | "dataInput" | "dataOutput" | "documentAnnotation" | "textAnnotation" | "transform" | "connect" | "settings";
|
|
2
2
|
type BPMNIconProps = {
|
|
3
3
|
id: BPMNIconId;
|
|
4
4
|
className?: string;
|
|
@@ -1,6 +1,16 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
import { TDiagramExtensionRenderProps } from '../../../store/extensions/DiagramExtension';
|
|
2
3
|
import { BPMNModelerExtension } from '../extensions/BPMNModelerExtension';
|
|
4
|
+
type TBPMNPropertiesPanelProps = TDiagramExtensionRenderProps<BPMNModelerExtension> & {
|
|
5
|
+
sections?: {
|
|
6
|
+
generalTitle: string;
|
|
7
|
+
additionalTitle: string;
|
|
8
|
+
additionalContent: ReactNode;
|
|
9
|
+
additionalEditable?: boolean;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
3
12
|
/** Renders the animated fixed inspector for the single selected BPMN element. */
|
|
4
|
-
export declare const BPMNPropertiesPanel: (({ diagram, extension }:
|
|
13
|
+
export declare const BPMNPropertiesPanel: (({ diagram, extension, sections }: TBPMNPropertiesPanelProps) => import("react").JSX.Element) & {
|
|
5
14
|
displayName: string;
|
|
6
15
|
};
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Edge } from '../../store/elements/Edge';
|
|
2
|
+
import { Gateway } from '../../store/elements/Gateway';
|
|
3
|
+
import { Node } from '../../store/elements/Node';
|
|
4
|
+
import { BPMDiagram, BPMDiagramSettings } from '../bpmn/BPMDiagram';
|
|
5
|
+
import { BPMNExecutionApplyResult, BPMNExecutionSettings, BPMNExecutionSettingsInput, BPMNExecutionSnapshot } from './types';
|
|
6
|
+
export type BPMNExecutionDiagramSettings = BPMDiagramSettings & {
|
|
7
|
+
execution?: BPMNExecutionSettingsInput;
|
|
8
|
+
};
|
|
9
|
+
/** Extends the complete BPMN modeler with live, serializable process execution state. */
|
|
10
|
+
export declare class BPMNExecutionDiagram extends BPMDiagram {
|
|
11
|
+
readonly executionSettings: BPMNExecutionSettings;
|
|
12
|
+
private restoringSerializedState;
|
|
13
|
+
constructor(settings?: BPMNExecutionDiagramSettings);
|
|
14
|
+
/** Restores serialized BPMN semantics without ever enabling interactive edition. */
|
|
15
|
+
import(serializedDiagram: string): void;
|
|
16
|
+
/** Replaces readonly content through a controlled loader while edition stays disabled. */
|
|
17
|
+
replaceReadonlyContent(loader: () => void | Promise<void>): Promise<boolean>;
|
|
18
|
+
/** Adds catalog-created BPMN nodes after promoting them to execution subclasses in place. */
|
|
19
|
+
add<T extends Node>(node: T): T;
|
|
20
|
+
/** Registers externally constructed BPMN edges as their execution-aware subclasses. */
|
|
21
|
+
connectWithEdge(from: Gateway, to: Gateway, edge: Edge): Edge;
|
|
22
|
+
/** Updates configurable execution colors without mutating semantic element styling. */
|
|
23
|
+
configureExecution(settings: BPMNExecutionSettingsInput): void;
|
|
24
|
+
/** Applies one process-engine snapshot and reports identifiers that could not be matched. */
|
|
25
|
+
applyExecutionSnapshot(snapshot: BPMNExecutionSnapshot): BPMNExecutionApplyResult;
|
|
26
|
+
/** Clears all operational snapshots while leaving the modeled BPMN process untouched. */
|
|
27
|
+
clearExecution(): void;
|
|
28
|
+
private resolveExecutionEdge;
|
|
29
|
+
private registerExecutionClasses;
|
|
30
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { BPMNEdge } from '../bpmn/edges/BPMNEdge';
|
|
2
|
+
import { BPMNEdgeExecutionSnapshot } from './types';
|
|
3
|
+
type BPMNExecutionEdgeState = ConstructorParameters<typeof BPMNEdge>[1] & {
|
|
4
|
+
executionId?: string;
|
|
5
|
+
execution?: BPMNEdgeExecutionSnapshot;
|
|
6
|
+
};
|
|
7
|
+
/** Extends a BPMN flow with visit history and configurable execution styling. */
|
|
8
|
+
export declare class BPMNExecutionEdge extends BPMNEdge {
|
|
9
|
+
executionId: string;
|
|
10
|
+
visited: boolean;
|
|
11
|
+
visitCount: number;
|
|
12
|
+
visitedAt: string | null;
|
|
13
|
+
constructor(parent: ConstructorParameters<typeof BPMNEdge>[0], state: BPMNExecutionEdgeState);
|
|
14
|
+
get stroke(): string | undefined;
|
|
15
|
+
/** Applies one visited-flow snapshot without altering routing or BPMN semantics. */
|
|
16
|
+
applyExecution(snapshot?: BPMNEdgeExecutionSnapshot): void;
|
|
17
|
+
/** Clears visit history while preserving the underlying BPMN flow definition. */
|
|
18
|
+
resetExecution(): void;
|
|
19
|
+
/** Replaces the stable external identifier used to match execution snapshots. */
|
|
20
|
+
setExecutionId(executionId: string): void;
|
|
21
|
+
/** Serializes execution identity and visit history beside normal BPMN edge data. */
|
|
22
|
+
serialize(): {
|
|
23
|
+
executionId: string;
|
|
24
|
+
execution: {
|
|
25
|
+
visited: boolean;
|
|
26
|
+
visitCount: number;
|
|
27
|
+
visitedAt: string | null;
|
|
28
|
+
};
|
|
29
|
+
kind: import('../bpmn/edges/BPMNEdge').BPMNEdgeKind;
|
|
30
|
+
condition: string;
|
|
31
|
+
isDefault: boolean;
|
|
32
|
+
isDirected: boolean;
|
|
33
|
+
arrowHeadEnd: import('../../store/types').EdgeArrowHead | undefined;
|
|
34
|
+
arrowHeadStart: import('../../store/types').EdgeArrowHead | undefined;
|
|
35
|
+
displacementEnd: [number, number] | undefined;
|
|
36
|
+
displacementStart: [number, number] | undefined;
|
|
37
|
+
lineStyle: import('../../store/types').EdgeLineStyle | undefined;
|
|
38
|
+
labels: {
|
|
39
|
+
alignment: "right" | "left" | "center";
|
|
40
|
+
id: string;
|
|
41
|
+
size: {
|
|
42
|
+
height: number;
|
|
43
|
+
width: number;
|
|
44
|
+
};
|
|
45
|
+
text: string;
|
|
46
|
+
position: [number, number];
|
|
47
|
+
}[];
|
|
48
|
+
pathType: import('../../store/types').EdgePathType;
|
|
49
|
+
startAnchor: {
|
|
50
|
+
mode: import('../../store/types').EdgeAnchorMode;
|
|
51
|
+
position: [number, number] | undefined;
|
|
52
|
+
};
|
|
53
|
+
endAnchor: {
|
|
54
|
+
mode: import('../../store/types').EdgeAnchorMode;
|
|
55
|
+
position: [number, number] | undefined;
|
|
56
|
+
};
|
|
57
|
+
steps: import('../../store/elements/EdgePoint').TSerializedEdgePoint[];
|
|
58
|
+
stroke: string | undefined;
|
|
59
|
+
strokeWidth: number | undefined;
|
|
60
|
+
to: string;
|
|
61
|
+
toParentId: string;
|
|
62
|
+
class: string;
|
|
63
|
+
};
|
|
64
|
+
/** Restores BPMN routing before applying independently persisted execution data. */
|
|
65
|
+
deserialize(state: ReturnType<this["serialize"]>): void;
|
|
66
|
+
}
|
|
67
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DiagramExtension } from '../../store/extensions/DiagramExtension';
|
|
2
|
+
/** Contributes floating execution badges without adding a second inspector panel. */
|
|
3
|
+
export declare class BPMNExecutionExtension extends DiagramExtension {
|
|
4
|
+
RenderDiagram: (({ diagram, }: import('../../store/extensions/DiagramExtension').TDiagramExtensionRenderProps<BPMNExecutionExtension>) => import("react").JSX.Element) & {
|
|
5
|
+
displayName: string;
|
|
6
|
+
};
|
|
7
|
+
/** Initializes the visual execution layer without changing BPMN modeler behavior. */
|
|
8
|
+
init(): void;
|
|
9
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { BPMNExecutionMarkerKind, BPMNExecutionMarkerSnapshot } from './types';
|
|
2
|
+
/** Models one independently extensible badge floating over a BPMN execution node. */
|
|
3
|
+
export declare class BPMNExecutionMarker {
|
|
4
|
+
readonly id: string;
|
|
5
|
+
kind: BPMNExecutionMarkerKind;
|
|
6
|
+
value: number | string | null;
|
|
7
|
+
message: string;
|
|
8
|
+
color: string | null;
|
|
9
|
+
constructor(snapshot: BPMNExecutionMarkerSnapshot);
|
|
10
|
+
/** Produces the stable persistence representation of this floating marker. */
|
|
11
|
+
serialize(): BPMNExecutionMarkerSnapshot;
|
|
12
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { BPMNExecutionMarker } from './BPMNExecutionMarker';
|
|
2
|
+
import { BPMNExecutionStatus, BPMNNodeExecutionSnapshot } from './types';
|
|
3
|
+
/** Owns runtime-only status and floating markers for one executable BPMN node. */
|
|
4
|
+
export declare class BPMNNodeExecutionState {
|
|
5
|
+
private currentStatus;
|
|
6
|
+
private activeTokenCount;
|
|
7
|
+
private errorMessage;
|
|
8
|
+
markers: BPMNExecutionMarker[];
|
|
9
|
+
constructor(snapshot?: BPMNNodeExecutionSnapshot);
|
|
10
|
+
get status(): BPMNExecutionStatus;
|
|
11
|
+
set status(status: BPMNExecutionStatus);
|
|
12
|
+
get tokenCount(): number;
|
|
13
|
+
get error(): string;
|
|
14
|
+
/** Changes runtime status and synchronizes its single canonical floating marker. */
|
|
15
|
+
setStatus(status: BPMNExecutionStatus): void;
|
|
16
|
+
/** Replaces the token badge while normalizing invalid or negative counts to zero. */
|
|
17
|
+
setTokenCount(tokenCount: number): void;
|
|
18
|
+
/** Replaces the exception badge while preserving the supplied diagnostic message. */
|
|
19
|
+
setError(message: string | null): void;
|
|
20
|
+
/** Applies a complete node snapshot and rebuilds canonical and custom markers. */
|
|
21
|
+
apply(snapshot?: BPMNNodeExecutionSnapshot): void;
|
|
22
|
+
/** Clears every operational value without modifying the underlying BPMN semantics. */
|
|
23
|
+
reset(): void;
|
|
24
|
+
/** Serializes runtime status together with canonical and extensible floating badges. */
|
|
25
|
+
serialize(): BPMNNodeExecutionSnapshot;
|
|
26
|
+
private synchronizeStatusMarker;
|
|
27
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Node } from '../../store/elements/Node';
|
|
2
|
+
import { BPMNNodeExecutionState } from './BPMNNodeExecutionState';
|
|
3
|
+
export type BPMNExecutionNode = Node & {
|
|
4
|
+
execution: BPMNNodeExecutionState;
|
|
5
|
+
};
|
|
6
|
+
/** Narrows promoted or directly constructed nodes to the execution-node contract. */
|
|
7
|
+
export declare function isBPMNExecutionNode(node: Node): node is BPMNExecutionNode;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { BlackBoxPoolNode } from '../../bpmn/nodes/BlackBoxPoolNode';
|
|
2
|
+
import { BPMNNodeExecutionState } from '../BPMNNodeExecutionState';
|
|
3
|
+
import { BPMNNodeExecutionSnapshot } from '../types';
|
|
4
|
+
/** Extends a standard BPMN black-box participant with execution metadata support. */
|
|
5
|
+
export declare class BPMNExecutionBlackBoxPoolNode extends BlackBoxPoolNode {
|
|
6
|
+
execution: BPMNNodeExecutionState;
|
|
7
|
+
constructor(parent: ConstructorParameters<typeof BlackBoxPoolNode>[0], state: ConstructorParameters<typeof BlackBoxPoolNode>[1] & {
|
|
8
|
+
execution?: BPMNNodeExecutionSnapshot;
|
|
9
|
+
});
|
|
10
|
+
/** Serializes execution metadata together with the hidden-participant model. */
|
|
11
|
+
serialize(): {
|
|
12
|
+
execution: BPMNNodeExecutionSnapshot;
|
|
13
|
+
box: [number, number, number, number];
|
|
14
|
+
id: string;
|
|
15
|
+
label: string;
|
|
16
|
+
movable: boolean | undefined;
|
|
17
|
+
selectable: boolean | undefined;
|
|
18
|
+
selected: boolean | undefined;
|
|
19
|
+
gateways: {
|
|
20
|
+
coordinates: [number, number];
|
|
21
|
+
fill: string | undefined;
|
|
22
|
+
id: string;
|
|
23
|
+
orientation: import('../../../store/types').TOrientation;
|
|
24
|
+
radius: number;
|
|
25
|
+
stroke: string | undefined;
|
|
26
|
+
strokeWidth: number;
|
|
27
|
+
outEdges: {
|
|
28
|
+
arrowHeadEnd: import('../../../store/types').EdgeArrowHead | undefined;
|
|
29
|
+
arrowHeadStart: import('../../../store/types').EdgeArrowHead | undefined;
|
|
30
|
+
displacementEnd: [number, number] | undefined;
|
|
31
|
+
displacementStart: [number, number] | undefined;
|
|
32
|
+
lineStyle: import('../../../store/types').EdgeLineStyle | undefined;
|
|
33
|
+
labels: {
|
|
34
|
+
alignment: "right" | "left" | "center";
|
|
35
|
+
id: string;
|
|
36
|
+
size: {
|
|
37
|
+
height: number;
|
|
38
|
+
width: number;
|
|
39
|
+
};
|
|
40
|
+
text: string;
|
|
41
|
+
position: [number, number];
|
|
42
|
+
}[];
|
|
43
|
+
pathType: import('../../../store/types').EdgePathType;
|
|
44
|
+
startAnchor: {
|
|
45
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
46
|
+
position: [number, number] | undefined;
|
|
47
|
+
};
|
|
48
|
+
endAnchor: {
|
|
49
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
50
|
+
position: [number, number] | undefined;
|
|
51
|
+
};
|
|
52
|
+
steps: import('../../../store/elements/EdgePoint').TSerializedEdgePoint[];
|
|
53
|
+
stroke: string | undefined;
|
|
54
|
+
strokeWidth: number | undefined;
|
|
55
|
+
to: string;
|
|
56
|
+
toParentId: string;
|
|
57
|
+
class: string;
|
|
58
|
+
}[];
|
|
59
|
+
class: string;
|
|
60
|
+
}[];
|
|
61
|
+
fill: string | undefined;
|
|
62
|
+
labelFontSize: number | undefined;
|
|
63
|
+
labelOffset: [number, number] | undefined;
|
|
64
|
+
stroke: string | undefined;
|
|
65
|
+
strokewWidth: number | undefined;
|
|
66
|
+
class: string;
|
|
67
|
+
};
|
|
68
|
+
/** Restores participant state before applying independently stored execution data. */
|
|
69
|
+
deserialize(state: ReturnType<this["serialize"]>): void;
|
|
70
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { DataStoreNode } from '../../bpmn/nodes/DataStoreNode';
|
|
2
|
+
import { BPMNNodeExecutionState } from '../BPMNNodeExecutionState';
|
|
3
|
+
import { BPMNNodeExecutionSnapshot } from '../types';
|
|
4
|
+
/** Extends a standard BPMN data store with optional execution metadata support. */
|
|
5
|
+
export declare class BPMNExecutionDataStoreNode extends DataStoreNode {
|
|
6
|
+
execution: BPMNNodeExecutionState;
|
|
7
|
+
constructor(parent: ConstructorParameters<typeof DataStoreNode>[0], state: ConstructorParameters<typeof DataStoreNode>[1] & {
|
|
8
|
+
execution?: BPMNNodeExecutionSnapshot;
|
|
9
|
+
});
|
|
10
|
+
/** Serializes optional execution metadata beside normal data-store semantics. */
|
|
11
|
+
serialize(): {
|
|
12
|
+
execution: BPMNNodeExecutionSnapshot;
|
|
13
|
+
box: [number, number, number, number];
|
|
14
|
+
id: string;
|
|
15
|
+
label: string;
|
|
16
|
+
movable: boolean | undefined;
|
|
17
|
+
selectable: boolean | undefined;
|
|
18
|
+
selected: boolean | undefined;
|
|
19
|
+
gateways: {
|
|
20
|
+
coordinates: [number, number];
|
|
21
|
+
fill: string | undefined;
|
|
22
|
+
id: string;
|
|
23
|
+
orientation: import('../../../store/types').TOrientation;
|
|
24
|
+
radius: number;
|
|
25
|
+
stroke: string | undefined;
|
|
26
|
+
strokeWidth: number;
|
|
27
|
+
outEdges: {
|
|
28
|
+
arrowHeadEnd: import('../../../store/types').EdgeArrowHead | undefined;
|
|
29
|
+
arrowHeadStart: import('../../../store/types').EdgeArrowHead | undefined;
|
|
30
|
+
displacementEnd: [number, number] | undefined;
|
|
31
|
+
displacementStart: [number, number] | undefined;
|
|
32
|
+
lineStyle: import('../../../store/types').EdgeLineStyle | undefined;
|
|
33
|
+
labels: {
|
|
34
|
+
alignment: "right" | "left" | "center";
|
|
35
|
+
id: string;
|
|
36
|
+
size: {
|
|
37
|
+
height: number;
|
|
38
|
+
width: number;
|
|
39
|
+
};
|
|
40
|
+
text: string;
|
|
41
|
+
position: [number, number];
|
|
42
|
+
}[];
|
|
43
|
+
pathType: import('../../../store/types').EdgePathType;
|
|
44
|
+
startAnchor: {
|
|
45
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
46
|
+
position: [number, number] | undefined;
|
|
47
|
+
};
|
|
48
|
+
endAnchor: {
|
|
49
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
50
|
+
position: [number, number] | undefined;
|
|
51
|
+
};
|
|
52
|
+
steps: import('../../../store/elements/EdgePoint').TSerializedEdgePoint[];
|
|
53
|
+
stroke: string | undefined;
|
|
54
|
+
strokeWidth: number | undefined;
|
|
55
|
+
to: string;
|
|
56
|
+
toParentId: string;
|
|
57
|
+
class: string;
|
|
58
|
+
}[];
|
|
59
|
+
class: string;
|
|
60
|
+
}[];
|
|
61
|
+
fill: string | undefined;
|
|
62
|
+
labelFontSize: number | undefined;
|
|
63
|
+
labelOffset: [number, number] | undefined;
|
|
64
|
+
stroke: string | undefined;
|
|
65
|
+
strokewWidth: number | undefined;
|
|
66
|
+
class: string;
|
|
67
|
+
};
|
|
68
|
+
/** Restores data-store state before applying independent execution metadata. */
|
|
69
|
+
deserialize(state: ReturnType<this["serialize"]>): void;
|
|
70
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { DocumentAnnotationNode } from '../../bpmn/nodes/DocumentAnnotationNode';
|
|
2
|
+
import { BPMNNodeExecutionState } from '../BPMNNodeExecutionState';
|
|
3
|
+
import { BPMNNodeExecutionSnapshot } from '../types';
|
|
4
|
+
/** Extends a BPMN document annotation without changing its resizing or text behavior. */
|
|
5
|
+
export declare class BPMNExecutionDocumentAnnotationNode extends DocumentAnnotationNode {
|
|
6
|
+
execution: BPMNNodeExecutionState;
|
|
7
|
+
constructor(parent: ConstructorParameters<typeof DocumentAnnotationNode>[0], state: ConstructorParameters<typeof DocumentAnnotationNode>[1] & {
|
|
8
|
+
execution?: BPMNNodeExecutionSnapshot;
|
|
9
|
+
});
|
|
10
|
+
/** Serializes optional execution metadata beside document-annotation state. */
|
|
11
|
+
serialize(): {
|
|
12
|
+
execution: BPMNNodeExecutionSnapshot;
|
|
13
|
+
box: [number, number, number, number];
|
|
14
|
+
id: string;
|
|
15
|
+
label: string;
|
|
16
|
+
movable: boolean | undefined;
|
|
17
|
+
selectable: boolean | undefined;
|
|
18
|
+
selected: boolean | undefined;
|
|
19
|
+
gateways: {
|
|
20
|
+
coordinates: [number, number];
|
|
21
|
+
fill: string | undefined;
|
|
22
|
+
id: string;
|
|
23
|
+
orientation: import('../../../store/types').TOrientation;
|
|
24
|
+
radius: number;
|
|
25
|
+
stroke: string | undefined;
|
|
26
|
+
strokeWidth: number;
|
|
27
|
+
outEdges: {
|
|
28
|
+
arrowHeadEnd: import('../../../store/types').EdgeArrowHead | undefined;
|
|
29
|
+
arrowHeadStart: import('../../../store/types').EdgeArrowHead | undefined;
|
|
30
|
+
displacementEnd: [number, number] | undefined;
|
|
31
|
+
displacementStart: [number, number] | undefined;
|
|
32
|
+
lineStyle: import('../../../store/types').EdgeLineStyle | undefined;
|
|
33
|
+
labels: {
|
|
34
|
+
alignment: "right" | "left" | "center";
|
|
35
|
+
id: string;
|
|
36
|
+
size: {
|
|
37
|
+
height: number;
|
|
38
|
+
width: number;
|
|
39
|
+
};
|
|
40
|
+
text: string;
|
|
41
|
+
position: [number, number];
|
|
42
|
+
}[];
|
|
43
|
+
pathType: import('../../../store/types').EdgePathType;
|
|
44
|
+
startAnchor: {
|
|
45
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
46
|
+
position: [number, number] | undefined;
|
|
47
|
+
};
|
|
48
|
+
endAnchor: {
|
|
49
|
+
mode: import('../../../store/types').EdgeAnchorMode;
|
|
50
|
+
position: [number, number] | undefined;
|
|
51
|
+
};
|
|
52
|
+
steps: import('../../../store/elements/EdgePoint').TSerializedEdgePoint[];
|
|
53
|
+
stroke: string | undefined;
|
|
54
|
+
strokeWidth: number | undefined;
|
|
55
|
+
to: string;
|
|
56
|
+
toParentId: string;
|
|
57
|
+
class: string;
|
|
58
|
+
}[];
|
|
59
|
+
class: string;
|
|
60
|
+
}[];
|
|
61
|
+
fill: string | undefined;
|
|
62
|
+
labelFontSize: number | undefined;
|
|
63
|
+
labelOffset: [number, number] | undefined;
|
|
64
|
+
stroke: string | undefined;
|
|
65
|
+
strokewWidth: number | undefined;
|
|
66
|
+
class: string;
|
|
67
|
+
};
|
|
68
|
+
/** Restores annotation state before applying independent execution metadata. */
|
|
69
|
+
deserialize(state: ReturnType<this["serialize"]>): void;
|
|
70
|
+
}
|