From 1dc68b72da6e229e31d9aab4c89db0249e3cbd6b Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Wed, 27 Jul 2022 12:30:22 -0700 Subject: [PATCH] Pass translation placeholders to repair title translations (#13289) --- src/panels/config/repairs/dialog-repairs-issue.ts | 3 ++- src/panels/config/repairs/ha-config-repairs.ts | 3 ++- src/translations/en.json | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/panels/config/repairs/dialog-repairs-issue.ts b/src/panels/config/repairs/dialog-repairs-issue.ts index 43c02074aa..9be79deb63 100644 --- a/src/panels/config/repairs/dialog-repairs-issue.ts +++ b/src/panels/config/repairs/dialog-repairs-issue.ts @@ -48,7 +48,8 @@ class DialogRepairsIssue extends LitElement { this.hass.localize( `component.${this._issue.domain}.issues.${ this._issue.translation_key || this._issue.issue_id - }.title` + }.title`, + this._issue.translation_placeholders || {} ) || this.hass!.localize("ui.panel.config.repairs.dialog.title") )} > diff --git a/src/panels/config/repairs/ha-config-repairs.ts b/src/panels/config/repairs/ha-config-repairs.ts index e516822113..e7fc178d3c 100644 --- a/src/panels/config/repairs/ha-config-repairs.ts +++ b/src/panels/config/repairs/ha-config-repairs.ts @@ -66,7 +66,8 @@ class HaConfigRepairs extends LitElement { >${this.hass.localize( `component.${issue.domain}.issues.${ issue.translation_key || issue.issue_id - }.title` + }.title`, + issue.translation_placeholders || {} )} diff --git a/src/translations/en.json b/src/translations/en.json index 117feb5073..e20154fb45 100755 --- a/src/translations/en.json +++ b/src/translations/en.json @@ -577,7 +577,7 @@ "title": "Media Management", "manage": "Manage", "no_items": "No media items found", - "folders_not_supported": "Folders can not be managed via the UI.", + "folders_not_supported": "Folders cannot be managed via the UI.", "highlight_button": "Click here to upload your first media", "upload_failed": "Upload failed: {reason}", "add_media": "Add Media", @@ -1246,7 +1246,7 @@ "learn": "Learn more", "ignore": "Ignore", "unignore": "Unignore", - "alert_not_fixable": "We can not repair this issue for you.", + "alert_not_fixable": "We cannot repair this issue for you.", "breaks_in_version": "This will break in version {version}. Please fix this issue before upgrading.", "ignored_in_version_short": "Ignored in version {version}", "ignored_in_version": "This issue was ignored in version {version}."