Fix for new diagram types
This commit is contained in:
@@ -28,6 +28,9 @@ const detectType = text => {
|
||||
if (text.match(/^\s*gitGraph/)) {
|
||||
return 'git';
|
||||
}
|
||||
if (text.match(/^\s*flowchart/)) {
|
||||
return 'flowchart';
|
||||
}
|
||||
|
||||
if (text.match(/^\s*info/)) {
|
||||
return 'info';
|
||||
|
||||
@@ -4,7 +4,7 @@ export const initEditor = monaco => {
|
||||
// Register a tokens provider for the language
|
||||
monaco.languages.setMonarchTokensProvider('mermaid', {
|
||||
typeKeywords: [
|
||||
'graph', 'stateDiagram', 'sequenceDiagram', 'classDiagram', 'pie'
|
||||
'graph', 'stateDiagram', 'sequenceDiagram', 'classDiagram', 'pie', 'flowchart', 'gantt'
|
||||
],
|
||||
keywords: [
|
||||
'patricipant','as'
|
||||
|
||||
Reference in New Issue
Block a user