{"scopeName":"source.mermaid.state-diagram","patterns":[{"include":"#main"}],"repository":{"composite-state":{"name":"meta.state.composite.mermaid","begin":"^\\s*(state)(?:\\s+([^-:\\s{]+))?\\s*({)","end":"}","patterns":[{"include":"#main"}],"beginCaptures":{"1":{"name":"storage.type.state.mermaid"},"2":{"name":"variable.state.name.mermaid"},"3":{"patterns":[{"include":"source.mermaid#brace"}]}},"endCaptures":{"0":{"patterns":[{"include":"source.mermaid#brace"}]}}},"concurrency":{"name":"keyword.control.flow.concurrency.mermaid","match":"--"},"main":{"patterns":[{"include":"source.mermaid#a11y"},{"include":"source.mermaid#directive"},{"include":"source.mermaid#comment"},{"include":"source.mermaid#direction"},{"include":"#terminal"},{"include":"#transition"},{"include":"#composite-state"},{"include":"#note"},{"include":"#concurrency"},{"include":"#state"}]},"marker":{"name":"entity.name.tag.modifier.$2.mermaid","match":"((\u003c\u003c))(choice|fork|join)((\u003e\u003e))","captures":{"1":{"name":"punctuation.definition.marker.begin.mermaid"},"2":{"name":"sublimelinter.gutter-mark"},"4":{"name":"punctuation.definition.marker.end.mermaid"},"5":{"name":"sublimelinter.gutter-mark"}}},"note":{"name":"meta.note.mermaid","begin":"^\\s*(note)\\s+((?:left|right)\\s+of)\\s+([^-:\\s{]+)","end":"(?!\\G)","patterns":[{"contentName":"string.unquoted.note-text.mermaid","begin":"\\G[ \\t]*$","end":"^\\s*(end)\\s+(note)(?=$|\\s)","endCaptures":{"1":{"name":"keyword.operator.end-note.mermaid"},"2":{"name":"storage.type.note.mermaid"}}},{"contentName":"string.unquoted.note-text.mermaid","begin":"\\G\\s*(:)[ \\t]*","end":"(?=\\s*$)","beginCaptures":{"1":{"patterns":[{"include":"source.mermaid#colon"}]}}}],"beginCaptures":{"1":{"name":"storage.type.note.mermaid"},"2":{"name":"constant.language.note-position.mermaid"},"3":{"name":"variable.state.name.mermaid"}}},"state":{"patterns":[{"name":"meta.state.statement.mermaid","begin":"^\\s*(state)(?=$|\\s)[ \\t]*","end":"(?=\\s*$)","patterns":[{"name":"string.quoted.double.state-description.mermaid","begin":"\\G\"","end":"\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.mermaid"}},"endCaptures":{"0":{"name":"punctuation.definition.string.end.mermaid"}}},{"name":"variable.state.name.mermaid","match":"\\G(?:[^-:\\s{%]|%(?!%))++"},{"begin":"(?\u003c=\")\\s*(as)(?=$|\\s)","end":"[^-:\\s{]+|(?=\\s*(?:$|%%))","beginCaptures":{"1":{"name":"keyword.operator.alias.mermaid"}},"endCaptures":{"0":{"name":"variable.state.name.mermaid"}}},{"include":"#marker"}],"beginCaptures":{"1":{"name":"storage.type.state.mermaid"}}},{"contentName":"string.unquoted.state-description.mermaid","begin":"([^-:\\s{]+)\\s*(:)[ \\t]*","end":"(?=\\s*(?:$|%%))","beginCaptures":{"1":{"name":"variable.state.name.mermaid"},"2":{"patterns":[{"include":"source.mermaid#colon"}]}}},{"name":"variable.state.name.mermaid","match":"[^-:\\s{]+"}]},"terminal":{"patterns":[{"name":"constant.language.state.initial.mermaid","match":"\\[\\*\\](?=\\s*--\u003e)"},{"match":"(?\u003c=--\u003e)\\s*(\\[\\*\\])","captures":{"1":{"name":"constant.language.state.final.mermaid"}}}]},"transition":{"name":"keyword.operator.transition.mermaid","match":"--\u003e"}}}