How do I get Lovelace to just show the actual state for a cover entity?

I have two Meross garage door sensors…the Meross integration works fine but the entity shows as an up/down arrow in lovelace. If the door is down, the arrow pointing up is dark and selectable and it opens the door…so everything works.

I would actually like to show the state of the cover (the word OPEN or CLOSED) in my lovelace view…not the arrow which seem to be the default for cover entities…

How do I do it???

I worked around this by setting up a sensor in YAML then referencing that on my Lovelace entities cards:

  - platform: template
    sensors:
      garage_door_status:
        friendly_name: 'Garage Door Status'
        value_template: >-
          {% if is_state('cover.garagedoor', 'open') %}
            Open
          {% elif is_state('cover.garagedoor', 'closed') %}
            Closed
          {% elif is_state('cover.garagedoor', 'opening') %}
            Opening
          {% elif is_state('cover.garagedoor', 'closing') %}
            Closing
          {% else %}
            Unknown
          {% endif %}

        icon_template: >-
          {% if is_state('cover.garagedoor', 'closed') %}
            mdi:garage
          {% else %}
            mdi:garage-open
          {% endif %}

You can replace all that with this:

  - platform: template
    sensors:
      garage_door_status:
        friendly_name: 'Garage Door Status'
        value_template: "{{ states('cover.garagedoor')|title }}"
        icon_template: >
          {% if is_state('cover.garagedoor', 'closed') %}
            mdi:garage
          {% else %}
            mdi:garage-open
          {% endif %}
2 Likes

Was searching exactly for this (Athom garage door open with ESPHome), found this page and wihile reading I realized you can just use a conditional card by including the state in the name of the printed entity.

- type: conditional
  conditions:
    - entity: cover.garage_door_opener
      state: "open"
  card:
    type: entities
    entities:
      - entity: cover.garage_door_opener
        name: 'Garage Door: Open'

- type: conditional
  conditions:
    - entity: cover.garage_door_opener
      state: "closed"
  card:
    type: entities
    entities:
      - entity: cover.garage_door_opener
        name: 'Garage Door: Closed'

- type: conditional
  conditions:
    - entity: cover.garage_door_opener
      state: "unknown"
  card:
    type: entities
    entities:
      - entity: cover.garage_door_opener
        name: 'Garage Door: Unknown'