2022-04-07 21:35:13 +00:00
|
|
|
<!DOCTYPE html>
|
2022-10-02 13:51:25 -07:00
|
|
|
<html lang="en">
|
2022-09-05 00:48:36 +05:30
|
|
|
<head>
|
|
|
|
<meta charset="utf-8" />
|
|
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
2022-09-26 18:16:36 -07:00
|
|
|
<title>States Mermaid Quick Test Page</title>
|
2022-09-05 00:48:36 +05:30
|
|
|
<link rel="icon" type="image/png" href="data:image/png;base64,iVBORw0KGgo=" />
|
|
|
|
<style>
|
|
|
|
div.mermaid {
|
|
|
|
/* font-family: 'trebuchet ms', verdana, arial; */
|
|
|
|
font-family: 'Courier New', Courier, monospace !important;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
2022-10-02 13:51:25 -07:00
|
|
|
<h1>State diagram demos</h1>
|
2022-09-05 00:48:36 +05:30
|
|
|
<pre class="mermaid">
|
2022-04-07 21:35:13 +00:00
|
|
|
stateDiagram
|
2022-09-26 18:16:36 -07:00
|
|
|
accTitle: This is the accessible title
|
|
|
|
accDescr:This is an accessible description
|
|
|
|
State1 --> State2
|
2022-09-05 00:48:36 +05:30
|
|
|
</pre>
|
2022-04-08 18:43:00 +00:00
|
|
|
|
2022-09-26 18:16:36 -07:00
|
|
|
<hr />
|
|
|
|
|
2022-09-05 00:48:36 +05:30
|
|
|
<pre class="mermaid">
|
2022-04-08 18:43:00 +00:00
|
|
|
stateDiagram-v2
|
2022-09-26 18:16:36 -07:00
|
|
|
accTitle: This is the accessible title
|
|
|
|
accDescr: This is an accessible description
|
|
|
|
[*] --> Still
|
|
|
|
Still --> [*]
|
|
|
|
Still --> Moving
|
|
|
|
Moving --> Still
|
|
|
|
Moving --> Crash
|
|
|
|
Crash --> [*]
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
|
|
<pre class="mermaid">
|
|
|
|
stateDiagram
|
|
|
|
accTitle: very very simple state
|
|
|
|
accDescr: This is a state diagram showing one state
|
|
|
|
State1
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
|
|
<pre class="mermaid">
|
|
|
|
stateDiagram
|
|
|
|
[*] --> First
|
|
|
|
state First {
|
|
|
|
[*] --> second
|
|
|
|
second --> [*]
|
|
|
|
}
|
|
|
|
</pre>
|
|
|
|
<pre class="mermaid">
|
|
|
|
stateDiagram
|
|
|
|
State1: The state with a note
|
|
|
|
note right of State1
|
|
|
|
Important information! You can write
|
|
|
|
notes.
|
|
|
|
end note
|
|
|
|
State1 --> State2
|
|
|
|
note left of State2 : This is the note to the left.
|
|
|
|
</pre>
|
|
|
|
<pre class="mermaid">
|
|
|
|
stateDiagram
|
|
|
|
State1
|
|
|
|
note right of State1
|
|
|
|
Line1<br>Line2<br />Line3<br />Line4<br />Line5
|
|
|
|
end note
|
2022-09-05 00:48:36 +05:30
|
|
|
</pre>
|
|
|
|
|
|
|
|
<script src="./mermaid.js"></script>
|
|
|
|
<script>
|
|
|
|
mermaid.initialize({
|
2022-09-26 18:16:36 -07:00
|
|
|
theme: 'base',
|
2022-09-05 00:48:36 +05:30
|
|
|
// themeCSS: '.node rect { fill: red; }',
|
|
|
|
logLevel: 3,
|
|
|
|
securityLevel: 'loose',
|
|
|
|
flowchart: { curve: 'basis' },
|
|
|
|
gantt: { axisFormat: '%m/%d/%Y' },
|
|
|
|
sequence: { actorMargin: 50 },
|
|
|
|
// sequenceDiagram: { actorMargin: 300 } // deprecated
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</body>
|
2022-04-07 21:35:13 +00:00
|
|
|
</html>
|