Add charts.js plugin, basic chart component
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
import Component from '@ember/component';
|
||||
|
||||
export default Component.extend({
|
||||
|
||||
chartData: {
|
||||
datasets: [{
|
||||
data: [10, 20, 30]
|
||||
}],
|
||||
labels: [
|
||||
'Red',
|
||||
'Yellow',
|
||||
'Blue'
|
||||
]
|
||||
},
|
||||
|
||||
chartOptions: {
|
||||
legend: {
|
||||
display: false
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
@@ -0,0 +1,5 @@
|
||||
{{ember-chart type='doughnut'
|
||||
data=chartData
|
||||
options=chartOptions
|
||||
width=200
|
||||
height=200}}
|
||||
Reference in New Issue
Block a user