Skip to content

Commit

Permalink
[#1227] Pie Chart > 차트가 안 보일정도로 브라우저 사이즈를 줄일 시 Error Log 발생 (#1228)
Browse files Browse the repository at this point in the history
Co-authored-by: jinhee park <jinhee@ex-em.com>
  • Loading branch information
jhee564 and jhee564 authored Jun 30, 2022
1 parent f395986 commit 5a5cd3e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/components/chart/plugins/plugins.pie.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ const modules = {
radius -= pieOption.pieStroke.lineWidth;
}

if (radius < 0) {
return;
}

pie.or = radius;
if (ix < pieDataSet.length - 1) {
pie.ir = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * (ix + 1));
Expand Down Expand Up @@ -140,6 +144,10 @@ const modules = {
radius -= pieOption.pieStroke.lineWidth;
}

if (radius < 0) {
return;
}

pie.or = radius;
if (ix < pieDataSet.length - 1) {
pie.ir = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * (ix + 1));
Expand Down

0 comments on commit 5a5cd3e

Please sign in to comment.