šŸ’” Lovelace: RGB light card

Hey!

Is there any way to hide the switch from the light card?
I setup to turn on/off with a tap on the card, so the switch is not needed.

Thanks! :slight_smile:

The light card doesnā€™t have a switch :man_shrugging:

However, if you see a switch on your entities card, adding the following may help:

type: entities
show_header_toggle: false # <= Add this line

If it doesnā€™t solve your problem, please post a screenshot so we can understand instead of guessing.

Hey! :slight_smile:
Thanks, but I want to hide this:

image

Thanks!

Strungling to re-enable what I have in shelly4hass integration until white channel was workingā€¦

After white channel was not supported under shelly4hass I migrated all shelly devices to native shelly integration.

So now I need some help.

Can somebody tell me how to re-enable some functions which are not working for me anymoreā€¦

So look in lovelace is like that:
image

The problem is that when I try to edit white channel I actually edit

So how to edit white channel under lovelaceā€¦ also editing color brigtness under lovelace would be very goodā€¦

Current lovelace code:

entities:
  - entity: light.shelly_rgbw2_dnevna
  - entity: sensor.shelly_rgbw2_dnevna_current_consumption
  - entity: sensor.shelly_rgbw2_dnevna_total_consumption
    name: Skupaj poraba
  - entity: sensor.variable_obvestilo_rgbw2_moc_svetlobe
  - entity: light.shelly_rgbw2_dnevna
    full_row: true
    step: 1
    type: custom:slider-entity-row
  - entity: sensor.variable_obvestilo_rgbw2_white
  - entity: light.shelly_rgbw2_dnevna
    full_row: true
    step: 1
    type: custom:slider-entity-row
    data:
      transition: 5
      white: 255
    target:
      device_id: 58c1420262940b82068d14666947731d
  - colors:
      - brightness: 1
        effect: 0
        icon_color: '#c0c0c0'
        rgb_color:
          - 255
          - 255
          - 255
        transition: 1
      - brightness: 220
        effect: 0
        icon_color: '#990000'
        rgb_color:
          - 255
          - 0
          - 0
        transition: 1
      - brightness: 220
        effect: 0
        icon_color: '#009900'
        rgb_color:
          - 0
          - 255
          - 0
        transition: 1
      - brightness: 220
        effect: 0
        icon_color: '#999900'
        rgb_color:
          - 255
          - 255
          - 0
        transition: 1
      - brightness: 220
        effect: 0
        icon_color: '#009999'
        rgb_color:
          - 0
          - 255
          - 255
        transition: 1
      - brightness: 220
        effect: 2
        icon_color: center/120% url('/local/images/rainbow.png')
        transition: 1
      - brightness: 1
        effect: 0
        icon_color: center/95% url('/local/images/night_mode.png')
        transition: 1
    entity: light.shelly_rgbw2_dnevna
    justify: between
    type: custom:rgb-light-card
show_header_toggle: false
title: LED trak
type: entities

Options for controller:

Did you ever figure out how to do this?

This card is awesome, but it would be even cooler if I could call the color picker wheel/color temp slider from one of the ā€œcolorā€ buttons.

Iā€™ve seen a few people ask about this but no actual answers.

For anyone want combine call service and static colors,
ā€œNote that you can mix lights and service calls in the same cardā€ here

image

type: entities
entities:
  - type: custom:rgb-light-card
    entity: light.id
    colors:
      - rgb_color:
          - 234
          - 136
          - 140
        brightness: 255
        transition: 1
        icon_color: '#10b2ec'
      - type: call-service
        service: script.turn_on
        service_data:
          entity_id: script.abc
        icon_color: '#90b2ec'
1 Like

I was trying to use this light card but it seems like my

hide_when_off: true

is not working:

    entities:
      - entity: light.e27_living_room
      - type: custom:rgb-light-card
        entity: light.e27_living_room
        hide_when_off: true
        justify: center
        colors:
          - rgb_color:
              - 234
              - 136
              - 140
            brightness: 255
            transition: 1
          - rgb_color:
              - 251
              - 180
              - 139
            brightness: 200
            transition: 1
          - rgb_color:
              - 136
              - 198
              - 237
            brightness: 150
            transition: 1

gives
grafik
while

hide_when_off: false

seems to work
grafik

@kingisch Can you please go to the templates section of the developer tools, and tell me what is the result of this template while your light is turned off ?

{{ states['light.e27_living_room'].state }} 

Thanks

sure, it is ā€œoffā€
Thank you!

Edit: I found the mistake. I accidentally added two different entities in the entity section :man_facepalming:
Sorry for that!

Iā€™m very much enjoying your card. Thanks again for making it.

Any possibility of a future version supporting templates?

Hey!
Did you manage to find a way to do this? Iā€™m trying to call 2 services - Stop_dynamic_scenes and Light.Turn_on.
However, i canā€™t seem to find a way to do that. I have gotten this far, but every combination i try to do to call different services with the same click, it just calls one of them and not the other one
Ideally, it would call the ā€œStop_dynamic_scenesā€ for all the buttons that i have in that row

type: custom:rgb-light-card
entity: light.office_floor
label_size: 11
size: 40
justify: center
colors:
  - type: call-service
    service: scene_presets.stop_dynamic_scenes_for_targets
    service_data:
      targets:
        entity_id: light.office_floor
    color_temp_kelvin: 6410
    brightness: 255
    icon_color: 'linear-gradient(15deg, #fffcf7, #cae9f3)'
    label: Energise

Can you put the two service calls in a script and then call that?

Hey!
I could, however, i have multiple colours set up in the UI. Having a script for each of them would clug up the system. Is there maybe a way to pass the service call data to the script, run the ā€œStop_dynamic_scenesā€, and then apply the service call for light_turn.on?

You donā€™t have to create a new script for each color, just create one script that accepts variables instead