v1.0.0 — stable release
MermaidKit 1.0 — native Mermaid diagrams in Swift, no JavaScript, no WebView.
Thirty diagram types parsed, laid out, and rendered natively — CoreGraphics/CoreText on Apple, Silica/Cairo on Linux — with layout quality machine-checked in CI. The public API is now frozen.
What 1.0 is
- 30 diagram types, end to end: flowchart, sequence, class, state, ER, gantt, pie, timeline, mindmap, journey, quadrant, packet, xychart, kanban, radar, treemap, gitgraph, sankey, requirement, C4, architecture, block, and more.
- Native rendering on Apple and Linux. Same layout and per-type draw code behind one
CGContextseam: CoreGraphics on Apple, Silica/Cairo/FontConfig on Linux (behind theLinuxRasterpackage trait). - Machine-checked layout quality. A geometry linter and a draw-vs-scene conformance ratchet gate every fixture in CI — layout regressions fail the build, not the eye.
- Clean
from:consumption on every platform. Silica and its transitive graph are gated behind theLinuxRastertrait (default OFF), so Apple andfrom:-pinned hosts resolve a Silica-free graph.
New in 1.0
- Line breaks in labels.
<br>in every form (<br>,<br/>,<br />, case-insensitive, with attributes), a literal\n, and any real newline break box/node labels and sequence notes onto multiple lines — the box grows to fit. Fixed chrome (legends, chart axes) collapses them to a space.
Stability stance
The entry points — MermaidParser, DiagramLayoutEngine, DiagramScene, DiagramLayoutLinter, MermaidRenderer, MermaidView, DiagramTheme — are stable. As of 1.0, model/layout field changes are semver-major.
Requirements
Swift 6.2 / Xcode 26. Platforms: macOS 14+, iOS 17+, visionOS 1+, and Linux. MermaidLayout is zero-dependency and platform-free; MermaidRender is CoreGraphics on Apple and links Silica only on Linux when LinuxRaster is enabled.
Install
.package(url: "https://github.com/2389-research/MermaidKit.git", from: "1.0.0")Known issue
A cross-process layout-ordering nondeterminism in a few non-layered types (the layered/flowchart family is deterministic), tracked as #1.
See CHANGELOG.md for the full history.