mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-10-11 18:19:42 +02:00
add attributes to demo ER diagram so attribute styles can be evaluated
This commit is contained in:

parent
395cc29701
commit
9cb7054ff9
@@ -16,17 +16,48 @@
|
|||||||
<body>
|
<body>
|
||||||
<pre class="mermaid">
|
<pre class="mermaid">
|
||||||
erDiagram
|
erDiagram
|
||||||
title This is a title
|
|
||||||
accDescription Test a description
|
|
||||||
CUSTOMER ||--o{ ORDER : places
|
CUSTOMER ||--o{ ORDER : places
|
||||||
ORDER ||--|{ LINE-ITEM : contains
|
ORDER ||--|{ LINE-ITEM : contains
|
||||||
CUSTOMER }|..|{ DELIVERY-ADDRESS : uses
|
ORDER }|..|{ DELIVERY-ADDRESS : uses
|
||||||
|
DELIVERY-ADDRESS }|--|| CUSTOMER : has
|
||||||
|
|
||||||
|
CUSTOMER ||--o{ ORDER : places
|
||||||
|
CUSTOMER {
|
||||||
|
string name
|
||||||
|
string region
|
||||||
|
string custNumber
|
||||||
|
string sector
|
||||||
|
}
|
||||||
|
ORDER ||--|{ LINE-ITEM : contains
|
||||||
|
ORDER {
|
||||||
|
int orderNumber
|
||||||
|
string deliveryAddress
|
||||||
|
}
|
||||||
|
LINE-ITEM {
|
||||||
|
string productCode
|
||||||
|
int quantity
|
||||||
|
float pricePerUnit
|
||||||
|
}
|
||||||
|
|
||||||
|
DELIVERY-ADDRESS {
|
||||||
|
int customerId
|
||||||
|
string addressLine1
|
||||||
|
string addressLine2
|
||||||
|
string city
|
||||||
|
string county
|
||||||
|
string state
|
||||||
|
string region
|
||||||
|
string country
|
||||||
|
string postalCode
|
||||||
|
}
|
||||||
|
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<script type="module">
|
<script type="module">
|
||||||
import mermaid from './mermaid.esm.mjs';
|
import mermaid from './mermaid.esm.mjs';
|
||||||
mermaid.initialize({
|
mermaid.initialize({
|
||||||
theme: 'forest',
|
theme: 'base',
|
||||||
// themeCSS: '.node rect { fill: red; }',
|
// themeCSS: '.node rect { fill: red; }',
|
||||||
logLevel: 3,
|
logLevel: 3,
|
||||||
securityLevel: 'loose',
|
securityLevel: 'loose',
|
||||||
|
Reference in New Issue
Block a user