@weasel-js/diagram 1.15.0 → 1.15.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.
Files changed (35) hide show
  1. package/README.md +114 -5
  2. package/dist/{chunk-GR2DK4S2.js → chunk-6YQSQXQT.js} +1485 -266
  3. package/dist/chunk-6YQSQXQT.js.map +1 -0
  4. package/dist/{chunk-FDCODMFW.js → chunk-7BV2MBED.js} +906 -606
  5. package/dist/chunk-7BV2MBED.js.map +1 -0
  6. package/dist/{chunk-IYUU5KUY.js → chunk-FQVZWS24.js} +11 -101
  7. package/dist/chunk-FQVZWS24.js.map +1 -0
  8. package/dist/{chunk-AXL4JQBM.js → chunk-LPTNAYER.js} +3 -3
  9. package/dist/{chunk-AXL4JQBM.js.map → chunk-LPTNAYER.js.map} +1 -1
  10. package/dist/{chunk-DE7UILJA.js → chunk-QGL6QJE4.js} +183 -23
  11. package/dist/chunk-QGL6QJE4.js.map +1 -0
  12. package/dist/{dataTypes-BIkhAOc4.d.ts → dataTypes-1ch6cMtq.d.ts} +12 -3
  13. package/dist/effect-audio.d.ts +2 -2
  14. package/dist/effect-audio.js +7 -11
  15. package/dist/effect-audio.js.map +1 -1
  16. package/dist/effect.d.ts +5 -5
  17. package/dist/effect.js +13 -20
  18. package/dist/effect.js.map +1 -1
  19. package/dist/icons.table.js +44 -0
  20. package/dist/icons.table.js.map +1 -1
  21. package/dist/icons.table.json +44 -0
  22. package/dist/index.d.ts +932 -37
  23. package/dist/index.js +707 -34
  24. package/dist/index.js.map +1 -1
  25. package/dist/{labelTrait-BBjRgxbz.d.ts → labelTrait-moIciyXr.d.ts} +4 -0
  26. package/dist/layout.d.ts +3 -3
  27. package/dist/{layout.entry-CbmGuqE-.d.ts → layout.entry-zstuljAl.d.ts} +2 -2
  28. package/dist/layout.js +2 -2
  29. package/dist/{stageTypes-UiO25hcn.d.ts → stageTypes-B7oF8Lww.d.ts} +1 -1
  30. package/dist/{types-B0n2CNTW.d.ts → types-D5ybp8Xh.d.ts} +32 -1
  31. package/package.json +12 -11
  32. package/dist/chunk-DE7UILJA.js.map +0 -1
  33. package/dist/chunk-FDCODMFW.js.map +0 -1
  34. package/dist/chunk-GR2DK4S2.js.map +0 -1
  35. package/dist/chunk-IYUU5KUY.js.map +0 -1
package/dist/index.d.ts CHANGED
@@ -1,17 +1,17 @@
1
- import { f as Port, g as DiagramNodeLike, h as DiagramNodeReader, C as ContainerRole, i as DiagramContainer, O as Outline, a as Row, B as BodySpec, M as MeasureRowText, j as ContainerHeader, E as EdgeHop, R as RowTextStyle, k as Bounds$2, d as LayoutOptions, l as LayoutResult, G as Graph, c as LayoutFn, m as GraphSource, n as LayoutPlanner, o as LayoutDirection, L as LayoutPorts, p as LayoutPlan, q as GraphNodeLike, S as StyleField, F as FontField } from './types-B0n2CNTW.js';
2
- export { r as BodyDivider, s as BodyFloor, t as BodyLayout, u as BuildGraphOptions, v as BuiltinOutline, w as DEFAULT_GROUP_INSET, x as DEFAULT_HOP_SIZE, y as DEFAULT_NODE_GAP, z as DEFAULT_RANK_GAP, A as DIAGRAM_TRAIT_KEY, H as DIVIDER_HEIGHT, D as DiagramGroup, e as DiagramNode, I as DiagramNodeEntry, J as EdgeLabelRoom, K as GraphEdge, N as GraphGroup, Q as GraphNode, T as GroupInset, U as HOPS_DOC_KEY, V as HopsDocValue, W as LayoutAxes, X as OutlineDef, P as PortAnchor, Y as PortSite, b as PortSpec, Z as RowBox, _ as RowPort, $ as RowPortBox, a0 as Slot, a1 as anchorOffset, a2 as axesFor, a3 as bodyBox, a4 as bodyOutline, a5 as bodyTrait, a6 as boxForContent, a7 as buildGraph, a8 as canvasMeasure, a9 as contentBox, aa as createDiagramNodes, ab as dataKeyReader, ac as diagramContainerOf, ad as diagramNodeOf, ae as expandGroupEdges, af as graphOrder, ag as headerBox, ah as insetOf, ai as isPinned, aj as layoutBody, ak as layoutRowPorts, al as measureBody, am as outlineDetail, an as outlinePath, ao as packAcross, ap as packClusters, aq as pinnedSet, ar as planOf, as as plannerPlan, at as rankGaps, au as registerOutline, av as seededOrder, aw as settle, ax as sizeToBody, ay as titleIdOf, az as translated, aA as untilSettled } from './types-B0n2CNTW.js';
3
- import { P as PortsOptions, A as AvoidInput, a as AvoidRouter, b as AvoidOptions, c as AvoidRoutes, d as PlaceLabelsOptions, F as ForceOptions } from './layout.entry-CbmGuqE-.js';
4
- export { e as AVOID_DEFAULTS, f as AvoidEdge, g as AvoidEnd, h as AvoidLabel, i as AvoidObstacle, j as AvoidPort, k as AvoidUpdateOptions, B as BodyNodeSpec, l as BuildBodyOptions, C as COMPASS, D as DEFAULT_PORTS, m as ForceBody, n as ForceRelaxation, o as Forest, L as LabelPlacements, p as LayeredPlan, q as PORT_LABEL_GAP, r as PerimeterPortLabelBox, s as PlaceLabel, t as PlaceLabelsInput, u as PlaceRoute, v as PortLabelPlacement, R as RowNodeData, w as backEdges, x as buildBody, y as chain, z as createAvoidRouter, E as edgeHops, G as footprintNode, H as force, I as forceRelaxation, J as forestOf, K as labelCenter, M as layered, N as layeredPlan, O as marginOf, Q as outlineFromD, S as outlinePolyline, T as placeLabels, U as portLabelBox, V as portLabelsOf, W as portOf, X as portSitesOf, Y as portsOf, Z as portsOnOutline, _ as radial, $ as ranksByLength, a0 as ranksOf, a1 as rayHit, a2 as routeHolds, a3 as subtreeBlocks, a4 as tree } from './layout.entry-CbmGuqE-.js';
5
- import { Vec2, ActionDeps, Action, InvocationCtx, TargetPredicate, GestureBinding, Contribution, DerivedDep, Path, SceneRegistry, paintsLayer, PoseDescriptor, ChromeState, CommandFill, CommandStroke, CursorSpec, Affordance, DropVerdict, Stroke, RectPose, DepName, CarryCallbacks, Carry, Tool, AddNodeSpec, NodeId, Scene, Op, MarkerRef, LayoutStrategy, ContainerBounds, RenderLayer, TransformFollower, PoseComposition, PlacedPage, Bounds as Bounds$3, GatedLayer, NodeShapeEntry, Paint, View, SelectionApi } from '@weasel-js/core';
1
+ import { f as Port, g as DiagramNodeLike, h as DiagramNodeReader, C as ContainerRole, i as DiagramContainer, O as Outline, a as Row, B as BodySpec, M as MeasureRowText, j as ContainerHeader, E as EdgeHop, R as RowTextStyle, k as Bounds$2, d as LayoutOptions, l as LayoutResult, G as Graph, c as LayoutFn, m as GraphSource, n as LayoutPlanner, o as LayoutDirection, L as LayoutPorts, p as LayoutPlan, q as GraphNodeLike, S as StyleField, F as FontField } from './types-D5ybp8Xh.js';
2
+ export { r as BodyDivider, s as BodyFloor, t as BodyLayout, u as BuildGraphOptions, v as BuiltinOutline, w as DEFAULT_GROUP_INSET, x as DEFAULT_HOP_SIZE, y as DEFAULT_NODE_GAP, z as DEFAULT_RANK_GAP, A as DIAGRAM_TRAIT_KEY, H as DIVIDER_HEIGHT, D as DiagramGroup, e as DiagramNode, I as DiagramNodeEntry, J as EdgeLabelRoom, K as GraphEdge, N as GraphGroup, Q as GraphNode, T as GridOptions, U as GroupInset, V as HOPS_DOC_KEY, W as HopsDocValue, X as LayoutAxes, Y as OutlineDef, P as PortAnchor, Z as PortSite, b as PortSpec, _ as RowBox, $ as RowPort, a0 as RowPortBox, a1 as Slot, a2 as anchorOffset, a3 as axesFor, a4 as bodyBox, a5 as bodyOutline, a6 as bodyTrait, a7 as boxForContent, a8 as buildGraph, a9 as canvasMeasure, aa as contentBox, ab as createDiagramNodes, ac as dataKeyReader, ad as diagramContainerOf, ae as diagramNodeOf, af as expandGroupEdges, ag as graphOrder, ah as grid, ai as headerBox, aj as insetOf, ak as isPinned, al as layoutBody, am as layoutRowPorts, an as measureBody, ao as outlineDetail, ap as outlinePath, aq as outlineSolid, ar as packAcross, as as packClusters, at as pinnedSet, au as planOf, av as plannerPlan, aw as rankGaps, ax as registerOutline, ay as seededOrder, az as settle, aA as sizeToBody, aB as titleIdOf, aC as translated, aD as untilSettled } from './types-D5ybp8Xh.js';
3
+ import { P as PortsOptions, A as AvoidInput, a as AvoidRouter, b as AvoidOptions, c as AvoidRoutes, d as PlaceLabelsOptions, F as ForceOptions } from './layout.entry-zstuljAl.js';
4
+ export { e as AVOID_DEFAULTS, f as AvoidEdge, g as AvoidEnd, h as AvoidLabel, i as AvoidObstacle, j as AvoidPort, k as AvoidUpdateOptions, B as BodyNodeSpec, l as BuildBodyOptions, C as COMPASS, D as DEFAULT_PORTS, m as ForceBody, n as ForceRelaxation, o as Forest, L as LabelPlacements, p as LayeredPlan, q as PORT_LABEL_GAP, r as PerimeterPortLabelBox, s as PlaceLabel, t as PlaceLabelsInput, u as PlaceRoute, v as PortLabelPlacement, R as RowNodeData, w as backEdges, x as buildBody, y as chain, z as createAvoidRouter, E as edgeHops, G as footprintNode, H as force, I as forceRelaxation, J as forestOf, K as labelCenter, M as layered, N as layeredPlan, O as marginOf, Q as outlineFromD, S as outlinePolyline, T as placeLabels, U as portLabelBox, V as portLabelsOf, W as portOf, X as portSitesOf, Y as portsOf, Z as portsOnOutline, _ as radial, $ as ranksByLength, a0 as ranksOf, a1 as rayHit, a2 as routeHolds, a3 as subtreeBlocks, a4 as tree } from './layout.entry-zstuljAl.js';
5
+ import { Vec2, ActionDeps, Action, InvocationCtx, TargetPredicate, GestureBinding, Contribution, DerivedDep, Path, SceneRegistry, paintsLayer, PoseDescriptor, ChromeState, CommandFill, CommandStroke, CursorSpec, Affordance, DropVerdict, Stroke, RectPose, DepName, CarryCallbacks, Carry, Tool, AddNodeSpec, NodeId, Scene, Op, MarkerRef, LayoutStrategy, ContainerBounds, RenderLayer, TransformFollower, PoseComposition, PlacedPage, Bounds as Bounds$3, GatedLayer, NodeShapeEntry, ToolsApi, Paint, View, SelectionApi, SceneCanvasTextEditor, ToolSet } from '@weasel-js/core';
6
6
  export { DropRefusal, DropVerdict } from '@weasel-js/core';
7
7
  import { Vec2 as Vec2$1, Path as Path$2 } from '@weasel-js/core/math';
8
8
  import * as react from 'react';
9
9
  import { PointerEvent as PointerEvent$1, ReactElement, ReactNode } from 'react';
10
- import { c as DataEdge, N as NodeStyle, a as DiagramData, b as DiagramSceneOptions, f as DiagramSpec, g as EdgeEnd, h as DiagramSceneData, i as DiagramEdge, O as OffPageSplit, D as DiagramTheme, E as EdgeStyle, j as DataContainer, d as DataNode } from './dataTypes-BIkhAOc4.js';
11
- export { A as ANCHOR_DERIVE_POSE, k as DEFAULT_LANE_SIZE, l as DEFAULT_NODE_STYLE, m as DEFAULT_POOL_ACROSS, n as DIAGRAM_ANCHOR, o as DIAGRAM_GROUP, p as DIAGRAM_ROLES, q as DIAGRAM_THEME_KEY, r as DataGroup, s as DataLane, t as DataMark, u as DiagramAnchor, v as DiagramDerivePose, w as DiagramFont, x as DiagramMark, y as DiagramRole, e as DiagramRouter, z as DiagramTextStyle, B as EDGE_STROKE_WIDTH, G as GROUP_DERIVE_POSE, C as GroupPoseOptions, L as LANE_STROKE_WIDTH, F as NODE_STROKE_WIDTH, H as OffPageTag, I as anchorDerivePose, J as boxAround, K as diagramAnchorOf, M as diagramEdgeOf, P as diagramGroupOf, Q as diagramMarkOf, R as groupDerivePose, S as layoutOwnsPort, T as layoutOwnsRoute, U as layoutWritesRoute, V as markShape, W as offPageTagId, X as offPageTagOf, Y as registerMarkShape, Z as rowTextStyle } from './dataTypes-BIkhAOc4.js';
10
+ import { c as DataEdge, N as NodeStyle, a as DiagramData, b as DiagramSceneOptions, f as DiagramSpec, g as EdgeEnd, h as DiagramSceneData, i as DiagramEdge, D as DiagramTheme, O as OffPageSplit, E as EdgeStyle, j as DataContainer, d as DataNode } from './dataTypes-1ch6cMtq.js';
11
+ export { A as ANCHOR_DERIVE_POSE, k as DEFAULT_LANE_SIZE, l as DEFAULT_NODE_STYLE, m as DEFAULT_POOL_ACROSS, n as DIAGRAM_ANCHOR, o as DIAGRAM_GROUP, p as DIAGRAM_ROLES, q as DIAGRAM_THEME_KEY, r as DataGroup, s as DataLane, t as DataMark, u as DiagramAnchor, v as DiagramDerivePose, w as DiagramFont, x as DiagramMark, y as DiagramRole, e as DiagramRouter, z as DiagramTextStyle, B as EDGE_STROKE_WIDTH, G as GROUP_DERIVE_POSE, C as GroupPoseOptions, L as LANE_STROKE_WIDTH, F as NODE_STROKE_WIDTH, H as OffPageTag, I as anchorDerivePose, J as boxAround, K as diagramAnchorOf, M as diagramEdgeOf, P as diagramGroupOf, Q as diagramMarkOf, R as groupDerivePose, S as layoutOwnsPort, T as layoutOwnsRoute, U as layoutWritesRoute, V as markShape, W as offPageTagId, X as offPageTagOf, Y as registerMarkShape, Z as rowTextStyle } from './dataTypes-1ch6cMtq.js';
12
12
  import { IconRef } from '@weasel-js/icons';
