fix: prevent pie chart crash on zero or negative values

This commit is contained in:
darshanr0107
2025-06-12 18:13:11 +05:30
parent 8a703bd09f
commit 83b9a17277
6 changed files with 76 additions and 2 deletions

View File

@@ -37,6 +37,11 @@ Drawing a pie chart is really simple in mermaid.
- Followed by `:` colon as separator
- Followed by `positive numeric value` (supported up to two decimal places)
**Note:**
> Pie chart values must be **positive numbers greater than zero**.\
> **Zero and negative values are not allowed** and will result in an error.
\[pie] \[showData] (OPTIONAL)
\[title] \[titlevalue] (OPTIONAL)
"\[datakey1]" : \[dataValue1]