Skip to content

Diagram Types

Vivek Sarin edited this page Nov 16, 2026 · 1 revision

Diagram types

FlowMotion supports the diagram types below. The header line tells FlowMotion which type to draw. The Animated column shows whether the diagram moves when you play it.

Diagram Header line Animated Use it for
Flowchart flowchart or graph Yes Systems, processes, and decisions
Sequence sequenceDiagram Yes Who talks to whom, and in what order
Activity @startuml with start, :action;, if, while, fork, stop Yes Step-by-step business workflows
State stateDiagram-v2 Yes Things that move between states
Mind map mindmap Yes Ideas and plans
Gantt gantt Yes Project timelines
C4 C4Context Partly Software and cloud landscapes
Architecture architecture-beta Partly Services and the links between them
Class classDiagram No Data models and their relationships
Entity relationship (ER) erDiagram No Database tables and their links

Diagrams that are not animated still appear as drawings. They are useful for documentation even without movement.

Examples

Flowchart

flowchart LR
  A[Client] -.->|poll| B(Cache)
  B ==> C{Hit?}
  C -->|yes| D([Respond])
  C --x E[(Store)]

Sequence diagram

sequenceDiagram
  participant U as User
  participant A as API
  participant D as Database
  U->>A: Place order
  A->>D: Save order
  D-->>A: Saved
  A-->>U: Confirmed

Gantt chart

gantt
  title Release plan
  dateFormat YYYY-MM-DD
  section Design
  Research      :done, r1, 2025-01-06, 7d
  Mockups       :active, m1, after r1, 5d
  section Build
  API           :crit, a1, after m1, 14d
  UI            :u1, after m1, 10d
  Launch        :milestone, l1, after a1 u1, 0d

Mind map

mindmap
  root((FlowMotion))
    Inputs
      YAML
      Text
    Outputs
      SVG
      HTML

State diagram

stateDiagram-v2
  [*] --> Idle
  Idle --> Running : start
  state Running {
    [*] --> Warm
    Warm --> Hot : heat
    Hot --> [*]
  }
  Running --> Idle : stop
  Running --> [*] : crash

Activity diagram (PlantUML)

@startuml
start
:Receive order;
if (In stock?) then (yes)
  :Charge card;
  fork
    :Pack items;
  fork again
    :Send receipt;
  end fork
else (no)
  :Notify customer;
endif
while (More items?) is (yes)
  :Scan item;
endwhile (no)
:Ship;
stop
@enduml

Class diagram

classDiagram
  class Animal {
    +String name
    +int age
    +eat() void
  }
  class Dog {
    +bark() void
  }
  Animal <|-- Dog

Entity relationship diagram

erDiagram
  CUSTOMER ||--o{ ORDER : places
  ORDER ||--|{ LINE_ITEM : contains
  CUSTOMER {
    string name PK
    string email
  }

Syntax notes

Some diagram types have their own keywords. The notes below cover the ones that differ from flowcharts.

Gantt

  • title sets the chart title.
  • section starts a new group of tasks.
  • Put a status tag before the dates: done, active, crit (critical), or milestone.
  • A task has an id, a start, and a duration. Use after <id> to start a task when another one ends.
  • Durations use d for days and w for weeks, such as 5d or 2w. Dates use YYYY-MM-DD.
  • These settings are accepted but have no effect: dateFormat, axisFormat, excludes, includes, todayMarker, tickInterval, weekday, and weekend.

Architecture

  • group <id>(<icon>)[<Label>] draws a group. An icon is optional.
  • service <id>(<icon>)[<Label>] in <group> places a service inside a group.
  • junction <id> draws a connection point between links.
  • Links use sides and names: gw:R --> L:server joins the right side of gw to the left side of server. Use T, B, L, and R for the sides.

Activity and PlantUML

  • start, stop, and end mark the beginning and the end of a flow.
  • :Action; draws an action.
  • if (condition) then (yes), else (no), endif draw a choice.
  • while (condition) is (yes) and endwhile draw a loop.
  • repeat and repeat while draw a loop that tests at the end.
  • fork, fork again, and end fork draw parallel paths.
  • partition and package draw a labelled group. kill and detach end a path.
  • Notes are accepted, but they are not shown.

PlantUML component, node, cloud, database, queue, and interface diagrams are also supported, with [Name] for a component.

Class and state (PlantUML)

  • class, interface, abstract, and enum define a type.
  • <<stereotype>>, such as <<abstract>>, marks a type with a label.
  • Relations: <|-- (inheritance), *-- (composition), o-- (aggregation), and ..> (dependency).

Sequence and state (Mermaid)

  • participant <id> as <Name> names a participant.
  • activate, deactivate, autonumber, alt, else, opt, par, loop, note, and similar keywords are accepted but not shown.

Not supported yet

FlowMotion does not draw these types yet: pie charts, XY charts, quadrant charts, timelines, user journeys, git graphs, requirement diagrams, Sankey diagrams, block diagrams, kanban boards, radar charts, treemaps, and packet diagrams.

Clone this wiki locally