forked from finos/architecture-as-code
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathblock-architecture.hbs
More file actions
58 lines (52 loc) · 1.94 KB
/
block-architecture.hbs
File metadata and controls
58 lines (52 loc) · 1.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
```mermaid
%%{init: {"flowchart": {"htmlLabels": false}}}%%
flowchart TB
classDef boundary fill:#f8fafc,stroke:#64748b,stroke-dasharray: 5 4,stroke-width:2px,color:#000;
classDef node fill:#ffffff,stroke:#1f2937,stroke-width:1px,color:#000;
classDef iface fill:#f1f5f9,stroke:#64748b,stroke-width:1px,font-size:10px,color:#000;
classDef highlight fill:#fef3c7,stroke:#f59e0b,stroke-width:2px,color:#000;
{{#if renderNodeTypeShapes}}
classDef actor fill:#e3f2fd,stroke:#1976d2,stroke-width:2px,color:#000;
classDef database fill:#fff3e0,stroke:#f57c00,stroke-width:2px,color:#000;
classDef webclient fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px,color:#000;
classDef service fill:#e8f5e8,stroke:#388e3c,stroke-width:2px,color:#000;
classDef messagebus fill:#fce4ec,stroke:#c2185b,stroke-width:2px,color:#000;
classDef system fill:#fff8e1,stroke:#f9a825,stroke-width:2px,color:#000;
{{/if}}
{{!-- Render container forest (if any) --}}
{{#each containers}}
{{> container.hbs}}
{{/each}}
{{!-- Render loose nodes (not inside any rendered container) --}}
{{#each looseNodes}}
{{#if ../renderNodeTypeShapes}}
{{> typed-node.hbs}}
{{else}}
{{{mermaidId id}}}["{{label}}"]:::node
{{/if}}
{{#each interfaces}}
{{{mermaidId id}}}["{{label}}"]:::iface
{{/each}}
{{/each}}
{{!-- Edges --}}
{{#each edges}}
{{{mermaidId source}}} -->{{#if label}}|{{label}}|{{/if}} {{{mermaidId target}}}
{{/each}}
{{!-- Dotted attachments (node -> interface) --}}
{{#each attachments}}
{{{mermaidId from}}} -.- {{{mermaidId to}}}
{{/each}}
{{!-- Highlights --}}
{{#each highlightNodeIds}}
class {{{mermaidId this}}} highlight
{{/each}}
{{!-- Clickable links for containers + loose nodes --}}
{{#if linkPrefix}}
{{#each containers}}
{{> click-links.hbs this linkPrefix=../linkPrefix linkMap=../linkMap}}
{{/each}}
{{#each looseNodes}}
{{> click-links.hbs this linkPrefix=../linkPrefix linkMap=../linkMap}}
{{/each}}
{{/if}}
```