Picture elements card editor: Add title to secondary description for custom cards (#22908)

This commit is contained in:
Yosi Levy 2024-11-20 16:45:29 +02:00 committed by GitHub
parent ac6e61b9b8
commit 7996f4e0b2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -166,7 +166,7 @@ export class HuiPictureElementsCardRowEditor extends LitElement {
`${((element as ConditionalElementConfig).elements || []).length.toString()} ${this.hass?.localize("ui.panel.lovelace.editor.card.picture-elements.elements")}`
);
}
return "Unknown type";
return element.title ?? "Unknown type";
}
private async _addElement(ev): Promise<void> {