mermaid-js / mermaid

Generation of diagrams like flowcharts or sequence diagrams from text in a similar manner as markdown
https://mermaid.js.org
MIT License
70.64k stars 6.32k forks source link

SequenceDiagram - Add a way to draw empty space between statements #1963

Open Banger opened 3 years ago

Banger commented 3 years ago

Possible solutions:

I know the "style" of notes could probably be changed to do that, but it would do it for the whole diagram, which is not what I want.

benb-petaf commented 1 year ago

Came looking for this functionality.

lizziemac commented 11 months ago

You could add <br/> to the subsequent step at the very beginning for a workaround in the meantime:

john-->>-alice: <br/><br/>Yeah!
bpernetupgrade commented 8 months ago

@lizziemac adding <br/> at the beginning or at the end of a message does not seem to be supported. It gives me an error.

obondarenko1 commented 4 months ago

That would be a really helpful functionality!

lizziemac commented 4 months ago

Hi @bpernetupgrade @obondarenko1! it appears to be working in the following examples without error (hit the copy icon to see the source code, or click the link). My one complaint is that the one with the sidebars also has an extended bar where the newlines are

with arrows/sidebars

sequenceDiagram
    Alice->>+John: Hello John, how are you?
    Alice->>+John: John, can you hear me?
    John-->>-Alice: <br/><br/>Hi Alice, I can hear you!
    John-->>-Alice: I feel great!

simple

sequenceDiagram
    Alice->John: Hello John, how are you?
    Alice->John: John, can you hear me?
    John->Alice: <br/><br/>Hi Alice, I can hear you!
    John->Alice: I feel great!
bpernetupgrade commented 3 months ago

@lizziemac ah! interesting, I use the gliffy integration, that must be the reason it's not working 😢

Screenshot 2024-05-16 at 9 08 41 AM