How to adjust padding inside mermaid node?

Viewed 2450

When I create mermaid flowcharts the horizontal padding between the text and the node border is big so that the nodes look unreasonably wide. There, furthermore, is this strange empty line below the text. All in all it does not look very balanced. What is the reason for this and how can I adjust the padding (in the mermaid docs something like this does not happen).

graph TD;
  a("Submission by author(s)") --> b("Review by editors")
  b --> c("Content revision by author(s)") --> d("Formatting by author(s)")

enter image description here

2 Answers

<br/> will move text to next line, hope that solves your problem, please find below sample code.

graph TD
A["this is big text, in one line"] --> B["line one <br/>line two"]

I found this maybe a mermaid bug.If you want display normal,just change your complute display setting. win10:desktop->display setting->Change the size of text,apps,and other items. Find value and modify to 100%,then reopen your document.

Related