telegramdesktop / tdesktop

Telegram Desktop messaging app
https://desktop.telegram.org/
Other
24.88k stars 4.94k forks source link

Request: Mermaid Code Rendering #27924

Closed us254 closed 2 weeks ago

us254 commented 2 weeks ago

Is your feature request related to a problem?

Yes, the current limitation of not being able to render Mermaid code directly within the platform hampers the ability to visualize and document complex workflows, diagrams, and charts. This reduces the effectiveness of documentation and collaboration.The inability to render Mermaid code means users cannot leverage the power of visual diagrams to enhance their documentation. This can lead to misunderstanding, miscommunication, and an overall less effective documentation and collaboration process.

Describe the solution you'd like

I would like the platform to support Mermaid code rendering. When Mermaid code is enclosed with triple backticks and prefixed with mermaid, the platform should automatically convert the code into a rendered diagram. Example:

graph TD;
    A-->B;
    A-->C;
    B-->D;
    C-->D; 

The above code should render a diagram showing the flow from A to B and C, and from B and C to D.

Describe alternatives you've considered

  1. Manually Embedding Diagrams: Users could manually create and embed images of diagrams. However, this approach is less dynamic and makes updates cumbersome. Additionally, it doesn't allow for easy textual revisions within the platform.
  2. External Diagram Tools: Users can utilize external tools like draw.io or Lucidchart and then embed the images. This, however, creates dependency on third-party tools and disrupts the workflow.

Additional context Implementing Mermaid code rendering will:

Your consideration of this feature request would greatly enhance the platform's utility and user satisfaction.

Thank you!

Aokromes commented 2 weeks ago

platform wide bugs / requests belongs to https://bugs.telegram.org/