Repository navigation
mermaid-text-0.55.0
Added
-
rect rgb(R, G, B)andrect rgba(R, G, B, A)in sequence diagrams.
Previously these were silently discarded; they are now parsed and rendered
as borderless background fills over the messages they enclose.Accepted colour forms:
rgb(R, G, B),rgba(R, G, B, A)(primary),
#RRGGBB/#RGBhex (best-effort), bare CSS name (falls back to
mid-greyRgb(128, 128, 128)).Fill glyph is chosen by luminance-keyed 3-step palette:
Effective intensity I Glyph I < 60░60 <= I < 130▒I >= 130▓Where
I = (255 - luminance(rgb)) * alpha_norm, luminance from Rec. 601
(0.299*R + 0.587*G + 0.114*B),alpha_norm = 1.0forrgb(...)or
alpha_u8 / 255.0forrgba(...).rectblocks are borderless: no╔ ╗ ╚ ╝corners, no║rails,
no[Rect]label tag. When arectis nested inside aloop/alt/
etc., the outer frame's░fill cells are overwritten with the denser
▒or▓glyph where warranted.
Snapshot churn
0 existing snapshots reclassified. 3 new snapshots added for the three
new rect-specific tests.