šŸŒ» Lovelace UI ā€¢ Minimalist

my entity fot the weather is :

cards:
                - type: 'custom:button-card'
                  template: custom_card_welcome_scenes
                  variables:
                    ulm_custom_card_paddy_welcome_time: sensor.time
                    custom_card_paddy_welcome_with_weather: weather.city ###(for example)

I tried with

sensor.city_temperature

But itā€™s a same thing

Hello,

Canā€™t find the answer anywhereā€¦ but how do i create a people count sensor ? :confused: I want to add the chip, but canā€™t find any solution. I want to add my wife and if, i have the devices tracker but i donā€™t know how to add a customer sensor with the right valuesā€¦

Thanks for your help

This thread is just becoming quite unreadable as different questions are getting mixed up :smiley:

You can create a template sensor for counting persons for example like this:

- platform: template
    sensors:
      persons_at_home:
        friendly_name: 'Persons at Home'
        value_template: >
          {{ [states.person.PERSON1, states.person.PERSON2]
              | selectattr('state', '==', 'home') | list | count }}

Who controls the community page, is there a way to get a subforum created for this? 1,000 replies are a lot to read and search through to figure things out.

1 Like

Hi,

Iā€™ve created a card adapted from the Simple thermostat card (above), to work with my heat pump system, as the current thermostat cards donā€™t handle all the possibilities of the HVAC component.

The bottom row uses the widget icon component. For now, Iā€™ve hard coded the colors of the widgets, but Iā€™d like to match the above by only displaying color when the mode is selected. Iā€™m unsure of how to handle it as the widget does not have state, as far as I know.

Any hint would be appreciated, thanks.

GIF-220114_143934

6 Likes

Just a little question, is there a way to activate a scene or automation by a button?

I would like to activate a scene or automation turning all the lights off.

Thanks

Create an pr and I will also take a look at your code, it is easier for people to help there.

Iā€™m facing the exact same issue as you, with nest as the thermostat. Probably have to proceed with some workaround to mark the thermostat for now, but hopefully I get to finish all the setup to further dive in to debug this issue.

I noticed having the same problem with another custom card (customcard_tpx01_aircodition), so for now the suspect is most likely as @http_edo13 suggest (we might missed some icon templates somewhere). Just for information, do you mind sharing the current frontend integrations you are having @http_edo13 & @micdejo ? For me currently I have:

  • button-card
  • mini media player
  • mini-graph-card
  • card-mod
  • my cards bundle

I have tried a few things but wasnā€™t able to get it to work. If iā€™m correct the ā€œcustom_card_httpedo13_thermostatā€ is based of of the ā€œcustom_card_tpx01_airconditionā€. Therefore, the problem occurs for both of the cards. I donā€™t know what is causing the problem though. For now iā€™m using the ā€œcustom_card_mpse_thermostatā€ which works fine.

2 Likes

yes, my card is based on tpx01 air condition. This is my entire configuration code:

---
custom_card_httpedo13_thermostat:
  template:
    - "ulm_language_variables"
    - "custom_card_httpedo13_thermostat_language_variables"
  tap_action:
    action: "toggle"
  icon: |
    [[[
        if (entity.attributes.hvac_action == 'heating') {
          return "mdi:radiator";
        }
        return "mdi:radiator-off";
    ]]]
  label: >-
    [[[
        if (entity.state =='off') {
          return variables.custom_card_httpedo13_thermostat_off;
        } else if (entity.state =='heat') {
          return variables.custom_card_httpedo13_thermostat_on;
        } else if (entity.attributes.hvac_action == 'heating') {
          return variables.custom_card_httpedo13_thermostat_heating;
        }
        return entity.state;
    ]]]
  state:
    - operator: "template"
      value: >
        [[[
          return entity.state != 'off';
        ]]]
      styles:
        label:
          - color: |
              [[[
                if (entity.attributes.hvac_action == 'heating'){
                  return "var(--card-background-color)";
                }
                return "rgba(var(--color-theme),0.9)";
              ]]]
        name:
          - font-weight: "bold"
          - color: |
              [[[
                if (entity.attributes.hvac_action == 'heating'){
                  return "var(--card-background-color)";
                }
                return "rgba(var(--color-theme),0.9)";
              ]]]
        icon:
          - color: "rgba(var(--color-red),1)"
        img_cell:
          - background-color: |
              [[[
                if (entity.attributes.hvac_action == 'heating'){
                  return 'var(--card-background-color)';
                }
                return 'rgba(var(--color-red),0.2)';
              ]]]
        card:
          - background-color: |
              [[[
                if (entity.attributes.hvac_action == 'heating'){
                  return '#ff8100';
                }
                return 'var(--card-background-color)';
              ]]]

custom_card_httpedo13_thermostat_with_buttons:
  triggers_update: "all"
  styles:
    grid:
      - grid-template-areas: "'item1' 'item2'"
      - grid-template-columns: "1fr"
      - grid-template-rows: "min-content  min-content"
      - row-gap: "12px"
    card:
      - border-radius: "var(--border-radius)"
      - box-shadow: "var(--box-shadow)"
      - padding: "12px"
      - background-color: |
          [[[
            if (states[variables.entity].attributes.hvac_action == 'heating'){
              return '#ff8100';
            }
            return 'var(--card-background-color)';
          ]]]
  tap_action:
    action: "call-service"
    service: "climate.set_hvac_mode"
    service_data:
      entity_id: "[[[ return variables.entity ]]]"
      hvac_mode: |
        [[[
          if (states[variables.entity].state == "off"){
            return 'heat';
          } else if (states[variables.entity].state == "heat"){
            return 'off';
          }
        ]]]
  custom_fields:
    item1:
      card:
        type: "custom:button-card"
        template: "list_items_favorite"
        styles:
          card:
            - background-color: |
                [[[
                  if (states[variables.entity].attributes.hvac_action == 'heating'){
                    return '#ff8100';
                  }
                  return 'var(--card-background-color)';
                ]]]
        custom_fields:
          item1:
            card:
              type: "custom:button-card"
              template:
                - "icon_info"
                - "custom_card_httpedo13_thermostat"
              tap_action:
                action: "call-service"
                service: "climate.set_hvac_mode"
                service_data:
                  entity_id: "[[[ return variables.entity ]]]"
                  hvac_mode: |
                    [[[
                      if (states[variables.entity].state == "off"){
                        return 'heat';
                      } else if (states[variables.entity].state == "heat"){
                        return 'off';
                      }
                    ]]]
              name: >
                [[[
                    if (variables.name == null) {
                      return variables.entity;
                    }
                    return variables.name;
                ]]]
              entity: "[[[ return variables.entity ]]]"
          item2:
            card:
              type: "custom:button-card"
              template: "widget_current_temperature"
              tap_action:
                action: "toggle"
              entity: "[[[ return variables.entity ]]]"
              icon: "mdi:temperature-celsius"
    item2:
      card:
        type: "custom:button-card"
        template: "list_3_items"
        styles:
          card:
            - background-color: |
                [[[
                  if (states[variables.entity].attributes.hvac_action == 'heating'){
                    return '#ff8100';
                  }
                  return 'var(--card-background-color)';
                ]]]
        custom_fields:
          item1:
            card:
              type: "custom:button-card"
              template: "widget_icon_for_thermostat"
              entity: "[[[ return variables.entity ]]]"
              tap_action:
                action: "call-service"
                service: "climate.set_temperature"
                service_data:
                  temperature: "[[[ return (parseFloat(states[variables.entity].attributes.temperature) - 0.5)  ]]]"
                  entity_id: "[[[ return variables.entity ]]]"
              icon: "mdi:minus"
          item2:
            card:
              type: "custom:button-card"
              template: "widget_temperature"
              tap_action:
                action: "toggle"
              entity: "[[[ return variables.entity ]]]"
              icon: "mdi:temperature-celsius"
          item3:
            card:
              type: "custom:button-card"
              template: "widget_icon_for_thermostat"
              entity: "[[[ return variables.entity ]]]"
              tap_action:
                action: "call-service"
                service: "climate.set_temperature"
                service_data:
                  temperature: "[[[ return (parseFloat(states[variables.entity].attributes.temperature) + 0.5)  ]]]"
                  entity_id: "[[[ return variables.entity ]]]"
              icon: "mdi:plus"


