-
Notifications
You must be signed in to change notification settings - Fork 3
card-mod support #10
Copy link
Copy link
Open
Description
Hi, with card-mod v4.x, tailwind-template-card will no longer work due to changes in card-mod which do patch application at the hui-card level rather than ha-card. This means that card-mod is applied to shadowRoot now, which is always replaced with this card. There are other custom cards that also take this approach, but since they are Lit based, card-mod can prepend itself and this still works.
One method to make this card always support card-mod is to apply directly using code like below on render. If this makes sense I can test and submit a PR.
customElements.whenDefined("card-mod").then(() => {
(customElements.get("card-mod") as any)?.applyToElement?.(
this,
"card",
this._config.card_mod
true,
"type-custom-tailwindcss-template-card"
);
});
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels