From 46fc8b601686da30eb9405efd435aa7e7ba0e05b Mon Sep 17 00:00:00 2001 From: Anmol Verma Date: Sun, 15 Dec 2024 15:52:07 +0530 Subject: [PATCH 1/3] decrease size --- packages/app/components/ScoreContainer.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/app/components/ScoreContainer.tsx b/packages/app/components/ScoreContainer.tsx index c81446f12..650925a45 100644 --- a/packages/app/components/ScoreContainer.tsx +++ b/packages/app/components/ScoreContainer.tsx @@ -21,7 +21,7 @@ interface ScoreProgressChartProps { const ScoreProgressChart: React.FC = ({ score, - size = 150, + size = 120, strokeWidth = 10, }) => { if (!score) return null; @@ -81,7 +81,7 @@ interface GradingPieChartProps { } const GradingPieChart: React.FC = ({ scores, - size = 150, + size = 120, strokeWidth = 10, }) => { if (!scores) return null; @@ -107,7 +107,7 @@ const GradingPieChart: React.FC = ({ return ( - + {total === 0 ? ( Date: Sun, 15 Dec 2024 16:22:46 +0530 Subject: [PATCH 2/3] add flexWrap --- packages/app/components/ScoreContainer.tsx | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/packages/app/components/ScoreContainer.tsx b/packages/app/components/ScoreContainer.tsx index 650925a45..19ce706cc 100644 --- a/packages/app/components/ScoreContainer.tsx +++ b/packages/app/components/ScoreContainer.tsx @@ -21,7 +21,7 @@ interface ScoreProgressChartProps { const ScoreProgressChart: React.FC = ({ score, - size = 120, + size = 150, strokeWidth = 10, }) => { if (!score) return null; @@ -81,7 +81,7 @@ interface GradingPieChartProps { } const GradingPieChart: React.FC = ({ scores, - size = 120, + size = 150, strokeWidth = 10, }) => { if (!scores) return null; @@ -107,7 +107,7 @@ const GradingPieChart: React.FC = ({ return ( - + {total === 0 ? ( = ({ style={{ flex: 1, flexDirection: media.gtXs ? 'column' : 'row', - gap: 15, + flexWrap: 'wrap', + gap: 30, + justifyContent: 'center', + alignItems: 'center', }} > From e7b3993fcac482d166789c70109bef3aee09d2a2 Mon Sep 17 00:00:00 2001 From: Anmol Verma Date: Mon, 16 Dec 2024 15:44:29 +0530 Subject: [PATCH 3/3] increase gap --- packages/app/components/ScoreContainer.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/app/components/ScoreContainer.tsx b/packages/app/components/ScoreContainer.tsx index 19ce706cc..190c6eb98 100644 --- a/packages/app/components/ScoreContainer.tsx +++ b/packages/app/components/ScoreContainer.tsx @@ -12,6 +12,7 @@ import { } from 'app/hooks/score'; import { View } from 'react-native'; import { useMedia } from 'tamagui'; +import useResponsive from 'app/hooks/useResponsive'; interface ScoreProgressChartProps { score: number; @@ -187,6 +188,7 @@ export const ScoreContainer: React.FC = ({ const handleScoreClick = useCalculateStore(id, type); const media = useMedia(); + const { sm } = useResponsive(); return ( @@ -218,7 +220,7 @@ export const ScoreContainer: React.FC = ({ flex: 1, flexDirection: media.gtXs ? 'column' : 'row', flexWrap: 'wrap', - gap: 30, + gap: sm ? 50 : 20, justifyContent: 'center', alignItems: 'center', }}