Merge pull request #3647 from DKurilo/feat/1414-notes-to-class-diagram

add the way to add notes to class diagram
This commit is contained in:
Knut Sveidqvist
2022-10-25 14:45:03 +02:00
committed by GitHub
13 changed files with 290 additions and 11 deletions

View File

@@ -11,7 +11,9 @@ Mermaid can render class diagrams.
```mermaid-example
classDiagram
note "From Duck till Zebra"
Animal <|-- Duck
note for Duck "can fly\ncan swim\ncan dive\ncan help in debugging"
Animal <|-- Fish
Animal <|-- Zebra
Animal : +int age
@@ -35,7 +37,9 @@ classDiagram
```mermaid
classDiagram
note "From Duck till Zebra"
Animal <|-- Duck
note for Duck "can fly\ncan swim\ncan dive\ncan help in debugging"
Animal <|-- Fish
Animal <|-- Zebra
Animal : +int age
@@ -549,6 +553,10 @@ You would define these actions on a separate line after all classes have been de
- (_optional_) tooltip is a string to be displayed when hovering over element (note: The styles of the tooltip are set by the class .mermaidTooltip.)
- note: callback function will be called with the nodeId as parameter.
## Notes
It is possible to add notes on digram using `note "line1\nline2"` or note for class using `note for class "line1\nline2"`
### Examples
_URL Link:_