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

Named composite example in State Diagram #5474

Closed
cbugk opened this issue Apr 19, 2024 · 1 comment · Fixed by #5485
Closed

Named composite example in State Diagram #5474

cbugk opened this issue Apr 19, 2024 · 1 comment · Fixed by #5485
Labels
Status: Triage Needs to be verified, categorized, etc Type: Enhancement New feature or request

Comments

@cbugk
Copy link
Contributor

cbugk commented Apr 19, 2024

Proposal

I would like to propose a change in State Diagram's composite examples. Since there weren't a documentation related issue type, I am opening one as syntax issue. I already have committed my changes on my fork. Will be creating a merge request shortly.

Example

Below is the addition I would like to append to the first example at https://mermaid.js.org/syntax/stateDiagram.html#composite-states

[*] --> NamedComposite
    NamedComposite: Another Composite
    state NamedComposite {
        [*] --> namedSimple
        namedSimple --> [*]
        namedSimple: Another simple
    }

Screenshots

AnotherComposite

@cbugk cbugk added Status: Triage Needs to be verified, categorized, etc Type: Enhancement New feature or request labels Apr 19, 2024
@cbugk
Copy link
Contributor Author

cbugk commented Apr 19, 2024

There is a strange occurance on my end. If naming is post-state-definition rather than pre-state-definition, color fill is dark grey for the parent state. I suppose it can not be rendered but its borders are honored in rendering somehow.
AnotherComposite_post_named

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Triage Needs to be verified, categorized, etc Type: Enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant