# Mermaid Chart

#### 🧜‍♀️ Mermaid Chart – Diagrams as Code, Simplified

The **Mermaid Chart** component in **Lowcoder** empowers users to create **diagrams using text-based syntax**. It’s a lightweight, flexible solution for visualizing processes, logic flows, and relationships — perfect for developers, analysts, and technical teams who prefer to "write" their charts.

#### 🧩 What You Can Create

With **Mermaid syntax**, you can render:

* **Flowcharts**
* **Gantt charts**
* **Sequence diagrams**
* **State diagrams**
* **Entity-relationship (ER) models**
* **Class diagrams**

#### 📝 Syntax Example (Flowchart)

```mermaid
graph TD
  A[Start] --> B{Decision}
  B -->|Yes| C[Proceed]
  B -->|No| D[Stop]
```

Just paste this into the Mermaid Chart component’s text input and it renders a live diagram!

#### ⚙️ Configuration Options

* **Input Field:** Write or bind dynamic Mermaid syntax via `{{ }}`
* **Render Modes:** Adjust size, font, alignment, and padding
* **Dynamic Diagrams:** Generate diagrams from query outputs using JavaScript transformers

#### 🎨 Styling

While Mermaid comes with default themes, you can customize elements like:

* **Text labels**
* **Node shapes and colors**
* **Arrows and connectors**

Advanced theming is possible using [Mermaid theme variables](https://mermaid.js.org/config/theming.html).

### Component Playground

{% embed url="<https://app.lowcoder.cloud/playground/mermaid/1>" %}

### Component Auto-Docs

{% embed url="<https://app.lowcoder.cloud/components/mermaid>" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.lowcoder.cloud/lowcoder-documentation/build-applications/app-editor/visual-components/dashboard-and-reporting/charts-and-graphs/mermaid-chart.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
