diff --git a/lovelace/decluttering_templates/coloured-vertical-stack.yaml b/lovelace/decluttering_templates/coloured-vertical-stack.yaml new file mode 100644 index 0000000..0e32e3b --- /dev/null +++ b/lovelace/decluttering_templates/coloured-vertical-stack.yaml @@ -0,0 +1,14 @@ +coloured-vertical-stack: + default: + - color: "black" + card: + type: custom:mod-card + card_mod: + style: | + ha-card { + --primary-color: [[color]]; + margin: 20px var(--main-layout-card-margin) 0; + } + card: + type: vertical-stack + cards: "[[cards]]" diff --git a/lovelace/home_dashboard/bathroom_dashboard.yaml b/lovelace/home_dashboard/bathroom_dashboard.yaml index eb47ccd..3bad03f 100644 --- a/lovelace/home_dashboard/bathroom_dashboard.yaml +++ b/lovelace/home_dashboard/bathroom_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #2982c4; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 1 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 1 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#2982c4" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -61,4 +46,4 @@ action: call-service service: "[[[ return entity.state == 'on' ? 'script.sonos_bathroom_unjoin' : 'script.sonos_bathroom_join' ]]]" - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/bedroom_dashboard.yaml b/lovelace/home_dashboard/bedroom_dashboard.yaml index c008734..ee6d98e 100644 --- a/lovelace/home_dashboard/bedroom_dashboard.yaml +++ b/lovelace/home_dashboard/bedroom_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #9489d1; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 2 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 2 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#9489d1" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -122,8 +107,11 @@ entity: light.bedside name: Bedside - - type: vertical-stack - cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#9489d1" + - cards: - type: custom:decluttering-card template: v3_section_title variables: @@ -168,4 +156,4 @@ entities: - switch.tapo_bedroom - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/guest_bedroom_dashboard.yaml b/lovelace/home_dashboard/guest_bedroom_dashboard.yaml index 88193a5..edbd9f2 100644 --- a/lovelace/home_dashboard/guest_bedroom_dashboard.yaml +++ b/lovelace/home_dashboard/guest_bedroom_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #0040A0; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 1 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 1 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#0040A0" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -76,4 +61,4 @@ name: Mercury icon: mdi:nas - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/hallway_dashboard.yaml b/lovelace/home_dashboard/hallway_dashboard.yaml index d445886..dbadece 100644 --- a/lovelace/home_dashboard/hallway_dashboard.yaml +++ b/lovelace/home_dashboard/hallway_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #b1633e; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 1 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 1 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#b1633e" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -69,4 +54,4 @@ entity: light.hallway_entrance name: Entrance - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/kitchen_dashboard.yaml b/lovelace/home_dashboard/kitchen_dashboard.yaml index 0971369..12be16e 100644 --- a/lovelace/home_dashboard/kitchen_dashboard.yaml +++ b/lovelace/home_dashboard/kitchen_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #bacd8c; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 2 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 2 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#bacd8c" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -70,8 +55,11 @@ entity: light.kitchen_secondary name: Secondary - - type: vertical-stack - cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#bacd8c" + - cards: - type: custom:decluttering-card template: v3_section_title variables: @@ -115,4 +103,4 @@ # variables: # power_sensor: sensor.kitchen_outlet_electric_consumption_w - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/living_room_dashboard.yaml b/lovelace/home_dashboard/living_room_dashboard.yaml index 8b9c9c0..57ccb47 100644 --- a/lovelace/home_dashboard/living_room_dashboard.yaml +++ b/lovelace/home_dashboard/living_room_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #6b8988; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 2 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 2 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#6b8988" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -128,8 +113,11 @@ tap_action: action: more-info - - type: vertical-stack - cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#6b8988" + - cards: - type: custom:decluttering-card template: v3_section_title variables: @@ -193,14 +181,12 @@ variables: power_sensor: sensor.desk_outlet_power - - type: vertical-stack - cards: - - type: custom:decluttering-card - template: v3_section_title - variables: - - title: Camera - - type: picture-glance - camera_image: camera.mercury_amcrest_1 - entities: [] + - type: custom:decluttering-card + template: v3_section_title + variables: + - title: Camera + - type: picture-glance + camera_image: camera.mercury_amcrest_1 + entities: [] - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/preferences_dashboard.yaml b/lovelace/home_dashboard/preferences_dashboard.yaml index 1e25115..d25551e 100644 --- a/lovelace/home_dashboard/preferences_dashboard.yaml +++ b/lovelace/home_dashboard/preferences_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #6A737A; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 2 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 2 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#6A737A" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -118,8 +103,11 @@ - input_number.isparkle_brightness_2 - input_number.isparkle_fade_2 - - type: vertical-stack - cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#6A737A" + - cards: - type: custom:decluttering-card template: v3_section_title variables: @@ -175,4 +163,4 @@ - input_number.toshiba_trigger_temp - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml diff --git a/lovelace/home_dashboard/terrarium_dashboard.yaml b/lovelace/home_dashboard/terrarium_dashboard.yaml index d61cc0c..dee4414 100644 --- a/lovelace/home_dashboard/terrarium_dashboard.yaml +++ b/lovelace/home_dashboard/terrarium_dashboard.yaml @@ -1,28 +1,13 @@ -- type: custom:mod-card - style: - layout-card: - .: | - * { - --primary-color: #0040A0; - margin: 0 var(--main-layout-card-margin); - } - - $: - horizontal-layout: - $: - .: | - #columns { - margin: 0 20px; - grid-gap: 20px; - } - card: - type: custom:layout-card - layout_type: custom:horizontal-layout - layout: - max_cols: 2 - cards: - - type: vertical-stack - cards: +- type: custom:layout-card + layout_type: custom:horizontal-layout + layout: + max_cols: 2 + cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#0040A0" + - cards: - type: custom:decluttering-card template: v3_title variables: @@ -51,8 +36,11 @@ - left_entity: sensor.terrarium_weather_temperature - left_name: Temperature - right_entity: sensor.terrarium_weather_pressure - - type: vertical-stack - cards: + - type: custom:decluttering-card + template: coloured-vertical-stack + variables: + - color: "#0040A0" + - cards: - type: custom:decluttering-card template: v3_section_title variables: @@ -62,4 +50,4 @@ entities: - camera.terrarium_cam_hd - - !include ../popup_cards.yaml + - !include ../popup_cards.yaml