custom_card_httpedo13_thermostat_with_buttons_collapse:
  triggers_update: "all"
  styles:
    grid:
      - grid-template-areas: "'item1' 'item2'"
      - grid-template-columns: "1fr"
      - grid-template-rows: "min-content  min-content"
      - row-gap: "12px"
    card:
      - border-radius: "var(--border-radius)"
      - box-shadow: "var(--box-shadow)"
      - padding: "12px"
      - background-color: |
          [[[
            if (states[variables.entity].attributes.hvac_action == 'heating'){
              return '#ff8100';
            }
            return 'var(--card-background-color)';
          ]]]
  tap_action:
    action: "call-service"
    service: "climate.set_hvac_mode"
    service_data:
      entity_id: "[[[ return variables.entity ]]]"
      hvac_mode: |
        [[[
          if (states[variables.entity].state == "off"){
            return 'heat';
          } else if (states[variables.entity].state == "heat"){
            return 'off';
          }
        ]]]
  custom_fields:
    item1:
      card:
        type: "custom:button-card"
        template: "list_items_favorite"
        styles:
          card:
            - background-color: |
                [[[
                  if (states[variables.entity].attributes.hvac_action == 'heating'){
                    return '#ff8100';
                  }
                  return 'var(--card-background-color)';
                ]]]
        custom_fields:
          item1:
            card:
              type: "custom:button-card"
              template:
                - "icon_info"
                - "custom_card_httpedo13_thermostat"
              tap_action:
                action: "call-service"
                service: "climate.set_hvac_mode"
                service_data:
                  entity_id: "[[[ return variables.entity ]]]"
                  hvac_mode: |
                    [[[
                      if (states[variables.entity].state == "off"){
                        return 'heat';
                      } else if (states[variables.entity].state == "heat"){
                        return 'off';
                      }
                    ]]]
              name: >
                [[[
                    if (variables.name == null) {
                      return variables.entity;
                    }
                    return variables.name;
                ]]]
              entity: "[[[ return variables.entity ]]]"
          item2:
            card:
              type: "custom:button-card"
              template: "widget_current_temperature"
              tap_action:
                action: "toggle"
              entity: "[[[ return variables.entity ]]]"
              icon: "mdi:temperature-celsius"
    item2:
      card:
        type: "conditional"
        conditions:
          - entity: "[[[ return states[variables.entity].entity_id ]]]"
            state: "heat"
        card:
          type: "custom:button-card"
          template: "list_3_items"
          styles:
            card:
              - background-color: |
                  [[[
                    if (states[variables.entity].attributes.hvac_action == 'heating'){
                      return '#ff8100';
                    }
                    return 'var(--card-background-color)';
                  ]]]
          custom_fields:
            item1:
              card:
                type: "custom:button-card"
                template: "widget_icon_for_thermostat"
                entity: "[[[ return variables.entity ]]]"
                tap_action:
                  action: "call-service"
                  service: "climate.set_temperature"
                  service_data:
                    temperature: "[[[ return (parseFloat(states[variables.entity].attributes.temperature) - 0.5)  ]]]"
                    entity_id: "[[[ return variables.entity ]]]"
                icon: "mdi:minus"
            item2:
              card:
                type: "custom:button-card"
                template: "widget_temperature"
                tap_action:
                  action: "toggle"
                entity: "[[[ return variables.entity ]]]"
                icon: "mdi:temperature-celsius"
            item3:
              card:
                type: "custom:button-card"
                template: "widget_icon_for_thermostat"
                entity: "[[[ return variables.entity ]]]"
                tap_action:
                  action: "call-service"
                  service: "climate.set_temperature"
                  service_data:
                    temperature: "[[[ return (parseFloat(states[variables.entity].attributes.temperature) + 0.5)  ]]]"
                    entity_id: "[[[ return variables.entity ]]]"
                icon: "mdi:plus"


