openKB icon indicating copy to clipboard operation
openKB copied to clipboard

Mermaid graphs style issues

Open alexrait opened this issue 8 years ago • 7 comments

The background of the text on a link is problematic.

graph TD; A -->aaa --> B(aa);
Produces this for me:

image

And on flowcharts it doesn't look good on the squares: image

Is there a way to solve it?

alexrait avatar Nov 21 '17 14:11 alexrait

You would have to edit the existing theme css or add a new css file.

mrvautin avatar Nov 21 '17 14:11 mrvautin

What exactly should be changed for that? It seems to me that the default values are not OK.

alexrait avatar Nov 21 '17 14:11 alexrait

I’m not sure it’s the default mermaid CSS which would need to be overwritten.

mrvautin avatar Nov 21 '17 15:11 mrvautin

Hi, this is still an issue.

I am fairly certain the default theme is nothing like what is displayed in OpenKB.

Looking at your code, I see you have packaged V6.0.0 directly inside the src & the colours in your CSS are nothing like the V6.0 default colours

Example screen shot from github ... image

Request, could you update to latest mermaid version 8.3.1? It no longer uses CSS files but instead embeds the theme (updage js, specify theme in initialise({}) & remove css file).

Here is a screenshot of my local OpenKB using latest version (8.3.1)... image

..it is much more usable / readable.

I could submit a PR if that is preferable?

Steve-Mcl avatar Oct 04 '19 11:10 Steve-Mcl

If you have already looked into this and know how to fix it, a PR is preferable.

mrvautin avatar Oct 04 '19 12:10 mrvautin

Hi, please see #283 - hopefully this is acceptable.

Steve-Mcl avatar Oct 04 '19 16:10 Steve-Mcl

update, the PR is here #284. please review and feedback if need be. thanks, Steve.

Steve-Mcl avatar Oct 05 '19 08:10 Steve-Mcl