#1152 add node spacing to flowchart configuration

This commit is contained in:
Marc Faber
2020-01-05 22:03:53 +01:00
parent 37ae863443
commit b3934c9788
3 changed files with 46 additions and 4 deletions

View File

@@ -474,4 +474,30 @@ describe('Flowchart', () => {
{ flowchart: { htmlLabels: false } }
);
});
it('22: Render a simple flowchart with nodeSpacing set to 100', () => {
imgSnapshotTest(
`graph TD
A[Christmas] -->|Get money| B(Go shopping)
B --> C{Let me think}
%% this is a comment
C -->|One| D[Laptop]
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ flowchart: { nodeSpacing: 50 } }
);
});
it('23: Render a simple flowchart with rankSpacing set to 100', () => {
imgSnapshotTest(
`graph TD
A[Christmas] -->|Get money| B(Go shopping)
B --> C{Let me think}
%% this is a comment
C -->|One| D[Laptop]
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ flowchart: { rankSpacing: '100' } }
);
});
});