widget_current_temperature:
  color: "var(--google-grey-500)"
  show_icon: false
  show_name: false
  show_label: true
  size: "20px"
  label: |-
    [[[
        var temperature = entity.attributes.current_temperature;
        if (temperature == null) {
          var temperature = '-';
        }
        return temperature + 'Ā°C'
    ]]]
  styles:
    label:
      - font-weight: "bold"
      - color: |
          [[[
            if (entity.attributes.hvac_action == 'heating'){
              return 'var(--card-background-color)';
            }
            return 'rgb(var(--color-theme),0.9)';
          ]]]
    grid:
      - grid-template-areas: "'l'"
    card:
      - box-shadow: "none"
      - padding: "0px"
      - border-radius: "14px"
      - place-self: "center"
      - height: "42px"
      - background-color: |
          [[[
            if (entity.attributes.hvac_action == 'heating'){
              return '#ff8100';
            }
            return 'var(--card-background-color)';
          ]]]

widget_temperature:
  color: "var(--google-grey-500)"
  show_icon: false
  show_name: false
  show_label: true
  size: "20px"
  label: |-
    [[[
        var temperature = entity.attributes.temperature;
        if (temperature == null) {
          var temperature = '-';
        }
        return temperature + 'Ā°C'
    ]]]
  styles:
    label:
      - color: |
          [[[
            if (entity.attributes.hvac_action == 'heating'){
              return 'var(--card-background-color)';
            }
            return 'rgb(var(--color-theme),0.9)';
          ]]]
    grid:
      - grid-template-areas: "'l'"
    card:
      - box-shadow: "none"
      - padding: "0px"
      - border-radius: "14px"
      - place-self: "center"
      - height: "42px"
      - background-color: |
          [[[
            if (entity.attributes.hvac_action == 'heating'){
              return '#ff8100';
            }
            return 'var(--card-background-color)';
          ]]]

widget_icon_for_thermostat:
  tap_action:
    action: "toggle"
  show_icon: true
  show_name: false
  styles:
    grid:
      - grid-template-areas: "'i'"
    card:
      - box-shadow: "none"
      - padding: "0px"
      - background-color: |
          [[[
            if (entity.attributes.hvac_action == 'heating'){
              return 'var(--card-background-color)';
            }
            return 'rgba(var(--color-theme),0.05)';
          ]]]
      - border-radius: "14px"
      - place-self: "center"
      - height: "42px"
    icon:
      - color: "rgba(var(--color-theme),0.9)"
  size: "20px"
  color: "var(--google-grey)"

list_items_favorite:
  styles:
    grid:
      - grid-template-areas: "'item1 item1 item2'"
      - grid-template-columns: "1fr 1fr 1fr"
      - grid-template-rows: "min-content"
      - column-gap: "7px"
    card:
      - box-shadow: "none"
      - padding: "0px"
icon_info:
  color: var(--google-grey)
  show_icon: true
  show_label: true
  show_name: true
  state:
    - styles:
        custom_fields:
          notification:
            - border-radius: 50%
            - position: absolute
            - left: 24px
            - top: -2px
            - height: 16px
            - width: 16px
            - border: 2px solid var(--card-background-color)
            - font-size: 12px
            - line-height: 14px
            - background-color: >
                [[[
                  return "rgba(var(--color-red),1)";
                ]]]
      value: unavailable
  styles:
    icon:
      - color: 'rgba(var(--color-theme),0.2)'
    label:
      - justify-self: start
      - align-self: start
      - font-weight: bolder
      - font-size: 12px
      - filter: opacity(40%)
      - margin-left: 12px
    name:
      - align-self: end
      - justify-self: start
      - font-weight: bold
      - font-size: 14px
      - margin-left: 12px
    state:
      - justify-self: start
      - align-self: start
      - font-weight: bolder
      - font-size: 12px
      - filter: opacity(40%)
      - margin-left: 12px
    img_cell:
      - background-color: 'rgba(var(--color-theme),0.05)'
      - border-radius: 50%
      - place-self: center
      - width: 42px
      - height: 42px
    grid:
      - grid-template-areas: '"i n" "i l"'
      - grid-template-columns: min-content auto
      - grid-template-rows: min-content min-content
    card:
      - border-radius: 21px 8px 8px 21px
      - box-shadow: none
      - padding: 0px
      # - background-color: 'rgba(var(--color-theme),0)'
  custom_fields:
    notification: >
      [[[
        if (entity.state =='unavailable'){
          return `<ha-icon icon="mdi:exclamation" style="width: 12px; height: 12px; color: var(--primary-background-color);"></ha-icon>`
        }
      ]]]
  size: 20px
