mkdocs-mermaid2-plugin icon indicating copy to clipboard operation
mkdocs-mermaid2-plugin copied to clipboard

Add Zoom and Pan to Diagrams? (ER Diagram very tiny)

Open plbremer opened this issue 1 year ago • 5 comments

I am not sure if I should be asking this on the mkdocs main repo or here.

The font size of my rendered ER Diagram is so small that it is unusable.

What is the recommended way to make this rendered diagram usable? I looked around and could not find any sort of config to add a zoom/scroll wheel. I am not sure where to start in terms of generating an image from a given markdown. Any advice would be appreciated!

image

plbremer avatar Apr 23 '24 21:04 plbremer

Thank you for your contribution! This is very appreciated.

github-actions[bot] avatar Apr 23 '24 22:04 github-actions[bot]

Beautiful diagram!

It is an issue on which I have had my attention on for some time. In principle, the Mermaid2 plugin doesn't do any theming or css. It is using the standard Mermaid standard javascript library, in the context of your MkDocs theme.

So, the starting point would be: which MkDocs theme are you using?

Is it Material, you might be in a better position. It doesn't mean that the theme's author (@squidfunk) would be able to fix this issue for you. But he might have some idea on where to look for a solution?

fralau avatar Apr 27 '24 06:04 fralau

Thanks for tagging! Related issue: https://github.com/squidfunk/mkdocs-material/issues/5208

squidfunk avatar Apr 27 '24 09:04 squidfunk

Hi Thanks for the response. I made my own topic here: https://github.com/squidfunk/mkdocs-material/discussions/7095

TLDR - I have about 0 hope of making a custom plugin in an amount of time that works. I was going to basically involve the mermaid javascript cli directly as a workaround. I ended up going with a different diagram entirely, rendering this moot.

plbremer avatar Apr 27 '24 14:04 plbremer

I note @squidfunk suggestion to use mkdocs-glitchbox.

For https://github.com/squidfunk/mkdocs-material/discussions/7095, I already thought of pre-producing images, but so far I have decided against it. The main advantage of the javascript library being that it is interactive (hyperlink are available).

fralau avatar Jun 03 '24 11:06 fralau