@openplanr/protocol 0.6.1 → 0.6.2
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/dashboard/closed-json-contract.mjs +99 -109
- package/lib/dashboard/operate-experience-audit-display-contract.d.mts +128 -153
- package/lib/dashboard/operate-experience-audit-display-contract.mjs +530 -585
- package/lib/dashboard/operate-experience-display-contract.d.mts +415 -437
- package/lib/dashboard/operate-experience-display-contract.mjs +768 -831
- package/lib/dashboard/operate-experience-surface-contract.d.mts +143 -148
- package/lib/dashboard/operate-experience-surface-contract.mjs +72 -73
- package/lib/dashboard/operate-review-contract.d.mts +7 -14
- package/lib/dashboard/operate-review-contract.mjs +46 -42
- package/lib/dashboard/operate-review-display-workspace-contract.d.mts +2 -5
- package/lib/dashboard/operate-review-display-workspace-contract.mjs +158 -104
- package/lib/dashboard/operate-review-payload-safety.mjs +4 -2
- package/lib/dashboard/operate-review-workspace-projection-v2.d.mts +47 -33
- package/lib/protocol/index.d.ts +2647 -543
- package/package.json +1 -1
- package/registries/commands.json +3 -3
- package/registries/skills.json +5 -5
- package/src/browser-contracts.d.mts +4 -1
- package/src/browser-contracts.mjs +16 -5
- package/src/canonical-json.d.mts +3 -1
- package/src/canonical-json.mjs +57 -20
- package/src/compat/live-evidence-v2.mjs +1604 -485
- package/src/compat/operate-experience-live-patch.mjs +67 -15
- package/src/compat/operating-planning-contracts.mjs +183 -51
- package/src/contracts.d.mts +54 -13
- package/src/contracts.mjs +625 -335
- package/src/design-contracts.mjs +58 -21
- package/src/design-handoff-contracts.d.mts +67 -11
- package/src/design-handoff-contracts.mjs +243 -98
- package/src/design-publication-contracts.mjs +98 -33
- package/src/diagram-authoring-contracts.d.mts +422 -78
- package/src/diagram-authoring-contracts.mjs +1697 -326
- package/src/diagram-contracts.d.mts +4 -1
- package/src/diagram-contracts.mjs +16 -4
- package/src/enterprise-contracts.d.mts +211 -46
- package/src/enterprise-contracts.mjs +727 -175
- package/src/errors.mjs +4 -0
- package/src/generated/canonical-registries.mjs +8 -8
- package/src/index.d.mts +8 -8
- package/src/index.mjs +36 -20
- package/src/json-schema.d.mts +21 -6
- package/src/json-schema.mjs +66 -18
- package/src/planning-contracts.d.mts +8 -2
- package/src/planning-contracts.mjs +33 -7
- package/src/registries.d.mts +11 -3
- package/src/registries.mjs +369 -87
- package/src/review-experience-contracts.d.mts +7 -2
- package/src/review-experience-contracts.mjs +198 -49
- package/src/semver.mjs +5 -1
- package/src/skill-source-contracts.d.mts +36 -16
- package/src/skill-source-contracts.mjs +25 -6
- package/src/task-contracts.d.mts +13 -3
- package/src/task-contracts.mjs +181 -40
- package/src/workspace-contracts.d.mts +38 -10
- package/src/workspace-contracts.mjs +147 -33
|
@@ -1,112 +1,456 @@
|
|
|
1
1
|
export type DiagramAuthoringDigest = `sha256:${string}`;
|
|
2
2
|
export type DiagramAuthoringProfile = 'flowchart' | 'process' | 'swimlane' | 'architecture';
|
|
3
|
-
export type DiagramAuthoringNodeKind =
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
export type DiagramAuthoringNodeKind =
|
|
4
|
+
| 'process'
|
|
5
|
+
| 'start'
|
|
6
|
+
| 'end'
|
|
7
|
+
| 'decision'
|
|
8
|
+
| 'data-store'
|
|
9
|
+
| 'component';
|
|
10
|
+
export type DiagramAuthoringRelationKind =
|
|
11
|
+
| 'association'
|
|
12
|
+
| 'dependency'
|
|
13
|
+
| 'flow'
|
|
14
|
+
| 'message'
|
|
15
|
+
| 'transition';
|
|
16
|
+
export type DiagramAuthoringContractKind =
|
|
17
|
+
| 'diagram-document'
|
|
18
|
+
| 'diagram-presentation'
|
|
19
|
+
| 'diagram-authoring-bundle'
|
|
20
|
+
| 'diagram-edit-transaction'
|
|
21
|
+
| 'diagram-source-map'
|
|
22
|
+
| 'diagram-fidelity-report'
|
|
23
|
+
| 'diagram-manifest'
|
|
24
|
+
| 'diagram-change-proposal'
|
|
25
|
+
| 'diagram-publication-state'
|
|
26
|
+
| 'diagram-authoring-capabilities';
|
|
27
|
+
export type DiagramEditOperationClass =
|
|
28
|
+
| 'insert-elements'
|
|
29
|
+
| 'update-semantics'
|
|
30
|
+
| 'remove-elements'
|
|
31
|
+
| 'set-membership-order'
|
|
32
|
+
| 'set-geometry'
|
|
33
|
+
| 'set-appearance-locks';
|
|
7
34
|
export type DiagramAuthoringSchema = Readonly<Record<string, unknown>>;
|
|
8
|
-
export interface DiagramAuthoringValidationError {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
export interface
|
|
14
|
-
|
|
35
|
+
export interface DiagramAuthoringValidationError {
|
|
36
|
+
path: string;
|
|
37
|
+
rule: string;
|
|
38
|
+
detail: string;
|
|
39
|
+
}
|
|
40
|
+
export interface DiagramAuthoringEnvelope<K extends string> {
|
|
41
|
+
kind: K;
|
|
42
|
+
schemaVersion: '1.0.0';
|
|
43
|
+
protocolVersion: '1.13.0';
|
|
44
|
+
}
|
|
45
|
+
export interface DiagramAuthoringNode {
|
|
46
|
+
id: string;
|
|
47
|
+
label: string;
|
|
48
|
+
kind: DiagramAuthoringNodeKind;
|
|
49
|
+
description: string | null;
|
|
50
|
+
}
|
|
51
|
+
export interface DiagramAuthoringRelation {
|
|
52
|
+
id: string;
|
|
53
|
+
from: string;
|
|
54
|
+
to: string;
|
|
55
|
+
kind: DiagramAuthoringRelationKind;
|
|
56
|
+
direction: 'forward' | 'both' | 'none';
|
|
57
|
+
label: string | null;
|
|
58
|
+
weight: number | null;
|
|
59
|
+
}
|
|
60
|
+
export interface DiagramAuthoringContainer {
|
|
61
|
+
id: string;
|
|
62
|
+
label: string;
|
|
63
|
+
members: string[];
|
|
64
|
+
}
|
|
65
|
+
export interface DiagramAuthoringAnnotation {
|
|
66
|
+
id: string;
|
|
67
|
+
text: string;
|
|
68
|
+
targetId: string | null;
|
|
69
|
+
}
|
|
70
|
+
export interface DiagramAuthoringAccessibility {
|
|
71
|
+
title: string;
|
|
72
|
+
description: string;
|
|
73
|
+
readingOrder: string[];
|
|
74
|
+
}
|
|
15
75
|
export interface DiagramAuthoringDocument extends DiagramAuthoringEnvelope<'planr-diagram'> {
|
|
16
|
-
diagramId: string;
|
|
76
|
+
diagramId: string;
|
|
77
|
+
title: string;
|
|
78
|
+
summary: string;
|
|
79
|
+
audience: 'engineer' | 'executive' | 'mixed';
|
|
17
80
|
grammar: { id: DiagramAuthoringProfile; version: '1.0.0' };
|
|
18
|
-
nodes: DiagramAuthoringNode[];
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
81
|
+
nodes: DiagramAuthoringNode[];
|
|
82
|
+
relations: DiagramAuthoringRelation[];
|
|
83
|
+
groups: DiagramAuthoringContainer[];
|
|
84
|
+
lanes: DiagramAuthoringContainer[];
|
|
85
|
+
events: never[];
|
|
86
|
+
series: never[];
|
|
87
|
+
axes: never[];
|
|
88
|
+
sets: never[];
|
|
89
|
+
annotations: DiagramAuthoringAnnotation[];
|
|
90
|
+
emphasis: Array<{ targetId: string; level: 'primary' | 'secondary' | 'muted' }>;
|
|
91
|
+
laneOrder: string[];
|
|
92
|
+
accessibility: DiagramAuthoringAccessibility;
|
|
93
|
+
documentDigest: DiagramAuthoringDigest;
|
|
94
|
+
}
|
|
95
|
+
export interface DiagramBounds {
|
|
96
|
+
x: number;
|
|
97
|
+
y: number;
|
|
98
|
+
width: number;
|
|
99
|
+
height: number;
|
|
100
|
+
}
|
|
101
|
+
export interface DiagramBoundaryAttachment {
|
|
102
|
+
side: 'top' | 'right' | 'bottom' | 'left';
|
|
103
|
+
offset: number;
|
|
104
|
+
}
|
|
105
|
+
export interface DiagramRoute {
|
|
106
|
+
mode: 'automatic' | 'manual';
|
|
107
|
+
strategy: 'straight' | 'orthogonal';
|
|
108
|
+
from: DiagramBoundaryAttachment;
|
|
109
|
+
to: DiagramBoundaryAttachment;
|
|
110
|
+
points: Array<{ x: number; y: number }>;
|
|
111
|
+
}
|
|
26
112
|
export interface DiagramAppearance {
|
|
27
|
-
shape:
|
|
113
|
+
shape:
|
|
114
|
+
| 'rectangle'
|
|
115
|
+
| 'rounded-rectangle'
|
|
116
|
+
| 'ellipse'
|
|
117
|
+
| 'diamond'
|
|
118
|
+
| 'cylinder'
|
|
119
|
+
| 'text'
|
|
120
|
+
| 'container'
|
|
121
|
+
| 'connector';
|
|
28
122
|
fill: 'surface' | 'accent' | 'success' | 'warning' | 'danger' | 'transparent';
|
|
29
|
-
stroke: 'default' | 'accent' | 'muted' | 'danger' | 'none';
|
|
30
|
-
|
|
123
|
+
stroke: 'default' | 'accent' | 'muted' | 'danger' | 'none';
|
|
124
|
+
strokeWidth: number;
|
|
125
|
+
strokeStyle: 'solid' | 'dashed' | 'dotted';
|
|
126
|
+
fontSize: number;
|
|
127
|
+
textAlign: 'left' | 'center' | 'right';
|
|
128
|
+
}
|
|
129
|
+
export interface DiagramGeometryLocks {
|
|
130
|
+
position: boolean;
|
|
131
|
+
size: boolean;
|
|
132
|
+
route: boolean;
|
|
133
|
+
}
|
|
134
|
+
export interface DiagramGeometry {
|
|
135
|
+
bounds: DiagramBounds | null;
|
|
136
|
+
route: DiagramRoute | null;
|
|
137
|
+
label: { x: number; y: number; width: number } | null;
|
|
138
|
+
zIndex: number;
|
|
139
|
+
}
|
|
140
|
+
export interface DiagramPlacement extends DiagramGeometry {
|
|
141
|
+
elementId: string;
|
|
142
|
+
appearance: DiagramAppearance;
|
|
143
|
+
locks: DiagramGeometryLocks;
|
|
31
144
|
}
|
|
32
|
-
export interface DiagramGeometryLocks { position: boolean; size: boolean; route: boolean }
|
|
33
|
-
export interface DiagramGeometry { bounds: DiagramBounds | null; route: DiagramRoute | null; label: { x: number; y: number; width: number } | null; zIndex: number }
|
|
34
|
-
export interface DiagramPlacement extends DiagramGeometry { elementId: string; appearance: DiagramAppearance; locks: DiagramGeometryLocks }
|
|
35
145
|
export interface DiagramPresentation extends DiagramAuthoringEnvelope<'diagram-presentation'> {
|
|
36
|
-
diagramId: string;
|
|
37
|
-
|
|
146
|
+
diagramId: string;
|
|
147
|
+
semanticDigest: DiagramAuthoringDigest;
|
|
148
|
+
coordinateSystem: 'global-canvas';
|
|
149
|
+
layout: {
|
|
150
|
+
direction: 'top-down' | 'left-right' | 'right-left' | 'bottom-up';
|
|
151
|
+
detailTier: 'simplified' | 'balanced' | 'faithful';
|
|
152
|
+
};
|
|
38
153
|
theme: { themeId: 'paper' | 'slate' | 'midnight'; mode: 'light' | 'dark' | 'auto' };
|
|
39
|
-
elements: DiagramPlacement[];
|
|
154
|
+
elements: DiagramPlacement[];
|
|
155
|
+
presentationDigest: DiagramAuthoringDigest;
|
|
156
|
+
}
|
|
157
|
+
export interface DiagramAuthoringSnapshot {
|
|
158
|
+
bundleDigest: DiagramAuthoringDigest;
|
|
159
|
+
semanticDigest: DiagramAuthoringDigest;
|
|
160
|
+
presentationDigest: DiagramAuthoringDigest;
|
|
40
161
|
}
|
|
41
|
-
export interface DiagramAuthoringSnapshot { bundleDigest: DiagramAuthoringDigest; semanticDigest: DiagramAuthoringDigest; presentationDigest: DiagramAuthoringDigest }
|
|
42
162
|
export interface DiagramSourceMap extends DiagramAuthoringEnvelope<'diagram-source-map'> {
|
|
43
|
-
diagramId: string;
|
|
44
|
-
|
|
45
|
-
|
|
163
|
+
diagramId: string;
|
|
164
|
+
semanticDigest: DiagramAuthoringDigest;
|
|
165
|
+
sourceDigest: DiagramAuthoringDigest;
|
|
166
|
+
sourceByteLength: number;
|
|
167
|
+
encoding: 'utf-8';
|
|
168
|
+
parser: { id: string; version: string };
|
|
169
|
+
certificationVersion: 'flowchart-copy-v1';
|
|
170
|
+
entries: Array<{
|
|
171
|
+
sourceId: string | null;
|
|
172
|
+
elementIds: string[];
|
|
173
|
+
range: { startByte: number; endByte: number } | null;
|
|
174
|
+
construct: string;
|
|
175
|
+
confidence: 'exact' | 'ambiguous';
|
|
176
|
+
losses: string[];
|
|
177
|
+
}>;
|
|
46
178
|
}
|
|
47
|
-
export interface DiagramAuthoringBundle
|
|
48
|
-
|
|
179
|
+
export interface DiagramAuthoringBundle
|
|
180
|
+
extends DiagramAuthoringEnvelope<'diagram-authoring-bundle'> {
|
|
181
|
+
diagramId: string;
|
|
182
|
+
document: DiagramAuthoringDocument;
|
|
183
|
+
presentation: DiagramPresentation;
|
|
49
184
|
originalSource: { format: 'mermaid'; text: string; sourceDigest: DiagramAuthoringDigest } | null;
|
|
50
|
-
sourceMap: DiagramSourceMap | null;
|
|
185
|
+
sourceMap: DiagramSourceMap | null;
|
|
186
|
+
bundleDigest: DiagramAuthoringDigest;
|
|
51
187
|
}
|
|
52
188
|
export type DiagramSemanticEntry =
|
|
53
189
|
| { collection: 'nodes'; value: DiagramAuthoringNode }
|
|
54
190
|
| { collection: 'relations'; value: DiagramAuthoringRelation }
|
|
55
191
|
| { collection: 'groups' | 'lanes'; value: DiagramAuthoringContainer }
|
|
56
192
|
| { collection: 'annotations'; value: DiagramAuthoringAnnotation };
|
|
57
|
-
export interface DiagramMembershipState {
|
|
193
|
+
export interface DiagramMembershipState {
|
|
194
|
+
groups: Array<{ id: string; members: string[] }>;
|
|
195
|
+
lanes: Array<{ id: string; members: string[] }>;
|
|
196
|
+
laneOrder: string[];
|
|
197
|
+
}
|
|
58
198
|
export type DiagramSemanticUpdate =
|
|
59
|
-
| {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
199
|
+
| {
|
|
200
|
+
type: 'update-semantics';
|
|
201
|
+
collection: 'nodes';
|
|
202
|
+
elementId: string;
|
|
203
|
+
before: Omit<DiagramAuthoringNode, 'id'>;
|
|
204
|
+
after: Omit<DiagramAuthoringNode, 'id'>;
|
|
205
|
+
}
|
|
206
|
+
| {
|
|
207
|
+
type: 'update-semantics';
|
|
208
|
+
collection: 'relations';
|
|
209
|
+
elementId: string;
|
|
210
|
+
before: Omit<DiagramAuthoringRelation, 'id'>;
|
|
211
|
+
after: Omit<DiagramAuthoringRelation, 'id'>;
|
|
212
|
+
}
|
|
213
|
+
| {
|
|
214
|
+
type: 'update-semantics';
|
|
215
|
+
collection: 'groups' | 'lanes';
|
|
216
|
+
elementId: string;
|
|
217
|
+
before: { label: string };
|
|
218
|
+
after: { label: string };
|
|
219
|
+
}
|
|
220
|
+
| {
|
|
221
|
+
type: 'update-semantics';
|
|
222
|
+
collection: 'annotations';
|
|
223
|
+
elementId: string;
|
|
224
|
+
before: Omit<DiagramAuthoringAnnotation, 'id'>;
|
|
225
|
+
after: Omit<DiagramAuthoringAnnotation, 'id'>;
|
|
226
|
+
}
|
|
227
|
+
| {
|
|
228
|
+
type: 'update-semantics';
|
|
229
|
+
collection: 'emphasis';
|
|
230
|
+
elementId: string;
|
|
231
|
+
before: 'primary' | 'secondary' | 'muted' | null;
|
|
232
|
+
after: 'primary' | 'secondary' | 'muted' | null;
|
|
233
|
+
index?: number;
|
|
234
|
+
}
|
|
235
|
+
| {
|
|
236
|
+
type: 'update-semantics';
|
|
237
|
+
collection: 'document';
|
|
238
|
+
before: Pick<DiagramAuthoringDocument, 'title' | 'summary' | 'audience' | 'accessibility'>;
|
|
239
|
+
after: Pick<DiagramAuthoringDocument, 'title' | 'summary' | 'audience' | 'accessibility'>;
|
|
240
|
+
}
|
|
241
|
+
| {
|
|
242
|
+
type: 'update-semantics';
|
|
243
|
+
collection: 'source-map';
|
|
244
|
+
before: DiagramSourceMap | null;
|
|
245
|
+
after: DiagramSourceMap | null;
|
|
246
|
+
};
|
|
66
247
|
export type DiagramEditOperation =
|
|
67
|
-
| {
|
|
248
|
+
| {
|
|
249
|
+
type: 'insert-elements';
|
|
250
|
+
elements: DiagramSemanticEntry[];
|
|
251
|
+
presentation: DiagramPlacement[];
|
|
252
|
+
positions?: Array<{ elementId: string; semanticIndex: number; presentationIndex: number }>;
|
|
253
|
+
}
|
|
68
254
|
| { type: 'remove-elements'; elements: DiagramSemanticEntry[]; presentation: DiagramPlacement[] }
|
|
69
255
|
| DiagramSemanticUpdate
|
|
70
256
|
| { type: 'set-membership-order'; before: DiagramMembershipState; after: DiagramMembershipState }
|
|
71
|
-
| {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
257
|
+
| {
|
|
258
|
+
type: 'set-geometry';
|
|
259
|
+
changes: Array<{ elementId: string; before: DiagramGeometry; after: DiagramGeometry }>;
|
|
260
|
+
}
|
|
261
|
+
| {
|
|
262
|
+
type: 'set-appearance-locks';
|
|
263
|
+
changes: Array<{
|
|
264
|
+
elementId: string;
|
|
265
|
+
before: { appearance: DiagramAppearance; locks: DiagramGeometryLocks };
|
|
266
|
+
after: { appearance: DiagramAppearance; locks: DiagramGeometryLocks };
|
|
267
|
+
}>;
|
|
268
|
+
};
|
|
269
|
+
export interface DiagramEditTransaction
|
|
270
|
+
extends DiagramAuthoringEnvelope<'diagram-edit-transaction'> {
|
|
271
|
+
transactionId: string;
|
|
272
|
+
diagramId: string;
|
|
273
|
+
base: DiagramAuthoringSnapshot;
|
|
274
|
+
operations: DiagramEditOperation[];
|
|
275
|
+
undoOf: string | null;
|
|
276
|
+
}
|
|
277
|
+
export interface DiagramChangeProposal extends DiagramAuthoringEnvelope<'diagram-change-proposal'> {
|
|
278
|
+
proposalId: string;
|
|
279
|
+
diagramId: string;
|
|
280
|
+
base: DiagramAuthoringSnapshot;
|
|
281
|
+
transaction: DiagramEditTransaction;
|
|
282
|
+
summary: string;
|
|
283
|
+
author: { kind: 'human' | 'agent'; id: string };
|
|
284
|
+
status: 'proposed' | 'accepted' | 'rejected' | 'stale';
|
|
285
|
+
}
|
|
286
|
+
export interface DiagramPublicationState
|
|
287
|
+
extends DiagramAuthoringEnvelope<'diagram-publication-state'> {
|
|
288
|
+
diagramId: string;
|
|
289
|
+
draft: DiagramAuthoringSnapshot | null;
|
|
290
|
+
published: DiagramAuthoringSnapshot | null;
|
|
291
|
+
audience: 'private' | 'company' | 'public';
|
|
292
|
+
capabilitySemantics: 'descriptive-only-requires-host-authorization';
|
|
293
|
+
}
|
|
76
294
|
export type DiagramFidelity = 'lossless' | 'partial' | 'unsupported';
|
|
77
|
-
export interface DiagramFidelityReport extends DiagramAuthoringEnvelope<'diagram-fidelity-report'> {
|
|
78
|
-
|
|
79
|
-
|
|
295
|
+
export interface DiagramFidelityReport extends DiagramAuthoringEnvelope<'diagram-fidelity-report'> {
|
|
296
|
+
diagramId: string;
|
|
297
|
+
basis: DiagramAuthoringSnapshot;
|
|
298
|
+
sourceDigest: DiagramAuthoringDigest | null;
|
|
299
|
+
sourceFormat: 'mermaid' | 'planr-diagram-bundle';
|
|
300
|
+
targetFormat: 'mermaid' | 'planr-diagram-bundle' | 'svg' | 'html' | 'png';
|
|
301
|
+
semantic: DiagramFidelity;
|
|
302
|
+
presentation: DiagramFidelity;
|
|
303
|
+
sourceText: DiagramFidelity;
|
|
304
|
+
losses: Array<{
|
|
305
|
+
dimension: 'semantic' | 'presentation' | 'sourceText';
|
|
306
|
+
code: string;
|
|
307
|
+
elementIds: string[];
|
|
308
|
+
message: string;
|
|
309
|
+
}>;
|
|
310
|
+
}
|
|
311
|
+
export interface DiagramAuthoringManifest extends DiagramAuthoringEnvelope<'diagram-manifest'> {
|
|
312
|
+
diagramId: string;
|
|
313
|
+
basis: DiagramAuthoringSnapshot;
|
|
314
|
+
bundle: { path: string; transportDigest: DiagramAuthoringDigest };
|
|
315
|
+
renderer: { id: string; version: string };
|
|
316
|
+
theme?: { id: string; version: string };
|
|
317
|
+
outputs: Array<{
|
|
318
|
+
path: string;
|
|
319
|
+
mediaType: 'image/svg+xml' | 'text/html' | 'image/png';
|
|
320
|
+
transportDigest: DiagramAuthoringDigest;
|
|
321
|
+
fidelity: DiagramFidelityReport;
|
|
322
|
+
}>;
|
|
323
|
+
}
|
|
324
|
+
export interface DiagramMermaidConstructCapability {
|
|
325
|
+
readonly construct: string;
|
|
326
|
+
readonly import: DiagramFidelity;
|
|
327
|
+
readonly export: DiagramFidelity;
|
|
328
|
+
readonly semanticRoundTrip: DiagramFidelity;
|
|
329
|
+
readonly mapping: string;
|
|
330
|
+
}
|
|
80
331
|
export interface DiagramAuthoringCapability {
|
|
81
|
-
readonly grammarId: DiagramAuthoringProfile;
|
|
82
|
-
readonly
|
|
83
|
-
readonly
|
|
332
|
+
readonly grammarId: DiagramAuthoringProfile;
|
|
333
|
+
readonly authoring: true;
|
|
334
|
+
readonly primitives: readonly (
|
|
335
|
+
| 'node'
|
|
336
|
+
| 'relation'
|
|
337
|
+
| 'group'
|
|
338
|
+
| 'lane'
|
|
339
|
+
| 'annotation'
|
|
340
|
+
| 'emphasis'
|
|
341
|
+
)[];
|
|
342
|
+
readonly nodeKinds: readonly DiagramAuthoringNodeKind[];
|
|
343
|
+
readonly relationKinds: readonly DiagramAuthoringRelationKind[];
|
|
84
344
|
readonly operations: readonly DiagramEditOperationClass[];
|
|
85
|
-
readonly mermaid: {
|
|
345
|
+
readonly mermaid: {
|
|
346
|
+
readonly mode: 'copy';
|
|
347
|
+
readonly certificationVersion: 'flowchart-copy-v1';
|
|
348
|
+
readonly constructs: readonly DiagramMermaidConstructCapability[];
|
|
349
|
+
readonly linkedSource: false;
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
export interface DiagramAuthoringCapabilities
|
|
353
|
+
extends DiagramAuthoringEnvelope<'diagram-authoring-capabilities'> {
|
|
354
|
+
readonly version: '1.0.0';
|
|
355
|
+
readonly liveCollaboration: false;
|
|
356
|
+
readonly profiles: readonly DiagramAuthoringCapability[];
|
|
357
|
+
readonly unsupportedGrammars: readonly string[];
|
|
358
|
+
}
|
|
359
|
+
export interface DiagramAuthoringValidationOptions {
|
|
360
|
+
document?: DiagramAuthoringDocument;
|
|
361
|
+
bundle?: DiagramAuthoringBundle;
|
|
362
|
+
baseBundle?: DiagramAuthoringBundle;
|
|
363
|
+
sourceText?: string;
|
|
364
|
+
}
|
|
365
|
+
export interface DiagramLegacyInspection {
|
|
366
|
+
valid: boolean;
|
|
367
|
+
errors: DiagramAuthoringValidationError[];
|
|
368
|
+
diagramId: string | null;
|
|
369
|
+
grammarId: string | null;
|
|
370
|
+
authoringAvailable: boolean;
|
|
371
|
+
requiresDerivedPresentation: boolean;
|
|
372
|
+
unsupportedNodeKinds: string[];
|
|
373
|
+
adoption: 'explicit-save-required';
|
|
374
|
+
sourceModified: false;
|
|
86
375
|
}
|
|
87
|
-
export interface DiagramAuthoringCapabilities extends DiagramAuthoringEnvelope<'diagram-authoring-capabilities'> { readonly version: '1.0.0'; readonly liveCollaboration: false; readonly profiles: readonly DiagramAuthoringCapability[]; readonly unsupportedGrammars: readonly string[] }
|
|
88
|
-
export interface DiagramAuthoringValidationOptions { document?: DiagramAuthoringDocument; bundle?: DiagramAuthoringBundle; baseBundle?: DiagramAuthoringBundle; sourceText?: string }
|
|
89
|
-
export interface DiagramLegacyInspection { valid: boolean; errors: DiagramAuthoringValidationError[]; diagramId: string | null; grammarId: string | null; authoringAvailable: boolean; requiresDerivedPresentation: boolean; unsupportedNodeKinds: string[]; adoption: 'explicit-save-required'; sourceModified: false }
|
|
90
376
|
export declare const DIAGRAM_AUTHORING_PROTOCOL_VERSION: '1.13.0';
|
|
91
377
|
export declare const DIAGRAM_AUTHORING_CONTRACT_VERSION: '1.0.0';
|
|
92
378
|
export declare const DIAGRAM_EDIT_OPERATION_CLASSES: readonly DiagramEditOperationClass[];
|
|
93
|
-
export declare const DIAGRAM_AUTHORING_LIMITS: Readonly<{
|
|
94
|
-
|
|
95
|
-
|
|
379
|
+
export declare const DIAGRAM_AUTHORING_LIMITS: Readonly<{
|
|
380
|
+
depth: 48;
|
|
381
|
+
values: 500000;
|
|
382
|
+
textCodeUnits: 8388608;
|
|
383
|
+
sourceBytes: 1048576;
|
|
384
|
+
elements: 10000;
|
|
385
|
+
operations: 256;
|
|
386
|
+
coordinate: 1000000;
|
|
387
|
+
}>;
|
|
388
|
+
export declare const DIAGRAM_AUTHORING_SCHEMAS: Readonly<
|
|
389
|
+
Record<DiagramAuthoringContractKind, DiagramAuthoringSchema>
|
|
390
|
+
>;
|
|
391
|
+
export declare const DIAGRAM_AUTHORING_CONTRACT_FILES: Readonly<
|
|
392
|
+
Record<DiagramAuthoringContractKind, string>
|
|
393
|
+
>;
|
|
96
394
|
export declare const DIAGRAM_AUTHORING_CAPABILITIES: Readonly<DiagramAuthoringCapabilities>;
|
|
97
|
-
export declare function getDiagramAuthoringCapability(
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
export declare function
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
export declare function
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
export declare function
|
|
110
|
-
|
|
111
|
-
|
|
395
|
+
export declare function getDiagramAuthoringCapability(
|
|
396
|
+
grammarId: string,
|
|
397
|
+
): DiagramAuthoringCapability | null;
|
|
398
|
+
export declare function diagramDocumentDigest(
|
|
399
|
+
value:
|
|
400
|
+
| Omit<DiagramAuthoringDocument, 'documentDigest'>
|
|
401
|
+
| DiagramAuthoringDocument
|
|
402
|
+
| Record<string, unknown>,
|
|
403
|
+
): DiagramAuthoringDigest;
|
|
404
|
+
export declare function diagramPresentationDigest(
|
|
405
|
+
value: Omit<DiagramPresentation, 'presentationDigest'> | DiagramPresentation,
|
|
406
|
+
): DiagramAuthoringDigest;
|
|
407
|
+
export declare function diagramAuthoringBundleDigest(
|
|
408
|
+
value: Omit<DiagramAuthoringBundle, 'bundleDigest'> | DiagramAuthoringBundle,
|
|
409
|
+
): DiagramAuthoringDigest;
|
|
410
|
+
export declare function validateDiagramAuthoringArtifact(
|
|
411
|
+
kind: string,
|
|
412
|
+
value: unknown,
|
|
413
|
+
options?: DiagramAuthoringValidationOptions,
|
|
414
|
+
): DiagramAuthoringValidationError[];
|
|
415
|
+
export declare function assertDiagramAuthoringArtifact<T>(
|
|
416
|
+
kind: DiagramAuthoringContractKind,
|
|
417
|
+
value: T,
|
|
418
|
+
options?: DiagramAuthoringValidationOptions,
|
|
419
|
+
): T;
|
|
420
|
+
export declare function validateDiagramDocument(
|
|
421
|
+
value: unknown,
|
|
422
|
+
options?: DiagramAuthoringValidationOptions,
|
|
423
|
+
): DiagramAuthoringValidationError[];
|
|
424
|
+
export declare function assertDiagramDocument<T extends DiagramAuthoringDocument>(
|
|
425
|
+
value: T,
|
|
426
|
+
options?: DiagramAuthoringValidationOptions,
|
|
427
|
+
): T;
|
|
428
|
+
export declare function validateDiagramPresentation(
|
|
429
|
+
value: unknown,
|
|
430
|
+
options?: DiagramAuthoringValidationOptions,
|
|
431
|
+
): DiagramAuthoringValidationError[];
|
|
432
|
+
export declare function assertDiagramPresentation<T extends DiagramPresentation>(
|
|
433
|
+
value: T,
|
|
434
|
+
options?: DiagramAuthoringValidationOptions,
|
|
435
|
+
): T;
|
|
436
|
+
export declare function validateDiagramAuthoringBundle(
|
|
437
|
+
value: unknown,
|
|
438
|
+
options?: DiagramAuthoringValidationOptions,
|
|
439
|
+
): DiagramAuthoringValidationError[];
|
|
440
|
+
export declare function assertDiagramAuthoringBundle<T extends DiagramAuthoringBundle>(
|
|
441
|
+
value: T,
|
|
442
|
+
options?: DiagramAuthoringValidationOptions,
|
|
443
|
+
): T;
|
|
444
|
+
export declare function validateDiagramEditTransaction(
|
|
445
|
+
value: unknown,
|
|
446
|
+
options?: DiagramAuthoringValidationOptions,
|
|
447
|
+
): DiagramAuthoringValidationError[];
|
|
448
|
+
export declare function assertDiagramEditTransaction<T extends DiagramEditTransaction>(
|
|
449
|
+
value: T,
|
|
450
|
+
options?: DiagramAuthoringValidationOptions,
|
|
451
|
+
): T;
|
|
452
|
+
export declare function summarizeDiagramAuthoringContent(bundle: DiagramAuthoringBundle): {
|
|
453
|
+
elementCount: number;
|
|
454
|
+
hasVisibleContent: boolean;
|
|
455
|
+
};
|
|
112
456
|
export declare function inspectLegacyDiagramDocument(value: unknown): DiagramLegacyInspection;
|