From f074f9f003ca579ed8833b27c97fd24efa1e9a92 Mon Sep 17 00:00:00 2001 From: Saheb Giri <47132373+iamsahebgiri@users.noreply.github.com> Date: Fri, 31 Mar 2023 17:33:51 +0530 Subject: [PATCH] fix: graphs issue (#655) * fix: prevent y axis to have decimal * fix: add padding and labels to line chart --- apps/app/components/core/sidebar/progress-chart.tsx | 1 + apps/app/components/workspace/completed-issues-graph.tsx | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/app/components/core/sidebar/progress-chart.tsx b/apps/app/components/core/sidebar/progress-chart.tsx index b79b5fa89..bb3f7e059 100644 --- a/apps/app/components/core/sidebar/progress-chart.tsx +++ b/apps/app/components/core/sidebar/progress-chart.tsx @@ -80,6 +80,7 @@ const ProgressChart: React.FC = ({ issues, start, end }) => { tick={{ fontSize: "12px", fill: "#1f2937" }} tickSize={10} minTickGap={10} + allowDecimals={false} /> } /> = ({ month, issues, setMonth for (let i = 1; i <= weeks; i++) { data.push({ - week_in_month: i, + week_in_month: `Week ${i}`, completed_count: issues?.find((item) => item.week_in_month === i)?.completed_count ?? 0, }); } @@ -58,8 +58,8 @@ export const CompletedIssuesGraph: React.FC = ({ month, issues, setMonth
- - + + } />