Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for mermaid js diagrams #22

Open
robinbaeurle opened this issue May 10, 2023 · 3 comments
Open

Add support for mermaid js diagrams #22

robinbaeurle opened this issue May 10, 2023 · 3 comments

Comments

@robinbaeurle
Copy link

Hi,
Based on squidfunk/mkdocs-material#5208.

Is it possible to add an option to support mermaid js diagrams in the same way as images are supported?

GitHub is also able to display markdown in a way that the mermaid js diagrams become zoomable: https://github.com/squidfunk/mkdocs-material/blob/master/docs/reference/diagrams.md#using-flowcharts

BR

@hellowac
Copy link

tks @blueswen

@blueswen
Copy link
Owner

blueswen commented Jun 4, 2023

Hi @robinbaeurle @hellowac ,

Since the compiled result of the Mermaid diagram is not an image, our plugins can't open it in lightbox like an image.

I spent some time investigating how GitHub implements the zoomable feature for Mermaid diagrams. They have a unique pipeline and script to add this viewer feature, as described in Include diagrams in your Markdown files with Mermaid. Regrettably, I haven't been able to identify the public package they use for the Mermaid viewer. If you know of any exceptional Mermaid viewer plugins, I would love to create another MkDocs plugin to implement this feature.

@AndBondStyle
Copy link
Contributor

I'm using kroki.io and mkdocs-kroki-plugin and it works great together with this plugin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants