Input_boolean icon based on state

Hello,

I have input boolean customization which is not loading on Lovelance UI. I’ve tried everything without any luck. Any assistance will be highly appreciated

configuration.yaml

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
input_boolean: !include input_boolean.yaml
#switch: !include switch.yaml
homeassistant:
  customize: !include customize.yaml
  customize_glob:
    "*.*":
      custom_ui_state_card: custom-ui
customizer:
  custom_ui: local

customize.yaml

input_boolean.garbage_out:
  icon: mdi:marker-check
  templates:
    icon: if (state == ‘off’) return ‘mdi:bell’; else return ‘mdi:bell-off’;
    icon_color: if (state === ‘off’) return ‘rgb(251, 210, 41)’; else return ‘rgb(54,
      95, 140)’;


image
Thanks

All that code you posted is for custom-ui. Do you have that installed?

@petro,

Yes, I have it installed. I deployed script as mentioned on install article. Is there anything i could check to verify sucessful install?

Thanks

If you have everything installed then the problem is that your quotes type is incorrect. Notice how your quotes are fancy looking?

This means you copied and pasted from a poor forum post that didn’t properly format the code. Your quote types should be ' or ".

1 Like

@petro,

Thank you so much for your assistance. That was it. It won’t happen again in my life…

Best Regards

1 Like