From 0aaf470a9e707f8b6bf09a2f31f75a5704ba3026 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Dudfield?= Date: Mon, 24 Aug 2026 22:22:17 +0200 Subject: [PATCH] prometheus: Fix metric count plural forms MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: René Dudfield --- prometheus/locales/en/translation.json | 4 ++-- .../KedaScalerMetricsChart/KedaScalerMetricsChart.tsx | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/prometheus/locales/en/translation.json b/prometheus/locales/en/translation.json index d39cc910b4..789a54733f 100644 --- a/prometheus/locales/en/translation.json +++ b/prometheus/locales/en/translation.json @@ -92,8 +92,8 @@ "Unknown Metric": "Unknown Metric", "Unknown Scaler": "Unknown Scaler", "Scaler Instance": "Scaler Instance", - "{{count}} metrics_one": "{{count}} metrics", - "{{count}} metrics_other": "{{count}} metric", + "{{count}} metrics_one": "{{count}} metric", + "{{count}} metrics_other": "{{count}} metrics", "Metric": "Metric", "Request Rate": "Request Rate", "Latency": "Latency", diff --git a/prometheus/src/components/Chart/KedaScalerMetricsChart/KedaScalerMetricsChart.tsx b/prometheus/src/components/Chart/KedaScalerMetricsChart/KedaScalerMetricsChart.tsx index 577a22e785..975cff5024 100644 --- a/prometheus/src/components/Chart/KedaScalerMetricsChart/KedaScalerMetricsChart.tsx +++ b/prometheus/src/components/Chart/KedaScalerMetricsChart/KedaScalerMetricsChart.tsx @@ -261,7 +261,13 @@ export function KedaScalerMetricsChart(props: KedaScalerMetricsChartProps) { ml: 1, }} > - ({t('{{count}} metrics', { count: group.series.length })}) + ( + {t('{{count}} metrics', { + count: group.series.length, + defaultValue_one: '{{count}} metric', + defaultValue_other: '{{count}} metrics', + })} + )