zombie-mermaid 2.2.3 → 2.2.6

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 (321) hide show
  1. package/README.md +4 -4
  2. package/dist/ascii.cjs +1 -11
  3. package/dist/ascii.d.cts +1 -167
  4. package/dist/ascii.d.ts +1 -167
  5. package/dist/ascii.js +1 -6591
  6. package/dist/cli.js +836 -10946
  7. package/dist/index.cjs +2 -81
  8. package/dist/index.cjs.map +1 -1
  9. package/dist/index.d.cts +42 -680
  10. package/dist/index.d.ts +42 -680
  11. package/dist/index.js +408 -10002
  12. package/dist/index.js.map +1 -1
  13. package/dist/mcp.cjs +1 -17909
  14. package/dist/mcp.d.cts +1 -11
  15. package/dist/mcp.d.ts +1 -11
  16. package/dist/mcp.js +1 -17884
  17. package/package.json +29 -29
  18. package/src/__tests__/workspace-package-boundaries.test.ts +15 -16
  19. package/src/__tests__/xychart-parser-categories.test.ts +78 -0
  20. package/src/ascii-entry.ts +14 -0
  21. package/src/cli/html-viewer.ts +5 -0
  22. package/src/mcp-entry.ts +21 -0
  23. package/dist/ascii.cjs.map +0 -1
  24. package/dist/ascii.js.map +0 -1
  25. package/dist/mcp.cjs.map +0 -1
  26. package/dist/mcp.js.map +0 -1
  27. package/packages/ascii-renderer/LICENSE +0 -22
  28. package/packages/ascii-renderer/src/ansi.ts +0 -490
  29. package/packages/ascii-renderer/src/canvas.ts +0 -658
  30. package/packages/ascii-renderer/src/class-diagram.ts +0 -2001
  31. package/packages/ascii-renderer/src/converter.ts +0 -446
  32. package/packages/ascii-renderer/src/coords.ts +0 -58
  33. package/packages/ascii-renderer/src/display-width.ts +0 -151
  34. package/packages/ascii-renderer/src/draw-arrows.ts +0 -549
  35. package/packages/ascii-renderer/src/draw-boxes.ts +0 -267
  36. package/packages/ascii-renderer/src/draw-bundles.ts +0 -611
  37. package/packages/ascii-renderer/src/draw-lines.ts +0 -174
  38. package/packages/ascii-renderer/src/draw-subgraphs.ts +0 -108
  39. package/packages/ascii-renderer/src/draw.ts +0 -337
  40. package/packages/ascii-renderer/src/edge-bundling.ts +0 -435
  41. package/packages/ascii-renderer/src/edge-cell-styles.ts +0 -81
  42. package/packages/ascii-renderer/src/edge-routing.ts +0 -1049
  43. package/packages/ascii-renderer/src/er-diagram.ts +0 -1488
  44. package/packages/ascii-renderer/src/flowchart.ts +0 -94
  45. package/packages/ascii-renderer/src/grid-occupancy.ts +0 -234
  46. package/packages/ascii-renderer/src/grid.ts +0 -1267
  47. package/packages/ascii-renderer/src/hyperlinks.ts +0 -248
  48. package/packages/ascii-renderer/src/index.ts +0 -163
  49. package/packages/ascii-renderer/src/lane-search.ts +0 -68
  50. package/packages/ascii-renderer/src/multiline-utils.ts +0 -82
  51. package/packages/ascii-renderer/src/pathfinder.ts +0 -448
  52. package/packages/ascii-renderer/src/registry.ts +0 -88
  53. package/packages/ascii-renderer/src/sequence.ts +0 -1318
  54. package/packages/ascii-renderer/src/shapes/circle.ts +0 -31
  55. package/packages/ascii-renderer/src/shapes/corners.ts +0 -273
  56. package/packages/ascii-renderer/src/shapes/diamond.ts +0 -31
  57. package/packages/ascii-renderer/src/shapes/hexagon.ts +0 -31
  58. package/packages/ascii-renderer/src/shapes/index.ts +0 -123
  59. package/packages/ascii-renderer/src/shapes/rectangle.ts +0 -199
  60. package/packages/ascii-renderer/src/shapes/rounded.ts +0 -31
  61. package/packages/ascii-renderer/src/shapes/special.ts +0 -352
  62. package/packages/ascii-renderer/src/shapes/stadium.ts +0 -122
  63. package/packages/ascii-renderer/src/shapes/state.ts +0 -204
  64. package/packages/ascii-renderer/src/shapes/types.ts +0 -78
  65. package/packages/ascii-renderer/src/territory.ts +0 -136
  66. package/packages/ascii-renderer/src/types.ts +0 -454
  67. package/packages/ascii-renderer/src/validate.ts +0 -189
  68. package/packages/ascii-renderer/src/xychart.ts +0 -1085
  69. package/packages/core/LICENSE +0 -22
  70. package/packages/core/src/click-directive.ts +0 -106
  71. package/packages/core/src/color-utils.ts +0 -205
  72. package/packages/core/src/diagram-type.ts +0 -35
  73. package/packages/core/src/direction-override.ts +0 -46
  74. package/packages/core/src/direction.ts +0 -56
  75. package/packages/core/src/index.ts +0 -34
  76. package/packages/core/src/init-directive.ts +0 -248
  77. package/packages/core/src/multiline-utils.ts +0 -275
  78. package/packages/core/src/statements.ts +0 -197
  79. package/packages/core/src/style-directives.ts +0 -214
  80. package/packages/core/src/text-metrics.ts +0 -498
  81. package/packages/core/src/theme.ts +0 -696
  82. package/packages/core/src/types.ts +0 -670
  83. package/packages/mcp/LICENSE +0 -22
  84. package/packages/mcp/src/index.ts +0 -17
  85. package/packages/mcp/src/server.ts +0 -135
  86. package/packages/mcp/src/tools/check-sequence-activations.ts +0 -91
  87. package/packages/mcp/src/tools/fix-sequence-activations.ts +0 -77
  88. package/packages/mcp/src/tools/render-ascii.ts +0 -99
  89. package/packages/mcp/src/tools/render-svg.ts +0 -95
  90. package/packages/mermaid-parser/LICENSE +0 -22
  91. package/packages/mermaid-parser/src/class/format.ts +0 -15
  92. package/packages/mermaid-parser/src/class/parser.ts +0 -593
  93. package/packages/mermaid-parser/src/class/types.ts +0 -166
  94. package/packages/mermaid-parser/src/er/parser.ts +0 -286
  95. package/packages/mermaid-parser/src/er/types.ts +0 -99
  96. package/packages/mermaid-parser/src/expanded-shapes.ts +0 -376
  97. package/packages/mermaid-parser/src/index.ts +0 -48
  98. package/packages/mermaid-parser/src/sequence/activation-check.ts +0 -149
  99. package/packages/mermaid-parser/src/sequence/activation-fix.ts +0 -112
  100. package/packages/mermaid-parser/src/sequence/box-color.ts +0 -85
  101. package/packages/mermaid-parser/src/sequence/parser.ts +0 -613
  102. package/packages/mermaid-parser/src/sequence/types.ts +0 -242
  103. package/packages/mermaid-parser/src/xychart/colors.ts +0 -177
  104. package/packages/mermaid-parser/src/xychart/parser.ts +0 -203
  105. package/packages/mermaid-parser/src/xychart/types.ts +0 -150
  106. package/packages/svg-renderer/LICENSE +0 -22
  107. package/packages/svg-renderer/src/class/layout.ts +0 -360
  108. package/packages/svg-renderer/src/class/renderer.ts +0 -636
  109. package/packages/svg-renderer/src/edge-curves.ts +0 -204
  110. package/packages/svg-renderer/src/elk-instance.ts +0 -292
  111. package/packages/svg-renderer/src/er/layout.ts +0 -200
  112. package/packages/svg-renderer/src/er/renderer.ts +0 -493
  113. package/packages/svg-renderer/src/index.ts +0 -58
  114. package/packages/svg-renderer/src/layout-engine/constants.ts +0 -19
  115. package/packages/svg-renderer/src/layout-engine/edge-bundling.ts +0 -379
  116. package/packages/svg-renderer/src/layout-engine/elk-adapter-utils.ts +0 -81
  117. package/packages/svg-renderer/src/layout-engine/elk-graph-builder.ts +0 -240
  118. package/packages/svg-renderer/src/layout-engine/from-elk.ts +0 -685
  119. package/packages/svg-renderer/src/layout-engine/layer-alignment.ts +0 -174
  120. package/packages/svg-renderer/src/layout-engine/to-elk.ts +0 -695
  121. package/packages/svg-renderer/src/layout-engine.ts +0 -74
  122. package/packages/svg-renderer/src/layout.ts +0 -8
  123. package/packages/svg-renderer/src/renderer.ts +0 -1485
  124. package/packages/svg-renderer/src/resolve-colors.ts +0 -339
  125. package/packages/svg-renderer/src/sequence/layout.ts +0 -698
  126. package/packages/svg-renderer/src/sequence/renderer.ts +0 -546
  127. package/packages/svg-renderer/src/shape-clipping.ts +0 -197
  128. package/packages/svg-renderer/src/styles.ts +0 -118
  129. package/packages/svg-renderer/src/xychart/layout.ts +0 -682
  130. package/packages/svg-renderer/src/xychart/renderer.ts +0 -684
  131. package/src/__tests__/ascii-canvas-write.test.ts +0 -137
  132. package/src/__tests__/ascii-charset-border-junctions.test.ts +0 -63
  133. package/src/__tests__/ascii-cjk-width.test.ts +0 -150
  134. package/src/__tests__/ascii-class-box-occupancy.test.ts +0 -462
  135. package/src/__tests__/ascii-class-column-width-488-489.test.ts +0 -639
  136. package/src/__tests__/ascii-class-cross-level-jog-corruption.test.ts +0 -187
  137. package/src/__tests__/ascii-class-detour-label-routing-487.test.ts +0 -114
  138. package/src/__tests__/ascii-class-diagram-compartments.test.ts +0 -70
  139. package/src/__tests__/ascii-class-label-box-collision.test.ts +0 -60
  140. package/src/__tests__/ascii-class-label-row-collision-531.test.ts +0 -135
  141. package/src/__tests__/ascii-class-label-territory-row-awareness.test.ts +0 -57
  142. package/src/__tests__/ascii-class-padding.test.ts +0 -104
  143. package/src/__tests__/ascii-class-parent-alignment-971.test.ts +0 -139
  144. package/src/__tests__/ascii-class-parent-alignment-972.test.ts +0 -208
  145. package/src/__tests__/ascii-class-reciprocal-relationships-448.test.ts +0 -169
  146. package/src/__tests__/ascii-combining-mark-width.test.ts +0 -70
  147. package/src/__tests__/ascii-coords-overlay.test.ts +0 -64
  148. package/src/__tests__/ascii-decision-lr-box-start.test.ts +0 -106
  149. package/src/__tests__/ascii-display-width-unit.test.ts +0 -154
  150. package/src/__tests__/ascii-draw-arrows-coverage.test.ts +0 -171
  151. package/src/__tests__/ascii-draw-arrows-single-point-path.test.ts +0 -112
  152. package/src/__tests__/ascii-edge-bundling-rank-violation-454.test.ts +0 -72
  153. package/src/__tests__/ascii-edge-ending-glyphs.test.ts +0 -206
  154. package/src/__tests__/ascii-edge-label-diagonal-fallback-418.test.ts +0 -95
  155. package/src/__tests__/ascii-edge-routing-fixes.test.ts +0 -178
  156. package/src/__tests__/ascii-edge-routing-single-point-path.test.ts +0 -107
  157. package/src/__tests__/ascii-edge-styles.test.ts +0 -149
  158. package/src/__tests__/ascii-emoji-cluster-width.test.ts +0 -101
  159. package/src/__tests__/ascii-er-box-occupancy.test.ts +0 -251
  160. package/src/__tests__/ascii-er-cardinality.test.ts +0 -40
  161. package/src/__tests__/ascii-er-corner-glyphs.test.ts +0 -249
  162. package/src/__tests__/ascii-er-jog-stray-line.test.ts +0 -111
  163. package/src/__tests__/ascii-er-label-padding.test.ts +0 -118
  164. package/src/__tests__/ascii-er-padding.test.ts +0 -114
  165. package/src/__tests__/ascii-er-relationship-label-corruption-350.test.ts +0 -458
  166. package/src/__tests__/ascii-er-relationship-overwrite.test.ts +0 -325
  167. package/src/__tests__/ascii-er-stray-connectors.test.ts +0 -347
  168. package/src/__tests__/ascii-er-unrelated-stem-separation-411.test.ts +0 -98
  169. package/src/__tests__/ascii-er-vertical-one-marker.test.ts +0 -110
  170. package/src/__tests__/ascii-label-line-terminal-fallback.test.ts +0 -172
  171. package/src/__tests__/ascii-lane-search.test.ts +0 -207
  172. package/src/__tests__/ascii-multibox-cjk-width.test.ts +0 -184
  173. package/src/__tests__/ascii-multiline.test.ts +0 -291
  174. package/src/__tests__/ascii-padding-edge-cases.test.ts +0 -154
  175. package/src/__tests__/ascii-pathfinder-route-edge.test.ts +0 -194
  176. package/src/__tests__/ascii-sequence-alt-else-label.test.ts +0 -236
  177. package/src/__tests__/ascii-sequence-block-wall-clearance.test.ts +0 -217
  178. package/src/__tests__/ascii-sequence-box-group.test.ts +0 -159
  179. package/src/__tests__/ascii-sequence-cjk-width.test.ts +0 -235
  180. package/src/__tests__/ascii-sequence-create-destroy.test.ts +0 -114
  181. package/src/__tests__/ascii-sequence-form-invariants.test.ts +0 -432
  182. package/src/__tests__/ascii-sequence-mermaid-parity.test.ts +0 -219
  183. package/src/__tests__/ascii-sequence-notes.test.ts +0 -61
  184. package/src/__tests__/ascii-sequence-padding.test.ts +0 -119
  185. package/src/__tests__/ascii-sequence-self-arrow.test.ts +0 -206
  186. package/src/__tests__/ascii-shape-diamond.test.ts +0 -38
  187. package/src/__tests__/ascii-shape-rectangle.test.ts +0 -258
  188. package/src/__tests__/ascii-shape-rounded.test.ts +0 -36
  189. package/src/__tests__/ascii-shapes-circle.test.ts +0 -41
  190. package/src/__tests__/ascii-shapes-hexagon.test.ts +0 -42
  191. package/src/__tests__/ascii-shapes-special.test.ts +0 -349
  192. package/src/__tests__/ascii-shapes-stadium.test.ts +0 -217
  193. package/src/__tests__/ascii-shapes-state.test.ts +0 -234
  194. package/src/__tests__/ascii-state-bidirectional-label-swap-530.test.ts +0 -130
  195. package/src/__tests__/ascii-subgraph-direction-honored-445.test.ts +0 -90
  196. package/src/__tests__/ascii-subgraph-label-border-clip.test.ts +0 -152
  197. package/src/__tests__/ascii-subgraph-title-padding.test.ts +0 -77
  198. package/src/__tests__/ascii-territory-unit.test.ts +0 -219
  199. package/src/__tests__/ascii-validate.test.ts +0 -220
  200. package/src/__tests__/ascii.test.ts +0 -328
  201. package/src/__tests__/box-color.test.ts +0 -80
  202. package/src/__tests__/class-arrow-directions.test.ts +0 -505
  203. package/src/__tests__/click-directive.test.ts +0 -63
  204. package/src/__tests__/color-utils.test.ts +0 -186
  205. package/src/__tests__/diagram-type.test.ts +0 -28
  206. package/src/__tests__/draw-lines.test.ts +0 -93
  207. package/src/__tests__/edge-cell-styles.test.ts +0 -180
  208. package/src/__tests__/elk-adapter-utils.test.ts +0 -166
  209. package/src/__tests__/grid-occupancy.test.ts +0 -240
  210. package/src/__tests__/helpers/ascii-form.ts +0 -142
  211. package/src/__tests__/helpers/terminal-display-width.ts +0 -74
  212. package/src/__tests__/mcp-check-sequence-activations-tool.test.ts +0 -85
  213. package/src/__tests__/mcp-fix-sequence-activations-tool.test.ts +0 -134
  214. package/src/__tests__/mcp-server.test.ts +0 -163
  215. package/src/__tests__/pathfinder.test.ts +0 -246
  216. package/src/__tests__/sequence-activation-fix.test.ts +0 -91
  217. package/src/__tests__/testdata/ascii/ampersand_lhs.txt +0 -18
  218. package/src/__tests__/testdata/ascii/ampersand_lhs_and_rhs.txt +0 -18
  219. package/src/__tests__/testdata/ascii/ampersand_rhs.txt +0 -18
  220. package/src/__tests__/testdata/ascii/ampersand_td_fanin.txt +0 -18
  221. package/src/__tests__/testdata/ascii/ampersand_td_fanout.txt +0 -18
  222. package/src/__tests__/testdata/ascii/ampersand_without_edge.txt +0 -18
  223. package/src/__tests__/testdata/ascii/back_reference_from_child.txt +0 -10
  224. package/src/__tests__/testdata/ascii/backlink_from_bottom.txt +0 -22
  225. package/src/__tests__/testdata/ascii/backlink_from_top.txt +0 -22
  226. package/src/__tests__/testdata/ascii/backlink_with_short_y_padding.txt +0 -20
  227. package/src/__tests__/testdata/ascii/cls_all_relationships.txt +0 -19
  228. package/src/__tests__/testdata/ascii/cls_annotation.txt +0 -29
  229. package/src/__tests__/testdata/ascii/cls_association.txt +0 -14
  230. package/src/__tests__/testdata/ascii/cls_basic.txt +0 -15
  231. package/src/__tests__/testdata/ascii/cls_dependency.txt +0 -14
  232. package/src/__tests__/testdata/ascii/cls_inheritance.txt +0 -20
  233. package/src/__tests__/testdata/ascii/cls_methods.txt +0 -21
  234. package/src/__tests__/testdata/ascii/comments.txt +0 -23
  235. package/src/__tests__/testdata/ascii/custom_padding.txt +0 -10
  236. package/src/__tests__/testdata/ascii/duplicate_labels.txt +0 -19
  237. package/src/__tests__/testdata/ascii/er_attributes.txt +0 -21
  238. package/src/__tests__/testdata/ascii/er_basic.txt +0 -8
  239. package/src/__tests__/testdata/ascii/er_identifying.txt +0 -18
  240. package/src/__tests__/testdata/ascii/flowchart_tb_simple.txt +0 -29
  241. package/src/__tests__/testdata/ascii/graph_bt_direction.txt +0 -28
  242. package/src/__tests__/testdata/ascii/graph_tb_direction.txt +0 -26
  243. package/src/__tests__/testdata/ascii/nested_subgraphs_with_labels.txt +0 -36
  244. package/src/__tests__/testdata/ascii/preserve_order_of_definition.txt +0 -23
  245. package/src/__tests__/testdata/ascii/self_reference.txt +0 -10
  246. package/src/__tests__/testdata/ascii/self_reference_with_edge.txt +0 -10
  247. package/src/__tests__/testdata/ascii/seq_basic.txt +0 -17
  248. package/src/__tests__/testdata/ascii/seq_multiple_messages.txt +0 -25
  249. package/src/__tests__/testdata/ascii/seq_self_message.txt +0 -18
  250. package/src/__tests__/testdata/ascii/single_node.txt +0 -8
  251. package/src/__tests__/testdata/ascii/single_node_longer_name.txt +0 -8
  252. package/src/__tests__/testdata/ascii/subgraph_complex_mixed.txt +0 -38
  253. package/src/__tests__/testdata/ascii/subgraph_complex_nested.txt +0 -49
  254. package/src/__tests__/testdata/ascii/subgraph_direction_override.txt +0 -47
  255. package/src/__tests__/testdata/ascii/subgraph_empty.txt +0 -10
  256. package/src/__tests__/testdata/ascii/subgraph_mixed_nodes.txt +0 -20
  257. package/src/__tests__/testdata/ascii/subgraph_mixed_nodes_td.txt +0 -48
  258. package/src/__tests__/testdata/ascii/subgraph_multiple_edges.txt +0 -32
  259. package/src/__tests__/testdata/ascii/subgraph_multiple_nodes.txt +0 -16
  260. package/src/__tests__/testdata/ascii/subgraph_nested.txt +0 -24
  261. package/src/__tests__/testdata/ascii/subgraph_nested_with_external.txt +0 -30
  262. package/src/__tests__/testdata/ascii/subgraph_node_outside_lr.txt +0 -17
  263. package/src/__tests__/testdata/ascii/subgraph_single_node.txt +0 -16
  264. package/src/__tests__/testdata/ascii/subgraph_td_direction.txt +0 -26
  265. package/src/__tests__/testdata/ascii/subgraph_td_multiple.txt +0 -44
  266. package/src/__tests__/testdata/ascii/subgraph_td_multiple_paddingy.txt +0 -42
  267. package/src/__tests__/testdata/ascii/subgraph_three_levels_nested.txt +0 -32
  268. package/src/__tests__/testdata/ascii/subgraph_three_separate.txt +0 -24
  269. package/src/__tests__/testdata/ascii/subgraph_two_separate.txt +0 -20
  270. package/src/__tests__/testdata/ascii/subgraph_with_labels.txt +0 -20
  271. package/src/__tests__/testdata/ascii/three_nodes.txt +0 -9
  272. package/src/__tests__/testdata/ascii/three_nodes_single_line.txt +0 -8
  273. package/src/__tests__/testdata/ascii/two_layer_single_graph.txt +0 -19
  274. package/src/__tests__/testdata/ascii/two_layer_single_graph_longer_names.txt +0 -19
  275. package/src/__tests__/testdata/ascii/two_nodes_linked.txt +0 -8
  276. package/src/__tests__/testdata/ascii/two_nodes_longer_names.txt +0 -8
  277. package/src/__tests__/testdata/ascii/two_root_nodes.txt +0 -19
  278. package/src/__tests__/testdata/ascii/two_root_nodes_longer_names.txt +0 -19
  279. package/src/__tests__/testdata/ascii/two_single_root_nodes.txt +0 -19
  280. package/src/__tests__/testdata/unicode/ampersand_lhs.txt +0 -18
  281. package/src/__tests__/testdata/unicode/ampersand_lhs_and_rhs.txt +0 -18
  282. package/src/__tests__/testdata/unicode/ampersand_rhs.txt +0 -18
  283. package/src/__tests__/testdata/unicode/ampersand_without_edge.txt +0 -18
  284. package/src/__tests__/testdata/unicode/back_reference_from_child.txt +0 -10
  285. package/src/__tests__/testdata/unicode/backlink_from_bottom.txt +0 -22
  286. package/src/__tests__/testdata/unicode/backlink_from_top.txt +0 -22
  287. package/src/__tests__/testdata/unicode/cls_all_relationships.txt +0 -19
  288. package/src/__tests__/testdata/unicode/cls_annotation.txt +0 -29
  289. package/src/__tests__/testdata/unicode/cls_association.txt +0 -14
  290. package/src/__tests__/testdata/unicode/cls_basic.txt +0 -15
  291. package/src/__tests__/testdata/unicode/cls_dependency.txt +0 -14
  292. package/src/__tests__/testdata/unicode/cls_inheritance.txt +0 -20
  293. package/src/__tests__/testdata/unicode/cls_methods.txt +0 -21
  294. package/src/__tests__/testdata/unicode/comments.txt +0 -23
  295. package/src/__tests__/testdata/unicode/duplicate_labels.txt +0 -19
  296. package/src/__tests__/testdata/unicode/er_attributes.txt +0 -21
  297. package/src/__tests__/testdata/unicode/er_basic.txt +0 -8
  298. package/src/__tests__/testdata/unicode/er_identifying.txt +0 -18
  299. package/src/__tests__/testdata/unicode/graph_bt_direction.txt +0 -28
  300. package/src/__tests__/testdata/unicode/preserve_order_of_definition.txt +0 -23
  301. package/src/__tests__/testdata/unicode/self_reference.txt +0 -10
  302. package/src/__tests__/testdata/unicode/self_reference_with_edge.txt +0 -10
  303. package/src/__tests__/testdata/unicode/seq_basic.txt +0 -17
  304. package/src/__tests__/testdata/unicode/seq_multiple_messages.txt +0 -25
  305. package/src/__tests__/testdata/unicode/seq_self_message.txt +0 -18
  306. package/src/__tests__/testdata/unicode/single_node.txt +0 -8
  307. package/src/__tests__/testdata/unicode/single_node_longer_name.txt +0 -8
  308. package/src/__tests__/testdata/unicode/three_nodes.txt +0 -9
  309. package/src/__tests__/testdata/unicode/three_nodes_single_line.txt +0 -8
  310. package/src/__tests__/testdata/unicode/two_layer_single_graph.txt +0 -19
  311. package/src/__tests__/testdata/unicode/two_layer_single_graph_longer_names.txt +0 -19
  312. package/src/__tests__/testdata/unicode/two_nodes_linked.txt +0 -8
  313. package/src/__tests__/testdata/unicode/two_nodes_longer_names.txt +0 -8
  314. package/src/__tests__/testdata/unicode/two_root_nodes.txt +0 -19
  315. package/src/__tests__/testdata/unicode/two_root_nodes_longer_names.txt +0 -19
  316. package/src/__tests__/testdata/unicode/two_single_root_nodes.txt +0 -19
  317. package/src/__tests__/text-metrics.test.ts +0 -473
  318. package/src/__tests__/theme-palette-contrast.test.ts +0 -84
  319. package/src/__tests__/theme.test.ts +0 -132
  320. package/src/__tests__/xychart-ascii.test.ts +0 -376
  321. package/src/__tests__/xychart-colors.test.ts +0 -149
