@draftably/mermaid 0.2.2 → 0.3.0
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/cdn/{font-data-DME3E71S-DQDSeeBH.mjs → font-data-DME3E71S-BMv5SaWY.mjs} +1 -1
- package/dist/cdn/index-Cfoobq16.mjs +9160 -0
- package/dist/cdn/mermaid-importer-Cylti6IA.mjs +4381 -0
- package/dist/chunks/mermaid-importer-S5o6DWXk.js +4381 -0
- package/dist/mermaid.esm.min.mjs +1 -1
- package/dist/mermaid.js +1 -1
- package/dist/types/src/dsl/compile.d.ts +2 -0
- package/dist/types/src/dsl/sequence-layout.d.ts +87 -0
- package/dist/types/src/dsl/syntax.d.ts +8 -2
- package/dist/types/src/engines/layout/arrange.d.ts +36 -0
- package/dist/types/src/engines/layout/compute.d.ts +7 -0
- package/dist/types/src/engines/layout/forces.d.ts +8 -0
- package/dist/types/src/engines/layout/grid.d.ts +10 -0
- package/dist/types/src/engines/layout/intent.d.ts +14 -0
- package/dist/types/src/engines/layout/layered.d.ts +5 -0
- package/dist/types/src/engines/layout/objective.d.ts +6 -0
- package/dist/types/src/engines/layout/packing.d.ts +7 -0
- package/dist/types/src/engines/layout/report.d.ts +7 -0
- package/dist/types/src/engines/layout/scene.d.ts +53 -0
- package/dist/types/src/engines/layout/seed.d.ts +3 -0
- package/dist/types/src/engines/layout/separation.d.ts +17 -0
- package/dist/types/src/engines/layout/settings.d.ts +6 -0
- package/dist/types/src/engines/layout/topology.d.ts +18 -0
- package/dist/types/src/engines/layout/trees.d.ts +8 -0
- package/dist/types/src/engines/layout/types.d.ts +133 -0
- package/dist/types/src/engines/layout/util.d.ts +19 -0
- package/dist/types/src/engines/layout-engine.d.ts +15 -0
- package/dist/types/src/engines/routing/compute.d.ts +6 -0
- package/dist/types/src/engines/routing/conflicts.d.ts +36 -0
- package/dist/types/src/engines/routing/context.d.ts +37 -0
- package/dist/types/src/engines/routing/cost.d.ts +13 -0
- package/dist/types/src/engines/routing/doglegs.d.ts +16 -0
- package/dist/types/src/engines/routing/find.d.ts +6 -0
- package/dist/types/src/engines/routing/geometry.d.ts +24 -0
- package/dist/types/src/engines/routing/heap.d.ts +20 -0
- package/dist/types/src/engines/routing/improve.d.ts +7 -0
- package/dist/types/src/engines/routing/nudge.d.ts +7 -0
- package/dist/types/src/engines/routing/paths.d.ts +8 -0
- package/dist/types/src/engines/routing/planned.d.ts +7 -0
- package/dist/types/src/engines/routing/ports.d.ts +10 -0
- package/dist/types/src/engines/routing/repair.d.ts +9 -0
- package/dist/types/src/engines/routing/score.d.ts +12 -0
- package/dist/types/src/engines/routing/search.d.ts +16 -0
- package/dist/types/src/engines/routing/settings.d.ts +4 -0
- package/dist/types/src/engines/routing/sidepairs.d.ts +20 -0
- package/dist/types/src/engines/routing/tidy-ports.d.ts +13 -0
- package/dist/types/src/engines/routing/tidy.d.ts +10 -0
- package/dist/types/src/engines/routing/tuning.d.ts +9 -0
- package/dist/types/src/engines/routing/types.d.ts +157 -0
- package/dist/types/src/engines/routing-engine.d.ts +20 -0
- package/dist/types/src/import/import-core.d.ts +5 -0
- package/dist/types/src/import/mermaid-sequence.d.ts +1 -1
- package/dist/types/src/model/appearance.d.ts +18 -2
- package/dist/types/src/model/labels.d.ts +23 -0
- package/dist/types/src/model/markers.d.ts +7 -0
- package/dist/types/src/model/note.d.ts +11 -2
- package/dist/types/src/model/routes.d.ts +5 -3
- package/dist/types/src/model/status.d.ts +18 -0
- package/dist/types/src/model/types.d.ts +20 -1
- package/package.json +2 -2
- package/dist/cdn/index-C8K0jvXo.mjs +0 -8605
- package/dist/cdn/mermaid-importer-CsurIKv3.mjs +0 -4132
- package/dist/chunks/mermaid-importer-BHKoojYC.js +0 -4132
|
@@ -13,7 +13,7 @@ export type PortSide = Side | 'auto';
|
|
|
13
13
|
export type Direction = 'RIGHT' | 'DOWN';
|
|
14
14
|
export type Theme = 'light' | 'dark';
|
|
15
15
|
import type { DiagramAppearance, Shade } from './appearance';
|
|
16
|
-
import type { EndMarker } from './markers';
|
|
16
|
+
import type { EndMarker, MessageKind } from './markers';
|
|
17
17
|
import type { Spot, Status } from './status';
|
|
18
18
|
export type ShapeKind = 'box' | 'pill' | 'circle' | 'diamond' | 'text' | 'icon' | 'image'
|
|
19
19
|
/** A seam between two cells of a `cells` group. */
|
|
@@ -70,6 +70,13 @@ export interface DiagramEdge {
|
|
|
70
70
|
tail?: EndMarker;
|
|
71
71
|
emphasis: boolean;
|
|
72
72
|
dashed: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* A sequence message's meaning, from `message=`, or `action` for work one participant does
|
|
75
|
+
* (an `action` line; `from` and `to` are that participant). Unset for a plain message.
|
|
76
|
+
*/
|
|
77
|
+
message?: MessageKind;
|
|
78
|
+
/** With `message: 'reply'`: the earlier message this one answers, from `answers=`. */
|
|
79
|
+
replyTo?: string;
|
|
73
80
|
/** How it differs between two versions of the diagram. */
|
|
74
81
|
status?: Status;
|
|
75
82
|
/** How the drawn emphasis state treats it; see `withState`. */
|
|
@@ -93,6 +100,8 @@ export interface EdgeLayout {
|
|
|
93
100
|
toOffset?: number;
|
|
94
101
|
/** A sequence message: drawn straight between the two lifelines at this height, not routed. */
|
|
95
102
|
row?: number;
|
|
103
|
+
/** A message between distant lanes: the middle of the gap between lifelines its label sits in. */
|
|
104
|
+
labelX?: number;
|
|
96
105
|
/**
|
|
97
106
|
* Set by the compiler for a forward line in a `flow` scope: its route planned from the ranks.
|
|
98
107
|
* The quick router takes it as it is when it clears every box.
|
|
@@ -274,8 +283,18 @@ export interface SequenceLayout {
|
|
|
274
283
|
rows: Record<string, number>;
|
|
275
284
|
phases: SequencePhase[];
|
|
276
285
|
grow: number;
|
|
286
|
+
activations?: Activation[];
|
|
277
287
|
};
|
|
288
|
+
/** With `activations=on`: the bars on the lifelines of participants at work on a call. */
|
|
289
|
+
activations?: Activation[];
|
|
290
|
+
/** The `activations=on` switch itself, which the Inspector turns on and off. */
|
|
291
|
+
bars?: true;
|
|
278
292
|
}
|
|
293
|
+
/** One activation bar: its participant, the call that opened it, and its box. */
|
|
294
|
+
export type Activation = Rect & {
|
|
295
|
+
node: string;
|
|
296
|
+
call: string;
|
|
297
|
+
};
|
|
279
298
|
export type SequencePhase = {
|
|
280
299
|
id: string;
|
|
281
300
|
label: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@draftably/mermaid",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "A drop-in for the mermaid package that draws diagrams with Draftably.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"mermaid-upstream": "npm:mermaid@12.2.0",
|
|
22
|
-
"@draftably/runtime": "0.
|
|
22
|
+
"@draftably/runtime": "0.6.0"
|
|
23
23
|
},
|
|
24
24
|
"engines": {
|
|
25
25
|
"node": ">=22.21.0"
|