Alternative to custom:fold-entity-row?

Hi everybody,

I use custom:fold-entity-row to, well, fold certain entities so that I can easily access a large number of those, but hide them when they are not needed. Here is a short screen capture of the part in question.

As you can see, the dashes / separators they use are larger than the rest of the column. This is fine on the desktop (as in the video), but on the android app it causes the entire lovelace page to be scrollable sideways when the fold is open.

Is there a good alternative I could use to

  • tidy up my lovelace by “hiding” these entities in separate cards until needed
  • do so without having to create additional entities (see below)

Previously, I used conditional-card to do this. I would create input_boolean.lovelace_helper_motion, then use conditional-card to display contents only when I’d turn on that input_boolean; which worked fine, but required me to create these helpers manually whenever I needed another card like this.

I also thought about using custom:lovelace-state-switch for this, but that would also require me to manually do this. I could create an input_select entity containing climate, motion, doors & windows, and use lovelace-state-switch to display contents according to what’s selected via input_select… but again, if I wanted to add to this, I’d have to modify the input_select entitty so that whatever I add is even a choice.

(it’s not that big of a deal, but perhaps there is a different approach that might work without customly created entities)

Thank you in advance for your ideas :slight_smile:

The separators should not extend outside the card. None of mine do. Can you post your config for the card?

Screenshot_2021-03-11 Overview - Home Assistant

2 Likes

You could also modify the card with custom mod card.


Just an example from my system with no separator.

Thank you. Then it is hopefully just some misconfiguration. Below is my code.

type: grid
cards:
  - type: 'custom:button-text-card'
    large: true
    font_color: '#000'
    background_color: '#E6F1FF'
    title: VIP
    icon: 'mdi:crown'
  - type: vertical-stack
    cards:
      - type: 'custom:fold-entity-row'
        head:
          type: section
          label: Fenster & TĂĽren
        entities:
          - type: 'custom:auto-entities'
            card:
              type: glance
              state_color: true
            filter:
              include:
                - entity_id: '*tuer_contact'
                  state: 'on'
                  options:
                    show_last_changed: true
                - entity_id: '*fenster_contact'
                  state: 'on'
                  options:
                    show_last_changed: true
            sort:
              method: last_changed
  - type: 'custom:fold-entity-row'
    head:
      type: section
      label: Heizungen
    entities:
      - type: 'custom:auto-entities'
        card:
          type: entities
          title: Heizungen
          state_color: true
        filter:
          include:
            - entity_id: climate.*
              options:
                secondary_info: last-changed
          exclude:
            - entity_id: '*158d*'
        sort:
          method: name
  - type: 'custom:fold-entity-row'
    head:
      type: section
      label: Motion
    entities:
      - type: 'custom:auto-entities'
        card:
          type: glance
          state_color: true
        filter:
          include:
            - entity_id: '*motion_occupancy'
              state: 'on'
              options:
                show_last_changed: true
            - entity_id: '*flur_*occupancy'
              state: 'on'
              options:
                show_last_changed: true
        sort:
          method: name
columns: 1
square: false

1 Like

Your vertical stack only has one fold-entity-row card in it. The next two aren’t indented far enough. They are on the same level as the stack (which probably isn’t required).

Hi, I liked the card you made, if and how to put the icon if there is a number in each category, there is a picture that I have attached, I would be happy to receive help

image