13
- import { D as DiagramLabel, L as LabelSpot } from './labelTrait-BBjRgxbz.js';
14
- export { a as LABEL_PLACEMENT, d as diagramLabelOf } from './labelTrait-BBjRgxbz.js';
13
+ import { D as DiagramLabel, L as LabelSpot } from './labelTrait-moIciyXr.js';
14
+ export { a as LABEL_PLACEMENT, d as diagramLabelOf } from './labelTrait-moIciyXr.js';
15
15
  import { Path as Path$1, Placement } from '@weasel-js/geom';
16
16
  import { EasingFn } from '@weasel-js/animator';
17
17
  import '@weasel-js/simulation';
@@ -659,8 +659,8 @@ interface RegionOptions<TLayer extends string> {
659
659
  }
660
660
  /** The node specs of one region, and its title unless `title` is null. */
661
661
  declare function regionSpecs<TLayer extends string>(role: ContainerRole, axis: 'x' | 'y', pose: RectPose, title: string | null, opts: RegionOptions<TLayer>): RegionSpec<TLayer>[];
662
- /** The lane specs a new pool at `at` starts with. */
663
- declare function firstLanes<TLayer extends string>(poolId: string, axis: 'x' | 'y', at: RectPose, opts: ContainerBuildOptions<TLayer>): RegionSpec<TLayer>[];
662
+ /** The lane specs a new pool at `at` starts with: one per title in `titles`, default `Lane 1` and `Lane 2`. */
663
+ declare function firstLanes<TLayer extends string>(poolId: string, axis: 'x' | 'y', at: RectPose, opts: ContainerBuildOptions<TLayer>, titles?: readonly string[]): RegionSpec<TLayer>[];
664
664
 
665
665
  /** A titled box, and pools of rows and of columns. */
666
666
  declare const CONTAINER_STENCILS: readonly ContainerStencil[];
@@ -685,6 +685,10 @@ interface ContainerStencil {
685
685
  };
686
686
  /** The glyph a palette draws on its button. */
687
687
  icon?: IconRef;
688
+ /** The title a new one is drawn with. Default `label`, and `'Pool'` for a pool. */
689
+ title?: string;
690
+ /** A new pool's lanes, by title, in the order they stack. Default two, `Lane 1` and `Lane 2`. */
691
+ lanes?: readonly string[];
688
692
  }
689
693
 
