open_drawio_mermaid
Open the draw.io editor with an editable diagram generated from Mermaid.js syntax. Convert flowcharts, sequence, class, ER, and other supported Mermaid types for editing in draw.io.
Instructions
Opens the draw.io editor with a diagram generated from Mermaid.js syntax, converted into an editable draw.io diagram. The recommended default for flowcharts, sequence, class, state and ER diagrams, gantt charts, mind maps, timelines, C4, architecture and the other types draw.io's Mermaid parser supports (28 in all).
Call get_drawio_reference with format "mermaid" once before your first Mermaid diagram in a conversation: it lists the header keyword and syntax hints for every supported type (a misspelled header yields a blank diagram) and flowchart styling.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dark | No | Dark mode setting. Default: auto | |
| content | Yes | The Mermaid.js diagram definition. Example: 'graph TD; A-->B; B-->C;' | |
| lightbox | No | Open in lightbox mode (read-only view). Default: false | |
| postLayout | No | Optional ELK layered layout for Mermaid FLOWCHARTS. The only value is "elk". draw.io's native Mermaid parser does its own layout, but it produces cramped or unbalanced output once the diagram has any structural complexity — request "elk" whenever ANY of these holds: >= ~20 nodes, OR >= 3 decision diamonds (`{...}` shapes), OR any feedback/back-edges (an edge pointing back to an earlier node, e.g. an error path looping to a retry), OR >= 3 distinct endpoints. The flow direction follows the flowchart code (`flowchart TD/TB` vs `LR/RL`), so there is no direction field here. Ignored for non-flowchart diagram types (sequence, class, ER, gantt, …), which lay themselves out. |