Explain line breaks in sequenceDiagram.md

Closes https://github.com/mermaid-js/mermaid/issues/4351
This commit is contained in:
Anatoli Babenia
2024-06-15 12:29:30 +03:00
committed by GitHub
parent d6ccd93cf2
commit c904c7d21a

View File

@@ -205,11 +205,22 @@ sequenceDiagram
Note over Alice,John: A typical interaction
```
It is also possible to add a line break (applies to text input in general):
## Line breaks
Line break can be added to Note and Message:
```mermaid-example
sequenceDiagram
Alice->John: Hello John, how are you?
Alice->John: Hello John,<br/>how are you?
Note over Alice,John: A typical interaction<br/>But now in two lines
```
Line breaks in Actor names requires aliases:
```mermaid-example
sequenceDiagram
participant Alice as Alice<br/>Johnson
Alice->John: Hello John,<br/>how are you?
Note over Alice,John: A typical interaction<br/>But now in two lines
```