Open tnichols217 opened 5 months ago
This will be quite complicated. CSS interpretation comes much later after using dot
to generate a picture file. At that point, the colors are already made, so PNG output won't work.
But, maybe you could make the plugin emit a SVG document inline (instead of the current "IMG" tag!) inside the document, and there use normal CSS rules to style it. You will need a way to have this plugin amend the CSS styling on the document somehow too.
I made a little progress in #25 . It makes the generated SVG refer to a non-existent CSS file. I don't have much interest in figuring out what and where that should go, or making the SVG primitives style to the colors.
It would be nice if you would pass the current obsidian theme (background color, text color, etc.) into graphviz so that the generated images will integrate nicely into obsidian.
I would be open to make a PR after familiarizing myself with the code if this is of interest