From 8902328b3051e6ef39fa1fb1aa0c72f5e5c96e59 Mon Sep 17 00:00:00 2001 From: Piotr Dobrowolski Date: Fri, 26 Oct 2018 10:06:17 +0200 Subject: [PATCH] Allow custom UI on "card" entities (#1824) This will always render entities with `custom_ui_state_card` attribute set in `entities` state card. Fixes custom UI on `media_player` objects. --- src/components/ha-cards.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/ha-cards.js b/src/components/ha-cards.js index 8a454756da..0a89dc750f 100644 --- a/src/components/ha-cards.js +++ b/src/components/ha-cards.js @@ -251,7 +251,10 @@ class HaCards extends PolymerElement { entities.forEach((entity) => { const domain = computeStateDomain(entity); - if (domain in DOMAINS_WITH_CARD) { + if ( + domain in DOMAINS_WITH_CARD && + !entity.attributes.custom_ui_state_card + ) { owncard.push(entity); size += DOMAINS_WITH_CARD[domain]; } else {