mermaid-js / mermaid-live-editor

Edit, preview and share mermaid charts/diagrams. New implementation of the live editor.
https://mermaid.live
MIT License
4.3k stars 654 forks source link

Copy database snippet has incorrect format #1535

Closed amnuts closed 2 months ago

amnuts commented 2 months ago

Describe the bug

On the live editor at https://www.mermaidchart.com/play, when you copy the 'database' snippet, it has the wrong formatting, putting into the clipboard a sub-routine instead. If you use the insert option for database, it's got the correct format.

To Reproduce

Go to the playground and start a graph with graph TD.

Go to the snippets and insert a database. You'll get dbId[("`label`")] inserted.

Click on the icon to copy the database, paste into the graph, and you'll have dbId[["`label`"]]

Expected behavior

Copying the database puts dbId[("`label`")] into the clipboard.

huynhicode commented 2 months ago

Thanks for reporting @amnuts !

Can you report the bug to the Mermaid Chart Issue Tracker so we can better track?

https://github.com/Mermaid-Chart/issue-tracker

amnuts commented 2 months ago

Thanks for letting me know the correct place, @huynhicode.

https://github.com/Mermaid-Chart/issue-tracker/issues/91