I am not sure should I make a "pure WL" implementation of grammar visualization. Currently, in the scale of 1-to-10 I am at 4. Anyone care to voice an opinion?
P.S. The "pure WL" implementation would be via the paclet "FuncitonalParsers".
The notebook uses the WL paclets:
"RakuMode"
"MermaidJS"
The most recent version of "RakuMode" uses "Chatbook.nb" as the notebook style to endow with Raku cells. (If the Mathematica's version is ≥ 13.3.)
The Raku packages:
"FunctionalParsers"
"EBNF::Grammar"
produce both Mermaid-JS and WL graph specs (from grammars in EBNF.)