@@ -1,242 +0,0 @@
1
- // ============================================================================
2
- // Sequence diagram types
3
- //
4
- // Models the parsed and positioned representations of a Mermaid sequence diagram.
5
- // Sequence diagrams show actor interactions over time (vertical timeline).
6
- // ============================================================================
7
-
8
- /** Parsed sequence diagram — logical structure from mermaid text */
9
- export interface SequenceDiagram {
10
- /** Ordered list of actors/participants */
11
- actors: Actor[]
12
- /** Messages between actors in chronological order */
13
- messages: Message[]
14
- /** Structural blocks (loop, alt, opt, par, critical) */
15
- blocks: Block[]
16
- /** Notes attached to actors */
17
- notes: Note[]
18
- /**
19
- * Standalone `activate X` / `deactivate X` statements, in source order.
20
- * The inline `+`/`-` arrow shorthand is *not* recorded here — it stays on
21
- * `Message.activate` / `Message.deactivate` — but both feed the same
22
- * activation stack at layout time (see layout.ts), so the two forms
23
- * render identically.
24
- */
25
- activations: ActivationEvent[]
26
- /**
27
- * `box <color?> <label?> … end` participant groups, in source order. A box
28
- * with no members (nothing declared inside it) is kept here but drawn by
29
- * neither renderer.
30
- */
31
- boxes: ParticipantBox[]
32
- }
33
-
34
- /** A `box … end` group of participants (Mermaid's "Grouping / Box"). */
35
- export interface ParticipantBox {
36
- /** Descriptive label; empty when the box has none. */
37
- label: string
38
- /**
39
- * Validated CSS colour (named, `#hex`, `rgb()`/`rgba()`, `hsl()`/`hsla()`)
40
- * exactly as written. Unset for a transparent box — including an explicit
41
- * `box transparent …`, and any first word that isn't a colour, which then
42
- * counts as the start of the label (Mermaid's `parseBoxData` rule).
43
- */
44
- color?: string
45
- /** Ids of the participants declared (or first used) inside the box. */
46
- actorIds: string[]
47
- }
48
-
49
- /**
50
- * One standalone `activate X` (`kind: 'start'`) or `deactivate X`
51
- * (`kind: 'end'`) statement. Mermaid's own grammar expands the `+`/`-` arrow
52
- * shorthand into exactly these events — `A->>+B` is a message followed by an
53
- * `activeStart` for the recipient, `A-->>-B` a message followed by an
54
- * `activeEnd` for the sender — so this is the primitive and the shorthand is
55
- * sugar over it.
56
- */
57
- export interface ActivationEvent {
58
- actorId: string
59
- kind: 'start' | 'end'
60
- /**
61
- * Index of the message this statement follows (-1 if it precedes every
62
- * message). The activation bar starts/ends at that message's row, which
63
- * is where the shorthand form's bar starts/ends too.
64
- */
65
- afterIndex: number
66
- }
67
-
68
- export interface Actor {
69
- id: string
70
- label: string
71
- /** 'participant' renders as a box, 'actor' renders as a stick figure */
72
- type: 'participant' | 'actor'
73
- /**
74
- * Index of the message that creates this participant (`create participant
75
- * X` on the line before it). The participant's box is drawn at that
76
- * message's row instead of in the header, and its lifeline starts there.
77
- * Unset for participants that exist from the top of the diagram.
78
- */
79
- createdAt?: number
80
- /**
81
- * Index of the message that destroys this participant (`destroy X` on the
82
- * line before it). Its lifeline ends at that message's row with a cross,
83
- * and no footer box is drawn. Unset for participants that live to the end.
84
- */
85
- destroyedAt?: number
86
- }
87
-
88
- export interface Message {
89
- from: string
90
- to: string
91
- label: string
92
- /** Arrow style: solid line or dashed line */
93
- lineStyle: 'solid' | 'dashed'
94
- /** Arrow head: filled (closed) or open */
95
- arrowHead: 'filled' | 'open'
96
- /**
97
- * Set for a "lost message" cross-terminator (`-x`/`--x`). `arrowHead`
98
- * stays `'filled'` for these (unchanged, to preserve existing SVG output)
99
- * — this flag lets the ASCII renderer draw a distinct cross glyph instead
100
- * of the plain filled arrowhead it shares with `->>`/`-->>`. See issue
101
- * #330; not yet modeled by the SVG renderer's markers.
102
- */
103
- isLost?: boolean
104
- /** Activate the target lifeline (+) */
105
- activate?: boolean
106
- /** Deactivate the source lifeline (-) */
107
- deactivate?: boolean
108
- /** Bidirectional arrow (`<<->>` or `<<-->>`) — draw an arrow head on both ends */
109
- bidirectional?: boolean
110
- /** Sequence number to display next to this arrow when `autonumber` is active */
111
- seqNumber?: number
112
- }
113
-
114
- export interface Block {
115
- /** Block type keyword */
116
- type: 'loop' | 'alt' | 'opt' | 'par' | 'critical' | 'break' | 'rect'
117
- /** Label for the block header */
118
- label: string
119
- /** Index of the first message inside this block */
120
- startIndex: number
121
- /** Index of the last message inside this block (inclusive) */
122
- endIndex: number
123
- /** For alt/par blocks: indices where "else"/"and" dividers appear (message indices) */
124
- dividers: Array<{ index: number; label: string }>
125
- }
126
-
127
- export interface Note {
128
- /** Which actor(s) the note is attached to */
129
- actorIds: string[]
130
- /** Note text content */
131
- text: string
132
- /** Position relative to the actor(s) */
133
- position: 'left' | 'right' | 'over'
134
- /** Message index after which this note appears */
135
- afterIndex: number
136
- }
137
-
138
- // ============================================================================
139
- // Positioned sequence diagram — ready for SVG rendering
140
- // ============================================================================
141
-
142
- export interface PositionedSequenceDiagram {
143
- width: number
144
- height: number
145
- actors: PositionedActor[]
146
- lifelines: Lifeline[]
147
- messages: PositionedMessage[]
148
- activations: Activation[]
149
- blocks: PositionedBlock[]
150
- notes: PositionedNote[]
151
- /** `box … end` group backgrounds, drawn behind everything else. */
152
- boxes: PositionedParticipantBox[]
153
- }
154
-
155
- /** A positioned `box … end` group: a full-height background behind its participants. */
156
- export interface PositionedParticipantBox {
157
- label: string
158
- /** See {@link ParticipantBox.color}. */
159
- color?: string
160
- x: number
161
- y: number
162
- width: number
163
- height: number
164
- }
165
-
166
- export interface PositionedActor {
167
- id: string
168
- label: string
169
- type: 'participant' | 'actor'
170
- /** Center x of the actor box */
171
- x: number
172
- /** Top y of the actor box */
173
- y: number
174
- width: number
175
- height: number
176
- }
177
-
178
- /** Vertical dashed line from actor to bottom of diagram */
179
- export interface Lifeline {
180
- actorId: string
181
- x: number
182
- topY: number
183
- bottomY: number
184
- /**
185
- * Set when the actor is destroyed mid-diagram (`Actor.destroyedAt`):
186
- * `bottomY` is then the destroying message's row rather than the diagram
187
- * bottom, and the renderer marks it with a cross.
188
- */
189
- destroyed?: boolean
190
- }
191
-
192
- export interface PositionedMessage {
193
- from: string
194
- to: string
195
- label: string
196
- lineStyle: 'solid' | 'dashed'
197
- arrowHead: 'filled' | 'open'
198
- /** Start point (from actor's lifeline) */
199
- x1: number
200
- /** End point (to actor's lifeline) */
201
- x2: number
202
- /** Vertical position */
203
- y: number
204
- /** Whether this is a self-message (same actor) */
205
- isSelf: boolean
206
- /** Bidirectional arrow (`<<->>` or `<<-->>`) — draw an arrow head on both ends */
207
- bidirectional: boolean
208
- /** Sequence number to display next to this arrow when `autonumber` is active */
209
- seqNumber?: number
210
- }
211
-
212
- /** Narrow rectangle on a lifeline showing active processing */
213
- export interface Activation {
214
- actorId: string
215
- x: number
216
- topY: number
217
- bottomY: number
218
- width: number
219
- }
220
-
221
- export interface PositionedBlock {
222
- type: Block['type']
223
- label: string
224
- x: number
225
- y: number
226
- width: number
227
- height: number
228
- /** Divider lines within the block (for alt/par) */
229
- dividers: Array<{ y: number; label: string }>
230
- }
231
-
232
- export interface PositionedNote {
233
- text: string
234
- x: number
235
- y: number
236
- width: number
237
- height: number
238
- /** Actor IDs this note is attached to (for SVG attribution) */
239
- actors?: string[]
240
- /** Note position relative to actors (for SVG attribution) */
241
- position?: 'left' | 'right' | 'over'
242
- }
@@ -1,177 +0,0 @@
1
- // ============================================================================
2
- // XY Chart — shared color palette
3
- //
4
- // Generates monochromatic shades from the theme accent color.
5
- // Series 0 = accent (or blue fallback). Series 1+ are darker/lighter
6
- // shades of the same hue with subtle hue drift to stay in the same
7
- // color family (like navy ↔ cyan from blue).
8
- //
9
- // Used by both the SVG and ASCII renderers.
10
- // ============================================================================
11
-
12
- /** Default accent for charts when the theme doesn't provide one. */
13
- export const CHART_ACCENT_FALLBACK = '#3b82f6' // blue-500
14
-
15
- // ---------------------------------------------------------------------------
16
- // HSL ↔ Hex conversion
17
- // ---------------------------------------------------------------------------
18
-
19
- function hexToHsl(hex: string): [number, number, number] {
20
- const h = hex.replace('#', '')
21
- const ri = parseInt(h.substring(0, 2), 16) / 255
22
- const gi = parseInt(h.substring(2, 4), 16) / 255
23
- const bi = parseInt(h.substring(4, 6), 16) / 255
24
-
25
- const max = Math.max(ri, gi, bi)
26
- const min = Math.min(ri, gi, bi)
27
- const l = (max + min) / 2
28
-
29
- if (max === min) return [0, 0, l * 100]
30
-
31
- const d = max - min
32
- const s = l > 0.5 ? d / (2 - max - min) : d / (max + min)
33
-
34
- let hue: number
35
- if (max === ri) hue = ((gi - bi) / d + (gi < bi ? 6 : 0)) / 6
36
- else if (max === gi) hue = ((bi - ri) / d + 2) / 6
37
- else hue = ((ri - gi) / d + 4) / 6
38
-
39
- return [hue * 360, s * 100, l * 100]
40
- }
41
-
42
- function hslToHex(h: number, s: number, l: number): string {
43
- const si = s / 100
44
- const li = l / 100
45
-
46
- const c = (1 - Math.abs(2 * li - 1)) * si
47
- const x = c * (1 - Math.abs(((h / 60) % 2) - 1))
48
- const m = li - c / 2
49
-
50
- let r: number, g: number, b: number
51
- if (h < 60) {
52
- r = c
53
- g = x
54
- b = 0
55
- } else if (h < 120) {
56
- r = x
57
- g = c
58
- b = 0
59
- } else if (h < 180) {
60
- r = 0
61
- g = c
62
- b = x
63
- } else if (h < 240) {
64
- r = 0
65
- g = x
66
- b = c
67
- } else if (h < 300) {
68
- r = x
69
- g = 0
70
- b = c
71
- } else {
72
- r = c
73
- g = 0
74
- b = x
75
- }
76
-
77
- const toHex = (v: number) =>
78
- Math.round((v + m) * 255)
79
- .toString(16)
80
- .padStart(2, '0')
81
- return `#${toHex(r)}${toHex(g)}${toHex(b)}`
82
- }
83
-
84
- // ---------------------------------------------------------------------------
85
- // Hex ↔ RGB conversion
86
- // ---------------------------------------------------------------------------
87
-
88
- function hexToRgb(hex: string): [number, number, number] {
89
- const h = hex.replace('#', '')
90
- return [
91
- parseInt(h.substring(0, 2), 16),
92
- parseInt(h.substring(2, 4), 16),
93
- parseInt(h.substring(4, 6), 16),
94
- ]
95
- }
96
-
97
- function rgbToHex(r: number, g: number, b: number): string {
98
- const toHex = (v: number) =>
99
- Math.round(Math.max(0, Math.min(255, v)))
100
- .toString(16)
101
- .padStart(2, '0')
102
- return `#${toHex(r)}${toHex(g)}${toHex(b)}`
103
- }
104
-
105
- // ---------------------------------------------------------------------------
106
- // Public API
107
- // ---------------------------------------------------------------------------
108
-
109
- /** Check whether a string is a valid 6-digit hex color (e.g. "#3b82f6"). */
110
- export function isValidHex(color: string): boolean {
111
- return /^#[0-9a-fA-F]{6}$/.test(color)
112
- }
113
-
114
- /**
115
- * Detect whether a background color is dark (lightness < 50%).
116
- */
117
- export function isDarkBackground(bgHex: string): boolean {
118
- return hexToHsl(bgHex)[2] < 50
119
- }
120
-
121
- /**
122
- * Mix two hex colors in RGB space.
123
- * `ratio` controls how much of `fgHex` shows: 0 = pure bg, 1 = pure fg.
124
- * Equivalent to alpha-compositing fg over bg at the given opacity.
125
- */
126
- export function mixHexColors(
127
- bgHex: string,
128
- fgHex: string,
129
- ratio: number,
130
- ): string {
131
- const [br, bg, bb] = hexToRgb(bgHex)
132
- const [fr, fg, fb] = hexToRgb(fgHex)
133
- const inv = 1 - ratio
134
- return rgbToHex(
135
- br * inv + fr * ratio,
136
- bg * inv + fg * ratio,
137
- bb * inv + fb * ratio,
138
- )
139
- }
140
-
141
- /**
142
- * Get the hex color for a series index.
143
- * Index 0 returns the accent color as-is.
144
- * Index 1+ alternate between darker and lighter shades of the same hue
145
- * with subtle hue drift (±8-12° per tier) to stay in the same family.
146
- *
147
- * When `bgColor` is provided, shade direction adapts to the background:
148
- * - Light bg: odd = darker, even = lighter (default)
149
- * - Dark bg: odd = lighter, even = darker (so shades stay visible)
150
- */
151
- export function getSeriesColor(
152
- index: number,
153
- accentColor: string,
154
- bgColor?: string,
155
- ): string {
156
- if (index === 0) return accentColor
157
- // Fall back to defaults when inputs aren't valid hex (e.g. CSS variable refs like "var(--accent)")
158
- const safeAccent = isValidHex(accentColor)
159
- ? accentColor
160
- : CHART_ACCENT_FALLBACK
161
- const safeBg = bgColor && isValidHex(bgColor) ? bgColor : undefined
162
- const [h, s] = hexToHsl(safeAccent)
163
- const chartS = Math.max(55, Math.min(85, s))
164
-
165
- const tier = Math.ceil(index / 2)
166
- const oddIndex = index % 2 === 1
167
-
168
- // On dark backgrounds, flip: odd = lighter, even = darker
169
- const dark = safeBg && isDarkBackground(safeBg) ? !oddIndex : oddIndex
170
- const l = dark ? Math.max(25, 48 - tier * 13) : Math.min(78, 55 + tier * 11)
171
-
172
- // Subtle hue drift: darker shades shift slightly negative, lighter shift positive
173
- const hShift = (dark ? -8 : 12) * tier
174
- const newH = (((h + hShift) % 360) + 360) % 360
175
-
176
- return hslToHex(newH, chartS, l)
177
- }
@@ -1,203 +0,0 @@
1
- import type { XYChart, XYAxis, XYChartSeries } from './types.ts'
2
- import type { Statement } from '@zombie-mermaid/core'
3
-
4
- // ============================================================================
5
- // XY Chart parser
6
- //
7
- // Parses Mermaid xychart-beta syntax into a typed XYChart structure.
8
- //
9
- // Supported directives:
10
- // xychart-beta [horizontal]
11
- // title "Chart Title"
12
- // x-axis [label1, label2, ...] — categorical
13
- // x-axis min --> max — numeric range
14
- // x-axis "Axis Title" [label1, ...] — with title
15
- // x-axis "Axis Title" min --> max — with title
16
- // y-axis (same patterns)
17
- // bar [val1, val2, ...]
18
- // line [val1, val2, ...]
19
- // ============================================================================
20
-
21
- /**
22
- * Parse a Mermaid xychart-beta diagram from preprocessed lines.
23
- * Lines should already be trimmed and comment-stripped.
24
- */
25
- export function parseXYChart(lines: Statement[]): XYChart {
26
- const xAxis: XYAxis = {}
27
- const yAxis: XYAxis = {}
28
- const series: XYChartSeries[] = []
29
- let title: string | undefined
30
- let horizontal = false
31
-
32
- for (const stmt of lines) {
33
- const line = stmt.text
34
- // Header line — detect horizontal
35
- if (/^xychart(-beta)?\b/i.test(line)) {
36
- if (/\bhorizontal\b/i.test(line)) horizontal = true
37
- continue
38
- }
39
-
40
- // Title
41
- const titleMatch = line.match(/^title\s+"([^"]+)"/)
42
- if (titleMatch) {
43
- title = titleMatch[1]
44
- continue
45
- }
46
-
47
- // x-axis with categories: x-axis "Title" [a, b, c] or x-axis [a, b, c]
48
- const xCatMatch = line.match(/^x-axis\s+(?:"([^"]*)"\s*)?\[([^\]]+)\]/)
49
- if (xCatMatch) {
50
- if (xCatMatch[1]) xAxis.title = xCatMatch[1]
51
- xAxis.categories = xCatMatch[2]!.split(',').map((s) => s.trim())
52
- continue
53
- }
54
-
55
- // x-axis with range: x-axis "Title" min --> max or x-axis min --> max
56
- const xRangeMatch = line.match(
57
- /^x-axis\s+(?:"([^"]*)"\s+)?(-?\d+(?:\.\d+)?)\s*-->\s*(-?\d+(?:\.\d+)?)/,
58
- )
59
- if (xRangeMatch) {
60
- if (xRangeMatch[1]) xAxis.title = xRangeMatch[1]
61
- xAxis.range = {
62
- min: parseFloat(xRangeMatch[2]!),
63
- max: parseFloat(xRangeMatch[3]!),
64
- }
65
- continue
66
- }
67
-
68
- // y-axis with range: y-axis "Title" min --> max or y-axis min --> max
69
- const yRangeMatch = line.match(
70
- /^y-axis\s+(?:"([^"]*)"\s+)?(-?\d+(?:\.\d+)?)\s*-->\s*(-?\d+(?:\.\d+)?)/,
71
- )
72
- if (yRangeMatch) {
73
- if (yRangeMatch[1]) yAxis.title = yRangeMatch[1]
74
- yAxis.range = {
75
- min: parseFloat(yRangeMatch[2]!),
76
- max: parseFloat(yRangeMatch[3]!),
77
- }
78
- continue
79
- }
80
-
81
- // y-axis with just title (no range)
82
- const yTitleOnly = line.match(/^y-axis\s+"([^"]+)"\s*$/)
83
- if (yTitleOnly) {
84
- yAxis.title = yTitleOnly[1]
85
- continue
86
- }
87
-
88
- // bar [...]
89
- const barMatch = line.match(/^bar\s+\[([^\]]+)\]/)
90
- if (barMatch) {
91
- series.push({
92
- type: 'bar',
93
- data: parseNumericArray(barMatch[1]!, 'bar', line, stmt.line),
94
- })
95
- continue
96
- }
97
-
98
- // line [...]
99
- const lineMatch = line.match(/^line\s+\[([^\]]+)\]/)
100
- if (lineMatch) {
101
- series.push({
102
- type: 'line',
103
- data: parseNumericArray(lineMatch[1]!, 'line', line, stmt.line),
104
- })
105
- continue
106
- }
107
-
108
- // None of the recognized directive shapes matched. A line that doesn't
109
- // start with any known xychart-beta keyword at all falls through
110
- // silently below, same as before — but a line that *does* start with
111
- // one of the five keyworded directives (x-axis/y-axis/bar/line/title)
112
- // and still failed every pattern above is almost certainly an attempt
113
- // at that directive with broken syntax (an unclosed bracket, a missing
114
- // quote, a malformed range). Previously this was silently dropped —
115
- // the diagram would render with that axis/series just missing and no
116
- // indication why. Surface an actionable error instead. See issue #541
117
- // (parser error-message quality audit — this parser had zero throw
118
- // sites before this pass).
119
- const keywordMatch = line.match(/^(x-axis|y-axis|bar|line|title)\b/i)
120
- if (keywordMatch) {
121
- throw malformedDirectiveError(
122
- keywordMatch[1]!.toLowerCase(),
123
- line,
124
- stmt.line,
125
- )
126
- }
127
- }
128
-
129
- // Auto-derive y-axis range from data if not specified
130
- if (!yAxis.range && series.length > 0) {
131
- const allValues = series.flatMap((s) => s.data)
132
- let min = Math.min(...allValues)
133
- let max = Math.max(...allValues)
134
- const span = max - min || 1
135
- // Add 10% padding
136
- min = min - span * 0.1
137
- max = max + span * 0.1
138
- // Floor to 0 if all values are positive and min is close to 0
139
- if (min > 0 && min < span * 0.5) min = 0
140
- yAxis.range = { min, max }
141
- }
142
-
143
- // Fallback y-axis range
144
- if (!yAxis.range) {
145
- yAxis.range = { min: 0, max: 100 }
146
- }
147
-
148
- return { title, horizontal, xAxis, yAxis, series }
149
- }
150
-
151
- /**
152
- * Parse a `bar`/`line` series' comma-separated bracket contents into
153
- * numbers, throwing on any element that isn't a valid number instead of
154
- * silently coercing it to `NaN` (which serializes as `null` and can
155
- * propagate into layout math with no indication anything was wrong — see
156
- * issue #541's audit finding on this exact parser).
157
- */
158
- function parseNumericArray(
159
- str: string,
160
- seriesType: 'bar' | 'line',
161
- line: string,
162
- lineNumber: number,
163
- ): number[] {
164
- return str.split(',').map((raw, index) => {
165
- const trimmed = raw.trim()
166
- const value = parseFloat(trimmed)
167
- if (trimmed.length === 0 || Number.isNaN(value)) {
168
- throw new Error(
169
- `Line ${lineNumber}: Invalid numeric value ${JSON.stringify(trimmed)} at position ${
170
- index + 1
171
- } in "${line}". Every value in a ${seriesType} [...] list must be a number.`,
172
- )
173
- }
174
- return value
175
- })
176
- }
177
-
178
- /** Expected-syntax hint per xychart-beta keyword, for `malformedDirectiveError`. */
179
- const XYCHART_DIRECTIVE_HELP: Record<string, string> = {
180
- 'x-axis':
181
- 'x-axis [A, B, C] (categories) or x-axis 0 --> 100 (numeric range), either optionally preceded by a quoted title',
182
- 'y-axis':
183
- 'y-axis 0 --> 100 (numeric range) or y-axis "Title" (title only), optionally preceded by a quoted title before a range',
184
- bar: 'bar [10, 20, 30] — a comma-separated numeric array in square brackets',
185
- line: 'line [10, 20, 30] — a comma-separated numeric array in square brackets',
186
- title: 'title "Chart Title" — a double-quoted string',
187
- }
188
-
189
- /**
190
- * Build the error for a line that starts with a recognized xychart-beta
191
- * keyword (x-axis/y-axis/bar/line/title) but doesn't match that keyword's
192
- * expected syntax in any of the forms this parser supports.
193
- */
194
- function malformedDirectiveError(
195
- keyword: string,
196
- line: string,
197
- lineNumber: number,
198
- ): Error {
199
- const help = XYCHART_DIRECTIVE_HELP[keyword] ?? keyword
200
- return new Error(
201
- `Line ${lineNumber}: Malformed xychart-beta "${keyword}" directive: "${line}". Expected: ${help}.`,
202
- )
203
- }