v0.7.0-alpha.1
Pre-release
Pre-release
·
284 commits
to main
since this release
Merman 0.7 moves the project from the Mermaid 11.12 line to Mermaid 11.15 compatibility and adds new public surfaces for native FFI, ASCII/Unicode rendering, and rustdoc Mermaid rendering. It also makes the playground useful as a real parity/debugging tool. A large amount of parser, layout, SVG, theme, and test infrastructure was reworked internally to make future Mermaid upgrades less brittle.
Breaking Changes
- Updated the compatibility target to Mermaid
11.15.0. If you keep semantic, layout, or SVG goldens, expect to refresh them. - PNG/JPG raster output now applies a safety budget by default. Very large diagrams are downscaled unless callers configure
RasterOptions, provide aRasterSizeLimit, or opt into unbounded raster output. RasterOptionsgained target-aware sizing fields. Callers using exhaustive struct literals should add..Default::default()or set the new fields explicitly.
Added
- Added ASCII/Unicode rendering through
merman-ascii,merman::ascii, andmerman-cli render --format ascii|unicode. - Added rustdoc integration through
merman-rustdoc, a proc-macro crate that renders Mermaid fences andinclude_mmd!files in rustdoc as inline headless SVG without injecting Mermaid JavaScript. The macro supportsscope,pipeline,fail,source,sanitize, andthemeoptions, including recursive inline item processing withscope = "tree", rustdoc light/dark theme switching by default, fixed build-time Mermaid themes with source-level config precedence, and strict SVG safety checks by default. - Added a more Mermaid CLI-like
merman-cli rendersurface, including markdown input handling, icon pack compatibility, and raster sizing flags. - Added the
@merman/webTypeScript/WASM package and a hosted playground with live editing, SVG export, Mermaid JS compare mode, diagnostics, benchmark tools, mobile layout support, and a larger example gallery. - Added experimental platform bindings through
merman-ffi: C ABI, Flutter/Dart, Android JNI, Apple SwiftPM, and Python UniFFI packages. - Added minimum support and parity tracking for additional Mermaid families including TreeView, Ishikawa, and Event Modeling, alongside Mermaid 11.15 updates for Class, XY Chart, Sankey, Pie, Flowchart, Sequence, C4, Timeline, Radar, Mindmap, Kanban, Gantt, and Block.
Changed
- Reworked theme handling to follow Mermaid 11.15 more closely, including supported theme metadata,
lookhandling,themeVariables, scopedthemeCSS, and SVG colors that remain readable inside host pages. - Reworked rasterization so PNG/JPG sizing is planned before allocating buffers. SVG output remains parity-oriented and does not clamp the root
viewBox. - Reworked major internals around render dispatch, config/font/theme resolution, Architecture/FCoSE layout seams, Graphlib/Dagre compatibility, and parity tooling. These changes are mostly internal, but they make 11.15 support and future Mermaid upgrades more stable.
Fixed
- Fixed deeply nested valid diagrams that previously hit Merman-specific depth limits or stack-sensitive parser/layout paths.
- Fixed many Mermaid 11.15 SVG parity gaps across Flowchart, Sequence, Class, Architecture, State, Block, Timeline, Pie, Radar, Treemap, Mindmap, ER, Journey, Requirement, Sankey, C4, and XY Chart.
- Fixed dark-host and custom-theme visibility issues for diagram labels, notes, edges, clusters, and chart elements.
- Fixed oversized raster exports and JPG background handling so image export is safer and more predictable.