Sean F made a nice PR back in June at
https://github.com/PreTeXtBook/pretext/pull/2568
that exposed only a little problem (on my end) with Mermaid images, @xml:id, and
@label. Twenty-four hours and thirteen commits later, I think I have that
little teeny-weeny problem resolved. A couple of bigger changes in the process.
* We are no longer doing special color and B&W versions of Mermaid image files.
Color is the default now, and you can get grayscale images with a Mermaid
"neutral" theme in a publication file. @Oscar - generated files with suffixes
like "-color" and "-bw" are no longer manufactured, nor utilized.
* For EPUB we need SVG versions of Mermaid images. That is a pretty routine
addition, but it means that the Python routine has a new signature (additional
"outformat" argument). @Oscar - the CLI will need to react, I expect. HTML is
native (Javascript renders the image), LaTeX uses PNG, EPUB uses SVG. I guess
I've not thought too hard about support for other formats.
@Oscar - sorry to plop this one in your lap. There's no real great way to do
this with less disruption.
For more technical details, see
https://github.com/PreTeXtBook/pretext/pull/2560
where Andrew S made a valiant attempt to address some of this.
Announcement soon.
Rob