-
Notifications
You must be signed in to change notification settings - Fork 49
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
feat: support sequence diagrams 🚀 #34
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
ad1992
force-pushed
the
aakansha/sequence
branch
from
November 2, 2023 09:13
ee429be
to
d936b04
Compare
Merging 🚀 |
zsviczian
added a commit
to zsviczian/mermaid-to-excalidraw
that referenced
this pull request
Nov 3, 2023
feat: support sequence diagrams 🚀 (excalidraw#34)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Support Mermaid Sequence diagrams
Notes
Add test cases for sequence
clean up playground
Activations
Loops
Alternate Paths
Parallel Actions
Breaks
Critical Regions
Self loops
Comments
Sequence numbers
background highlights
critical label shouldn't overlap with loop text
Remove font customization as Mermaid breaks with customizing font
Entity codes to escape characters
I use the API
diagram.parser.yy.getMessages
and the text gets removed in this API when it containes entity codes (mermaid-js/mermaid#4983). So this API needs to be fixed in mermaid package. I can add a hacky fix rn to support it but will prefer using the message API to reduce the dependency on DOM. Opened a PR - mermaid-js/mermaid#5002.Right now I have added the support in this PR by handling entity codes. Once PR is merged that part will be removed
Unsupported Features
For this we have to upgrade to at least 10.3.0 as this is supported 10.3.0 onwards, however the SVG nodes order is reversed which is making this upgrade trickier, more info here - The order of svg is reversed for sequence diagram participant nodes mermaid-js/mermaid#4946
I use the APIdiagram.parser.yy.getMessages
and the text gets removed in this API when it containes entity codes (getMessages API doesn't support Entity codes mermaid-js/mermaid#4983). So this API needs to be fixed in mermaid package. I can add a hacky fix rn to support it but will prefer using the message API to reduce the dependency on DOM.Opened a PR - fix: getMessageAPI so it considers entity codes mermaid-js/mermaid#5002 and have added support in this PR as well
They don't work on mermaid itself - Actor Menus on Sequence Diagrams do not popup. mermaid-js/mermaid#4212