• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

JBZoo / Mermaid-PHP
92%

Build:
DEFAULT BRANCH: master
Repo Added 12 Dec 2019 02:26PM UTC
Files 50
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH master
branch: SELECT
CHANGE BRANCH
x
  • No branch selected
  • 1.0.0
  • 1.1.0
  • 1.1.1
  • 2.0.0
  • 2.1.0
  • 2.1.1
  • 2.1.2
  • 2.1.3
  • 2.2.0
  • 2.3.0
  • 2.3.1
  • feature/9-self-hosting-offline
  • feature/node-links-and-link-styles
  • master
  • pr-7-credit
  • release/8.0

23 Jul 2026 07:33PM UTC coverage: 91.755% (+1.4%) from 90.404%
35708859880

push

github

web-flow
feat: add Sequence Diagram support (#10) (#33)

## Summary

Adds first-class Mermaid `sequenceDiagram` support to the library,
following the same fluent, object-oriented style as the existing
`Graph`/`Timeline` families. Requested in #10.

A sequence diagram is modeled as an **ordered stream of statements with
nesting** (not two flat sets like `Graph`). A tiny `Statement` interface
(`render(int $shift): string`, extends `\Stringable`) is implemented by
every body element; participants/boxes form a header region; the
`SequenceDiagram` container renders header + ordered body and plugs into
the existing `Render`/`Helper` machinery.

## What's covered (full `sequenceDiagram` syntax)

- **Participants / actors** — aliases, `safeMode` (md5 ids, like
`Node`), repeatable per-participant `link()`
- **Messages** — all 10 arrow types, inline activation (`+`/`-`,
mutually exclusive) and explicit `activate`/`deactivate`
- **Notes** — `left of` / `right of` / `over` (one or two participants)
- **Lifecycle** — `create` / `destroy`; **comments** (`%%`)
- **Boxes** — participant grouping with optional color
- **Control blocks** — `loop`, `opt`, `break`, `rect` (single-section)
and `alt`/`else`, `par`/`and`, `critical`/`option` (multi-section),
arbitrarily nestable
- **Container** — title frontmatter, `autonumber`, `getParticipant()`,
`addMessageByIds()` (throws on unknown id), `renderHtml()`,
`getLiveEditorUrl()`

## Notes

- The `break` block class is named **`BreakBlock`** — `break` is a
reserved word in PHP, so `class Break` is a parse error. It still emits
the Mermaid `break` keyword.
- `Render::html()` / `Helper::getLiveEditorUrl()` union types widened to
accept `SequenceDiagram`.
- README updated with the new diagram type and a runnable example.

## Testing

- `tests/SequenceDiagramTest.php`: 23 tests, 58 assertions — every arrow
type, activation, notes, lifecycle, comments, boxes/links, all blocks +
nesting, container ordering, `addMessageByIds` errors, and an ... (continued)

153 of 158 new or added lines in 16 files covered. (96.84%)

690 of 752 relevant lines covered (91.76%)

79.63 hits per line

Relevant lines Covered
Build:
Build:
752 RELEVANT LINES 690 COVERED LINES
79.63 HITS PER LINE
Source Files on master
  • Tree
  • List 50
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
35708859880 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 22 Sep 2026 09:10AM UTC web-flow github
91.76
35585104869 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 21 Sep 2026 09:46AM UTC web-flow github
91.76
35501534454 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 20 Sep 2026 09:09AM UTC web-flow github
91.76
35432641367 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 19 Sep 2026 08:41AM UTC web-flow github
91.76
35326712892 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 18 Sep 2026 08:54AM UTC web-flow github
91.76
35204388485 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 17 Sep 2026 09:19AM UTC web-flow github
91.76
35077885455 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 16 Sep 2026 09:10AM UTC web-flow github
91.76
34951715823 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 15 Sep 2026 09:17AM UTC web-flow github
91.76
34829315801 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 14 Sep 2026 09:42AM UTC web-flow github
91.76
34749273671 master feat: add Sequence Diagram support (#10) (#33) ## Summary Adds first-class Mermaid `sequenceDiagram` support to the library, following the same fluent, object-oriented style as the existing `Graph`/`Timeline` families. Requested in #10. A seque... push 13 Sep 2026 09:18AM UTC web-flow github
91.76
See All Builds (3741)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc