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

Markdown strings formatting without automatic text wrapping #4391

Closed
mpusz opened this issue May 12, 2023 · 1 comment · Fixed by #4856
Closed

Markdown strings formatting without automatic text wrapping #4391

mpusz opened this issue May 12, 2023 · 1 comment · Fixed by #4856
Labels
Good first issue! Status: Approved Is ready to be worked on Type: Bug / Error Something isn't working or is incorrect

Comments

@mpusz
Copy link

mpusz commented May 12, 2023

Description

I am trying to create a graph with nodes where each of the nodes has three or four lines of text. The first line should be bold, the second one in italics, and the last ones in regular font. With the new markdown strings feature I can handle formatting but it also enables automatic text wrapping. With this instead of 3 lines I sometimes get 5 or more which is an issue for me and it breaks the all purpose of such graphs.

How can I prevent breaking this into separate lines?

Steps to reproduce

The below should always be rendered as four lines:

flowchart TD
    angular_velocity["`**angular_velocity**
      *angular_displacement / duration*
      [rad/s, 1/s]
      {vector}`"]
Loading

Screenshots

No response

Code Sample

flowchart TD
    angular_velocity["`**angular_velocity**
      *angular_displacement / duration*
      [rad/s, 1/s]
      {vector}`"]
    frequency["frequency\n(1 / period_duration)\n[Hz, 1/s]"]
    rotational_frequency["rotational_frequency\n(rotation / duration)\n[1/s]"]
    angular_frequency["angular_frequency\n(phase_angle / duration)\n[rad/s, 1/s]"]
    damping_coefficient["damping_coefficient\n(1 / time_constant)\n[1/s]"]

Setup

  • Mermaid version: 10.1.0
  • Browser and Version: Chrome latest

Additional Context

No response

@mpusz mpusz added Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect labels May 12, 2023
@sidharthv96
Copy link
Member

@knsv maybe we can add a config option to disable text wrapping?

@sidharthv96 sidharthv96 added Status: Approved Is ready to be worked on Good first issue! fix and removed Status: Triage Needs to be verified, categorized, etc labels May 17, 2023
@jgreywolf jgreywolf removed the fix label Jun 7, 2023
@jgreywolf jgreywolf added roadmap items to add to roadmap for auto workflow and removed roadmap items to add to roadmap for auto workflow labels Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good first issue! Status: Approved Is ready to be worked on Type: Bug / Error Something isn't working or is incorrect
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants