From 6bf8faa96abbfb244a8a739ded2bc78c826935e9 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Mon, 21 Apr 2025 10:47:43 +0200 Subject: [PATCH] Translation for number of occurrences (#25117) * Translation for number of occurrences * Update src/translations/en.json --- src/panels/config/logs/dialog-system-log-detail.ts | 8 +++++--- src/translations/en.json | 3 +-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/panels/config/logs/dialog-system-log-detail.ts b/src/panels/config/logs/dialog-system-log-detail.ts index 243216304c..f12051b04f 100644 --- a/src/panels/config/logs/dialog-system-log-detail.ts +++ b/src/panels/config/logs/dialog-system-log-detail.ts @@ -159,9 +159,11 @@ class DialogSystemLogDetail extends LitElement { this.hass!.locale, this.hass!.config )} - (${item.count} - ${this.hass.localize( - "ui.panel.config.logs.detail.occurrences" + (${this.hass.localize( + "ui.panel.config.logs.detail.number_of_occurrences", + { + count: item.count, + } )})
` : ""} diff --git a/src/translations/en.json b/src/translations/en.json index 624a74bbdd..774adb572d 100644 --- a/src/translations/en.json +++ b/src/translations/en.json @@ -3162,7 +3162,7 @@ "documentation": "documentation", "issues": "issues", "first_occurred": "First occurred", - "occurrences": "occurrences", + "number_of_occurrences": "{count} {count, plural,\n one {occurrence}\n other {occurrences}\n}", "last_logged": "Last logged" } }, @@ -9320,7 +9320,6 @@ "documentation": "[%key:ui::panel::config::logs::detail::documentation%]", "issues": "[%key:ui::panel::config::logs::detail::issues%]", "first_occurred": "[%key:ui::panel::config::logs::detail::first_occurred%]", - "occurrences": "[%key:ui::panel::config::logs::detail::occurrences%]", "last_logged": "[%key:ui::panel::config::logs::detail::last_logged%]" } }