-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDonut.jsx
65 lines (55 loc) · 1.43 KB
/
Donut.jsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
import React, { Component } from 'react';
import Chart from 'react-apexcharts'
class Donut extends Component {
constructor(props) {
super(props);
this.state = {
options: {
title: {
text: 'Total applications 17',
},
plotOptions: {
pie: {
customScale: 0.5,
offsetX:-100,
offsetY: -30,
donut:{
size: '40%'
}
}
},
legend: {
horizontalAlign: 'left',
itemMargin: {
horizontal: 20,
vertical: 5
},
offsetX: -40,
offsetY: -60,
show: true,
showForSingleSeries: true,
position:'bottom',
customLegendItems: ['Rejection (11)', 'Interviews done (3)', 'Interview booked (2)', 'Proposals (1)']
},
colors:['#252525',
'#E5A560',
'#EDC67D',
'#F4DCAC',
'#FFF'],
dataLabels: {
enabled: false
}
},
series: [11, 3, 2, 1],
labels: ['Rejection', 'Interviews done', 'Interview booked', 'Proposals']
}
}
render() {
return (
<div className="donut">
<Chart options={this.state.options} series={this.state.series} type="donut" width="380" />
</div>
);
}
}
export default Donut;