1
1
### [ @coreui/react-chartjs ] ( https://coreui.io/ ) changelog
2
2
3
+ ##### ` 1.0.0-alpha.4 `
4
+ BREAKING CHANGE:
5
+ - ` <CCharts> ` component has been deprecated and will be removed in v1.0.0
6
+ - use ` <CChart type="..."> ` instead
7
+ or one of following types:
8
+ ` <CChartBar> `
9
+ ` <CChartHorizontalBar> `
10
+ ` <CChartLine> `
11
+ ` <CChartDoughnut> `
12
+ ` <CChartRadar> `
13
+ ` <CChartPie> `
14
+ ` <CChartPolarArea> `
15
+
16
+ sample import:
17
+ ``` jsx
18
+ import {
19
+ CChart ,
20
+ CChartBar ,
21
+ CChartHorizontalBar ,
22
+ CChartLine ,
23
+ CChartDoughnut ,
24
+ CChartRadar ,
25
+ CChartPie ,
26
+ CChartPolarArea
27
+ } from ' @coreui/react-chartjs' ;
28
+ ```
29
+
30
+
3
31
##### ` 1.0.0-alpha.0 `
4
32
- initial version
5
33
@@ -9,56 +37,3 @@ npm install @coreui/react
9
37
npm install @coreui/react-chartjs
10
38
```
11
39
12
- import:
13
- ``` jsx
14
- import { CCharts } from ' @coreui/react-chartjs' ;
15
- ```
16
-
17
- usage:
18
- ``` jsx
19
- ...
20
- class CoreUICharts extends Component {
21
- ...
22
- render () {
23
- return (
24
- < CCharts
25
- type= " radar"
26
- datasets= {[
27
- {
28
- label: ' 2019' ,
29
- backgroundColor: ' rgba(179,181,198,0.2)' ,
30
- borderColor: ' rgba(179,181,198,1)' ,
31
- pointBackgroundColor: ' rgba(179,181,198,1)' ,
32
- pointBorderColor: ' #fff' ,
33
- pointHoverBackgroundColor: ' #fff' ,
34
- pointHoverBorderColor: ' rgba(179,181,198,1)' ,
35
- tooltipLabelColor: ' rgba(179,181,198,1)' ,
36
- data: [65 , 59 , 90 , 81 , 56 , 55 , 40 ]
37
- },
38
- {
39
- label: ' 2020' ,
40
- backgroundColor: ' rgba(255,99,132,0.2)' ,
41
- borderColor: ' rgba(255,99,132,1)' ,
42
- pointBackgroundColor: ' rgba(255,99,132,1)' ,
43
- pointBorderColor: ' #fff' ,
44
- pointHoverBackgroundColor: ' #fff' ,
45
- pointHoverBorderColor: ' rgba(255,99,132,1)' ,
46
- tooltipLabelColor: ' rgba(255,99,132,1)' ,
47
- data: [28 , 48 , 40 , 19 , 96 , 27 , 100 ]
48
- }
49
- ]}
50
- options= {{
51
- aspectRatio: 1.5 ,
52
- tooltips: {
53
- enabled: true
54
- }
55
- }}
56
- labels= {[
57
- ' Eating' , ' Drinking' , ' Sleeping' , ' Designing' ,
58
- ' Coding' , ' Cycling' , ' Running'
59
- ]}
60
- / >
61
- )
62
- }
63
- ...
64
- ` ` `
0 commit comments