Update delete resource dialog (#13764)

This commit is contained in:
Paul Bottein 2022-09-16 16:38:29 +02:00 committed by GitHub
parent 614c1574ca
commit 3b103619ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 3 deletions

View File

@ -157,9 +157,16 @@ export class HaConfigLovelaceRescources extends LitElement {
removeResource: async () => {
if (
!(await showConfirmationDialog(this, {
text: this.hass!.localize(
"ui.panel.config.lovelace.resources.confirm_delete"
title: this.hass!.localize(
"ui.panel.config.lovelace.resources.confirm_delete_title"
),
text: this.hass!.localize(
"ui.panel.config.lovelace.resources.confirm_delete_text",
{ url: resource!.url }
),
dismissText: this.hass!.localize("ui.common.cancel"),
confirmText: this.hass!.localize("ui.common.delete"),
destructive: true,
}))
) {
return false;

View File

@ -1761,7 +1761,8 @@
"no_resources": "No resources",
"add_resource": "Add resource"
},
"confirm_delete": "Are you sure you want to delete this resource?",
"confirm_delete_title": "Delete resource?",
"confirm_delete_text": "{url} will be permanently deleted.",
"refresh_header": "Do you want to refresh?",
"refresh_body": "You have to refresh the page to complete the removal. Do you want to refresh now?",
"cant_edit_yaml": "You are using your dashboard in YAML mode, therefore you cannot manage your resources through the UI. Manage them in configuration.yaml.",