690
694
  type Bounds$1 = {
@@ -693,7 +697,7 @@ type Bounds$1 = {
693
697
  width: number;
694
698
  height: number;
695
699
  };
696
- type AnyScene$4 = Scene<unknown, string, unknown>;
700
+ type AnyScene$7 = Scene<unknown, string, unknown>;
697
701
  /** The ops that insert `stencil` at `bounds`: the region and its title, and a
698
702
  * pool's first lanes. Applied as one batch, they are one undo entry. */
699
703
  declare function containerBuild<TLayer extends string>(stencil: ContainerStencil, bounds: Bounds$1, opts: ContainerBuildOptions<TLayer>): {
@@ -703,19 +707,19 @@ declare function containerBuild<TLayer extends string>(stencil: ContainerStencil
703
707
  /** The axis a pool stacks its lanes along, read off its header. */
704
708
  declare const poolAxisOf: (pool: DiagramContainer) => "x" | "y";
705
709
  /** The lanes of `poolId`, in the order they stack. */
706
- declare function lanesOf(scene: AnyScene$4, poolId: string): NodeId[];
710
+ declare function lanesOf(scene: AnyScene$7, poolId: string): NodeId[];
707
711
  /**
708
712
  * Add a lane to `poolId` before the lane at `index`, or at the end of the
709
713
  * stack, as one history entry. The pool grows to hold it. Returns the new
710
714
  * lane's id, or null when `poolId` is not a pool.
711
715
  */
712
- declare function addLane(scene: AnyScene$4, poolId: string, index?: number, style?: NodeStyle): string | null;
716
+ declare function addLane(scene: AnyScene$7, poolId: string, index?: number, style?: NodeStyle): string | null;
713
717
  /**
714
718
  * Remove container `id` and keep its members, which take its place in its
715
719
  * parent, as one history entry. A pool's members are its lanes' members, and
716
720
  * a lane's go past its pool. Connectors on what is removed go with it.
717
721
  */
718
- declare function releaseMembers(scene: AnyScene$4, id: string): void;
722
+ declare function releaseMembers(scene: AnyScene$7, id: string): void;
719
723
 
720
724
  /**
721
725
  * The commands that set the selected connectors' router: Around shapes,
@@ -769,6 +773,8 @@ interface DiagramTypeEdge {
769
773
  router?: RouterName;
770
774
  markerStart?: MarkerRef | null;
771
775
  markerEnd?: MarkerRef | null;
776
+ /** A dash pattern, as `Stroke.dash`: a requirement's dashed relationship. Unset, solid. */
777
+ dash?: readonly number[];
772
778
  }
773
779
  /** A kind of diagram: the stencil groups a new one opens with, how its connectors start out, and the
774
780
  * layout Auto layout runs. */
@@ -781,12 +787,19 @@ interface DiagramType {
781
787
  edge?: DiagramTypeEdge;
782
788
  /** A key of `LAYOUTS`. Unset: no auto layout. */
783
789
  layout?: string;
790
+ /** The notations a graph page of this type is written in, as a document page's `notation` names them: the first
791
+ * is the one a page authored as this type takes, and a page imported in any of them opens as this type. Unset,
792
+ * a flowchart. */
793
+ notations?: readonly string[];
784
794
  }
785
795
  /** What {@link DIAGRAM_TYPE_DOC_KEY} holds: the diagram's type, and the groups its Shapes panel shows. */
786
796
  interface DiagramTypeDoc {
787
797
  type: string;
788
798
  groups: readonly string[];
789
799
  }
800
+ /** The notation a flowchart's page names, where it must name one to say it is not of its chart's type: a document
801
+ * page leaves `notation` unset for it. */
802
+ declare const FLOWCHART_NOTATION = "flowchart";
790
803
  /** The document value a diagram's type and shown stencil groups are saved under. */
791
804
  declare const DIAGRAM_TYPE_DOC_KEY = "diagram:type";
792
805
 
@@ -815,6 +828,9 @@ interface DiagramStencil {
815
828
  icon?: IconRef;
816
829
  /** Laid over the style the body is drawn in: a BPMN end event's heavier ring. */
817
830
  style?: Partial<NodeStyle>;
831
+ /** The theme role the body is drawn in, kept on its trait as an imported shape's is: C4's `muted` for what lies
832
+ * outside the system. The host resolves its colors (`StencilInsertOptions.theme`). */
833
+ themeRole?: string;
818
834
  /** How its body stacks its rows, as `BodySpec`'s fields of the same names. */
819
835
  padding?: number;
820
836
  gap?: number;
@@ -878,6 +894,8 @@ interface StencilInsertOptions {
878
894
  header: NodeStyle;
879
895
  bodies: readonly NodeStyle[];
880
896
  };
897
+ /** Resolves the role a stencil names (`DiagramStencil.themeRole`); one naming a role is drawn in `style` without it. */
898
+ theme?: DiagramTheme;
881
899
  }
882
900
  /**
883
901
  * Registers the `insert` dep for stencil kinds. Any other kind goes to the
@@ -1048,7 +1066,7 @@ interface LaneScratch {
1048
1066
  declare function laneScratchOf(hit: {
1049
1067
  payload?: unknown;
1050
1068
  } | null | undefined): LaneScratch | null;
1051
- type AnyScene$3 = Scene<unknown, string, unknown>;
1069
+ type AnyScene$6 = Scene<unknown, string, unknown>;
1052
1070
  /** A pool as the affordances see it: its box, the axis it stacks along, and its lanes in order.
1053
1071
  * `pose` is as stored, `at` where it draws. */
1054
1072
  interface PoolLanes {
@@ -1063,7 +1081,7 @@ interface PoolLanes {
1063
1081
  }[];
1064
1082
  }
1065
1083
  /** Every pool in `scene` that is drawn and not locked. */
1066
- declare function poolsOf(scene: AnyScene$3): PoolLanes[];
1084
+ declare function poolsOf(scene: AnyScene$6): PoolLanes[];
1067
1085
  /** Options for {@link laneLayer}. */
1068
1086
  interface LaneLayerOptions {
1069
1087
  /** Screen-pixel reach of a boundary either side of it. Default 4. */
@@ -1074,9 +1092,9 @@ interface LaneLayerOptions {
1074
1092
  stroke?: CommandStroke;
1075
1093
  }
1076
1094
  /** The affordance: a boundary region after each lane of each pool, and an add-lane button per pool. */
1077
- declare function createLaneAffordance(scene: AnyScene$3, opts?: LaneLayerOptions): Affordance;
1095
+ declare function createLaneAffordance(scene: AnyScene$6, opts?: LaneLayerOptions): Affordance;
1078
1096
  /** The composed layer, for `CanvasExtensionApi.registerLayer`. */
1079
- declare function laneLayer(scene: AnyScene$3, opts?: LaneLayerOptions): RenderLayer<unknown>;
1097
+ declare function laneLayer(scene: AnyScene$6, opts?: LaneLayerOptions): RenderLayer<unknown>;
1080
1098
 
1081
1099
  /**
1082
1100
  * The container actions: dragging the boundary after a lane resizes it, the
@@ -1091,7 +1109,7 @@ declare const LANE_RESIZE_ACTION_ID = "diagram.resizeLane";
1091
1109
  declare const ADD_LANE_ACTION_ID = "diagram.addLane";
1092
1110
  /** The command that removes the selected containers and keeps their members. */
1093
1111
  declare const RELEASE_MEMBERS_ACTION_ID = "diagram.releaseMembers";
1094
- type AnyScene$2 = Scene<unknown, string, unknown>;
1112
+ type AnyScene$5 = Scene<unknown, string, unknown>;
1095
1113
  /** A lane resized: its new size along its pool's stack. */
1096
1114
  interface LaneResize {
1097
1115
  poolId: string;
@@ -1103,10 +1121,10 @@ interface LaneResize {
1103
1121
  declare function commitLaneResizeToScene(resize: LaneResize, ctx: InvocationCtx): void;
1104
1122
  /** Where everything stands with the lane at `index` of `pool` resized to `size`: the
1105
1123
  * lane, its title, the pool and its title, and every later lane with what it holds. */
1106
- declare function laneResizeFrame(scene: AnyScene$2, pool: PoolLanes, index: number, size: number): Map<string, RectPose>;
1124
+ declare function laneResizeFrame(scene: AnyScene$5, pool: PoolLanes, index: number, size: number): Map<string, RectPose>;
1107
1125
  /** Options for the container actions. */
1108
1126
  interface LaneActionOptions extends LaneLayerOptions {
1109
- scene: AnyScene$2;
1127
+ scene: AnyScene$5;
1110
1128
  /** The selected ids, which Release members reads. */
1111
1129
  selected?: () => readonly string[];
1112
1130
  /** Defaults to {@link commitLaneResizeToScene}. */
@@ -1790,6 +1808,10 @@ declare function labelSize(text: string, style: RowTextStyle, measure?: MeasureR
1790
1808
  width: number;
1791
1809
  height: number;
1792
1810
  };
1811
+ /** The id of the label at edge `edgeId`'s `from` or `to` end (`DataEdge.endLabels`). */
1812
+ declare const endLabelIdOf: (edgeId: string, end: "from" | "to") => string;
1813
+ /** Where an end label sits: just off the end, to the left of travel. `to`'s is at `'end'`. */
1814
+ declare const END_LABEL_PLACEMENT: DiagramLabel;
1793
1815
  /** Options for {@link edgeLabelSpec}. */
1794
1816
  interface EdgeLabelOptions<TLayer extends string> {
1795
1817
  layer: TLayer;
@@ -1801,8 +1823,11 @@ interface EdgeLabelOptions<TLayer extends string> {
1801
1823
  /** Sizes the box. Default: a per-character estimate. */
1802
1824
  measure?: MeasureRowText;
1803
1825
  }
1804
- /** The label node for edge `edgeId`: a leaf that derives its pose from the edge's route. */
1805
- declare function edgeLabelSpec<TLayer extends string>(edgeId: string, text: string, opts: EdgeLabelOptions<TLayer>): AddNodeSpec<unknown, TLayer, RectPose>;
1826
+ /** The label node for edge `edgeId`: a leaf that derives its pose from the edge's route. `id` defaults to
1827
+ * `<edgeId>/label`. */
1828
+ declare function edgeLabelSpec<TLayer extends string>(edgeId: string, text: string, opts: EdgeLabelOptions<TLayer> & {
1829
+ id?: string;
1830
+ }): AddNodeSpec<unknown, TLayer, RectPose>;
1806
1831
  /**
1807
1832
  * Removes node `id` if it is an edge label left with no text, and says whether
1808
1833
  * it did. The default edit adds a label before its text is typed, so a host
@@ -1862,9 +1887,9 @@ interface DraggableLabel {
1862
1887
  }
1863
1888
  /** Every editable label in `scene` whose edge derives a path, in render order. */
1864
1889
  declare function draggableLabels(scene: Scene<unknown, string, unknown>): Iterable<DraggableLabel>;
1865
- type AnyScene$1 = Scene<unknown, string, unknown>;
1890
+ type AnyScene$4 = Scene<unknown, string, unknown>;
1866
1891
  /** The topmost draggable label whose box holds `at`, as its press scratch. */
1867
- declare function labelUnder(scene: AnyScene$1, at: Vec2$1): LabelScratch | null;
1892
+ declare function labelUnder(scene: AnyScene$4, at: Vec2$1): LabelScratch | null;
1868
1893
  /** The composed layer, for `CanvasExtensionApi.registerLayer`. Register it
1869
1894
  * before the port layer: the last registered is hit first, and a port or a
1870
1895
  * route handle must win over a label beside it. */
@@ -2188,7 +2213,8 @@ declare function subpathOf(path: Path$1, index: number): Path$1 | null;
2188
2213
  * so their own pose is a placeholder, and a resize handle on it sits at the
2189
2214
  * origin and resizes nothing. A group's box is its members' union, and a
2190
2215
  * pool's lane is sized by its pool's stack and resized by dragging its
2191
- * boundary.
2216
+ * boundary. A sequence's part is drawn from its root's data, and a selected
2217
+ * one is there to be deleted, not resized.
2192
2218
  */
2193
2219
  declare function diagramResizable(scene: {
2194
2220
  get(id: never): {
@@ -2681,6 +2707,175 @@ declare function diagramLayoutOf(specs: readonly DiagramSpec[]): {
2681
2707
  containers: ContainerEdit[];
2682
2708
  };
2683
2709
 
2710
+ /**
2711
+ * A sequence diagram as plain data: participants left to right, and the steps
2712
+ * between them top to bottom, one row each.
2713
+ */
2714
+
2715
+ /** One column: a head drawn at the top, and the lifeline under it. */
2716
+ interface SeqParticipant {
2717
+ /** Messages, notes, and boxes name it by this. */
2718
+ id: string;
2719
+ /** What its head says. Default its id. */
2720
+ label?: string;
2721
+ /** Default `'rect'`. `actor`, `boundary`, `control`, `entity`, `cylinder`, `collections`, and `queue` are the UML figures. */
2722
+ outline?: Outline;
2723
+ /** The theme role its head is drawn in. */
2724
+ style?: string;
2725
+ /** Colors of its own, over its role's. */
2726
+ colors?: Partial<NodeStyle>;
2727
+ }
2728
+ /** A message from one lifeline to another, or to itself. */
2729
+ interface SeqMessage {
2730
+ kind: 'message';
2731
+ id: string;
2732
+ from: string;
2733
+ to: string;
2734
+ text?: string;
2735
+ line: 'solid' | 'dashed';
2736
+ head: 'arrow' | 'open' | 'cross' | 'none';
2737
+ /** An arrowhead at the `from` end too. */
2738
+ both?: boolean;
2739
+ /** Sent without waiting for an answer. */
2740
+ async?: boolean;
2741
+ /** Starts an activation on that end, at this message. */
2742
+ activate?: 'to' | 'from';
2743
+ /** Ends the innermost activation on that end, at this message. */
2744
+ deactivate?: 'to' | 'from';
2745
+ }
2746
+ /** A note beside one lifeline, or over one or more. */
2747
+ interface SeqNote {
2748
+ kind: 'note';
2749
+ id: string;
2750
+ /** Participant ids. Over two, it spans from the first to the last. */
2751
+ over: readonly string[];
2752
+ /** Beside its participant rather than over it. */
2753
+ side?: 'left' | 'right';
2754
+ text: string;
2755
+ }
2756
+ /** A lifeline's activation starting or ending, its head created, or its lifeline ended. */
2757
+ interface SeqMark {
2758
+ kind: 'activate' | 'deactivate' | 'create' | 'destroy';
2759
+ participant: string;
2760
+ }
2761
+ /** A run of steps boxed together: a loop, the branches of an alt, the threads of a par. */
2762
+ interface SeqFragment {
2763
+ kind: 'fragment';
2764
+ id: string;
2765
+ /** `region` is a plain colored box, with no type tab. */
2766
+ type: 'loop' | 'alt' | 'opt' | 'par' | 'critical' | 'break' | 'region';
2767
+ /** One for most types; an `alt`'s branches, a `par`'s threads, a `critical`'s options each start another. */
2768
+ sections: readonly SeqSection[];
2769
+ colors?: Partial<NodeStyle>;
2770
+ }
2771
+ /** One section of a fragment: its guard or title, and its steps. */
2772
+ interface SeqSection {
2773
+ label?: string;
2774
+ steps: readonly SeqStep[];
2775
+ }
2776
+ /** One row of a sequence, or a fragment holding a run of rows. */
2777
+ type SeqStep = SeqMessage | SeqNote | SeqMark | SeqFragment;
2778
+ /** A box drawn around some participants' columns. */
2779
+ interface SeqBox {
2780
+ id: string;
2781
+ label?: string;
2782
+ /** Participant ids. */
2783
+ members: readonly string[];
2784
+ colors?: Partial<NodeStyle>;
2785
+ }
2786
+ /** A sequence diagram, the data `sequenceSpecs` draws. */
2787
+ interface SequenceData {
2788
+ participants: readonly SeqParticipant[];
2789
+ /** Top to bottom, one row each; a fragment holds a run. */
2790
+ steps: readonly SeqStep[];
2791
+ boxes?: readonly SeqBox[];
2792
+ /** Messages are numbered from this one. Unset, they are not numbered. */
2793
+ autonumber?: number;
2794
+ }
2795
+ /** A step with an id of its own: a message, a note, or a fragment. */
2796
+ type SeqIdStep = SeqMessage | SeqNote | SeqFragment;
2797
+ /** Where a step stands: the list it is in (`null` the top level, else a fragment's section), and its place in it. */
2798
+ interface StepPlace {
2799
+ parent: {
2800
+ fragment: string;
2801
+ section: number;
2802
+ } | null;
2803
+ index: number;
2804
+ }
2805
+ /** A run of text in a sequence an edit can set: a head's, a message's or note's, a fragment section's label, or a box's. */
2806
+ type SeqTextTarget = {
2807
+ participant: string;
2808
+ } | {
2809
+ step: string;
2810
+ } | {
2811
+ fragment: string;
2812
+ section: number;
2813
+ } | {
2814
+ box: string;
2815
+ };
2816
+ /**
2817
+ * What starts or ends an activation, or ends a lifeline: a mark step, by where
2818
+ * it stands, or a message's `activate` or `deactivate` flag.
2819
+ */
2820
+ type SeqMarkRef = {
2821
+ place: StepPlace;
2822
+ } | {
2823
+ message: string;
2824
+ flag: 'activate' | 'deactivate';
2825
+ };
2826
+
2827
+ /**
2828
+ * Writing a sequence edit into a scene: the root's data replaced and its parts
2829
+ * built again, as one undo entry.
2830
+ */
2831
+
2832
+ type AnyScene$3 = Scene<unknown, string, unknown>;
2833
+ /** How a scene's sequences are drawn when an edit builds their parts again. */
2834
+ interface SequenceDrawOptions {
2835
+ /** Measures text. Default an estimate from character count; pass what the sequence was first drawn with. */
2836
+ measure?: MeasureRowText;
2837
+ /** Default the scene's own `diagram:theme`. */
2838
+ theme?: DiagramTheme;
2839
+ }
2840
+ /** Replaces root `id`'s sequence with `data` and builds its parts again, as one undo entry under `label`. */
2841
+ declare function commitSequence(scene: AnyScene$3, id: string, data: SequenceData, label: string, opts?: SequenceDrawOptions): void;
2842
+ /**
2843
+ * Adds a new sequence root drawing `data` with its top-left corner at `at`,
2844
+ * as one undo entry under `label`, and returns its id. On `layer`, default
2845
+ * the scene's first.
2846
+ */
2847
+ declare function startSequence(scene: AnyScene$3, at: {
2848
+ x: number;
2849
+ y: number;
2850
+ }, data: SequenceData, label: string, opts?: SequenceDrawOptions & {
2851
+ layer?: string;
2852
+ }): string;
2853
+ /** Builds every sequence in `scene` again from its own data, in the batch the caller has open: after a theme change. */
2854
+ declare function redrawSequences(scene: AnyScene$3, opts?: SequenceDrawOptions): void;
2855
+ /** A sequence edit: root `id`'s new data. */
2856
+ interface SequenceEdit {
2857
+ id: string;
2858
+ data: SequenceData;
2859
+ /** What undo calls it. */
2860
+ label: string;
2861
+ }
2862
+ /**
2863
+ * Folds a text edit that has just been written to one of a sequence's text
2864
+ * parts into its root's data: the edit is undone and `commit` gets the
2865
+ * sequence with the new text, so the change is one entry on the data, not a
2866
+ * part that the next build would overwrite. Does nothing for any other node,
2867
+ * or text that did not change.
2868
+ */
2869
+ declare function foldSequenceText(scene: AnyScene$3, textId: string, commit: (edit: SequenceEdit) => void): void;
2870
+ /** Options for a sequence's editing actions: how an edit is committed and drawn. */
2871
+ interface SequenceEditOptions extends SequenceDrawOptions {
2872
+ /** Defaults to {@link commitSequence} against `deps.scene`, with the draw options. */
2873
+ commit?: (edit: SequenceEdit, ctx: Pick<InvocationCtx, 'deps'>) => void;
2874
+ id?: string;
2875
+ }
2876
+ /** `opts.commit`, or {@link commitSequence} against the scene the edit's deps hold, drawn with `opts`. */
2877
+ declare function sequenceCommitOf(opts: SequenceEditOptions): (edit: SequenceEdit, ctx: Pick<InvocationCtx, 'deps'>) => void;
2878
+
2684
2879
  /** One end of a data edge moved onto node `node`, at `port` or on its body. */
2685
2880
  interface ReconnectChange {
2686
2881
  /** The data edge's id, `edgeIdOf` of it. */
@@ -2805,6 +3000,11 @@ interface DiagramViewProps {
2805
3000
  onReorder?: (change: ReorderChange) => void;
2806
3001
  /** Set to report a double-click on an edge, for its label to be edited. */
2807
3002
  onEditLabel?: (edge: string) => void;
3003
+ /** Set to edit the sequences `sequenceSpecs` drew: drag a message, note, or fragment to another row, a head
3004
+ * to another column, a message end to another lifeline, double-click text to edit it in place, click a part
3005
+ * to select it, and press Delete to remove it. Reports each edit as the sequence's new data and draws
3006
+ * nothing: rebuild its specs from it. `useSequenceTools`, passed as `tools`, adds to a sequence. */
3007
+ onEditSequence?: (edit: SequenceEdit) => void;
2808
3008
  /** Set to let an edge's label be dragged along and beside it, and to enable
2809
3009
  * Reset label for the selected edge. Reports the placement and draws
2810
3010
  * nothing; store it as the data edge's `labelPlacement`, and delete that
@@ -2823,6 +3023,10 @@ interface DiagramViewProps {
2823
3023
  connectBodies?: boolean;
2824
3024
  /** Contributions to install after the view's own: a tool's bindings, a key. */
2825
3025
  ambient?: readonly Contribution[];
3026
+ /** Tools the user can pick beside select, keyed by id, as `<SceneCanvas tools>` takes them: `useSequenceTools`'s, say. */
3027
+ tools?: Record<string, Tool>;
3028
+ /** Called with the canvas's tools, for a palette to pick them from. */
3029
+ onToolsCreated?: (tools: ToolsApi) => void;
2826
3030
  /** Whether ports are drawn. `'connect'` draws them and lets one be dragged
2827
3031
  * onto another; `'show'` only draws them. Default: `'connect'` when
2828
3032
  * `onConnect` is set, else `'none'`. */
@@ -3066,7 +3270,7 @@ declare function relayoutBodies(scene: RelayoutScene, ids: Iterable<string>, mea
3066
3270
  * naming a shape's or connector's role, and setting a color by hand.
3067
3271
  */
3068
3272
 
3069
- type AnyScene = Scene<unknown, string, unknown>;
3273
+ type AnyScene$2 = Scene<unknown, string, unknown>;
3070
3274
  /** What a styleable node says about its style: a shape or a connector, the role it names, and the
3071
3275
  * colors its author set by hand. */
3072
3276
  interface DiagramStyleState {
@@ -3094,7 +3298,7 @@ interface ApplyDiagramThemeOptions {
3094
3298
  }
3095
3299
  /** Recolors the whole scene in `theme` and saves it as the `diagram:theme` document value, as one
3096
3300
  * undo entry. Colors the author set by hand stay. */
3097
- declare function applyDiagramTheme(scene: AnyScene, theme: DiagramTheme, label?: string, opts?: ApplyDiagramThemeOptions): void;
3301
+ declare function applyDiagramTheme(scene: AnyScene$2, theme: DiagramTheme, label?: string, opts?: ApplyDiagramThemeOptions): void;
3098
3302
  /** Options for {@link setDiagramStyle} and {@link setDiagramColor}. */
3099
3303
  interface DiagramStyleEditOptions {
3100
3304
  /** The theme to color by. Default the scene's own `diagram:theme`. */
@@ -3106,20 +3310,20 @@ interface DiagramStyleEditOptions {
3106
3310
  * it, as one undo entry. Choosing a role hands back any color the author had
3107
3311
  * set, so the role shows.
3108
3312
  */
3109
- declare function setDiagramStyle(scene: AnyScene, ids: readonly string[], role: string, opts?: DiagramStyleEditOptions): void;
3313
+ declare function setDiagramStyle(scene: AnyScene$2, ids: readonly string[], role: string, opts?: DiagramStyleEditOptions): void;
3110
3314
  /**
3111
3315
  * Sets `field` to `color` on every shape and connector among `ids` — `text`
3112
3316
  * reaching a shape's rows and a connector's label — and records it in their
3113
3317
  * `ownStyle`, so a theme change leaves it. One undo entry. A connector has no
3114
3318
  * fill, and ignores one.
3115
3319
  */
3116
- declare function setDiagramColor(scene: AnyScene, ids: readonly string[], field: StyleField, color: string, opts?: Pick<DiagramStyleEditOptions, 'label'>): void;
3320
+ declare function setDiagramColor(scene: AnyScene$2, ids: readonly string[], field: StyleField, color: string, opts?: Pick<DiagramStyleEditOptions, 'label'>): void;
3117
3321
  /**
3118
3322
  * Sets the text of every shape and connector among `ids` — a shape's rows, a
3119
3323
  * connector's label — to `size`, and records it in their `ownFont`, so a
3120
3324
  * theme's size change leaves it. One undo entry.
3121
3325
  */
3122
- declare function setDiagramFontSize(scene: AnyScene, ids: readonly string[], size: number, opts?: Pick<DiagramStyleEditOptions, 'label'> & {
3326
+ declare function setDiagramFontSize(scene: AnyScene$2, ids: readonly string[], size: number, opts?: Pick<DiagramStyleEditOptions, 'label'> & {
3123
3327
  measure?: MeasureRowText;
3124
3328
  }): void;
3125
3329
 
@@ -3181,6 +3385,18 @@ declare const MIND_MAP_TYPE: DiagramType;
3181
3385
  declare const UML_CLASS_TYPE: DiagramType;
3182
3386
  /** An entity-relationship diagram: connectors routed orthogonally, one at the start and many at the end. */
3183
3387
  declare const ERD_TYPE: DiagramType;
3388
+ /** A state machine: states and pseudostates, composites holding more, transitions ending in an arrow. */
3389
+ declare const STATE_TYPE: DiagramType;
3390
+ /** A requirement diagram: requirements and the elements meeting them, joined by dashed relationships. */
3391
+ declare const REQUIREMENT_TYPE: DiagramType;
3392
+ /** A C4 model, at any of its levels: a page authored as one is a context diagram. */
3393
+ declare const C4_TYPE: DiagramType;
3394
+ /** A block diagram: the flowchart's shapes, laid out on a grid. */
3395
+ declare const BLOCK_TYPE: DiagramType;
3396
+ /** An architecture diagram: services in groups, joined square at their sides with plain links. */
3397
+ declare const ARCHITECTURE_TYPE: DiagramType;
3398
+ /** A kanban board: a pool of column lanes, cards stacked down them, and no connectors. */
3399
+ declare const KANBAN_TYPE: DiagramType;
3184
3400
  /** The diagram types this package ships, by id, in menu order. */
3185
3401
  declare const DIAGRAM_TYPES: Readonly<Record<string, DiagramType>>;
3186
3402
  /** Whether `stencil` is a container's rather than a shape's. */
@@ -3190,7 +3406,13 @@ declare function groupStencils(ids: readonly string[], catalog?: Readonly<Record
3190
3406
  /** The ids of `group`'s stencils. */
3191
3407
  declare const groupStencilIds: (group: StencilGroup) => string[];
3192
3408
 
3193
- /** A scene as the type reader and writers use it. */
3409
+ /** A scene as the type readers use it. */
3410
+ interface DiagramTypeReadable {
3411
+ doc: {
3412
+ get(key: string): unknown;
3413
+ };
3414
+ }
3415
+ /** A scene as the type writers use it. */
3194
3416
  interface DiagramTypeScene {
3195
3417
  doc: {
3196
3418
  get(key: string): unknown;
@@ -3209,9 +3431,13 @@ interface DiagramTypeWriteOptions {
3209
3431
  declare function diagramTypeDocValue(id: string, types?: Types): DiagramTypeDoc;
3210
3432
  /** The type and shown groups a scene holds. A scene holding none, or naming a type `types` lacks,
3211
3433
  * reads as flowchart with its groups. */
3212
- declare function diagramTypeDocOf(scene: Pick<DiagramTypeScene, 'doc'>, types?: Types): DiagramTypeDoc;
3434
+ declare function diagramTypeDocOf(scene: DiagramTypeReadable, types?: Types): DiagramTypeDoc;
3213
3435
  /** The type a scene holds, as {@link diagramTypeDocOf} reads it. */
3214
- declare function diagramTypeOf(scene: Pick<DiagramTypeScene, 'doc'>, types?: Types): DiagramType;
3436
+ declare function diagramTypeOf(scene: DiagramTypeReadable, types?: Types): DiagramType;
3437
+ /** The notation a graph page of the scene's type is written in. */
3438
+ declare const diagramNotationOf: (scene: DiagramTypeReadable, types?: Types) => string;
3439
+ /** The type whose pages `notation` writes, unset read as a flowchart's; `null` when no type in `types` claims it. */
3440
+ declare function diagramTypeOfNotation(notation: string | undefined, types?: Types): DiagramType | null;
3215
3441
  /** Makes the scene type `id`, its shown groups replaced by the type's. */
3216
3442
  declare function setDiagramType(scene: DiagramTypeScene, id: string, opts?: DiagramTypeWriteOptions): void;
3217
3443
  /** Shows stencil group `id` after the ones shown. Nothing when it is shown already. */
@@ -3220,7 +3446,7 @@ declare function addStencilGroup(scene: DiagramTypeScene, id: string, opts?: Dia
3220
3446
  declare function removeStencilGroup(scene: DiagramTypeScene, id: string, opts?: DiagramTypeWriteOptions): void;
3221
3447
 
3222
3448
  /** The stroke a new connector in a diagram of `type` starts with: the theme's, with each end marker
3223
- * the type sets put over it. A marker set to `null` draws no marker on that end. */
3449
+ * the type sets put over it, and its dash. A marker set to `null` draws no marker on that end. */
3224
3450
  declare function diagramTypeEdgeStroke(theme: DiagramTheme, type: DiagramType): Stroke;
3225
3451
 
3226
3452
  /** Network devices, each labeled under its drawing. A database and a cloud wear the general figures, with their labels inside. */
@@ -3267,4 +3493,673 @@ declare const ERD_STENCILS: readonly DiagramStencil[];
3267
3493
  /** The ERD symbols as a stencil group. */
3268
3494
  declare const ERD_GROUP: StencilGroup;
3269
3495
 
3270
- export { ADD_LANE_ACTION_ID, type ApplyDiagramThemeOptions, type ApplyLayoutOptions, AvoidInput, AvoidOptions, AvoidRouter, AvoidRoutes, type AvoidRouting, type AvoidRoutingOptions, type AvoidSceneOptions, BPMN_GROUP, BPMN_STENCILS, BPMN_TYPE, type BodyEnd, type BodyHit, BodySpec, Bounds$2 as Bounds, CONNECTOR_ACTION_ID, CONNECTOR_TOOL_ID, CONNECT_ACTION_ID, CONTAINERS_GROUP, CONTAINER_HEADER, CONTAINER_LAYOUTS, CONTAINER_STENCILS, type CanConnect, type CanDropItem, type CanReparent, type ConnectActionOptions, type ConnectEnd, type ConnectView, type ContainerBuildOptions, type ContainerEdit, ContainerHeader, type ContainerLayoutOptions, ContainerRole, type ContainerStencil, DEFAULT_EDGE_STROKE, DEFAULT_EDGE_STYLE, DEFAULT_GROUP_STYLE, DIAGRAM_CONTAINER_LAYOUT, DIAGRAM_EDGE, DIAGRAM_ITEM_CARRY, DIAGRAM_LABEL, DIAGRAM_LANE_COLUMNS_LAYOUT, DIAGRAM_LANE_ROWS_LAYOUT, DIAGRAM_OFF_PAGE_TAG, DIAGRAM_PASS_ORDER, DIAGRAM_POOL_COLUMNS_LAYOUT, DIAGRAM_POOL_ROWS_LAYOUT, DIAGRAM_THEMES, DIAGRAM_THEME_EXTENSION, DIAGRAM_TYPES, DIAGRAM_TYPE_DOC_KEY, DataContainer, DataEdge, DataNode, type DeleteReport, DiagramContainer, type DiagramContributionOptions, DiagramData, DiagramEdge, DiagramLabel, type DiagramLayout, DiagramNodeLike, DiagramNodeReader, type DiagramOverlay, DiagramSceneData, DiagramSceneOptions, type DiagramShapeOptions, DiagramSpec, type DiagramStencil, type DiagramStyleEditOptions, type DiagramStyleState, DiagramTheme, type DiagramType, type DiagramTypeDoc, type DiagramTypeEdge, type DiagramTypeScene, type DiagramTypeWriteOptions, DiagramView, type DiagramViewApi, type DiagramViewProps, type DraggableLabel, type DropParentScene, EASED_LAYOUTS, EDGE_DERIVE_PATH, EDGE_END_AFFORDANCE_KIND, EDGE_END_LAYER_ID, EDIT_CONTAINER_TITLE_ACTION_ID, EDIT_EDGE_LABEL_ACTION_ID, ERD_GROUP, ERD_STENCILS, ERD_TYPE, type EasedProducerOptions, EdgeEnd, type EdgeEndAffordanceOptions, type EdgeEndScratch, EdgeHop, type EdgeLabelOptions, type EdgeRoute, type EdgeRouteOptions, type EdgeRouteState, EdgeStyle, type EditEdgeLabelOptions, type EndChange, FLOWCHART_GROUP, FLOWCHART_STENCILS, FLOWCHART_TYPE, FOLLOW_OFF_PAGE_ACTION_ID, type FollowOffPageOptions, FontField, ForceOptions, type ForceProducerOptions, GRAB_EDGE_END_ACTION_ID, GRAB_LABEL_ACTION_ID, GRAB_PORT_ACTION_ID, GRAB_WAYPOINT_ACTION_ID, Graph, GraphNodeLike, GraphSource, type Hops, type HopsOptions, ITEM_DROP_ACTION_ID, type ItemDrop, type ItemDropOptions, type ItemDropTarget, LABEL_DERIVE_POSE, LABEL_DRAG_AFFORDANCE_KIND, LABEL_DRAG_LAYER_ID, LANE_AFFORDANCE_KIND, LANE_HEADER_SIZE, LANE_LAYER_ID, LANE_RESIZE_ACTION_ID, LAYOUTS, LAYOUT_ACTION_ID, type LabelDragOptions, type LabelEdit, type LabelMove, type LabelPlacement, type LabelPlacementOptions, type LabelPoseOptions, type LabelScratch, LabelSpot, type LaneActionOptions, type LaneLayerOptions, type LaneResize, type LaneScratch, type LaneStackOptions, type LayeredRoute, type LayeredRouteInput, type LayoutActionOptions, type LayoutDiagramOptions, LayoutDirection, LayoutFn, LayoutOptions, LayoutPlan, LayoutPlanner, LayoutPorts, LayoutResult, type LayoutRoutes, type LiveLayout, type LiveLayoutCtx, type LiveLayoutFrame, type LiveLayoutProducer, MIND_MAP_GROUP, MIND_MAP_STENCILS, MIND_MAP_TYPE, MIN_LANE_SIZE, MOVE_LABEL_ACTION_ID, MeasureRowText, type MovingEnd, NETWORK_GROUP, NETWORK_STENCILS, NETWORK_TYPE, type NodeMove, type NodeResize, NodeStyle, OFF_PAGE_STUB, OFF_PAGE_TAG_DERIVE_POSE, OFF_PAGE_TAG_PADDING, ORG_CHART_TYPE, ORG_GROUP, ORG_STENCILS, type OffPageEdgeInput, type OffPageMarkerOptions, OffPageSplit, type OffPageSplitInput, type OffPageTagLook, type OffPageTarget, Outline, POOL_HEADER_SIZE, PORT_AFFORDANCE_KIND, PORT_LAYER_ID, type ParticipantPose, type ParticipantScene, type ParticipantSource, type PendingEdge, PlaceLabelsOptions, type PoolLanes, Port, type PortAffordanceOptions, type PortScratch, PortsOptions, RECONNECT_ACTION_ID, RELEASE_MEMBERS_ACTION_ID, REMOVE_WAYPOINT_ACTION_ID, REORDER_ACTION_ID, RESET_LABEL_ACTION_ID, RESET_ROUTE_ACTION_ID, ROUTERS, ROUTER_LABELS, ROUTE_EDIT_ACTION_ID, type ReconnectChange, type ReconnectOptions, type RegionOptions, type RegionSpec, type RelayoutScene, type ReorderChange, type ReorderGap, type ReorderItem, type ReorderMove, type ReorderOptions, type ReorderSlots, type ResolvedRoute, type RouteChange, type RouteEdge, type RouteEdit, type RouteEditOptions, type RouteHandle, type RouteRequest, type RoutedScene, type Router, type RouterEdit, type RouterName, Row, RowTextStyle, SELECT_LABEL_EDGE_ACTION_ID, SET_HOPS_ACTION_ID, SET_ROUTER_ACTION_IDS, STENCIL_GROUPS, STEP_REORDER_ACTION_ID, type SelfLoop, type SetHopsOptions, type SetRouterOptions, type SpecRouterOptions, StencilGhost, type StencilGhostProps, type StencilGroup, type StencilInsertOptions, StyleField, type StyledRegion, type ThemePath, type ThemedNode, type ThemedScene, UML_CLASS_TYPE, UML_GROUP, UML_STENCILS, type UseLiveLayoutOptions, WAYPOINT_AFFORDANCE_KIND, WAYPOINT_HIT_PX, WAYPOINT_LAYER_ID, type WaypointAffordanceOptions, type WaypointScratch, addLane, addStencilGroup, addThemeRole, applyDiagramTheme, applyLayout, avoid, avoidSceneInput, bezier, bodyAt, bodyFollower, commitEdgeToScene, commitLabelToScene, commitLaneResizeToScene, commitReconnectToScene, commitRouteToScene, commitRouterToScene, connectBinding, connectorTool, containerBuild, containerShape, createAddLaneAction, createConnectAction, createDiagramContribution, createEdgeEndAffordance, createFollowOffPageAction, createItemDropAction, createLabelDragAction, createLaneAffordance, createLaneResizeAction, createLayoutAction, createPortAffordance, createReconnectAction, createReleaseMembersAction, createRemoveWaypointAction, createReorderAction, createResetLabelAction, createResetRouteAction, createRouteEditAction, createSetHopsAction, createSetRouterAction, createSpecHops, createSpecLabelPlacer, createSpecRouter, createStepReorderAction, createWaypointAffordance, dataEdgeStyle, dataNodeStyle, dataOffPage, dataRegionStyle, defaultCanConnect, diagramCanDropInto, diagramContainerLayout, diagramContainers, diagramDropParentAt, diagramEdgeEnds, diagramLabelDrag, diagramLayoutOf, diagramOffPage, diagramPages, diagramPorts, diagramResizable, diagramScene, diagramShape, diagramStyleOf, diagramThemeFrom, diagramThemeFromTokens, diagramThemeOf, diagramTypeDocOf, diagramTypeDocValue, diagramTypeEdgeStroke, diagramTypeOf, diagramWaypoints, documentBoundsOf, dragItemProps, dragSegment, dragVertex, draggableLabels, dropEmptyEdgeLabel, easedProducer, edgeDerivePath, edgeEndLayer, edgeEndScratchOf, edgeIdOf, edgeLabelSpec, edgeRouter, editContainerTitleAction, editContainerTitleBinding, editEdgeLabelAction, editEdgeLabelBinding, editableTheme, firstLanes, followOffPageBinding, forceProducer, forkTheme, grabPortAction, grabPortBindings, groupReorderContribution, groupReorderSlots, groupStencilIds, groupStencils, headerIdOf, hopFollower, insertWaypoint, installAvoidRouting, installHops, installLabelPlacement, installOffPageMarkers, isBodyEnd, isBodyOrRegion, isContainerStencil, isDiagramBody, isShippedTheme, itemDropContribution, labelDerivePose, labelDragLayer, labelScratchOf, labelSize, labelUnder, laneHeader, laneLayer, laneResizeFrame, laneScratchOf, laneStackLayout, lanesOf, layeredRoutes, layoutDiagram, layoutPoses, movedLabelData, nextOffPageRef, offPageFarText, offPageOps, offPageSplits, offPageTagData, offPageTagDerivePose, offPageTagLook, offPageTagSize, offPageTagSpec, offPageTagSpecs, offPageTagText, offPageTargetOf, orthogonal, parseDiagramTheme, pinSegment, poolAxisOf, poolHeader, poolsOf, portLayer, portScratchOf, reconnectBinding, regionHeaderAt, regionSpecs, registerDiagramShape, relayoutBodies, releaseMembers, removeSegment, removeStencilGroup, removeThemeRole, removeWaypoint, renameThemeRole, rendererMeasure, reorderBinding, reorderContribution, resolveEnd, roleEdgeStyle, roleStyle, routeDataOps, routeHandles, routeStateOf, routeWrites, routedData, routerActions, routesOf, sceneParticipants, segmentAxis, selfLoop, sequenceSlots, setDiagramColor, setDiagramFontSize, setDiagramStyle, setDiagramType, setThemeValue, simplifyStops, stackedLanes, startItemDrag, stencilBuild, stencilIdOf, stencilKind, stencilTool, straight, subpathOf, themeDocValue, themeEdgeStroke, themeFont, themeLabelFont, themeLabelStyle, themeRoles, themeToJson, themeValue, themeWrites, titlePose, unpinSegment, useAvoidRouting, useConnectorTool, useHops, useLabelPlacement, useLiveLayout, useMirroredSelection, useOffPageMarkers, useStencilInsert, useStencilTool, waypointFollower, waypointLayer, waypointScratchOf, withDiagramRegistry, withHops, withRouter };
3496
+ /** A state machine's states and pseudostates, notes, and composite states. */
3497
+ declare const STATE_STENCILS: readonly (DiagramStencil | ContainerStencil)[];
3498
+ /** The state machine symbols as a stencil group. */
3499
+ declare const STATE_GROUP: StencilGroup;
3500
+
3501
+ /** A requirement diagram's requirements and the elements that satisfy them. */
3502
+ declare const REQUIREMENT_STENCILS: readonly DiagramStencil[];
3503
+ /** The requirement diagram symbols as a stencil group. */
3504
+ declare const REQUIREMENT_GROUP: StencilGroup;
3505
+
3506
+ /** C4's people, systems, containers, and components, each a store or a queue where C4 has one, and the
3507
+ * boundaries around them. */
3508
+ declare const C4_STENCILS: readonly (DiagramStencil | ContainerStencil)[];
3509
+ /** The C4 symbols as a stencil group. */
3510
+ declare const C4_GROUP: StencilGroup;
3511
+
3512
+ /** An architecture diagram's services, by the icons Mermaid builds in, a junction to join edges at, and a group. */
3513
+ declare const ARCHITECTURE_STENCILS: readonly (DiagramStencil | ContainerStencil)[];
3514
+ /** The architecture symbols as a stencil group. */
3515
+ declare const ARCHITECTURE_GROUP: StencilGroup;
3516
+
3517
+ /** A kanban board: a pool whose lanes are its columns, and cards to stack down them, each with a `field` row of
3518
+ * metadata. */
3519
+ declare const KANBAN_STENCILS: readonly (DiagramStencil | ContainerStencil)[];
3520
+ /** The kanban symbols as a stencil group. */
3521
+ declare const KANBAN_GROUP: StencilGroup;
3522
+
3523
+ /**
3524
+ * The edits a sequence takes, each a pure function from one `SequenceData` to
3525
+ * the next. A no-op returns the data it was given, so a caller can tell
3526
+ * nothing changed by identity.
3527
+ */
3528
+
3529
+ type Steps = readonly SeqStep[];
3530
+ /** The step list `parent` names: the top level, or one section of a fragment anywhere in `steps`. `null` when there is none. */
3531
+ declare function stepListOf(steps: Steps, parent: StepPlace['parent']): Steps | null;
3532
+ /** The step with `id`, at any depth. */
3533
+ declare function findStep(steps: Steps, id: string): SeqStep | null;
3534
+ /** Where the step with `id` stands. */
3535
+ declare function placeOf(steps: Steps, id: string, parent?: StepPlace['parent']): StepPlace | null;
3536
+ /**
3537
+ * The step `id` moved to `to`, whose `index` counts the list as it stands
3538
+ * before the move. A fragment cannot move into itself.
3539
+ */
3540
+ declare function moveStep(data: SequenceData, id: string, to: StepPlace): SequenceData;
3541
+ /** Participant `id` moved to `index` among them, counted as they stand before the move. */
3542
+ declare function moveParticipant(data: SequenceData, id: string, index: number): SequenceData;
3543
+ /** Message `id`'s `end` moved to `participant`'s lifeline. */
3544
+ declare function reconnectMessage(data: SequenceData, id: string, end: 'from' | 'to', participant: string): SequenceData;
3545
+ /** `data` with `target`'s text set to `text`. Empty text clears a label; a note keeps its text as given. */
3546
+ declare function setSequenceText(data: SequenceData, target: SeqTextTarget, text: string): SequenceData;
3547
+ /** The text `target` holds in `data`, as an edit opens on it. */
3548
+ declare function sequenceTextOf(data: SequenceData, target: SeqTextTarget): string | null;
3549
+
3550
+ /**
3551
+ * Authoring a sequence's columns: participants added and removed, boxes drawn
3552
+ * around them, messages numbered. Pure functions from one `SequenceData` to
3553
+ * the next; a no-op returns the data it was given.
3554
+ */
3555
+
3556
+ /** Whether a participant, step, or box in `data` already has `id`. */
3557
+ declare const seqIdTaken: (data: SequenceData, id: string) => boolean;
3558
+ /** An id nothing in `data` uses yet: `prefix` and the lowest free number from 1. */
3559
+ declare function freshSeqId(data: SequenceData, prefix: string): string;
3560
+ /** What a new participant is drawn as: a plain box, or the UML stick figure. */
3561
+ type SeqParticipantKind = 'participant' | 'actor';
3562
+ /** A participant `data` can take: a fresh id, and a label naming its kind and number ("Actor 2"). */
3563
+ declare function newParticipant(data: SequenceData, kind?: SeqParticipantKind): SeqParticipant;
3564
+ /** `p` added at `index` among the participants (default last). Nothing changes when its id is taken. */
3565
+ declare function addParticipant(data: SequenceData, p: SeqParticipant, index?: number): SequenceData;
3566
+ /**
3567
+ * Participant `id` removed, with what names it: every message to or from it,
3568
+ * every activation, creation, or destruction of it, and it from every note
3569
+ * and box, a note or box left naming no one going too. Fragments stay, even
3570
+ * emptied, since they hold no participant of their own.
3571
+ */
3572
+ declare function removeParticipant(data: SequenceData, id: string): SequenceData;
3573
+ /** Participant `id` drawn as `outline`; `undefined` or `'rect'` is the plain box. */
3574
+ declare function setParticipantOutline(data: SequenceData, id: string, outline: Outline | undefined): SequenceData;
3575
+ /**
3576
+ * `box` drawn around its members: ids naming no participant are dropped, each
3577
+ * member leaves any box it was in (one left empty goes), and the members are
3578
+ * gathered side by side where the first of them stands, since a box spans
3579
+ * every column between its ends. Nothing changes for a box naming no one, or
3580
+ * whose id is taken.
3581
+ */
3582
+ declare function addBox(data: SequenceData, box: SeqBox): SequenceData;
3583
+ /** Box `id` removed; its members stay. */
3584
+ declare function removeBox(data: SequenceData, id: string): SequenceData;
3585
+ /** Messages numbered from `from`, or not numbered at all for `undefined`. */
3586
+ declare function setAutonumber(data: SequenceData, from: number | undefined): SequenceData;
3587
+
3588
+ /** How a message is drawn: its line, its head, and whether it has a head at both ends or is sent without waiting. */
3589
+ type SeqArrow = Pick<SeqMessage, 'line' | 'head'> & Pick<Partial<SeqMessage>, 'both' | 'async'>;
3590
+ /** The arrows a message is commonly drawn with, by name; each one Mermaid writes. */
3591
+ declare const SEQ_ARROWS: {
3592
+ /** A call: a solid line, a filled head. */
3593
+ readonly sync: {
3594
+ readonly line: "solid";
3595
+ readonly head: "arrow";
3596
+ };
3597
+ /** An answer: a dashed line, a filled head. */
3598
+ readonly reply: {
3599
+ readonly line: "dashed";
3600
+ readonly head: "arrow";
3601
+ };
3602
+ /** Sent without waiting: a solid line, an open head. */
3603
+ readonly async: {
3604
+ readonly line: "solid";
3605
+ readonly head: "open";
3606
+ readonly async: true;
3607
+ };
3608
+ /** Lost or refused: a solid line ending in a cross. */
3609
+ readonly lost: {
3610
+ readonly line: "solid";
3611
+ readonly head: "cross";
3612
+ };
3613
+ /** A plain solid line. */
3614
+ readonly line: {
3615
+ readonly line: "solid";
3616
+ readonly head: "none";
3617
+ };
3618
+ /** A plain dashed line. */
3619
+ readonly dashed: {
3620
+ readonly line: "dashed";
3621
+ readonly head: "none";
3622
+ };
3623
+ /** Both ways: a solid line, filled heads at both ends. */
3624
+ readonly both: {
3625
+ readonly line: "solid";
3626
+ readonly head: "arrow";
3627
+ readonly both: true;
3628
+ };
3629
+ };
3630
+ /** A name in {@link SEQ_ARROWS}. */
3631
+ type SeqArrowName = keyof typeof SEQ_ARROWS;
3632
+ /** The fragment types that hold more than one section: an alt's branches, a par's threads, a critical's options. */
3633
+ declare const SEQ_MULTI_SECTION: ReadonlySet<SeqFragment['type']>;
3634
+ /** `step` inserted at `at`, whose index is clamped to its list. Nothing changes where `at` names no list, or the step's id is taken. */
3635
+ declare function insertStep(data: SequenceData, step: SeqStep, at: StepPlace): SequenceData;
3636
+ /** What {@link insertMessage} takes. */
3637
+ interface NewSeqMessage {
3638
+ from: string;
3639
+ to: string;
3640
+ at: StepPlace;
3641
+ /** A name in {@link SEQ_ARROWS}, or an arrow of its own. Default `'sync'`. */
3642
+ arrow?: SeqArrowName | SeqArrow;
3643
+ text?: string;
3644
+ /** Default a fresh `m` id. */
3645
+ id?: string;
3646
+ }
3647
+ /** A message from `from` to `to` (the same for a self-message) inserted at `at`. Nothing changes for an unknown participant. */
3648
+ declare function insertMessage(data: SequenceData, m: NewSeqMessage): SequenceData;
3649
+ /** What {@link insertNote} takes. */
3650
+ interface NewSeqNote {
3651
+ /** Participant ids: one, or the first and last of a span. */
3652
+ over: readonly string[];
3653
+ /** Beside its participant rather than over it. */
3654
+ side?: 'left' | 'right';
3655
+ at: StepPlace;
3656
+ /** Default `'Note'`. */
3657
+ text?: string;
3658
+ /** Default a fresh `n` id. */
3659
+ id?: string;
3660
+ }
3661
+ /** A note over (or beside) participants inserted at `at`. Nothing changes for an unknown participant or none at all. */
3662
+ declare function insertNote(data: SequenceData, n: NewSeqNote): SequenceData;
3663
+ /**
3664
+ * A lifeline mark inserted at `at`: an activation starting or ending, its head
3665
+ * created there (it is then not drawn at the top), or its lifeline ended.
3666
+ * Nothing changes for an unknown participant, or a second `create` of one.
3667
+ */
3668
+ declare function insertMark(data: SequenceData, mark: SeqMark, at: StepPlace): SequenceData;
3669
+ /** Step `id` removed, with all a fragment holds. */
3670
+ declare function removeStep(data: SequenceData, id: string): SequenceData;
3671
+ /** The step at `at` removed: how a mark, which has no id, is taken out. */
3672
+ declare function removeStepAt(data: SequenceData, at: StepPlace): SequenceData;
3673
+ /**
3674
+ * What `refs` name removed: each mark step at its place, and each message
3675
+ * flag cleared. The places are read against `data` as given, so removing one
3676
+ * does not shift the next. A place holding anything but a mark is left alone.
3677
+ */
3678
+ declare function removeMarks(data: SequenceData, refs: readonly SeqMarkRef[]): SequenceData;
3679
+ /** Every `kind` mark naming `participant` removed, at any depth: a created head drawn at the top again, say. */
3680
+ declare function removeMarksOf(data: SequenceData, kind: SeqMark['kind'], participant: string): SequenceData;
3681
+ /** What {@link wrapSteps} takes. */
3682
+ interface NewSeqFragment {
3683
+ type: SeqFragment['type'];
3684
+ /** The first section's guard or title. */
3685
+ label?: string;
3686
+ /** Default a fresh `f` id. */
3687
+ id?: string;
3688
+ }
3689
+ /**
3690
+ * The steps of the list at `parent` from `start` up to (not including) `end`
3691
+ * wrapped in a new fragment standing where they stood. An empty run makes an
3692
+ * empty fragment at `start`. Nothing changes where `parent` names no list.
3693
+ */
3694
+ declare function wrapSteps(data: SequenceData, parent: StepPlace['parent'], start: number, end: number, f: NewSeqFragment): SequenceData;
3695
+ /** Fragment `id` dissolved: its sections' steps, in order, stand where it stood. */
3696
+ declare function unwrapFragment(data: SequenceData, id: string): SequenceData;
3697
+ /** An empty section added to an alt, par, or critical, at `index` among its sections (default last). Other types hold one. */
3698
+ declare function addSection(data: SequenceData, id: string, label?: string, index?: number): SequenceData;
3699
+ /** Section `index` of fragment `id` removed, with its steps. A fragment's only section stays: remove the fragment instead. */
3700
+ declare function removeSection(data: SequenceData, id: string, index: number): SequenceData;
3701
+ /** Fragment `id` retyped. A fragment with several sections keeps them, so it takes only another type that holds several. */
3702
+ declare function setFragmentType(data: SequenceData, id: string, type: SeqFragment['type']): SequenceData;
3703
+ /** Message `id` drawn with `arrow`, a name in {@link SEQ_ARROWS} or an arrow of its own. */
3704
+ declare function setMessageArrow(data: SequenceData, id: string, arrow: SeqArrowName | SeqArrow): SequenceData;
3705
+ /** Message `id`'s activation flags set: which end it starts an activation on, and which end it ends one on; `undefined` clears one. */
3706
+ declare function setMessageActivation(data: SequenceData, id: string, flags: {
3707
+ activate?: 'to' | 'from' | undefined;
3708
+ deactivate?: 'to' | 'from' | undefined;
3709
+ }): SequenceData;
3710
+
3711
+ /** The sizes a sequence is laid out with, and how its text is measured. */
3712
+
3713
+ /** A box in world units. */
3714
+ interface SeqRect {
3715
+ x: number;
3716
+ y: number;
3717
+ width: number;
3718
+ height: number;
3719
+ }
3720
+
3721
+ /** Options for {@link sequenceLayout}. */
3722
+ interface SequenceLayoutOptions {
3723
+ /** Measures text. Default an estimate from character count. */
3724
+ measure?: MeasureRowText;
3725
+ /** The face text is set in. Default 12px sans-serif. */
3726
+ font?: {
3727
+ fontFamily: string;
3728
+ fontSize: number;
3729
+ };
3730
+ }
3731
+ /** A head: at the top, or at its `create` row. */
3732
+ interface SeqHeadPlace {
3733
+ id: string;
3734
+ box: SeqRect;
3735
+ created: boolean;
3736
+ }
3737
+ /** A lifeline, from under its head to the foot, or to where it was destroyed: by the `destroy` mark at `destroyedBy`. */
3738
+ interface SeqLifelinePlace {
3739
+ id: string;
3740
+ x: number;
3741
+ y0: number;
3742
+ y1: number;
3743
+ destroyed: boolean;
3744
+ destroyedBy?: StepPlace;
3745
+ }
3746
+ /** A message's line from `x1` (its `from` end) to `x2`, at `y`; a self-message loops down to `loopY`. */
3747
+ interface SeqMessagePlace {
3748
+ id: string;
3749
+ y: number;
3750
+ x1: number;
3751
+ x2: number;
3752
+ loopY?: number;
3753
+ text?: SeqRect;
3754
+ number?: {
3755
+ n: number;
3756
+ box: SeqRect;
3757
+ };
3758
+ }
3759
+ /** An activation bar, with what opened it and what closed it; one the diagram's end closed has no `closer`. */
3760
+ interface SeqActivationPlace {
3761
+ participant: string;
3762
+ depth: number;
3763
+ box: SeqRect;
3764
+ opener: SeqMarkRef;
3765
+ closer?: SeqMarkRef;
3766
+ }
3767
+ interface SeqNotePlace {
3768
+ id: string;
3769
+ box: SeqRect;
3770
+ }
3771
+ /** A fragment's box, its type tab (none for a `region`), and each section's top and label. */
3772
+ interface SeqFragmentPlace {
3773
+ id: string;
3774
+ type: SeqFragment['type'];
3775
+ box: SeqRect;
3776
+ tab?: SeqRect;
3777
+ sections: {
3778
+ y: number;
3779
+ label?: SeqRect;
3780
+ }[];
3781
+ }
3782
+ interface SeqBoxPlace {
3783
+ id: string;
3784
+ box: SeqRect;
3785
+ label?: SeqRect;
3786
+ }
3787
+ /** Where a dragged step dropped at `y` would go. */
3788
+ interface SeqSlot {
3789
+ y: number;
3790
+ place: StepPlace;
3791
+ }
3792
+ /** Every part of a sequence, placed. */
3793
+ interface SequenceLayout {
3794
+ width: number;
3795
+ height: number;
3796
+ /** Lifeline x by participant, in data order. */
3797
+ columns: readonly {
3798
+ id: string;
3799
+ x: number;
3800
+ }[];
3801
+ heads: readonly SeqHeadPlace[];
3802
+ lifelines: readonly SeqLifelinePlace[];
3803
+ messages: readonly SeqMessagePlace[];
3804
+ activations: readonly SeqActivationPlace[];
3805
+ notes: readonly SeqNotePlace[];
3806
+ fragments: readonly SeqFragmentPlace[];
3807
+ boxes: readonly SeqBoxPlace[];
3808
+ /** Every place a step can be dropped, top to bottom. */
3809
+ slots: readonly SeqSlot[];
3810
+ }
3811
+ /**
3812
+ * Lays `data` out: lifelines spaced to the widest text between neighbors, a
3813
+ * row per step sized to its text, self-messages looped, heads started at
3814
+ * their `create` and lifelines ended at their `destroy`, nested activations
3815
+ * stepped right, and each fragment boxed over the lifelines its steps touch.
3816
+ */
3817
+ declare function sequenceLayout(data: SequenceData, opts?: SequenceLayoutOptions): SequenceLayout;
3818
+
3819
+ /**
3820
+ * `sequenceSpecs` — a sequence diagram as scene specs: one root holding the
3821
+ * `SequenceData`, and every part drawn from it as a child the root owns. The
3822
+ * parts take no press of their own; an edit replaces the root's data and
3823
+ * builds them again.
3824
+ */
3825
+
3826
+ /** The theme role each kind of part is drawn in, where its data names none. */
3827
+ declare const SEQUENCE_ROLES: {
3828
+ readonly note: "warning";
3829
+ readonly number: "accent";
3830
+ };
3831
+ /** Options for {@link sequenceSpecs}. */
3832
+ interface SequenceSpecsOptions<TLayer extends string = 'main'> {
3833
+ /** The root's id; every part's id starts with it. */
3834
+ id: string;
3835
+ /** Where the diagram's top-left corner stands. Default the origin. */
3836
+ at?: Vec2$1;
3837
+ /** Default `'main'`. */
3838
+ layer?: TLayer;
3839
+ /** Default the night theme. */
3840
+ theme?: DiagramTheme;
3841
+ /** Default the theme's face. */
3842
+ font?: {
3843
+ fontFamily: string;
3844
+ fontSize: number;
3845
+ };
3846
+ /** Measures text. Default an estimate from character count. */
3847
+ measure?: MeasureRowText;
3848
+ /** How the scene folds a child's pose into its parent's. Default `RIGID_POSE_COMPOSITION`. */
3849
+ composition?: PoseComposition<RectPose>;
3850
+ }
3851
+ /**
3852
+ * The root and parts of a sequence diagram: its root at `at`, sized to the
3853
+ * layout, holding `data`; boxes, fragments, lifelines, activations, messages,
3854
+ * notes, and heads drawn over one another in that order, each from the
3855
+ * theme's roles, its own colors over them.
3856
+ */
3857
+ declare function sequenceSpecs<TLayer extends string = 'main'>(data: SequenceData, opts: SequenceSpecsOptions<TLayer>): DiagramSpec<TLayer>[];
3858
+
3859
+ /**
3860
+ * What a sequence's scene nodes carry under `data.diagram`: the root holds the
3861
+ * whole `SequenceData`, and every part drawn from it names its root and what
3862
+ * it draws.
3863
+ */
3864
+
3865
+ /** Where a root's parts stand, in its own frame: what a drag reads to place a drop without laying the data out again. */
3866
+ interface SequenceGeometry {
3867
+ columns: readonly {
3868
+ id: string;
3869
+ x: number;
3870
+ }[];
3871
+ slots: readonly SeqSlot[];
3872
+ heads: readonly {
3873
+ id: string;
3874
+ box: SeqRect;
3875
+ }[];
3876
+ messages: readonly SeqMessagePlace[];
3877
+ notes: readonly {
3878
+ id: string;
3879
+ box: SeqRect;
3880
+ }[];
3881
+ /** Where a fragment is taken hold of: its type tab, or a region's top edge. Absent on a root drawn before fragments could be. */
3882
+ fragments?: readonly {
3883
+ id: string;
3884
+ grip: SeqRect;
3885
+ }[];
3886
+ /** Where a box is taken hold of: the strip above its heads that holds its label. Absent as for `fragments`. */
3887
+ boxes?: readonly {
3888
+ id: string;
3889
+ grip: SeqRect;
3890
+ }[];
3891
+ /** Where a part drawn for lifeline marks is taken hold of, by the part's id under the root: an activation bar, a
3892
+ * destruction's cross. Absent as for `fragments`. */
3893
+ marks?: readonly {
3894
+ id: string;
3895
+ grip: SeqRect;
3896
+ }[];
3897
+ }
3898
+ /** The trait on a sequence's root. */
3899
+ interface SequenceRootTrait {
3900
+ sequence: SequenceData;
3901
+ geometry: SequenceGeometry;
3902
+ }
3903
+ /** What a part draws. */
3904
+ type SeqPartKind = 'head' | 'lifeline' | 'destroy' | 'message' | 'activation' | 'note' | 'fragment' | 'divider' | 'box' | 'number' | 'text';
3905
+ /** The trait on a part of a sequence: its root, what it draws, and for text, what an edit of it sets. */
3906
+ interface SeqPartTrait {
3907
+ root: string;
3908
+ part: SeqPartKind;
3909
+ /** The participant or step it draws. */
3910
+ id?: string;
3911
+ /** For text an edit can set. */
3912
+ target?: SeqTextTarget;
3913
+ /** For an activation bar or a destruction's cross: the marks and message flags that draw it, which deleting it removes. */
3914
+ marks?: readonly SeqMarkRef[];
3915
+ }
3916
+ /** The sequence a root node holds, or `null` for any other node. */
3917
+ declare function sequenceRootOf(node: {
3918
+ data: unknown;
3919
+ }): SequenceRootTrait | null;
3920
+ /** The part trait a node drawn for a sequence carries, or `null`. */
3921
+ declare function sequencePartOf(node: {
3922
+ data: unknown;
3923
+ }): SeqPartTrait | null;
3924
+
3925
+ /** Editing a sequence's text in place, through a canvas's own text editor. */
3926
+
3927
+ /** Whether `data` is a sequence's text an edit can set: a head's, a message's or note's, a section's, a box's. */
3928
+ declare const isSequenceText: (data: unknown) => boolean;
3929
+ /**
3930
+ * The `<SceneCanvas textEditor>` options that open on a sequence's text and,
3931
+ * as the edit closes, fold it into one edit of the sequence's data for
3932
+ * `report`. `undefined` while `report` is.
3933
+ */
3934
+ declare function useSequenceTextEdit(scene: Scene<unknown, string, unknown>, report: ((edit: SequenceEdit) => void) | undefined): Exclude<SceneCanvasTextEditor<DiagramSceneData>, false> | undefined;
3935
+
3936
+ /**
3937
+ * What makes a sequence's parts grabbable: a head, a message or note, a
3938
+ * fragment's tab, a box's label strip, an activation bar, a destruction's
3939
+ * cross, and each end of a message, as regions over every sequence root in the scene.
3940
+ * The parts themselves take no press, so these regions are the only way in.
3941
+ */
3942
+
3943
+ /** The layer id the sequence regions are composed into. */
3944
+ declare const SEQUENCE_LAYER_ID = "diagram-sequence";
3945
+ /** The affordance kind a press on a sequence part reports. */
3946
+ declare const SEQUENCE_AFFORDANCE_KIND: "layer:diagram-sequence";
3947
+ /** What a press on a sequence part hands the sequence actions, as the hit's `payload`. */
3948
+ interface SequenceScratch {
3949
+ targetId: string;
3950
+ /** The sequence root's id. */
3951
+ root: string;
3952
+ /** A head, a message's, note's or fragment's row, one end of a message, a box, or a part drawn for lifeline marks. */
3953
+ part: 'head' | 'step' | 'end' | 'box' | 'mark';
3954
+ /** The participant's, step's, or box's id; for a mark's part, the part's id under the root (`act:0`). */
3955
+ id: string;
3956
+ end?: 'from' | 'to';
3957
+ }
3958
+ /** Read a sequence press's scratch back off the hit an action was handed. */
3959
+ declare function sequenceScratchOf(hit: {
3960
+ payload?: unknown;
3961
+ } | null | undefined): SequenceScratch | null;
3962
+
3963
+ /**
3964
+ * Dragging a sequence's parts: a message or note to another row, a head to
3965
+ * another column, a message's end to another lifeline. Each drag previews the
3966
+ * parts it carries and, on release, hands one edit of the root's data to
3967
+ * `commit`, which by default replaces it in the scene as one undo entry.
3968
+ */
3969
+
3970
+ /** The action that drags a sequence part. */
3971
+ declare const SEQUENCE_DRAG_ACTION_ID = "diagram.sequence.drag";
3972
+ /** The action that absorbs the rest of a press on a sequence part, so it reaches neither marquee nor pan. */
3973
+ declare const GRAB_SEQUENCE_ACTION_ID = "diagram.sequence.grab";
3974
+ /** The `diagram.sequence.drag` action: an ongoing drag of whatever sequence part was pressed. */
3975
+ declare function createSequenceDragAction(opts?: SequenceEditOptions): Action;
3976
+ /**
3977
+ * Both halves of sequence editing: the layer to `registerLayer` — last, so a
3978
+ * sequence part wins over anything beside it — and the contribution to pass
3979
+ * as `ambient`, which carries the drag. Like `diagramPorts`, one without the
3980
+ * other fails quietly. Text is edited in place by the host's text editor,
3981
+ * through `foldSequenceText`.
3982
+ */
3983
+ declare function diagramSequence(opts: SequenceEditOptions & {
3984
+ scene: Scene<unknown, string, unknown>;
3985
+ }): {
3986
+ layer: RenderLayer<unknown>;
3987
+ contribution: Contribution;
3988
+ };
3989
+
3990
+ /**
3991
+ * The clicks that author a sequence: a lifeline added where the click falls
3992
+ * between two, or a new sequence started on empty canvas; a note dropped on
3993
+ * the row nearest the click. Each hands one edit of the root's data to the
3994
+ * commit, by default one undo entry in the scene.
3995
+ */
3996
+
3997
+ /** The action a Participant tool's click runs. */
3998
+ declare const ADD_PARTICIPANT_ACTION_ID = "diagram.sequence.addParticipant";
3999
+ /** The action a Note tool's click runs. */
4000
+ declare const ADD_NOTE_ACTION_ID = "diagram.sequence.addNote";
4001
+ /** The action a Mark tool's click runs. */
4002
+ declare const ADD_MARK_ACTION_ID = "diagram.sequence.addMark";
4003
+ /** Options for the sequence authoring actions. */
4004
+ interface SequenceAuthorOptions extends SequenceEditOptions {
4005
+ /**
4006
+ * Starts a new sequence holding `data` with its top-left corner at `at`, for
4007
+ * a Participant click on empty canvas. Default {@link startSequence} against
4008
+ * the scene when `commit` is the default; with a `commit` of its own and no
4009
+ * `start`, a click off every sequence does nothing.
4010
+ */
4011
+ start?: ((at: Vec2, data: SequenceData, deps: ActionDeps) => void) | null;
4012
+ }
4013
+ /** Within this many world units of a lifeline, a note click lands over it rather than beside it. */
4014
+ declare const NOTE_OVER_REACH = 20;
4015
+ /** The Participant tool's action: a click on a sequence adds a lifeline there, of `params.kind`; one off every sequence starts one. */
4016
+ declare function createAddParticipantAction(opts?: SequenceAuthorOptions): Action;
4017
+ /** The Note tool's click: a note on the row nearest the click, over or beside the nearest lifeline. */
4018
+ declare function createAddNoteAction(opts?: SequenceEditOptions): Action;
4019
+ /**
4020
+ * The Mark tool's click: a mark of `params.mark` (default `activate`) on the
4021
+ * lifeline nearest the click, at the row slot nearest it: an activation
4022
+ * starting or ending, the head created there, or the lifeline ended.
4023
+ */
4024
+ declare function createAddMarkAction(opts?: SequenceEditOptions): Action;
4025
+
4026
+ /**
4027
+ * The drags that author a sequence: a message from one lifeline to another
4028
+ * (or back to itself), a note spanning the lifelines dragged across, and a
4029
+ * fragment wrapping the rows dragged across. Each previews what it would add
4030
+ * as gesture chrome and, on release, hands one edit of the root's data to the
4031
+ * commit, by default one undo entry in the scene.
4032
+ */
4033
+
4034
+ /** The action a Message tool's drag runs. */
4035
+ declare const DRAW_MESSAGE_ACTION_ID = "diagram.sequence.drawMessage";
4036
+ /** The action a Note tool's drag runs. */
4037
+ declare const DRAW_NOTE_ACTION_ID = "diagram.sequence.drawNote";
4038
+ /** The action a Fragment tool's drag runs. */
4039
+ declare const WRAP_FRAGMENT_ACTION_ID = "diagram.sequence.wrapFragment";
4040
+ /**
4041
+ * The Message tool's drag: from the lifeline nearest the press to the one
4042
+ * nearest the release, inserted at the row slot nearest the press, drawn with
4043
+ * `params.arrow`. Released back on its own lifeline, it is a self-message.
4044
+ */
4045
+ declare function createDrawMessageAction(opts?: SequenceEditOptions): Action;
4046
+ /**
4047
+ * The Note tool's drag: a note over every lifeline from the one nearest the
4048
+ * press to the one nearest the release, on the row slot nearest the press.
4049
+ * Released on the lifeline it started on, it lands as a click there would.
4050
+ */
4051
+ declare function createDrawNoteAction(opts?: SequenceEditOptions): Action;
4052
+ /**
4053
+ * The Fragment tool's drag: a fragment of `params.type` (default `loop`)
4054
+ * wrapping the rows between the slot nearest the press and the slot in the
4055
+ * same list nearest the pointer. A still release wraps nothing, leaving an
4056
+ * empty fragment to drag rows into.
4057
+ */
4058
+ declare function createWrapFragmentAction(opts?: SequenceEditOptions): Action;
4059
+
4060
+ /**
4061
+ * Picking a sequence's parts and deleting them. A click on a head, a message,
4062
+ * a note, a fragment's tab, or a box's label strip selects the scene node that
4063
+ * draws it; Delete on a selection holding such nodes removes what they draw
4064
+ * from their root's data, one edit per root, and the rest of the selection as
4065
+ * core's delete would.
4066
+ */
4067
+
4068
+ /** The action a click on a sequence part runs. */
4069
+ declare const SELECT_SEQUENCE_PART_ACTION_ID = "diagram.sequence.select";
4070
+ type AnyScene$1 = Scene<unknown, string, unknown>;
4071
+ /** The id of the node that draws what `s` names, among its root's parts: a head, a message, a note, a fragment's box, a box. */
4072
+ declare function sequencePartNodeOf(scene: AnyScene$1, s: Pick<SequenceScratch, 'root' | 'part' | 'id'>): string | null;
4073
+ /** The sequence part's click: selects the node drawing it, or with Shift adds it to the selection or takes it out. */
4074
+ declare const selectSequencePartAction: Action;
4075
+ /**
4076
+ * `ids` split into the sequence edits deleting them make, one per root, and
4077
+ * the ids that are no sequence's part. An activation bar or a destruction's
4078
+ * cross removes the marks and message flags that draw it. A part that draws
4079
+ * nothing an edit can remove (a number, a section label) is dropped.
4080
+ */
4081
+ declare function sequenceDeletes(scene: AnyScene$1, ids: readonly string[]): {
4082
+ edits: {
4083
+ id: string;
4084
+ data: SequenceData;
4085
+ }[];
4086
+ rest: string[];
4087
+ };
4088
+ /** Options for {@link createSequenceDeleteAction}. */
4089
+ interface SequenceDeleteOptions extends SequenceEditOptions {
4090
+ /** Deletes the selected ids that are no sequence's part. Default core's `commitDeleteToScene`. */
4091
+ others?: (ids: readonly NodeId[], deps: ActionDeps) => void;
4092
+ }
4093
+ /**
4094
+ * Core's `delete`, for a canvas holding sequences: the selected sequence parts
4095
+ * are removed from their roots' data (a head takes its participant and what
4096
+ * names it), the rest go to `others`, and the selection is emptied.
4097
+ */
4098
+ declare function createSequenceDeleteAction(opts?: SequenceDeleteOptions): Action;
4099
+
4100
+ /**
4101
+ * What a selection names in a sequence: the root it is in, and the
4102
+ * participants, messages, notes, fragments, and boxes its parts draw. What a
4103
+ * host's panel reads to offer the edits that apply to a selection.
4104
+ */
4105
+
4106
+ type AnyScene = Scene<unknown, string, unknown>;
4107
+ /** A selection read as one sequence's parts. Each list is in selection order, without repeats. */
4108
+ interface SequenceSelection {
4109
+ /** The root's id. */
4110
+ root: string;
4111
+ data: SequenceData;
4112
+ participants: string[];
4113
+ messages: string[];
4114
+ notes: string[];
4115
+ fragments: string[];
4116
+ boxes: string[];
4117
+ }
4118
+ /**
4119
+ * The sequence `ids` select in: the root of the first sequence part among
4120
+ * them, or a selected root, else the scene's only sequence (with nothing
4121
+ * selected in it), else `null`. Parts of any other root are left out.
4122
+ */
4123
+ declare function sequenceSelectionOf(scene: AnyScene, ids: readonly string[]): SequenceSelection | null;
4124
+
4125
+ /**
4126
+ * The sequence authoring tools: each a declarative shell binding a click or a
4127
+ * drag to the action that owns the edit. Every binding comes twice, once
4128
+ * plain and once on the sequence layer's regions, since a press on a head,
4129
+ * message, or note is claimed by that layer and reaches only bindings that
4130
+ * name it.
4131
+ */
4132
+
4133
+ /** The ids `useSequenceTools` keys its tools by. */
4134
+ type SequenceToolId = 'diagram.sequence.participant' | 'diagram.sequence.message' | 'diagram.sequence.note' | 'diagram.sequence.fragment' | 'diagram.sequence.mark';
4135
+ /** The sequence authoring tools: lifelines, messages, notes, fragments, and lifeline marks. */
4136
+ declare const SEQUENCE_TOOLS: ToolSet<SequenceToolId>;
4137
+ /** Options for {@link sequenceTools} and {@link useSequenceTools}. */
4138
+ interface SequenceToolsOptions extends SequenceAuthorOptions {
4139
+ /** What the Participant tool adds, read at each click. Default a plain participant. */
4140
+ participant?: () => SeqParticipantKind;
4141
+ /** The arrow the Message tool draws, read as each drag moves. Default `'sync'`. */
4142
+ arrow?: () => SeqArrowName | SeqArrow;
4143
+ /** The type the Fragment tool wraps rows in, read as each drag moves. Default `'loop'`. */
4144
+ fragment?: () => SeqFragment['type'];
4145
+ /** The mark the Mark tool puts on a lifeline, read at each click. Default `'activate'`. */
4146
+ mark?: () => SeqMark['kind'];
4147
+ }
4148
+ /**
4149
+ * Every tool in {@link SEQUENCE_TOOLS}, keyed by id, for `<SceneCanvas tools>`:
4150
+ * Participant clicks a lifeline in where the click falls (or starts a sequence
4151
+ * on empty canvas), Message drags from one lifeline to another at the row of
4152
+ * the press, Note clicks or drags across lifelines, Fragment drags across
4153
+ * rows to wrap them, and Mark clicks an activation's start or end, a
4154
+ * creation, or a destruction onto a lifeline. Each commits one undo entry
4155
+ * through `commit`.
4156
+ */
4157
+ declare function sequenceTools(opts?: SequenceToolsOptions): Record<SequenceToolId, Tool>;
4158
+ /**
4159
+ * {@link sequenceTools}, built once per change of what draws an edit. The
4160
+ * commit and the participant, arrow, fragment, and mark readers are read through a
4161
+ * ref, so a host can pass fresh closures every render.
4162
+ */
4163
+ declare function useSequenceTools(opts?: SequenceToolsOptions): Record<SequenceToolId, Tool>;
4164
+
4165
+ export { ADD_LANE_ACTION_ID, ADD_MARK_ACTION_ID, ADD_NOTE_ACTION_ID, ADD_PARTICIPANT_ACTION_ID, ARCHITECTURE_GROUP, ARCHITECTURE_STENCILS, ARCHITECTURE_TYPE, type ApplyDiagramThemeOptions, type ApplyLayoutOptions, AvoidInput, AvoidOptions, AvoidRouter, AvoidRoutes, type AvoidRouting, type AvoidRoutingOptions, type AvoidSceneOptions, BLOCK_TYPE, BPMN_GROUP, BPMN_STENCILS, BPMN_TYPE, type BodyEnd, type BodyHit, BodySpec, Bounds$2 as Bounds, C4_GROUP, C4_STENCILS, C4_TYPE, CONNECTOR_ACTION_ID, CONNECTOR_TOOL_ID, CONNECT_ACTION_ID, CONTAINERS_GROUP, CONTAINER_HEADER, CONTAINER_LAYOUTS, CONTAINER_STENCILS, type CanConnect, type CanDropItem, type CanReparent, type ConnectActionOptions, type ConnectEnd, type ConnectView, type ContainerBuildOptions, type ContainerEdit, ContainerHeader, type ContainerLayoutOptions, ContainerRole, type ContainerStencil, DEFAULT_EDGE_STROKE, DEFAULT_EDGE_STYLE, DEFAULT_GROUP_STYLE, DIAGRAM_CONTAINER_LAYOUT, DIAGRAM_EDGE, DIAGRAM_ITEM_CARRY, DIAGRAM_LABEL, DIAGRAM_LANE_COLUMNS_LAYOUT, DIAGRAM_LANE_ROWS_LAYOUT, DIAGRAM_OFF_PAGE_TAG, DIAGRAM_PASS_ORDER, DIAGRAM_POOL_COLUMNS_LAYOUT, DIAGRAM_POOL_ROWS_LAYOUT, DIAGRAM_THEMES, DIAGRAM_THEME_EXTENSION, DIAGRAM_TYPES, DIAGRAM_TYPE_DOC_KEY, DRAW_MESSAGE_ACTION_ID, DRAW_NOTE_ACTION_ID, DataContainer, DataEdge, DataNode, type DeleteReport, DiagramContainer, type DiagramContributionOptions, DiagramData, DiagramEdge, DiagramLabel, type DiagramLayout, DiagramNodeLike, DiagramNodeReader, type DiagramOverlay, DiagramSceneData, DiagramSceneOptions, type DiagramShapeOptions, DiagramSpec, type DiagramStencil, type DiagramStyleEditOptions, type DiagramStyleState, DiagramTheme, type DiagramType, type DiagramTypeDoc, type DiagramTypeEdge, type DiagramTypeReadable, type DiagramTypeScene, type DiagramTypeWriteOptions, DiagramView, type DiagramViewApi, type DiagramViewProps, type DraggableLabel, type DropParentScene, EASED_LAYOUTS, EDGE_DERIVE_PATH, EDGE_END_AFFORDANCE_KIND, EDGE_END_LAYER_ID, EDIT_CONTAINER_TITLE_ACTION_ID, EDIT_EDGE_LABEL_ACTION_ID, END_LABEL_PLACEMENT, ERD_GROUP, ERD_STENCILS, ERD_TYPE, type EasedProducerOptions, EdgeEnd, type EdgeEndAffordanceOptions, type EdgeEndScratch, EdgeHop, type EdgeLabelOptions, type EdgeRoute, type EdgeRouteOptions, type EdgeRouteState, EdgeStyle, type EditEdgeLabelOptions, type EndChange, FLOWCHART_GROUP, FLOWCHART_NOTATION, FLOWCHART_STENCILS, FLOWCHART_TYPE, FOLLOW_OFF_PAGE_ACTION_ID, type FollowOffPageOptions, FontField, ForceOptions, type ForceProducerOptions, GRAB_EDGE_END_ACTION_ID, GRAB_LABEL_ACTION_ID, GRAB_PORT_ACTION_ID, GRAB_SEQUENCE_ACTION_ID, GRAB_WAYPOINT_ACTION_ID, Graph, GraphNodeLike, GraphSource, type Hops, type HopsOptions, ITEM_DROP_ACTION_ID, type ItemDrop, type ItemDropOptions, type ItemDropTarget, KANBAN_GROUP, KANBAN_STENCILS, KANBAN_TYPE, LABEL_DERIVE_POSE, LABEL_DRAG_AFFORDANCE_KIND, LABEL_DRAG_LAYER_ID, LANE_AFFORDANCE_KIND, LANE_HEADER_SIZE, LANE_LAYER_ID, LANE_RESIZE_ACTION_ID, LAYOUTS, LAYOUT_ACTION_ID, type LabelDragOptions, type LabelEdit, type LabelMove, type LabelPlacement, type LabelPlacementOptions, type LabelPoseOptions, type LabelScratch, LabelSpot, type LaneActionOptions, type LaneLayerOptions, type LaneResize, type LaneScratch, type LaneStackOptions, type LayeredRoute, type LayeredRouteInput, type LayoutActionOptions, type LayoutDiagramOptions, LayoutDirection, LayoutFn, LayoutOptions, LayoutPlan, LayoutPlanner, LayoutPorts, LayoutResult, type LayoutRoutes, type LiveLayout, type LiveLayoutCtx, type LiveLayoutFrame, type LiveLayoutProducer, MIND_MAP_GROUP, MIND_MAP_STENCILS, MIND_MAP_TYPE, MIN_LANE_SIZE, MOVE_LABEL_ACTION_ID, MeasureRowText, type MovingEnd, NETWORK_GROUP, NETWORK_STENCILS, NETWORK_TYPE, NOTE_OVER_REACH, type NewSeqFragment, type NewSeqMessage, type NewSeqNote, type NodeMove, type NodeResize, NodeStyle, OFF_PAGE_STUB, OFF_PAGE_TAG_DERIVE_POSE, OFF_PAGE_TAG_PADDING, ORG_CHART_TYPE, ORG_GROUP, ORG_STENCILS, type OffPageEdgeInput, type OffPageMarkerOptions, OffPageSplit, type OffPageSplitInput, type OffPageTagLook, type OffPageTarget, Outline, POOL_HEADER_SIZE, PORT_AFFORDANCE_KIND, PORT_LAYER_ID, type ParticipantPose, type ParticipantScene, type ParticipantSource, type PendingEdge, PlaceLabelsOptions, type PoolLanes, Port, type PortAffordanceOptions, type PortScratch, PortsOptions, RECONNECT_ACTION_ID, RELEASE_MEMBERS_ACTION_ID, REMOVE_WAYPOINT_ACTION_ID, REORDER_ACTION_ID, REQUIREMENT_GROUP, REQUIREMENT_STENCILS, REQUIREMENT_TYPE, RESET_LABEL_ACTION_ID, RESET_ROUTE_ACTION_ID, ROUTERS, ROUTER_LABELS, ROUTE_EDIT_ACTION_ID, type ReconnectChange, type ReconnectOptions, type RegionOptions, type RegionSpec, type RelayoutScene, type ReorderChange, type ReorderGap, type ReorderItem, type ReorderMove, type ReorderOptions, type ReorderSlots, type ResolvedRoute, type RouteChange, type RouteEdge, type RouteEdit, type RouteEditOptions, type RouteHandle, type RouteRequest, type RoutedScene, type Router, type RouterEdit, type RouterName, Row, RowTextStyle, SELECT_LABEL_EDGE_ACTION_ID, SELECT_SEQUENCE_PART_ACTION_ID, SEQUENCE_AFFORDANCE_KIND, SEQUENCE_DRAG_ACTION_ID, SEQUENCE_LAYER_ID, SEQUENCE_ROLES, SEQUENCE_TOOLS, SEQ_ARROWS, SEQ_MULTI_SECTION, SET_HOPS_ACTION_ID, SET_ROUTER_ACTION_IDS, STATE_GROUP, STATE_STENCILS, STATE_TYPE, STENCIL_GROUPS, STEP_REORDER_ACTION_ID, type SelfLoop, type SeqArrow, type SeqArrowName, type SeqBox, type SeqFragment, type SeqIdStep, type SeqMark, type SeqMarkRef, type SeqMessage, type SeqNote, type SeqPartKind, type SeqPartTrait, type SeqParticipant, type SeqParticipantKind, type SeqRect, type SeqSection, type SeqSlot, type SeqStep, type SeqTextTarget, type SequenceAuthorOptions, type SequenceData, type SequenceDeleteOptions, type SequenceDrawOptions, type SequenceEdit, type SequenceEditOptions, type SequenceGeometry, type SequenceLayout, type SequenceLayoutOptions, type SequenceRootTrait, type SequenceScratch, type SequenceSelection, type SequenceSpecsOptions, type SequenceToolId, type SequenceToolsOptions, type SetHopsOptions, type SetRouterOptions, type SpecRouterOptions, StencilGhost, type StencilGhostProps, type StencilGroup, type StencilInsertOptions, type StepPlace, StyleField, type StyledRegion, type ThemePath, type ThemedNode, type ThemedScene, UML_CLASS_TYPE, UML_GROUP, UML_STENCILS, type UseLiveLayoutOptions, WAYPOINT_AFFORDANCE_KIND, WAYPOINT_HIT_PX, WAYPOINT_LAYER_ID, WRAP_FRAGMENT_ACTION_ID, type WaypointAffordanceOptions, type WaypointScratch, addBox, addLane, addParticipant, addSection, addStencilGroup, addThemeRole, applyDiagramTheme, applyLayout, avoid, avoidSceneInput, bezier, bodyAt, bodyFollower, commitEdgeToScene, commitLabelToScene, commitLaneResizeToScene, commitReconnectToScene, commitRouteToScene, commitRouterToScene, commitSequence, connectBinding, connectorTool, containerBuild, containerShape, createAddLaneAction, createAddMarkAction, createAddNoteAction, createAddParticipantAction, createConnectAction, createDiagramContribution, createDrawMessageAction, createDrawNoteAction, createEdgeEndAffordance, createFollowOffPageAction, createItemDropAction, createLabelDragAction, createLaneAffordance, createLaneResizeAction, createLayoutAction, createPortAffordance, createReconnectAction, createReleaseMembersAction, createRemoveWaypointAction, createReorderAction, createResetLabelAction, createResetRouteAction, createRouteEditAction, createSequenceDeleteAction, createSequenceDragAction, createSetHopsAction, createSetRouterAction, createSpecHops, createSpecLabelPlacer, createSpecRouter, createStepReorderAction, createWaypointAffordance, createWrapFragmentAction, dataEdgeStyle, dataNodeStyle, dataOffPage, dataRegionStyle, defaultCanConnect, diagramCanDropInto, diagramContainerLayout, diagramContainers, diagramDropParentAt, diagramEdgeEnds, diagramLabelDrag, diagramLayoutOf, diagramNotationOf, diagramOffPage, diagramPages, diagramPorts, diagramResizable, diagramScene, diagramSequence, diagramShape, diagramStyleOf, diagramThemeFrom, diagramThemeFromTokens, diagramThemeOf, diagramTypeDocOf, diagramTypeDocValue, diagramTypeEdgeStroke, diagramTypeOf, diagramTypeOfNotation, diagramWaypoints, documentBoundsOf, dragItemProps, dragSegment, dragVertex, draggableLabels, dropEmptyEdgeLabel, easedProducer, edgeDerivePath, edgeEndLayer, edgeEndScratchOf, edgeIdOf, edgeLabelSpec, edgeRouter, editContainerTitleAction, editContainerTitleBinding, editEdgeLabelAction, editEdgeLabelBinding, editableTheme, endLabelIdOf, findStep, firstLanes, foldSequenceText, followOffPageBinding, forceProducer, forkTheme, freshSeqId, grabPortAction, grabPortBindings, groupReorderContribution, groupReorderSlots, groupStencilIds, groupStencils, headerIdOf, hopFollower, insertMark, insertMessage, insertNote, insertStep, insertWaypoint, installAvoidRouting, installHops, installLabelPlacement, installOffPageMarkers, isBodyEnd, isBodyOrRegion, isContainerStencil, isDiagramBody, isSequenceText, isShippedTheme, itemDropContribution, labelDerivePose, labelDragLayer, labelScratchOf, labelSize, labelUnder, laneHeader, laneLayer, laneResizeFrame, laneScratchOf, laneStackLayout, lanesOf, layeredRoutes, layoutDiagram, layoutPoses, moveParticipant, moveStep, movedLabelData, newParticipant, nextOffPageRef, offPageFarText, offPageOps, offPageSplits, offPageTagData, offPageTagDerivePose, offPageTagLook, offPageTagSize, offPageTagSpec, offPageTagSpecs, offPageTagText, offPageTargetOf, orthogonal, parseDiagramTheme, pinSegment, placeOf, poolAxisOf, poolHeader, poolsOf, portLayer, portScratchOf, reconnectBinding, reconnectMessage, redrawSequences, regionHeaderAt, regionSpecs, registerDiagramShape, relayoutBodies, releaseMembers, removeBox, removeMarks, removeMarksOf, removeParticipant, removeSection, removeSegment, removeStencilGroup, removeStep, removeStepAt, removeThemeRole, removeWaypoint, renameThemeRole, rendererMeasure, reorderBinding, reorderContribution, resolveEnd, roleEdgeStyle, roleStyle, routeDataOps, routeHandles, routeStateOf, routeWrites, routedData, routerActions, routesOf, sceneParticipants, segmentAxis, selectSequencePartAction, selfLoop, seqIdTaken, sequenceCommitOf, sequenceDeletes, sequenceLayout, sequencePartNodeOf, sequencePartOf, sequenceRootOf, sequenceScratchOf, sequenceSelectionOf, sequenceSlots, sequenceSpecs, sequenceTextOf, sequenceTools, setAutonumber, setDiagramColor, setDiagramFontSize, setDiagramStyle, setDiagramType, setFragmentType, setMessageActivation, setMessageArrow, setParticipantOutline, setSequenceText, setThemeValue, simplifyStops, stackedLanes, startItemDrag, startSequence, stencilBuild, stencilIdOf, stencilKind, stencilTool, stepListOf, straight, subpathOf, themeDocValue, themeEdgeStroke, themeFont, themeLabelFont, themeLabelStyle, themeRoles, themeToJson, themeValue, themeWrites, titlePose, unpinSegment, unwrapFragment, useAvoidRouting, useConnectorTool, useHops, useLabelPlacement, useLiveLayout, useMirroredSelection, useOffPageMarkers, useSequenceTextEdit, useSequenceTools, useStencilInsert, useStencilTool, waypointFollower, waypointLayer, waypointScratchOf, withDiagramRegistry, withHops, withRouter, wrapSteps };