-
Notifications
You must be signed in to change notification settings - Fork 17k
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
core(mermaid): allow greater customization #29939
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Skipped Deployment
|
@ianchi thanks for the contribution! could you please separate the subgraph fix into a separate PR and add a test for it in |
Done. Just a warning. Doing it in two separate PR brings a problem. If both were merged tests would fail. One of the PR should be ammended after the other is merged. |
thanks! I merged the fix PR - feel free to update |
hi @vbarda the PR has conflicts resolved |
Hi @vbarda, I believe this is ready to be merged. |
@ianchi thanks! i might actually do a slightly different refactor, since looks like directives are actually deprecated now so might as well go w/ the new recommended format https://mermaid.js.org/config/directives.html |
By allowing an init directive most styles can be customized. By setting a `theme` and `look` or by setting `themeVariables`
Hi @vbarda I've updated to use frontmatter. |
@ianchi i was looking more at mermaid docs and it looks like frontmatter is really poorly documented. i think we can keep your original change! sorry for the false alarm |
It is not well documented, but basically in the It is not a bad idea to use front matter, if you use the live playground it is what is generated, so it is easy to copy from there. |
@ianchi fair point - i didn't have any other concerns besides that, so you can go ahead w/ updating tests :) thanks! |
Hi @vbarda, updated tests. |
Thank you @ianchi - made a few small changes and will merge! |
Adds greater style customization by allowing a custom frontmatter config. This allows to set a
theme
andlook
or to adjust theme by settingthemeVariables
Example: