Custom:fold-entity-row without entity icon

Hi,

could someone help me how to remove the icon (and its space)? Thanks

imagen

type: custom:fold-entity-row
    head:
      entity: sensor.warehouse
      name: Warehouse
    open: false
    state_color: true
    entities:
      - entity: light.light1
      - entity: light.light2
      - entity: light.light3

This should be enough to do it!

type: custom:fold-entity-row
    head:
      entity: sensor.warehouse
      icon: none # Added this line
      name: Warehouse
      layout: horizontal
    open: false
    state_color: true
    entities:
      - entity: light.light1
      - entity: light.light2
      - entity: light.light3

PS: This is a much more graceful solution than custom:expander-card, which is what I was using - will transition to this now!

1 Like

Yes, I found this option.

I didn’t express myself well, I meant without an icon and without the space it occupies, moving the text to the left.

This option does not belong to fold-entity-row.

And this is misplaced:

    state_color: true

card-mod thread

1 Like

right, but it isn’t important (copy/paste error)

Without this the card not show states (checked)

1 Like

Ah sorry, I see!

Well in that case, @Ildar_Gabdullin’s amazing posts will help you:

Go there and search for Hiding an icon or a state:

Youll find code like this:

type: entities
entities:
  - entity: sun.sun
    card_mod:
      style:
        hui-generic-entity-row:
          $: |
            state-badge {
              display: none;
            }

card-mod is super useful. I have this post bookmarked whenever I am doing something outside of normal Home Assistant’s design rules:

1 Like

Actually, this is not the BEST way - may cause decreasing a row’s height.
Depends on a particular card…

1 Like

What would you recommend then for an entities card?

Same) check it 1st, and then decide if you need another way.

You are right.
Although “state_color” is not mentioned in Docs and was supposed to be used ether:
— in “group_config”;
— in “head”;
— in entities for some entity/entities,
it is present in a source code & may be defined on a “root” level of the card.

1 Like

Thanks to both of you, this is the solution:

    type: custom:fold-entity-row
    head:
      entity: sensor.warehouse
      name: Warehouse
      card_mod:
        style:
          hui-generic-entity-row $: |
            state-badge {
              display: none;
            }
    open: false
    state_color: true
    entities:
      - entity: light.light1
      - entity: light.light2
      - entity: light.light3
1 Like