diff options
author | Sonja Galovic <galovicsonja@gmail.com> | 2022-04-27 19:52:48 +0200 |
---|---|---|
committer | Sonja Galovic <galovicsonja@gmail.com> | 2022-04-27 19:52:48 +0200 |
commit | 98d3f4dedaabf62213b95dd8e7b67f9e8ab99006 (patch) | |
tree | 5f85498c4abcdcf83aeacdb30eaeaa166de406e4 /frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts | |
parent | 086010248b30924d4b597483fcec3f9988ed2419 (diff) |
Sredjen dizajn tabele. Sredjena difoltna vrednost za missingvalue. Grafici uredjeni.
Diffstat (limited to 'frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts')
-rw-r--r-- | frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts b/frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts index 248c9aa8..f141f522 100644 --- a/frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts +++ b/frontend/src/app/_elements/_charts/pie-chart/pie-chart.component.ts @@ -8,8 +8,8 @@ import {Chart} from 'chart.js'; }) export class PieChartComponent implements AfterViewInit { - @Input()width: number = 600; - @Input()height: number = 450; + @Input()width?: number; + @Input()height?: number; @ViewChild('piechart') chartRef!: ElementRef; constructor() { } @@ -22,7 +22,7 @@ export class PieChartComponent implements AfterViewInit { datasets: [{ label: "Population (millions)", backgroundColor: ["#3e95cd", "#8e5ea2","#3cba9f","#e8c3b9","#c45850"], - data: [2478,5267,734,784,433] + data: [2478,5267,734,784,433], }] }, options: { @@ -34,7 +34,9 @@ export class PieChartComponent implements AfterViewInit { legend: { display: false }, - } + }, + layout: { + padding: 15} } }); |