1 Like

Hey guys, this is the first theme Iā€™m trying and I really love how easy it is to implement and how it looks like! Thx to @CM000n for sharing your config! But Iā€™m facing a strange issue regarding some CSS styles not being applied when using SSL or opening it locally on a tablet.



In the first pic everything is fine - opened in a browser via HTTP://local-ip. But when is access the same page using the same browser but HTTPS://xxx.duckdns.org or if I open the page locally on a tablet, some CSS styles are missing in the 2nd picture (e.g. border-radius is not defined)

Does anyone have an idea what the problem could be?

Just my2cent for this ā€œthemeā€:

i rly like itā€¦butā€¦as for now it needs to be heavily maintained and a lot of effort to implement it into the system. also I have the feeling that it slows down a bit the entire frontend. but this is only a feeling. I rly respect the effort you all put into it and itā€™s often easy to say ā€œwhy canā€™t I simply click on Ā“install`and everything is fine?ā€. I think if this will come to a greater audience it needs to get much easier to install and maintain.

during the last days I found an error in the code generatorā€¦solution was adding 2 tabs on a single line. ok, fine for me. I am a technical based project manager for a big company and I like to find solutions by myself. I am rly looking forward on your efforts in making this a fully HACS compatible ā€œThemeā€. but I am curious when it comes to upgrading/changing the style of integration, manually vs. hacs. but hey, challenge accepted because this theme is rly so minimalistic that it is pretty much close to perfection :slight_smile:

i am still missing a lot of things but I am as stupid as possible so that I am not able to program this on my own or to support in any case of programming. as for now I am still maintaining 2 versions of dashboard. one with HA based cards heavily based on the grid card as a fall back if something went wrong and the ā€œminimalisticā€ version. a lot of work but hopefully some day there will be only one to maintain :slight_smile:

thank you all for your effort!

cheers,
ben

Already sorted. Turns out I could use the entity.state.

Iā€™ve created a pull request with the code as well.

Thanks

Yes, the integration into HACS will probably be a big big breaking change in many places.
Some things will be made easier, but others will not.
At the moment we canā€™t and donā€™t want to offer a 1 click solution like dwain or HKI.
Most of the people who have contributed so far are tinkerers themselves and make their contribution because they enjoy it and can learn something new. Nothing more and nothing less.

So letā€™s just see what else the future brings.

2 Likes

Maybe your Theme is just not applied, when you Open it from another device? Seems like it is using the standard theme.
Theme Settings in Home Assistant are per Device.
Please have a look in your Settings.

Hi again,

has anybody a good idea for a lock card or already realized it?

cheers,
ben

Hi,

I want to use the Minimalist button card templates with the standard UI.
I donā€™t know where to put the ā€œbutton_card_templates.yamlā€ and how to include it in the lovelace UI.

can someone please guide me ? :slight_smile:

Thank You

Installation UI mode

Hello erverybody,

has anybody an idea why my popups not working?
I have done everything as described:

  • browser_mod is installed and added to the .yaml
  • All Addons added like in the README_popups.md on github described

When I press a button, it turns dark gray as if trying to open the menu, but nothing happens.

This is my Code for the light button (exactly the same as on the manual):

                  - type: "custom:button-card"
                    template:
                      - card_light
                      - popup_light
                    entity: light.terrasse_grillbeleuchtung

Thank you