Make voice assistant translatable in dialog (#17163)

This commit is contained in:
Simon Lamon 2023-07-04 20:42:36 +02:00 committed by GitHub
parent 7584404d31
commit 9cf8ec4cbb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 2 deletions

View File

@ -798,7 +798,11 @@ export class EntityRegistrySettingsEditor extends LitElement {
.disabled=${this.disabled}
@click=${this._handleVoiceAssistantsClicked}
>
<span>Voice assistants</span>
<span
>${this.hass.localize(
"ui.dialogs.entity_registry.editor.voice_assistants"
)}</span
>
<span slot="secondary">
${this.entry.aliases.length
? [...this.entry.aliases]
@ -1320,7 +1324,10 @@ export class EntityRegistrySettingsEditor extends LitElement {
}
private _handleVoiceAssistantsClicked() {
showVoiceAssistantsView(this, "Voice assistants");
showVoiceAssistantsView(
this,
this.hass.localize("ui.dialogs.entity_registry.editor.voice_assistants")
);
}
private async _showOptionsFlow() {

View File

@ -1101,6 +1101,7 @@
"stream_orientation_7": "Rotate right and flip",
"stream_orientation_8": "Rotate right"
},
"voice_assistants": "[%key:ui::panel::config::dashboard::voice_assistants::main%]",
"no_aliases": "Configure aliases and expose settings for voice assistants"
}
},