Added integration name to System Options dialog (#3996)

* Added integration name to System Options dialog

* Passed integration name into translation string

* Translated integration name

* Added option for no translation
This commit is contained in:
springstan 2019-10-14 21:28:44 +02:00 committed by Bram Kragten
parent 9d3dfad98c
commit 59e4cdc62a
2 changed files with 16 additions and 4 deletions

View File

@ -60,7 +60,13 @@ class DialogConfigEntrySystemOptions extends LitElement {
@opened-changed="${this._openedChanged}" @opened-changed="${this._openedChanged}"
> >
<h2> <h2>
${this.hass.localize("ui.dialogs.config_entry_system_options.title")} ${this.hass.localize(
"ui.dialogs.config_entry_system_options.title",
"integration",
this.hass.localize(
`component.${this._params.entry.domain}.config.title`
) || this._params.entry.domain
)}
</h2> </h2>
<paper-dialog-scrollable> <paper-dialog-scrollable>
${this._loading ${this._loading
@ -89,7 +95,13 @@ class DialogConfigEntrySystemOptions extends LitElement {
</p> </p>
<p class="secondary"> <p class="secondary">
${this.hass.localize( ${this.hass.localize(
"ui.dialogs.config_entry_system_options.enable_new_entities_description" "ui.dialogs.config_entry_system_options.enable_new_entities_description",
"integration",
this.hass.localize(
`component.${
this._params.entry.domain
}.config.title`
) || this._params.entry.domain
)} )}
</p> </p>
</div> </div>

View File

@ -559,9 +559,9 @@
} }
}, },
"config_entry_system_options": { "config_entry_system_options": {
"title": "System Options", "title": "System Options for {integration}",
"enable_new_entities_label": "Enable newly added entities.", "enable_new_entities_label": "Enable newly added entities.",
"enable_new_entities_description": "If disabled, newly discovered entities will not be automatically added to Home Assistant." "enable_new_entities_description": "If disabled, newly discovered entities for {integration} will not be automatically added to Home Assistant."
}, },
"zha_device_info": { "zha_device_info": {
"manuf": "by {manufacturer}", "manuf": "by {manufacturer}",