Help with yaml API documentation

Hello to all,
I have been getting my feet wet with Yaml but where is the documentation? I have been following Keith’s tutorial called ‘Fun with cutom:button-card’ and for the most part the examples work well, The problem is that I am unable to find the necessary documentation so that I might change the samples to suit my own needs. Here is some example code:

      icon:
        - opacity: 0.5
      name:
        - font-size: 0.65em
        - white-space: normal

Now I can see how changing the icon opacity value will affect the icon but since this is a ‘list’ value I suspect the the icon object has many parameters like ‘color’ or ‘size’. Also, I can see the name object ‘white-space’ has a value of ‘normal’, but where do I find the documentation that lists all the possible values for ‘white-space’?
I am hoping someone here can tell me where this information is located, otherwise I will be left with just coping examples. :thinking:

Thanks for you help
Sam

That’s a css property. w3schools is a good reference:
https://www.w3schools.com/cssref/pr_text_white-space.asp

1 Like

Thank you. I guess I missed the fact the yaml is using CSS for documentation, Very confusing. Makes me wonder why Home Assistant didn’t just go with CSS instead of yaml? :thinking:

In any case, thank you again. This will definitely help.

It isn’t.

You will find the majority of the yaml configuration options in the Home Assistant docs. It’s just that you asked about a single particular option for a custom integration that happens to be css.

Because they are completely different things with different applications.

For a basic yaml primer read this: YAML for Non-programmers