Skip to content

Card does not appear when dashboard is shown #119

Open
@CoryAlbrecht

Description

@CoryAlbrecht

In a web browser (Chrome, Ubuntu) the card does not appear when the dashboard is loaded but will appear on a manual page refresh (e.g. Ctrl+R). If you go to another tab on the same dashboard and return, it is gone again and you have to refresh to get it back.

In the companion app (Samsung Galaxy Tab S6 Lite, Google Pixel 8) the card does not appear and the app cannot be refreshed by swiping down.

I have multiple cards like this to show if there are any active alarms or timers on any of the Google/Nest Minis throughout my home, and they all act like this.

type: custom:state-switch
entity: >-
  {% set nt = state_attr('sensor.bathroom_mini_alarms', 'alarms')|count %} {% if
  (nt >= 1) and (nt <= 3) %}
    {{state_attr('sensor.bathroom_mini_alarms', 'alarms')|count}}
  {% elif nt >= 4 %}3{% endif %}
tap_action:
  action: more-info
states:
  '1':
    type: custom:timer-bar-card
    name: Active Alarms
    entities:
      - entity: sensor.bathroom_mini_alarm_1
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_1
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_1
                  alarm_device: sensor.bathroom_mini_alarms
              styles:
                button:
                  margin: 0px 0px 0px 8px
  '2':
    type: custom:timer-bar-card
    name: Active Alarms
    entities:
      - entity: sensor.bathroom_mini_alarm_1
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_1
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_1
                  alarm_device: sensor.bathroom_mini_alarms
              styles:
                button:
                  margin: 0px 0px 0px 8px
      - entity: sensor.bathroom_mini_alarm_2
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_2
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_2
                  alarm_device: sensor.bathroom_mini_alarms
              styles:
                button:
                  margin: 0px 0px 0px 8px
  '3':
    type: custom:timer-bar-card
    name: Active Alarms
    entities:
      - entity: sensor.bathroom_mini_alarm_1
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_1
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_1
                  alarm_device: sensor.bathroom_mini_alarms
              styles:
                button:
                  margin: 0px 0px 0px 8px
      - entity: sensor.bathroom_mini_alarm_2
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_2
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_2
                  alarm_device: sensor.bathroom_mini_alarms
              styles:
                button:
                  margin: 0px 0px 0px 8px
      - entity: sensor.bathroom_mini_alarm_3
        extend_paper_buttons_row:
          position: right
          entity: sensor.bathroom_mini_alarm_3
          buttons:
            - layout: icon
              icon: mdi:delete
              tap_action:
                confirmation:
                  text: Do you want to delete the alarm? (Cannot be undone.)
                action: call-service
                service: script.delete_google_home_alarm
                service_data:
                  alarm_id: sensor.bathroom_mini_alarm_3
                  alarm_device: sensor.bathroom_mini_alarms
                styles: null
                button:
                  margin: 0px 0px 0px 8px

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions