I have an input_select which is set based on time of year(holidays). Based on this, I am trying to dynamically navigate to the appropriate page and also display the entity state as the name in a button card(YAML below). Admittedly I thought it should be simple, but I can’t figure out the YAML. I’ve tried multiple versions of return/variable/states, it seems so obvious but I’m missing something.
1. Code should be posted formatted. You can see yourself that it lost indents which are crucial in yaml.
2. You are trying to use templates in a button card - but templates are not supported here. Only a few standard card support templates. Consider using a custom card which does support templating (config-template-card, button-card, …).
Yes, forgive me I was trying to copy and paste in a hurry and didn’t format it. I just got back to this, I had tried a custom card before but I can’t get the template to spit out the state of the entity, it keeps it as full text and displays exactly what I put in there or tries to navigate to that path. It has to be something simple but I have tried multiple iterations and the closest I get is an error stating “states is not part of return”
Thank you for explanation. I should have known I was attempting to build a string link but that just wasn’t clicking. Appreciate the help, it is working as expected with your code.
If I could move the topic I would, I should have done so when switched to the custom button card.