Merge pull request #6651 from mermaid-js/6584-piechart-zero-negative-values

6584: prevent pie chart crash on zero or negative values
This commit is contained in:
Knut Sveidqvist
2025-08-08 09:52:16 +00:00
committed by GitHub
9 changed files with 128 additions and 29 deletions

View File

@@ -82,4 +82,13 @@ describe('pie chart', () => {
`
);
});
it('should render pie slices only for non-zero values but shows all legends', () => {
imgSnapshotTest(
` pie title Pets adopted by volunteers
"Dogs" : 386
"Cats" : 85
"Rats" : 1
`
);
});
});