[package] license = "Apache-2.0" name = "xai-grok-mermaid" version = "0.1.0" edition.workspace = true description = "Render Mermaid diagram source to a rasterized PNG behind a swappable engine trait" [dependencies] # SVG -> PNG rasterization. `resvg` re-exports the matching `usvg` (0.47) and # `tiny_skia`; we deliberately use `resvg::usvg` rather than the workspace # `usvg` (0.45.1) so `resvg::render` typechecks against the tree we parse. resvg = { workspace = true } tiny-skia = { workspace = true } fontdb = { workspace = true } thiserror = { workspace = true } tracing = { workspace = true } which = { workspace = true } # Subprocess infra (MmdcEngine + the out-of-process render child): detached # spawning + wall-clock timeout + process-group reaping. xai-tty-utils = { workspace = true } wait-timeout = { workspace = true } tempfile = { workspace = true } # Vendored dagre-based Mermaid -> SVG engine (third_party/mermaid-to-svg, MIT). # Always compiled — the default engine, no feature gate. mermaid-to-svg = { workspace = true } # Subprocess process-group reaping (killpg) for the sync subprocess path, since # xai-tty-utils' ProcessGroup only wraps tokio children. [target.'cfg(unix)'.dependencies] libc = { workspace = true } [dev-dependencies] # `png` codec enabled LOCALLY only (workspace pins image with # default-features=false; "Do not add features globally"). Used by tests to # decode the output PNG and assert its dimensions. image = { workspace = true, features = ["png"] }