figdown 0.2.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,90 +0,0 @@
1
- # EXPERIMENTAL / EXPERIMENTAL constructs
2
-
3
- Everything in this file is **outside the v0.1 conformance surface and outside
4
- the compatibility promise**. The engine accepts it and your document keeps
5
- working, but it may change or be withdrawn in a later `0.x`. The parser emits
6
- no warning, so a line that parses tells you nothing.
7
-
8
- Use these when the figure genuinely needs them. If the figure must be
9
- portable, do not — and if you use one anyway, say so beside the figure.
10
-
11
- ## Markers and zones — `threshold`, `band`
12
-
13
- ```figdown
14
- figdown 0.1 block
15
- group pool "Storage pool"
16
- node used "In use" in=pool
17
- threshold "High watermark = stop writes" in=pool offset=80%
18
- threshold "Low watermark = resume writes" in=pool offset=45%
19
- band "Reserved" 15% in=pool fill=#fee2e2
20
- band "Shared quota" 20..70% in=pool extend=down
21
- ```
22
-
23
- - `threshold` needs a quoted label **and** `offset=<0..100>%`, both mandatory
24
- — the `%` included. There is no `value=` and no `ref=`.
25
- - `band` needs a quoted label **first**, then either one percentage (a size)
26
- or an explicit `<a>..<b>%` range. `..` is the language's ONE range
27
- separator; the hyphen form is a line error. `extend=up|down|left|right`, and `up`
28
- is the default.
29
- - The label is the knowledge in both cases. `offset=` is a fraction of the
30
- target's rendered extent, **not a value of any quantity** — the target
31
- declares no scale, so there is no conversion. Put the number in the label
32
- or it is not in the document.
33
- - Both attach to a node or a group via `in=`.
34
- - **Attach at the scope the fact belongs to.** A limit shared by everything in
35
- a group is one group-level marker; a fact true of one element attaches to
36
- that element. The renderer may draw the two the same way — the difference is
37
- in the text, and the text is the knowledge.
38
-
39
- ## Link bundles — `bundle`
40
-
41
- ```figdown
42
- figdown 0.1 block
43
- node leaf "Leaf"
44
- node s1 "Spine 1"
45
- node s2 "Spine 2"
46
- edge leaf -- s1
47
- edge leaf -- s2
48
- bundle ecmp "ECMP uplink set (2 × 100G)" leaf--s1,leaf--s2
49
- ```
50
-
51
- Names a set of already-declared edges as one logical link. The dashed ring is
52
- drawn for you, and the member list is one comma-delimited token. Each member
53
- must name an edge that already exists and is unambiguous — v0.1 has no way to
54
- address one of two parallel edges between the same pair, so a bundle over
55
- parallel links cannot be spelled.
56
-
57
- ## Overlay planes — `plane`, `plane=`
58
-
59
- ```figdown
60
- figdown 0.1 block
61
- plane overlay "VXLAN tunnels" z-index=2
62
- node l1 "Leaf 1"
63
- node l2 "Leaf 2"
64
- node s1 "Spine" plane=overlay
65
- edge l1 <-> l2 plane=overlay
66
- ```
67
-
68
- The **label is the knowledge** — "VXLAN tunnels" is what a reader keeps, not
69
- the paint order. Every document has an implicit `base` plane at `z-index=0`,
70
- and every element reports it unless it names another. An omitted `z-index=`
71
- takes the plane's 1-based declaration index. `z-index=` reorders the
72
- annotation pass only — edges, bundle rings, thresholds and bands. `plane=` is
73
- legal on a node, group, external endpoint, edge, class, bundle, threshold and
74
- band.
75
-
76
- ## Charts from a table — `chart`, `type=`
77
-
78
- ```figdown
79
- figdown 0.1 table
80
- table t "Throughput"
81
- | Port | Gbps |
82
- |------|------|
83
- | 1 | 25 |
84
- | 2 | 40 |
85
- chart t type=bar3d
86
- ```
87
-
88
- Draws bars from a table's numeric cells. `type=` is the only option key and
89
- `bar3d` is its only value. For anything a chart library would do better, keep
90
- the raster and put the numbers in a table (`../transcribe.md`).