mirror of
https://github.com/chartjs/Chart.js.git
synced 2024-10-06 04:09:08 +02:00
Update 05-Pie-Doughnut-Chart.md
This commit is contained in:
parent
b9776736d4
commit
0f49be56a4
@ -55,7 +55,7 @@ var data = [
|
||||
]
|
||||
```
|
||||
|
||||
For a pie chart, you must pass in an array of objects with a value and a color property. The value attribute should be a number, Chart.js will total all of the numbers and calculate the relative proportion of each. The color attribute should be a string. Similar to CSS, for this string you can use HEX notation, RGB, RGBA or HSL.
|
||||
For a pie chart, you must pass in an array of objects with a value and an optional color property. The value attribute should be a number, Chart.js will total all of the numbers and calculate the relative proportion of each. The color attribute should be a string. Similar to CSS, for this string you can use HEX notation, RGB, RGBA or HSL.
|
||||
|
||||
### Chart options
|
||||
|
||||
@ -155,4 +155,4 @@ Calling `removeData(index)` on your Chart instance will remove segment at that p
|
||||
```javascript
|
||||
myDoughnutChart.removeData();
|
||||
// Other segments will update to fill the empty space left.
|
||||
```
|
||||
```
|
||||
|
Loading…
Reference in New Issue
Block a user