From f53eea81c493377968f2a5383830165c4d3c1d21 Mon Sep 17 00:00:00 2001
From: springstan <46536646+springstan@users.noreply.github.com>
Date: Fri, 1 Nov 2019 16:12:49 +0100
Subject: [PATCH] Translated a bunch of strings (#4137)
* Translated customization page
- added translation key-value pairs to en.json
- translated form-customize, customize-icon and its key-value
* Translated mutliple pages:
- devices
- entity-registry
- config-entry
- dashboard -> hint to advanced mode toggle
* Translated custom panel confirm message
* Added translation for no entries in logbook
* Updated translation keys, tested and removed ha-types file translations
* Removed setting an if to true for testing
* Use template literal instead of string concatenation
---
.../config/customize/ha-form-customize.js | 25 +++++-----
.../config/dashboard/ha-config-dashboard.js | 4 +-
.../config/devices/ha-config-device-page.ts | 24 +++++++---
.../config/devices/ha-devices-data-table.ts | 24 +++++++---
.../dialog-entity-registry-detail.ts | 4 +-
.../config-entry/ha-config-entry-page.ts | 6 ++-
src/panels/custom/ha-panel-custom.ts | 20 ++++++--
src/panels/logbook/ha-logbook.js | 5 +-
src/translations/en.json | 46 +++++++++++++++++--
9 files changed, 119 insertions(+), 39 deletions(-)
diff --git a/src/panels/config/customize/ha-form-customize.js b/src/panels/config/customize/ha-form-customize.js
index 7b1bca7a49..c83cbfb152 100644
--- a/src/panels/config/customize/ha-form-customize.js
+++ b/src/panels/config/customize/ha-form-customize.js
@@ -3,13 +3,14 @@ import "@polymer/paper-item/paper-item";
import "@polymer/paper-listbox/paper-listbox";
import { html } from "@polymer/polymer/lib/utils/html-tag";
import { PolymerElement } from "@polymer/polymer/polymer-element";
+import LocalizeMixin from "../../../mixins/localize-mixin";
import hassAttributeUtil from "../../../util/hass-attributes-util";
import "./ha-form-customize-attributes";
import { computeStateDomain } from "../../../common/entity/compute_state_domain";
-class HaFormCustomize extends PolymerElement {
+class HaFormCustomize extends LocalizeMixin(PolymerElement) {
static get template() {
return html`
@@ -55,7 +56,7 @@ class HaLogbook extends EventsMixin(PolymerElement) {
- No logbook entries found.
+ [[localize('ui.panel.logbook.entries_not_found')]]
diff --git a/src/translations/en.json b/src/translations/en.json
index 4010000729..e90789c50f 100755
--- a/src/translations/en.json
+++ b/src/translations/en.json
@@ -737,7 +737,19 @@
"picker": {
"header": "Customization",
"introduction": "Tweak per-entity attributes. Added/edited customizations will take effect immediately. Removed customizations will take effect when the entity is updated."
- }
+ },
+ "warning": {
+ "include_sentence": "It seems that your configuration.yaml doesn't properly",
+ "include_link": "include customize.yaml",
+ "not_applied": "Changes made here are written in it, but will not be applied after a configuration reload unless the include is in place."
+ },
+ "attributes_customize": "The following attributes are already set in customize.yaml",
+ "attributes_outside": "The following attributes are customized from outside of customize.yaml",
+ "different_include": "Possibly via a domain, a glob or a different include.",
+ "attributes_set": "The following attributes of the entity are set programmatically.",
+ "attributes_override": "You can override them if you like.",
+ "attributes_not_set": "The following attributes weren't set. Set them if you like.",
+ "pick_attribute": "Pick an attribute to override"
},
"automation": {
"caption": "Automation",
@@ -1157,6 +1169,20 @@
"actions": {
"caption": "When something is triggered..."
}
+ },
+ "device_not_found": "Device not found.",
+ "info": "Device info",
+ "details": "Here are all the details of your device.",
+ "entities": "Entities",
+ "automations": "Automations",
+ "confirm_rename_entity_ids": "Do you also want to rename the entity id's of your entities?",
+ "data_table": {
+ "device": "Device",
+ "manufacturer": "Manufacturer",
+ "model": "Model",
+ "area": "Area",
+ "integration": "Integration",
+ "battery": "Battery"
}
},
"entity_registry": {
@@ -1184,7 +1210,8 @@
"delete": "DELETE",
"confirm_delete": "Are you sure you want to delete this entry?",
"confirm_delete2": "Deleting an entry will not remove the entity from Home Assistant. To do this, you will need to remove the integration '{platform}' from Home Assistant.",
- "update": "UPDATE"
+ "update": "UPDATE",
+ "note": "Note: this might not work yet with all integrations."
}
},
"person": {
@@ -1224,6 +1251,7 @@
"home_assistant_website": "Home Assistant website",
"configure": "Configure",
"none": "Nothing configured yet",
+ "integration_not_found": "Integration not found.",
"config_entry": {
"settings_button": "Edit settings for {integration}",
"system_options_button": "System options for {integration}",
@@ -1389,7 +1417,8 @@
},
"logbook": {
"showing_entries": "[%key:ui::panel::history::showing_entries%]",
- "period": "Period"
+ "period": "Period",
+ "entries_not_found": "No logbook entries found."
},
"lovelace": {
"cards": {
@@ -1686,7 +1715,9 @@
},
"advanced_mode": {
"title": "Advanced Mode",
- "description": "Home Assistant hides advanced features and options by default. You can make these features accessible by checking this toggle. This is a user-specific setting and does not impact other users using Home Assistant."
+ "description": "Home Assistant hides advanced features and options by default. You can make these features accessible by checking this toggle. This is a user-specific setting and does not impact other users using Home Assistant.",
+ "hint_enable": "Missing config options? Enable advanced mode on",
+ "link_profile_page": "your profile page"
},
"refresh_tokens": {
"header": "Refresh Tokens",
@@ -1995,6 +2026,13 @@
"more_integrations": "More",
"finish": "Finish"
}
+ },
+ "custom": {
+ "external_panel": {
+ "question_trust": "Do you trust the external panel {name} at {link}?",
+ "complete_access": "It will have access to all data in Home Assistant.",
+ "hide_message": "Check docs for the panel_custom component to hide this message"
+ }
}
}
}