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

Mermaid Double Border Circles Display Incorrectly #67

Open
noluyorAbi opened this issue May 1, 2024 · 1 comment
Open

Mermaid Double Border Circles Display Incorrectly #67

noluyorAbi opened this issue May 1, 2024 · 1 comment

Comments

@noluyorAbi
Copy link

Description

I've encountered an issue with the Nord theme in Obsidian where Mermaid diagrams do not display double borders around circles correctly. Instead of showing a distinct double border, the circle merely appears enlarged. This issue does not occur in other themes. Attached are screenshots from both Nord and another theme for comparison.

Nord Theme (issue):
image

For reference Atom Theme
image

Steps to Reproduce:

  1. Use the following Mermaid code in a note with the Nord theme enabled.
  2. Compare the rendering with another theme that supports double borders correctly.
graph LR
    id1(( )) --> circleId0(("`P0`"))
    circleId0(("`P0`")) -->|a| circleId1(("`P1`"))
    circleId1(("`P1`")) -->|a| circleId2(("`P2`"))
    circleId2(("`P2`")) -->|a| doubleCircleId3((("`P3`")))
    doubleCircleId3((("`P3`"))) -->|a| circleId0(("`P0`"))
Loading

Expected Behavior:

Circles with double borders should display two distinct borders.

Actual Behavior:

The circle appears larger with no distinct double borders.

Comment

Thanks for this awesome theme; it's my go-to theme in Obsidian! I've noticed a small issue that slightly disrupts my workflow with graphs, and I wanted to open a ticket to possibly get it fixed. Any help with this would be greatly appreciated. Thanks for the hard work and dedication to making such a valuable theme for the community :)

@noluyorAbi
Copy link
Author

noluyorAbi commented Jun 10, 2024

For anyone encountering a similar issue and looking for a workaround:

I set the --background-modifier-border variable to gray. This change affects all borders within the theme, including the borders of the nodes in mermaid diagrams. While this solution isn't perfect and impacts more elements than desired, it serves as a temporary fix.

--background-modifier-border: gray; /* Adjusts the border color */

Note that this approach is a compromise, as it alters the appearance of all borders throughout the theme. However, it can be a manageable solution until a more targeted fix is implemented.

image

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

1 participant