diff --git a/src/app/components/StackedBarChart.tsx b/src/app/components/StackedBarChart.tsx index 2da6902..a5d114f 100644 --- a/src/app/components/StackedBarChart.tsx +++ b/src/app/components/StackedBarChart.tsx @@ -3,6 +3,7 @@ import { useTranslations } from 'next-intl'; import { useMemo } from 'react'; import { BarChart, Bar, Cell, XAxis, Tooltip } from 'recharts'; +import { pluralize } from '@/app/lib/pluralize'; type Files = { data: { @@ -147,6 +148,16 @@ export const StackedBarChart = ({ data }: Files) => { ); }; + const pluralizeCheks = (number: number) => { + const translate = [t('check'), t('checks-few'), t('checks')]; + return pluralize(number, translate[0], translate[1], translate[2]); + }; + + const pluralizeViolations = (number: number) => { + const translate = [t('violation'), t('violations-few'), t('violations')]; + return pluralize(number, translate[0], translate[1], translate[2]); + }; + return ( <>
| ФАЙЛ | -РАЗМЕР | -ЗАЩИТА | -ДАТА | -ДЕЙСТВИЯ | -
|---|---|---|---|---|
|
-
-
-
-
-
-
-
- Screenshot 2025-11-13 at 10.20.14.p...
-
-
- ПОЛНАЯ ЗАЩИТА
-
- ВСЕ МОДУЛИ
-
-
- |
- - 1.93 МБ - | -
-
-
-
-
-
-
- 100%
-
- |
- - 27.11.2025 10:16 - | -- - | -
|
-
-
-
-
-
-
-
- Screenshot 2025-11-13 at 10.20.14.p...
-
-
- ПОЛНАЯ ЗАЩИТА
-
- ВСЕ МОДУЛИ
-
-
- |
- - 1.93 МБ - | -
-
-
-
-
-
-
- 100%
-
- |
- - 27.11.2025 10:16 - | -- - | -
|
-
-
-
-
-
-
-
- Screenshot 2025-11-13 at 10.20.14.p...
-
-
- ПОЛНАЯ ЗАЩИТА
-
- ВСЕ МОДУЛИ
-
-
- |
- - 1.93 МБ - | -
-
-
-
-
-
-
- 100%
-
- |
- - 27.11.2025 10:16 - | -- - | -