Code Monkey home page Code Monkey logo

Comments (4)

viking2010 avatar viking2010 commented on June 21, 2024 1

Thanks for the feedback. I'll give the conditional card and the decluttering card another shot. Appreciate the comments.

from uptime-card.

dylandoamaral avatar dylandoamaral commented on June 21, 2024

Hi, I am not really sure to understand your feature request.

The card alone works for one sensor, not for a group of sensors. So you want the card to be printed only if the sensor is down ?

from uptime-card.

viking2010 avatar viking2010 commented on June 21, 2024

Hi, thanks for replying. I'll try to clarify a little more.

I use the uptime card for multiple sensors within a vertical stack like this:
image

Whilst it may not be necessary, here's the yaml code for the above anyway:

type: vertical-stack
title: WiFi Plugs - Other Areas
cards:
  - type: custom:uptime-card
    status_adaptive_color: true
    color:
      icon: white
      title: white
      status: white
      tooltip: white
      half: '#ffff00'
      ko: '#ff0000'
    show:
      footer: true
      header: true
      title: true
      status: true
      timeline: true
      average: true
    alias:
      ok: Up
      ko: Down
    bar:
      height: 10
      round: 1
      spacing: 5
      amount: 15
    update_interval: 60
    icon_adaptive_color: true
    title_adaptive_color: false
    init:
      duration: 1
      animation: slide
    tooltip:
      hour24: true
    tap_action:
      action: more-info
    alignment:
      header: spaced
      status: spaced
      icon_first: false
    blink:
      target: status
      effect: fade
      speed: 10
    hours_to_show: 0.25
    icon: mdi:power-socket-uk
    title_template: Power Strip - Bedroom 1
    entity: binary_sensor.wifi_power_strip_bedroom1
  - type: custom:uptime-card
    icon: mdi:power-socket-uk
    status_adaptive_color: true
    color:
      icon: white
      title: white
      status: white
      tooltip: white
      half: '#ffff00'
      ko: '#ff0000'
    show:
      footer: true
      header: true
      title: true
      status: true
      timeline: true
      average: true
    alias:
      ok: Up
      ko: Down
    bar:
      height: 10
      round: 1
      spacing: 5
      amount: 15
    update_interval: 60
    icon_adaptive_color: true
    title_adaptive_color: false
    init:
      duration: 1
      animation: raise
    tooltip:
      hour24: true
    tap_action:
      action: more-info
    alignment:
      header: spaced
      status: spaced
      icon_first: false
    blink:
      target: status
      effect: fade
      speed: 10
    hours_to_show: 0.25
    entity: binary_sensor.wifi_plug_speaker_light
    title_template: LEDs & WiFi Speaker
  - type: custom:uptime-card
    status_adaptive_color: true
    color:
      icon: white
      title: white
      status: white
      tooltip: white
      half: '#ffff00'
      ko: '#ff0000'
    show:
      footer: true
      header: true
      title: true
      status: true
      timeline: true
      average: true
    alias:
      ok: Up
      ko: Down
    bar:
      height: 10
      round: 1
      spacing: 5
      amount: 15
    update_interval: 60
    icon_adaptive_color: true
    title_adaptive_color: false
    init:
      duration: 1
      animation: slide
    tooltip:
      hour24: true
    tap_action:
      action: more-info
    alignment:
      header: spaced
      status: spaced
      icon_first: false
    blink:
      target: status
      effect: fade
      speed: 10
    hours_to_show: 0.25
    entity: binary_sensor.wifi_plug_fridge
    icon: mdi:power-socket-uk
    title_template: Fridge
  - type: custom:uptime-card
    status_adaptive_color: true
    color:
      icon: white
      title: white
      status: white
      tooltip: white
      half: '#ffff00'
      ko: '#ff0000'
    show:
      footer: true
      header: true
      title: true
      status: true
      timeline: true
      average: true
    alias:
      ok: Up
      ko: Down
    bar:
      height: 10
      round: 1
      spacing: 5
      amount: 15
    update_interval: 60
    icon_adaptive_color: true
    title_adaptive_color: false
    init:
      duration: 1
      animation: slide
    tooltip:
      hour24: true
    tap_action:
      action: more-info
    alignment:
      header: spaced
      status: spaced
      icon_first: false
    blink:
      target: status
      effect: fade
      speed: 10
    hours_to_show: 0.25
    icon: mdi:power-socket-uk
    entity: binary_sensor.wifi_plug_spare_plug
    title_template: Spare Plug

I use 7 vertical stack cards, like the one above, with 35 different binary sensors monitoring devices on my network. So it can get a little cluttered seeing everything that's 'green'. So what I thought would be a nice addition, if it were possible, would be to add some sort of filter and only display the binary sensors when they are offline.....eg a "hide sensor if status value is {enter value here}". This way I would only see the problems on the network and not everything in one go where I then have to scroll through a number of devices. It's pure laziness on my part lol!

I've tried playing with various filter or conditional cards but they don't really do what I want them to do. It doesn't matter if it isn't something that can be done, I was just throwing the idea out there really. It's been of great value just having the uptime card. It's saved me looking to purchase a network monitoring solution for my own home network!

Cheers

from uptime-card.

dylandoamaral avatar dylandoamaral commented on June 21, 2024

I really think that https://www.home-assistant.io/dashboards/conditional/ is exactly what you are looking for. You said that it didn't work for you but why ?

Therefore, since you are combining two cards and you are repeating yourself a lot, I suggest you to use https://github.com/custom-cards/decluttering-card.

from uptime-card.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.