diff --git a/cypress/platform/knsv2.html b/cypress/platform/knsv2.html index 260d540d3..9c91100bb 100644 --- a/cypress/platform/knsv2.html +++ b/cypress/platform/knsv2.html @@ -85,7 +85,7 @@ end Apa --> C -
+flowchart LR subgraph Apa["Apa"] B["This is B"] @@ -95,7 +95,7 @@ end Apa --> C-+flowchart RL subgraph Apa["Apa"] subgraph Gorilla @@ -107,7 +107,7 @@ end Gorilla --> C-+flowchart LR subgraph Apa["Apa"] subgraph Gorilla @@ -154,6 +154,32 @@ flowchart LR Apa --- C A --x C ++--- +config: + look: neo + theme: neo + layout: elk + elk.mergeEdges: true + themeVariables: {} +--- +%% 'elk.stress', +%% 'elk.force' +%%'elk.mrtree' +%% 'elk.sporeOverlap +stateDiagram + direction TB + A --> B + A --> C + A --> D + A --> E + A --> F + state F { + Another + } + Another --> A + +@@ -180,6 +206,12 @@ flowchart LR++ %%{init: {"layout": "elk", "mergeEdges": true} }%% +flowchart + A --> B(This is B) +%%{init: {"layout": "elk", "mergeEdges": false, "elk.nodePlacement.strategy": "SIMPLE"} }%% stateDiagram @@ -200,7 +232,7 @@ flowchart LR if_state --> True : if n >= 0-+%%{init: {"layout": "dagre", "mergeEdges": true} }%% stateDiagram direction TB @@ -221,7 +253,7 @@ State T1 { }-+%%{init: {"layouts": "elk2", "mergeEdges": true} }%% stateDiagram State S1 { @@ -231,7 +263,7 @@ State T1 { S1 --> S2-+%%{init: {"layout": "elk", "mergeEdges": true} }%% stateDiagram State T1 { @@ -241,7 +273,7 @@ State T1 { }-+%%{init: {"layout": "elk", "mergeEdges": true} }%% stateDiagram [*] --> T1 diff --git a/packages/mermaid/src/config.type.ts b/packages/mermaid/src/config.type.ts index be69ce455..afe636144 100644 --- a/packages/mermaid/src/config.type.ts +++ b/packages/mermaid/src/config.type.ts @@ -68,7 +68,7 @@ export interface MermaidConfig { * Defines which main look to use for the diagram. * */ - look?: 'classic' | 'handdrawn' | 'slick'; + look?: 'classic' | 'handdrawn'; /** * Defines the seed to be used when using handdrawn look. This is important for the automated tests as they will always find differences without the seed. The default value is 0 which gives a random seed. * diff --git a/packages/mermaid/src/diagrams/flowchart/flowDb.ts b/packages/mermaid/src/diagrams/flowchart/flowDb.ts index 0faa5c048..b24fc8805 100644 --- a/packages/mermaid/src/diagrams/flowchart/flowDb.ts +++ b/packages/mermaid/src/diagrams/flowchart/flowDb.ts @@ -852,7 +852,7 @@ export const getData = () => { const n = getVertices(); n.forEach((vertex) => { - const node = addNodeFromVertex(vertex, nodes, parentDB, subGraphDB, config, useRough); + const node = addNodeFromVertex(vertex, nodes, parentDB, subGraphDB, config, config.look); }); const e = getEdges(); diff --git a/packages/mermaid/src/rendering-util/rendering-elements/shapes/trapezoid.ts b/packages/mermaid/src/rendering-util/rendering-elements/shapes/trapezoid.ts index 1677ef8cf..eb25dc52a 100644 --- a/packages/mermaid/src/rendering-util/rendering-elements/shapes/trapezoid.ts +++ b/packages/mermaid/src/rendering-util/rendering-elements/shapes/trapezoid.ts @@ -37,7 +37,7 @@ export const trapezoid = async (parent: SVGAElement, node: Node): Promise- (node.useRough ? 'rough-node' : 'node') + ' ' + node.cssClasses + ' ' + (extra || ''); + (node.look === 'handdrawn' ? 'rough-node' : 'node') + ' ' + node.cssClasses + ' ' + (extra || ''); diff --git a/packages/mermaid/src/schemas/config.schema.yaml b/packages/mermaid/src/schemas/config.schema.yaml index 381337f10..107a0e2ec 100644 --- a/packages/mermaid/src/schemas/config.schema.yaml +++ b/packages/mermaid/src/schemas/config.schema.yaml @@ -78,7 +78,6 @@ properties: enum: - classic - handdrawn - - slick default: 'classic' handdrawnSeed: description: |