@diagrammo/dgmo 0.8.3 → 0.8.5
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/.claude/commands/dgmo-diagram-this.md +60 -0
- package/.claude/commands/dgmo-document-project.md +128 -0
- package/.claude/commands/dgmo.md +452 -50
- package/.cursorrules +32 -37
- package/.github/copilot-instructions.md +35 -44
- package/.windsurfrules +32 -37
- package/README.md +4 -4
- package/dist/cli.cjs +188 -185
- package/dist/editor.cjs +338 -0
- package/dist/editor.cjs.map +1 -0
- package/dist/editor.d.cts +27 -0
- package/dist/editor.d.ts +27 -0
- package/dist/editor.js +307 -0
- package/dist/editor.js.map +1 -0
- package/dist/highlight.cjs +560 -0
- package/dist/highlight.cjs.map +1 -0
- package/dist/highlight.d.cts +32 -0
- package/dist/highlight.d.ts +32 -0
- package/dist/highlight.js +530 -0
- package/dist/highlight.js.map +1 -0
- package/dist/index.cjs +3467 -1078
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +22 -1
- package/dist/index.d.ts +22 -1
- package/dist/index.js +3466 -1078
- package/dist/index.js.map +1 -1
- package/docs/language-reference.md +46 -37
- package/gallery/fixtures/arc.dgmo +18 -0
- package/gallery/fixtures/area.dgmo +19 -0
- package/gallery/fixtures/bar-stacked.dgmo +10 -0
- package/gallery/fixtures/bar.dgmo +10 -0
- package/gallery/fixtures/c4-full.dgmo +52 -0
- package/gallery/fixtures/c4.dgmo +17 -0
- package/gallery/fixtures/chord.dgmo +12 -0
- package/gallery/fixtures/class-basic.dgmo +14 -0
- package/gallery/fixtures/class-full.dgmo +43 -0
- package/gallery/fixtures/doughnut.dgmo +8 -0
- package/gallery/fixtures/flowchart-basic.dgmo +3 -0
- package/gallery/fixtures/flowchart-colors.dgmo +5 -0
- package/gallery/fixtures/flowchart-complex.dgmo +17 -0
- package/gallery/fixtures/flowchart-decision.dgmo +5 -0
- package/gallery/fixtures/flowchart-full.dgmo +13 -0
- package/gallery/fixtures/flowchart-groups.dgmo +10 -0
- package/gallery/fixtures/flowchart-loop.dgmo +7 -0
- package/gallery/fixtures/flowchart-nested.dgmo +7 -0
- package/gallery/fixtures/flowchart-shapes.dgmo +5 -0
- package/gallery/fixtures/function.dgmo +8 -0
- package/gallery/fixtures/funnel.dgmo +7 -0
- package/gallery/fixtures/gantt-full.dgmo +49 -0
- package/gallery/fixtures/gantt.dgmo +42 -0
- package/gallery/fixtures/heatmap.dgmo +8 -0
- package/gallery/fixtures/infra-full.dgmo +78 -0
- package/gallery/fixtures/infra-overload.dgmo +25 -0
- package/gallery/fixtures/infra.dgmo +47 -0
- package/gallery/fixtures/initiative-status-full.dgmo +46 -0
- package/gallery/fixtures/initiative-status-phases.dgmo +29 -0
- package/gallery/fixtures/initiative-status.dgmo +9 -0
- package/gallery/fixtures/line.dgmo +19 -0
- package/gallery/fixtures/multi-line.dgmo +11 -0
- package/gallery/fixtures/org-basic.dgmo +16 -0
- package/gallery/fixtures/org-full.dgmo +69 -0
- package/gallery/fixtures/org-teams.dgmo +25 -0
- package/gallery/fixtures/pie.dgmo +9 -0
- package/gallery/fixtures/polar-area.dgmo +8 -0
- package/gallery/fixtures/quadrant.dgmo +18 -0
- package/gallery/fixtures/radar.dgmo +8 -0
- package/gallery/fixtures/sankey.dgmo +31 -0
- package/gallery/fixtures/scatter.dgmo +21 -0
- package/gallery/fixtures/sequence-tags-protocols.dgmo +45 -0
- package/gallery/fixtures/sequence-tags.dgmo +41 -0
- package/gallery/fixtures/sequence.dgmo +35 -0
- package/gallery/fixtures/sitemap-basic.dgmo +12 -0
- package/gallery/fixtures/sitemap-full.dgmo +156 -0
- package/gallery/fixtures/slope.dgmo +9 -0
- package/gallery/fixtures/spr-eras.dgmo +62 -0
- package/gallery/fixtures/state.dgmo +30 -0
- package/gallery/fixtures/timeline-intraday.dgmo +14 -0
- package/gallery/fixtures/timeline.dgmo +32 -0
- package/gallery/fixtures/venn.dgmo +10 -0
- package/gallery/fixtures/wordcloud.dgmo +24 -0
- package/package.json +71 -2
- package/src/c4/layout.ts +372 -90
- package/src/c4/parser.ts +100 -55
- package/src/chart.ts +91 -28
- package/src/class/parser.ts +41 -12
- package/src/cli.ts +211 -62
- package/src/completion.ts +378 -183
- package/src/d3.ts +1044 -303
- package/src/dgmo-mermaid.ts +16 -13
- package/src/dgmo-router.ts +69 -23
- package/src/echarts.ts +646 -153
- package/src/editor/dgmo.grammar +69 -0
- package/src/editor/dgmo.grammar.d.ts +2 -0
- package/src/editor/dgmo.grammar.js +18 -0
- package/src/editor/dgmo.grammar.terms.d.ts +5 -0
- package/src/editor/dgmo.grammar.terms.js +35 -0
- package/src/editor/highlight-api.ts +444 -0
- package/src/editor/highlight.ts +36 -0
- package/src/editor/index.ts +28 -0
- package/src/editor/keywords.ts +222 -0
- package/src/editor/tokens.ts +30 -0
- package/src/er/parser.ts +48 -14
- package/src/er/renderer.ts +112 -53
- package/src/gantt/calculator.ts +91 -29
- package/src/gantt/parser.ts +197 -71
- package/src/gantt/renderer.ts +1120 -350
- package/src/graph/flowchart-parser.ts +46 -25
- package/src/graph/state-parser.ts +47 -17
- package/src/index.ts +96 -31
- package/src/infra/parser.ts +157 -53
- package/src/infra/renderer.ts +723 -271
- package/src/initiative-status/parser.ts +138 -44
- package/src/kanban/parser.ts +25 -14
- package/src/org/layout.ts +111 -44
- package/src/org/parser.ts +69 -22
- package/src/palettes/index.ts +3 -2
- package/src/sequence/parser.ts +193 -61
- package/src/sitemap/parser.ts +65 -29
- package/src/utils/arrows.ts +2 -22
- package/src/utils/duration.ts +39 -21
- package/src/utils/legend-constants.ts +0 -2
- package/src/utils/parsing.ts +75 -31
|
@@ -9,13 +9,7 @@ import {
|
|
|
9
9
|
OPTION_NOCOLON_RE,
|
|
10
10
|
ALL_CHART_TYPES,
|
|
11
11
|
} from '../utils/parsing';
|
|
12
|
-
import type {
|
|
13
|
-
ParsedGraph,
|
|
14
|
-
GraphNode,
|
|
15
|
-
GraphEdge,
|
|
16
|
-
GraphShape,
|
|
17
|
-
GraphDirection,
|
|
18
|
-
} from './types';
|
|
12
|
+
import type { ParsedGraph, GraphNode, GraphEdge, GraphShape } from './types';
|
|
19
13
|
|
|
20
14
|
// ============================================================
|
|
21
15
|
// Helpers
|
|
@@ -36,10 +30,7 @@ interface NodeRef {
|
|
|
36
30
|
* Try to parse a node reference from a text fragment.
|
|
37
31
|
* Order matters: subroutine & document before process.
|
|
38
32
|
*/
|
|
39
|
-
function parseNodeRef(
|
|
40
|
-
text: string,
|
|
41
|
-
palette?: PaletteColors
|
|
42
|
-
): NodeRef | null {
|
|
33
|
+
function parseNodeRef(text: string, palette?: PaletteColors): NodeRef | null {
|
|
43
34
|
const t = text.trim();
|
|
44
35
|
if (!t) return null;
|
|
45
36
|
|
|
@@ -47,7 +38,12 @@ function parseNodeRef(
|
|
|
47
38
|
let m = t.match(/^\[\[([^\]]+)\]\]$/);
|
|
48
39
|
if (m) {
|
|
49
40
|
const { label, color } = extractColor(m[1].trim(), palette);
|
|
50
|
-
return {
|
|
41
|
+
return {
|
|
42
|
+
id: nodeId('subroutine', label),
|
|
43
|
+
label,
|
|
44
|
+
shape: 'subroutine',
|
|
45
|
+
color,
|
|
46
|
+
};
|
|
51
47
|
}
|
|
52
48
|
|
|
53
49
|
// Document: [Label~]
|
|
@@ -99,7 +95,12 @@ function splitArrows(line: string): string[] {
|
|
|
99
95
|
const segments: string[] = [];
|
|
100
96
|
let lastIndex = 0;
|
|
101
97
|
// Simpler approach: find all `->` positions, then determine if there's a label prefix
|
|
102
|
-
const arrowPositions: {
|
|
98
|
+
const arrowPositions: {
|
|
99
|
+
start: number;
|
|
100
|
+
end: number;
|
|
101
|
+
label?: string;
|
|
102
|
+
color?: string;
|
|
103
|
+
}[] = [];
|
|
103
104
|
|
|
104
105
|
// Find all -> occurrences
|
|
105
106
|
let searchFrom = 0;
|
|
@@ -124,10 +125,14 @@ function splitArrows(line: string): string[] {
|
|
|
124
125
|
scanBack--;
|
|
125
126
|
}
|
|
126
127
|
// Check if this `-` could be the start of the arrow
|
|
127
|
-
if (
|
|
128
|
+
if (
|
|
129
|
+
line[scanBack] === '-' &&
|
|
130
|
+
(scanBack === 0 || /\s/.test(line[scanBack - 1]))
|
|
131
|
+
) {
|
|
128
132
|
// Content between opening `-` and `->` (strip trailing `-` that is part of `->`)
|
|
129
133
|
let arrowContent = line.substring(scanBack + 1, idx);
|
|
130
|
-
if (arrowContent.endsWith('-'))
|
|
134
|
+
if (arrowContent.endsWith('-'))
|
|
135
|
+
arrowContent = arrowContent.slice(0, -1);
|
|
131
136
|
// Parse label and color from arrow content
|
|
132
137
|
const colorMatch = arrowContent.match(/\(([^)]+)\)\s*$/);
|
|
133
138
|
if (colorMatch) {
|
|
@@ -159,7 +164,8 @@ function splitArrows(line: string): string[] {
|
|
|
159
164
|
}
|
|
160
165
|
// Arrow marker
|
|
161
166
|
let arrowToken = '->';
|
|
162
|
-
if (arrow.label && arrow.color)
|
|
167
|
+
if (arrow.label && arrow.color)
|
|
168
|
+
arrowToken = `-${arrow.label}(${arrow.color})->`;
|
|
163
169
|
else if (arrow.label) arrowToken = `-${arrow.label}->`;
|
|
164
170
|
else if (arrow.color) arrowToken = `-(${arrow.color})->`;
|
|
165
171
|
segments.push(arrowToken);
|
|
@@ -190,7 +196,9 @@ function parseArrowToken(token: string, palette?: PaletteColors): ArrowInfo {
|
|
|
190
196
|
const m = token.match(/^-(.+?)(?:\(([^)]+)\))?->$/);
|
|
191
197
|
if (m) {
|
|
192
198
|
const label = m[1]?.trim() || undefined;
|
|
193
|
-
let color = m[2]
|
|
199
|
+
let color = m[2]
|
|
200
|
+
? (resolveColor(m[2].trim(), palette) ?? undefined)
|
|
201
|
+
: undefined;
|
|
194
202
|
if (label && !color) {
|
|
195
203
|
color = inferArrowColor(label);
|
|
196
204
|
}
|
|
@@ -214,7 +222,7 @@ export function parseFlowchart(
|
|
|
214
222
|
const lines = content.split('\n');
|
|
215
223
|
const result: ParsedGraph = {
|
|
216
224
|
type: 'flowchart',
|
|
217
|
-
direction: '
|
|
225
|
+
direction: 'TB',
|
|
218
226
|
nodes: [],
|
|
219
227
|
edges: [],
|
|
220
228
|
options: {},
|
|
@@ -406,9 +414,9 @@ export function parseFlowchart(
|
|
|
406
414
|
|
|
407
415
|
// Options (space-separated, before content)
|
|
408
416
|
if (!contentStarted) {
|
|
409
|
-
// Bare boolean: direction-
|
|
410
|
-
if (/^direction-
|
|
411
|
-
result.direction = '
|
|
417
|
+
// Bare boolean: direction-lr
|
|
418
|
+
if (/^direction-lr$/i.test(trimmed)) {
|
|
419
|
+
result.direction = 'LR';
|
|
412
420
|
continue;
|
|
413
421
|
}
|
|
414
422
|
|
|
@@ -435,7 +443,10 @@ export function parseFlowchart(
|
|
|
435
443
|
|
|
436
444
|
// Validation: no nodes found
|
|
437
445
|
if (result.nodes.length === 0 && !result.error) {
|
|
438
|
-
const diag = makeDgmoError(
|
|
446
|
+
const diag = makeDgmoError(
|
|
447
|
+
1,
|
|
448
|
+
'No nodes found. Add flowchart content with shape syntax like [Process] or (Start).'
|
|
449
|
+
);
|
|
439
450
|
result.diagnostics.push(diag);
|
|
440
451
|
result.error = formatDgmoError(diag);
|
|
441
452
|
}
|
|
@@ -449,7 +460,13 @@ export function parseFlowchart(
|
|
|
449
460
|
}
|
|
450
461
|
for (const node of result.nodes) {
|
|
451
462
|
if (!connectedIds.has(node.id)) {
|
|
452
|
-
result.diagnostics.push(
|
|
463
|
+
result.diagnostics.push(
|
|
464
|
+
makeDgmoError(
|
|
465
|
+
node.lineNumber,
|
|
466
|
+
`Node "${node.label}" is not connected to any other node`,
|
|
467
|
+
'warning'
|
|
468
|
+
)
|
|
469
|
+
);
|
|
453
470
|
}
|
|
454
471
|
}
|
|
455
472
|
}
|
|
@@ -485,7 +502,7 @@ export function looksLikeFlowchart(content: string): boolean {
|
|
|
485
502
|
// Look for patterns like `[X] ->` or `-> [X]` or `(X) ->` etc.
|
|
486
503
|
const shapeNearArrow =
|
|
487
504
|
/[\])][ \t]*-.*->/.test(content) || // shape ] or ) followed by arrow
|
|
488
|
-
/->[ \t]*[
|
|
505
|
+
/->[ \t]*[[(</]/.test(content); // arrow followed by shape opener
|
|
489
506
|
|
|
490
507
|
return shapeNearArrow;
|
|
491
508
|
}
|
|
@@ -509,7 +526,11 @@ export function extractSymbols(docText: string): DiagramSymbols {
|
|
|
509
526
|
for (const rawLine of docText.split('\n')) {
|
|
510
527
|
const line = rawLine.trim();
|
|
511
528
|
// Skip old-style colon metadata and new-style space-separated options
|
|
512
|
-
if (
|
|
529
|
+
if (
|
|
530
|
+
inMetadata &&
|
|
531
|
+
(/^[a-z-]+\s*:/i.test(line) || /^[a-z-]+\s+\S/i.test(line))
|
|
532
|
+
)
|
|
533
|
+
continue;
|
|
513
534
|
inMetadata = false;
|
|
514
535
|
if (line.length === 0 || /^\s/.test(rawLine)) continue;
|
|
515
536
|
const m = NODE_ID_RE.exec(line);
|
|
@@ -8,12 +8,7 @@ import {
|
|
|
8
8
|
OPTION_NOCOLON_RE,
|
|
9
9
|
ALL_CHART_TYPES,
|
|
10
10
|
} from '../utils/parsing';
|
|
11
|
-
import type {
|
|
12
|
-
ParsedGraph,
|
|
13
|
-
GraphNode,
|
|
14
|
-
GraphGroup,
|
|
15
|
-
GraphDirection,
|
|
16
|
-
} from './types';
|
|
11
|
+
import type { ParsedGraph, GraphNode, GraphGroup } from './types';
|
|
17
12
|
|
|
18
13
|
// ============================================================
|
|
19
14
|
// Constants
|
|
@@ -36,7 +31,12 @@ const GROUP_BRACKET_RE = /^\[([^\]]+)\](?:\(([^)]+)\))?\s*$/;
|
|
|
36
31
|
*/
|
|
37
32
|
function splitArrows(line: string): string[] {
|
|
38
33
|
const segments: string[] = [];
|
|
39
|
-
const arrowPositions: {
|
|
34
|
+
const arrowPositions: {
|
|
35
|
+
start: number;
|
|
36
|
+
end: number;
|
|
37
|
+
label?: string;
|
|
38
|
+
color?: string;
|
|
39
|
+
}[] = [];
|
|
40
40
|
|
|
41
41
|
let searchFrom = 0;
|
|
42
42
|
while (searchFrom < line.length) {
|
|
@@ -52,9 +52,13 @@ function splitArrows(line: string): string[] {
|
|
|
52
52
|
while (scanBack > 0 && line[scanBack] !== '-') {
|
|
53
53
|
scanBack--;
|
|
54
54
|
}
|
|
55
|
-
if (
|
|
55
|
+
if (
|
|
56
|
+
line[scanBack] === '-' &&
|
|
57
|
+
(scanBack === 0 || /\s/.test(line[scanBack - 1]))
|
|
58
|
+
) {
|
|
56
59
|
let arrowContent = line.substring(scanBack + 1, idx);
|
|
57
|
-
if (arrowContent.endsWith('-'))
|
|
60
|
+
if (arrowContent.endsWith('-'))
|
|
61
|
+
arrowContent = arrowContent.slice(0, -1);
|
|
58
62
|
const colorMatch = arrowContent.match(/\(([^)]+)\)\s*$/);
|
|
59
63
|
if (colorMatch) {
|
|
60
64
|
color = colorMatch[1].trim();
|
|
@@ -81,7 +85,8 @@ function splitArrows(line: string): string[] {
|
|
|
81
85
|
if (beforeText || i === 0) segments.push(beforeText);
|
|
82
86
|
|
|
83
87
|
let arrowToken = '->';
|
|
84
|
-
if (arrow.label && arrow.color)
|
|
88
|
+
if (arrow.label && arrow.color)
|
|
89
|
+
arrowToken = `-${arrow.label}(${arrow.color})->`;
|
|
85
90
|
else if (arrow.label) arrowToken = `-${arrow.label}->`;
|
|
86
91
|
else if (arrow.color) arrowToken = `-(${arrow.color})->`;
|
|
87
92
|
segments.push(arrowToken);
|
|
@@ -101,11 +106,14 @@ interface ArrowInfo {
|
|
|
101
106
|
function parseArrowToken(token: string, palette?: PaletteColors): ArrowInfo {
|
|
102
107
|
if (token === '->') return {};
|
|
103
108
|
const colorOnly = token.match(/^-\(([^)]+)\)->$/);
|
|
104
|
-
if (colorOnly)
|
|
109
|
+
if (colorOnly)
|
|
110
|
+
return { color: resolveColor(colorOnly[1].trim(), palette) ?? undefined };
|
|
105
111
|
const m = token.match(/^-(.+?)(?:\(([^)]+)\))?->$/);
|
|
106
112
|
if (m) {
|
|
107
113
|
const label = m[1]?.trim() || undefined;
|
|
108
|
-
const color = m[2]
|
|
114
|
+
const color = m[2]
|
|
115
|
+
? (resolveColor(m[2].trim(), palette) ?? undefined)
|
|
116
|
+
: undefined;
|
|
109
117
|
return { label, color };
|
|
110
118
|
}
|
|
111
119
|
return {};
|
|
@@ -122,13 +130,20 @@ interface NodeRef {
|
|
|
122
130
|
color?: string;
|
|
123
131
|
}
|
|
124
132
|
|
|
125
|
-
function parseStateNodeRef(
|
|
133
|
+
function parseStateNodeRef(
|
|
134
|
+
text: string,
|
|
135
|
+
palette?: PaletteColors
|
|
136
|
+
): NodeRef | null {
|
|
126
137
|
const t = text.trim();
|
|
127
138
|
if (!t) return null;
|
|
128
139
|
|
|
129
140
|
// Pseudostate: [*]
|
|
130
141
|
if (t === '[*]') {
|
|
131
|
-
return {
|
|
142
|
+
return {
|
|
143
|
+
id: PSEUDOSTATE_ID,
|
|
144
|
+
label: PSEUDOSTATE_LABEL,
|
|
145
|
+
shape: 'pseudostate',
|
|
146
|
+
};
|
|
132
147
|
}
|
|
133
148
|
|
|
134
149
|
// State: bare text with optional (color) suffix
|
|
@@ -350,7 +365,13 @@ export function parseState(
|
|
|
350
365
|
// Use explicit source if available, else implicit from indent
|
|
351
366
|
const sourceId = lastNodeId ?? implicitSourceId;
|
|
352
367
|
if (sourceId) {
|
|
353
|
-
addEdge(
|
|
368
|
+
addEdge(
|
|
369
|
+
sourceId,
|
|
370
|
+
node.id,
|
|
371
|
+
lineNumber,
|
|
372
|
+
pendingArrow.label,
|
|
373
|
+
pendingArrow.color
|
|
374
|
+
);
|
|
354
375
|
}
|
|
355
376
|
pendingArrow = null;
|
|
356
377
|
}
|
|
@@ -367,7 +388,10 @@ export function parseState(
|
|
|
367
388
|
|
|
368
389
|
// Validation: no nodes found
|
|
369
390
|
if (result.nodes.length === 0 && !result.error) {
|
|
370
|
-
const diag = makeDgmoError(
|
|
391
|
+
const diag = makeDgmoError(
|
|
392
|
+
1,
|
|
393
|
+
'No states found. Add state transitions like: Idle -> Active'
|
|
394
|
+
);
|
|
371
395
|
result.diagnostics.push(diag);
|
|
372
396
|
result.error = formatDgmoError(diag);
|
|
373
397
|
}
|
|
@@ -381,7 +405,13 @@ export function parseState(
|
|
|
381
405
|
}
|
|
382
406
|
for (const node of result.nodes) {
|
|
383
407
|
if (!connectedIds.has(node.id)) {
|
|
384
|
-
result.diagnostics.push(
|
|
408
|
+
result.diagnostics.push(
|
|
409
|
+
makeDgmoError(
|
|
410
|
+
node.lineNumber,
|
|
411
|
+
`State "${node.label}" is not connected to any other state`,
|
|
412
|
+
'warning'
|
|
413
|
+
)
|
|
414
|
+
);
|
|
385
415
|
}
|
|
386
416
|
}
|
|
387
417
|
}
|
package/src/index.ts
CHANGED
|
@@ -27,13 +27,8 @@ export type { RenderCategory } from './dgmo-router';
|
|
|
27
27
|
// Parsers
|
|
28
28
|
// ============================================================
|
|
29
29
|
|
|
30
|
-
export { parseChart } from './chart';
|
|
31
|
-
export type {
|
|
32
|
-
ParsedChart,
|
|
33
|
-
ChartType,
|
|
34
|
-
ChartDataPoint,
|
|
35
|
-
ChartEra,
|
|
36
|
-
} from './chart';
|
|
30
|
+
export { parseChart, parseDataRowValues } from './chart';
|
|
31
|
+
export type { ParsedChart, ChartType, ChartDataPoint, ChartEra } from './chart';
|
|
37
32
|
|
|
38
33
|
export { parseExtendedChart } from './echarts';
|
|
39
34
|
export type { ParsedExtendedChart, ExtendedChartType } from './echarts';
|
|
@@ -46,7 +41,13 @@ export {
|
|
|
46
41
|
computeTimeTicks,
|
|
47
42
|
formatDateLabel,
|
|
48
43
|
} from './d3';
|
|
49
|
-
export type {
|
|
44
|
+
export type {
|
|
45
|
+
ParsedVisualization,
|
|
46
|
+
VisualizationType,
|
|
47
|
+
D3ExportDimensions,
|
|
48
|
+
ArcLink,
|
|
49
|
+
ArcNodeGroup,
|
|
50
|
+
} from './d3';
|
|
50
51
|
|
|
51
52
|
export {
|
|
52
53
|
parseSequenceDgmo,
|
|
@@ -99,7 +100,10 @@ export type {
|
|
|
99
100
|
ClassLayoutEdge,
|
|
100
101
|
} from './class/layout';
|
|
101
102
|
|
|
102
|
-
export {
|
|
103
|
+
export {
|
|
104
|
+
renderClassDiagram,
|
|
105
|
+
renderClassDiagramForExport,
|
|
106
|
+
} from './class/renderer';
|
|
103
107
|
|
|
104
108
|
export { parseERDiagram, looksLikeERDiagram } from './er/parser';
|
|
105
109
|
|
|
@@ -113,11 +117,7 @@ export type {
|
|
|
113
117
|
} from './er/types';
|
|
114
118
|
|
|
115
119
|
export { layoutERDiagram } from './er/layout';
|
|
116
|
-
export type {
|
|
117
|
-
ERLayoutResult,
|
|
118
|
-
ERLayoutNode,
|
|
119
|
-
ERLayoutEdge,
|
|
120
|
-
} from './er/layout';
|
|
120
|
+
export type { ERLayoutResult, ERLayoutNode, ERLayoutEdge } from './er/layout';
|
|
121
121
|
|
|
122
122
|
export { renderERDiagram, renderERDiagramForExport } from './er/renderer';
|
|
123
123
|
|
|
@@ -136,10 +136,7 @@ export { parseInlineMarkdown, truncateBareUrl } from './utils/inline-markdown';
|
|
|
136
136
|
export type { InlineSpan } from './utils/inline-markdown';
|
|
137
137
|
|
|
138
138
|
export { parseOrg } from './org/parser';
|
|
139
|
-
export type {
|
|
140
|
-
ParsedOrg,
|
|
141
|
-
OrgNode,
|
|
142
|
-
} from './org/parser';
|
|
139
|
+
export type { ParsedOrg, OrgNode } from './org/parser';
|
|
143
140
|
|
|
144
141
|
export { layoutOrg } from './org/layout';
|
|
145
142
|
export type {
|
|
@@ -159,7 +156,11 @@ export type {
|
|
|
159
156
|
KanbanTagGroup,
|
|
160
157
|
KanbanTagEntry,
|
|
161
158
|
} from './kanban/types';
|
|
162
|
-
export {
|
|
159
|
+
export {
|
|
160
|
+
computeCardMove,
|
|
161
|
+
computeCardArchive,
|
|
162
|
+
isArchiveColumn,
|
|
163
|
+
} from './kanban/mutations';
|
|
163
164
|
export { renderKanban, renderKanbanForExport } from './kanban/renderer';
|
|
164
165
|
|
|
165
166
|
export { parseC4 } from './c4/parser';
|
|
@@ -176,7 +177,13 @@ export type {
|
|
|
176
177
|
C4TagEntry,
|
|
177
178
|
} from './c4/types';
|
|
178
179
|
|
|
179
|
-
export {
|
|
180
|
+
export {
|
|
181
|
+
layoutC4Context,
|
|
182
|
+
layoutC4Containers,
|
|
183
|
+
layoutC4Components,
|
|
184
|
+
layoutC4Deployment,
|
|
185
|
+
rollUpContextRelationships,
|
|
186
|
+
} from './c4/layout';
|
|
180
187
|
export type {
|
|
181
188
|
C4LayoutResult,
|
|
182
189
|
C4LayoutNode,
|
|
@@ -197,7 +204,10 @@ export {
|
|
|
197
204
|
renderC4DeploymentForExport,
|
|
198
205
|
} from './c4/renderer';
|
|
199
206
|
|
|
200
|
-
export {
|
|
207
|
+
export {
|
|
208
|
+
parseInitiativeStatus,
|
|
209
|
+
looksLikeInitiativeStatus,
|
|
210
|
+
} from './initiative-status/parser';
|
|
201
211
|
export type {
|
|
202
212
|
ParsedInitiativeStatus,
|
|
203
213
|
ISNode,
|
|
@@ -214,7 +224,10 @@ export type {
|
|
|
214
224
|
ISLayoutGroup,
|
|
215
225
|
} from './initiative-status/layout';
|
|
216
226
|
|
|
217
|
-
export {
|
|
227
|
+
export {
|
|
228
|
+
renderInitiativeStatus,
|
|
229
|
+
renderInitiativeStatusForExport,
|
|
230
|
+
} from './initiative-status/renderer';
|
|
218
231
|
export type { ISRenderOptions } from './initiative-status/renderer';
|
|
219
232
|
|
|
220
233
|
export { collapseInitiativeStatus } from './initiative-status/collapse';
|
|
@@ -247,16 +260,42 @@ export { collapseSitemapTree } from './sitemap/collapse';
|
|
|
247
260
|
|
|
248
261
|
// ── Infra Chart ────────────────────────────────────────────
|
|
249
262
|
export { parseInfra } from './infra/parser';
|
|
250
|
-
export type {
|
|
263
|
+
export type {
|
|
264
|
+
ParsedInfra,
|
|
265
|
+
InfraNode,
|
|
266
|
+
InfraEdge,
|
|
267
|
+
InfraGroup,
|
|
268
|
+
InfraTagGroup,
|
|
269
|
+
InfraProperty,
|
|
270
|
+
InfraDiagnostic,
|
|
271
|
+
InfraComputeParams,
|
|
272
|
+
InfraBehaviorKey,
|
|
273
|
+
} from './infra/types';
|
|
251
274
|
export { INFRA_BEHAVIOR_KEYS } from './infra/types';
|
|
252
275
|
export { computeInfra } from './infra/compute';
|
|
253
|
-
export type {
|
|
276
|
+
export type {
|
|
277
|
+
ComputedInfraModel,
|
|
278
|
+
ComputedInfraNode,
|
|
279
|
+
ComputedInfraEdge,
|
|
280
|
+
InfraLatencyPercentiles,
|
|
281
|
+
InfraAvailabilityPercentiles,
|
|
282
|
+
InfraCbState,
|
|
283
|
+
} from './infra/types';
|
|
254
284
|
export { validateInfra, validateComputed } from './infra/validation';
|
|
255
285
|
export { inferRoles, collectDiagramRoles } from './infra/roles';
|
|
256
286
|
export type { InfraRole } from './infra/roles';
|
|
257
287
|
export { layoutInfra } from './infra/layout';
|
|
258
|
-
export type {
|
|
259
|
-
|
|
288
|
+
export type {
|
|
289
|
+
InfraLayoutResult,
|
|
290
|
+
InfraLayoutNode,
|
|
291
|
+
InfraLayoutEdge,
|
|
292
|
+
InfraLayoutGroup,
|
|
293
|
+
} from './infra/layout';
|
|
294
|
+
export {
|
|
295
|
+
renderInfra,
|
|
296
|
+
parseAndLayoutInfra,
|
|
297
|
+
computeInfraLegendGroups,
|
|
298
|
+
} from './infra/renderer';
|
|
260
299
|
export type { InfraLegendGroup, InfraPlaybackState } from './infra/renderer';
|
|
261
300
|
export type { CollapsedSitemapResult } from './sitemap/collapse';
|
|
262
301
|
|
|
@@ -264,7 +303,13 @@ export type { CollapsedSitemapResult } from './sitemap/collapse';
|
|
|
264
303
|
export { parseGantt } from './gantt/parser';
|
|
265
304
|
export { calculateSchedule } from './gantt/calculator';
|
|
266
305
|
export { renderGantt, buildTagLaneRowList } from './gantt/renderer';
|
|
267
|
-
export type {
|
|
306
|
+
export type {
|
|
307
|
+
GanttInteractiveOptions,
|
|
308
|
+
GanttRow,
|
|
309
|
+
GanttGroupRow,
|
|
310
|
+
GanttTaskRow,
|
|
311
|
+
GanttLaneHeaderRow,
|
|
312
|
+
} from './gantt/renderer';
|
|
268
313
|
export { resolveTaskName, collectTasks } from './gantt/resolver';
|
|
269
314
|
export type {
|
|
270
315
|
ParsedGantt,
|
|
@@ -288,7 +333,11 @@ export { collapseOrgTree } from './org/collapse';
|
|
|
288
333
|
export type { CollapsedOrgResult } from './org/collapse';
|
|
289
334
|
|
|
290
335
|
export { resolveOrgImports } from './org/resolver';
|
|
291
|
-
export type {
|
|
336
|
+
export type {
|
|
337
|
+
ReadFileFn,
|
|
338
|
+
ResolveImportsResult,
|
|
339
|
+
ImportSource,
|
|
340
|
+
} from './org/resolver';
|
|
292
341
|
|
|
293
342
|
export { layoutGraph } from './graph/layout';
|
|
294
343
|
export type {
|
|
@@ -298,13 +347,23 @@ export type {
|
|
|
298
347
|
LayoutGroup,
|
|
299
348
|
} from './graph/layout';
|
|
300
349
|
|
|
301
|
-
export {
|
|
350
|
+
export {
|
|
351
|
+
renderFlowchart,
|
|
352
|
+
renderFlowchartForExport,
|
|
353
|
+
} from './graph/flowchart-renderer';
|
|
302
354
|
|
|
303
355
|
// ============================================================
|
|
304
356
|
// Config Builders (produce framework-specific config objects)
|
|
305
357
|
// ============================================================
|
|
306
358
|
|
|
307
|
-
export {
|
|
359
|
+
export {
|
|
360
|
+
buildExtendedChartOption,
|
|
361
|
+
buildSimpleChartOption,
|
|
362
|
+
renderExtendedChartForExport,
|
|
363
|
+
getExtendedChartLegendGroups,
|
|
364
|
+
getSimpleChartLegendGroups,
|
|
365
|
+
computeScatterLabelGraphics,
|
|
366
|
+
} from './echarts';
|
|
308
367
|
export type { ScatterLabelPoint } from './echarts';
|
|
309
368
|
export { renderLegendSvg, type LegendGroupData } from './utils/legend-svg';
|
|
310
369
|
export { LEGEND_HEIGHT } from './utils/legend-constants';
|
|
@@ -403,7 +462,13 @@ export {
|
|
|
403
462
|
PIPE_METADATA,
|
|
404
463
|
extractTagDeclarations,
|
|
405
464
|
} from './completion';
|
|
406
|
-
export type {
|
|
465
|
+
export type {
|
|
466
|
+
DiagramSymbols,
|
|
467
|
+
ExtractFn,
|
|
468
|
+
DirectiveSpec,
|
|
469
|
+
DirectiveValueSpec,
|
|
470
|
+
PipeKeySpec,
|
|
471
|
+
} from './completion';
|
|
407
472
|
|
|
408
473
|
export { parseFirstLine, ALL_CHART_TYPES } from './utils/parsing';
|
|
409
474
|
|