From c6131ffc43084587aecef8199718eac8b479a476 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20FAMIBELLE-PRONZOLA?= Date: Sat, 4 Jun 2022 01:38:19 +0400 Subject: [PATCH] Reduce KatStats --- components/stats/bar-stats.js | 4 ++-- components/stats/kat-stats.js | 4 ++-- components/stats/traductions-stats.js | 13 +------------ pages/index.js | 5 ++++- 4 files changed, 9 insertions(+), 17 deletions(-) diff --git a/components/stats/bar-stats.js b/components/stats/bar-stats.js index 91295c6..5e41a2b 100644 --- a/components/stats/bar-stats.js +++ b/components/stats/bar-stats.js @@ -19,11 +19,11 @@ const BorderLinearProgress = styled(LinearProgress)(({theme}) => ({ export default function BarStats({percent}) { return ( - + - {`${Math.round( + {`${Math.round( percent, )}%`} diff --git a/components/stats/kat-stats.js b/components/stats/kat-stats.js index f8d4d2d..410421d 100644 --- a/components/stats/kat-stats.js +++ b/components/stats/kat-stats.js @@ -8,10 +8,10 @@ import TraductionsStats from './traductions-stats' export default function KatStats({emoji, value, total}) { return ( - + - + diff --git a/components/stats/traductions-stats.js b/components/stats/traductions-stats.js index 9497ab2..b200c25 100644 --- a/components/stats/traductions-stats.js +++ b/components/stats/traductions-stats.js @@ -13,20 +13,9 @@ export default function TraductionsStats({value, total}) { - + {translated} - - Paroles traduites - - - - - {value} - - - Paroles non traduites - diff --git a/pages/index.js b/pages/index.js index 59873ee..5a47f24 100644 --- a/pages/index.js +++ b/pages/index.js @@ -80,7 +80,10 @@ export default function Home({errorCode, errorMessage, stats}) { - + + Traductions + + {statsByLang.map(({code, value, emoji}) => ( ))}