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

Newline by \n does not give a newline in mermaid live #1515

Open
richelbilderbeek opened this issue Aug 26, 2024 · 2 comments
Open

Newline by \n does not give a newline in mermaid live #1515

richelbilderbeek opened this issue Aug 26, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@richelbilderbeek
Copy link

Describe the bug

In mermaid one can use \n to create multiline texts:

flowchart TD

  test[No more\nnewlines?]
Loading

pasting that text in mermaid.live, however ...

flowchart TD

  test[No more\nnewlines?]

does not result in a multi-line-text, as shown in this screenshot:

Screenshot from 2024-08-26 15-37-24

To Reproduce
Link to Live Editor: here
Steps to reproduce the behavior:

  1. Go to https://mermaid.live
  2. Paste the following text:
flowchart TD

  test[No more\nnewlines?]
  1. Observe that no newline is shown

Expected behavior

I expected a newline when I use \n in the live editor

Screenshots

Here it is again:

Screenshot from 2024-08-26 15-37-24

Desktop (please complete the following information):

  • OS: [e.g. iOS]: Ubuntu
  • Browser [e.g. chrome, safari]: Firefox
  • Version [e.g. 22]: 129.0.2 (64-bit)

Additional context

I'm a heavy mermaid user (yet with holidays), so I estimate this happened in the last two months.

@richelbilderbeek richelbilderbeek added the bug Something isn't working label Aug 26, 2024
@richelbilderbeek richelbilderbeek changed the title Newline by \n does not work anymore Newline by \n does not give a newline in mermaid live Aug 26, 2024
@SebastianSimon
Copy link

SebastianSimon commented Aug 28, 2024

I think in the same version, I noticed another bug: moderately long labels are now no longer rendered.

Example:

flowchart TD
  X(This is a somewhat long label.)
Loading

On the Website:

Screenshot 2024-08-28 at 13-22-42 Online FlowChart   Diagrams Editor - Mermaid Live Editor

@richelbilderbeek
Copy link
Author

richelbilderbeek commented Sep 9, 2024

I mentioned the bug from @SebastianSimon in #1533, using the standard bug report form 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants