Skip to content

Commit b7ca814

Browse files
committed
Change size of chart
1 parent a9969fe commit b7ca814

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

scripts/chart/chart-core.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ function donutChart() {
4949
.attr('height', height + margin.top + margin.bottom)
5050
.attr('class', 'backColorChart')
5151
.append('g')
52-
.attr('transform', 'translate(' + (width / 2 - 100) + ',' + (height / 2 + 10) + ')');
52+
.attr('transform', 'translate(' + (width / 2 - 105) + ',' + (height / 2 + 12) + ')');
5353
// ===========================================================================================
5454

5555
// ===========================================================================================
@@ -74,7 +74,7 @@ function donutChart() {
7474
.data(pie(data))
7575
.enter().append("g")
7676
.attr("transform", function (d, i) {
77-
return "translate(" + (130) + "," + (i * 20 - 30) + ")"; // place each legend on the right and bump each one down 15 pixels
77+
return "translate(" + (130) + "," + (i * 20 - 40) + ")"; // place each legend on the right and bump each one down 15 pixels
7878
})
7979
.attr("class", "legend");
8080

scripts/ui.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ class UI {
8181
drawChart(tabs) {
8282
var donut = donutChart()
8383
.width(480)
84-
.height(240)
84+
.height(230)
8585
.cornerRadius(5) // sets how rounded the corners are on each slice
8686
.padAngle(0.020) // effectively dictates the gap between slices
8787
.variable('percentage')

0 commit comments

Comments
 (0)