thomasloven / lovelace-card-mod

🔹 Add CSS styles to (almost) any lovelace card
MIT License
1.13k stars 168 forks source link

Allow for styling of future elements #290

Closed jdtechsol closed 9 months ago

jdtechsol commented 1 year ago

Example: I can include styling for but it will be ignored since the element does not exist until it is shown. Can we please allow for styling of future elements?

ildar170975 commented 1 year ago

Please give a reproducible example.

AINER commented 1 year ago

Maybe I'm wrong, but it seems to me that they meant preliminary application of styles. Because when popups open or page reloads, styles are applied in real time, resulting in annoying jittery elements

https://github.com/thomasloven/lovelace-card-mod/assets/101467664/a356bcd1-3b3f-454c-b504-2f53a5fb7331

ildar170975 commented 1 year ago

resulting in annoying jittery elements

This is called "transition" and an expected behaviour since you have not disabled it.

thomasloven commented 9 months ago

It is possible. The DOM Navigation section of the readme explains how.