Same here. Iām missing more examples as well. Iām in the same situation with deriving my stuff from the examples and some information why this and that is set in this and that way in this examples. Would be helpfull for such threads as well, becuase, then there would be less newbie questions.
Even with the great help from KTibow all over the thread, I do not understand such examples as hui-image$: in your case without having the html base for this.
In my case it is still not working with e.g. hui-grid-card$:
Thank you for explanaition.
Why to use .: | at the beginning of styles?
Isnāt
style:
.: |
the same as
style: |
If not, what is the difference?
Is there any documentation describing this syntax? Is it card-mod specific syntax? If so how do you know that unless described in card-mod documentation??
Theyāre exactly the same, except the first one lets you also apply styles to both inside the card, and inside shadow-roots. You canāt do that with style: |. Example:
style:
.: |
/* Stuff that applies to ha-card */
hui-image: |
/* Stuff that applies inside of hui-image */
so could you explain why this code works even the style definition doesnāt start with .:
To me it looks like separator which ends one string, allowing to start another part of style definition especially it itās goint to be css string (yaml dictionary doesnāt require this separator)
But itās my best guess. For unknown reason you are not answering my questions about pointing to docs which describe this syntax.
BTW the new syntax of shadow roots might be tricky in regard of indentation
This
multiple-entity-row:
$:
ha-entity-toggle:
$: |
translates to:
multiple-entity-row$:
ha-entity-toggle$: |
See, that intendation of ha-entity-toggle relativelly to mutliple-entity-row must remain unchanged!
Again, nothing which is can be found described enywhere.
In the second case only one element (ouf ot three) is fount to be styled. So itās not always interchangable.
It seems like the first syntax find all ha-entity-toggle and then goes into shadow-root, while the second one finds only the first DOM node matching the pattern
I just updated to 2020.12.0 in order to try to fix the recorder problems I have been having, but my header is no longer transparent using the following. I just wanted to see if anyone else is seeing the same thing before I open an issue on Github.