Modernize lovelace code for lovelace_gen, hacs
This commit is contained in:
@@ -2,62 +2,6 @@ title: Dashboard
|
||||
path: dashboard
|
||||
icon: mdi:home-assistant
|
||||
panel: true
|
||||
popup_cards:
|
||||
vacuum.xiaomi_vacuum_cleaner:
|
||||
title: Dammsugare
|
||||
card: !include vacuum_card.yaml
|
||||
|
||||
binary_sensor.door_open:
|
||||
title: Öppna dörrar
|
||||
card:
|
||||
type: vertical-stack
|
||||
cards:
|
||||
- type: entities
|
||||
entities: &door_entities
|
||||
- binary_sensor.hall_ytterdorr
|
||||
- binary_sensor.tvattstuga_ytterdorr
|
||||
- binary_sensor.vardagsrum_ytterdorr
|
||||
- binary_sensor.sovrum_ytterdorr
|
||||
- type: history-graph
|
||||
entities: *door_entities
|
||||
|
||||
device_tracker.thomas_presence:
|
||||
title: Thomas
|
||||
large: true
|
||||
card:
|
||||
type: vertical-stack
|
||||
cards:
|
||||
- type: entities
|
||||
entities: &thomas_entities
|
||||
- device_tracker.thomas_iphone_beta
|
||||
- device_tracker.thomas_iphone_2
|
||||
- sensor.thomas_iphone_bt
|
||||
- sensor.thomas_iphone_bt2
|
||||
- type: history-graph
|
||||
entities:
|
||||
- device_tracker.thomas_presence
|
||||
- type: history-graph
|
||||
entities: *thomas_entities
|
||||
|
||||
device_tracker.anneli_presence:
|
||||
title: Anneli
|
||||
large: true
|
||||
card:
|
||||
type: vertical-stack
|
||||
cards:
|
||||
- type: entities
|
||||
entities: &anneli_entities
|
||||
- device_tracker.anneli_lovn
|
||||
- device_tracker.anneli_loven
|
||||
- sensor.anneli_iphone_bt
|
||||
- sensor.anneli_iphone_bt2
|
||||
- sensor.anneli_klocka_bt
|
||||
- sensor.anneli_klocka_bt2
|
||||
- type: history-graph
|
||||
entities:
|
||||
- device_tracker.anneli_presence
|
||||
- type: history-graph
|
||||
entities: *anneli_entities
|
||||
cards:
|
||||
- type: custom:layout-card
|
||||
layout: vertical
|
||||
@@ -87,7 +31,7 @@ cards:
|
||||
max_width: 960
|
||||
layout: vertical
|
||||
cards:
|
||||
- type: custom:useful-markdown-card
|
||||
- type: markdown
|
||||
style: |
|
||||
ha-card {
|
||||
padding-top: 24px;
|
||||
@@ -95,13 +39,14 @@ cards:
|
||||
h1 {
|
||||
text-align: center;
|
||||
font-size: 6em;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
h2 {
|
||||
text-align: center;
|
||||
}
|
||||
content: |
|
||||
# [[ sensor.time ]]
|
||||
## [[ sensor.date ]]
|
||||
# {{ states("sensor.time") }}
|
||||
## {{ states("sensor.date") }} V.{{ states("sensor.week") }}
|
||||
- type: custom:weather-card
|
||||
entity: weather.smhi_home
|
||||
icons: /local/weather_icons/
|
||||
|
||||
@@ -6,10 +6,9 @@ cards:
|
||||
- type: custom:layout-card
|
||||
rebuild: 1000
|
||||
cards:
|
||||
- !include dev_card.yaml
|
||||
- !include timeofday_card.yaml
|
||||
- !include ../timeofday_card.yaml
|
||||
- type: custom:browser-player
|
||||
- !include local_services.hidden.yaml
|
||||
- !include ../local_services.hidden.yaml
|
||||
- type: custom:auto-entities
|
||||
card:
|
||||
type: entities
|
||||
@@ -17,6 +16,9 @@ cards:
|
||||
filter:
|
||||
include:
|
||||
- state: "unavailable"
|
||||
exclude:
|
||||
- attributes:
|
||||
type: browser_mod
|
||||
- type: custom:auto-entities
|
||||
card:
|
||||
type: entities
|
||||
@@ -51,6 +53,9 @@ cards:
|
||||
- domain: switch
|
||||
options:
|
||||
secondary_info: entity-id
|
||||
exclude:
|
||||
- attributes:
|
||||
type: browser_mod
|
||||
- type: custom:auto-entities
|
||||
card:
|
||||
type: entities
|
||||
@@ -61,6 +66,19 @@ cards:
|
||||
device_class: "battery"
|
||||
options:
|
||||
secondary_info: entity-id
|
||||
style: |
|
||||
{% if state_attr(config.entity, 'unit_of_measurement') == "%" %}
|
||||
:host {
|
||||
--paper-item-icon-color:
|
||||
{% if states(config.entity)|float < 25 %}
|
||||
red
|
||||
{% elif states(config.entity)|float < 40 %}
|
||||
orange
|
||||
{% else %}
|
||||
var(--text-light-color)
|
||||
{% endif %};
|
||||
}
|
||||
{% endif %}
|
||||
- type: custom:auto-entities
|
||||
card:
|
||||
type: entities
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
title: Diverse
|
||||
icon: mdi:home-assistant
|
||||
cards:
|
||||
- !include floorplan.yaml {"no_other":"true"}
|
||||
- !include floorplan.yaml {"no_light":"true"}
|
||||
- !include coffee_card.yaml
|
||||
- !include temperatures_card.yaml
|
||||
- !include power_card.yaml
|
||||
- !include
|
||||
- /config/lovelace/floorplan.yaml
|
||||
- {"no_other":"true"}
|
||||
- !include
|
||||
- /config/lovelace/floorplan.yaml
|
||||
- {"no_light":"true"}
|
||||
- !include /config/lovelace/coffee_card.yaml
|
||||
- !include /config/lovelace/temperatures_card.yaml
|
||||
- !include /config/lovelace/power_card.yaml
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
title: Security
|
||||
icon: mdi:shield-home
|
||||
cards:
|
||||
- !include cameras/barnrum.yaml
|
||||
- !include cameras/kontor.yaml
|
||||
- !include cameras/vardagsrum.yaml
|
||||
- !include cameras/hallen.yaml
|
||||
- !include /config/lovelace/cameras/barnrum.yaml
|
||||
- !include /config/lovelace/cameras/kontor.yaml
|
||||
- !include /config/lovelace/cameras/vardagsrum.yaml
|
||||
- !include /config/lovelace/cameras/hallen.yaml
|
||||
- type: entities
|
||||
entities:
|
||||
- type: custom:hui-glance-card
|
||||
|
||||
Reference in New Issue
Block a user