Replace main_button_state_red with state_color_button_nav

This commit is contained in:
2025-07-13 21:40:47 -04:00
parent 367fadf870
commit 008b500b74

View File

@ -1,34 +1,4 @@
streamline_templates: streamline_templates:
main_button_state_red:
default:
- name: ''
- columns: 2
- navigation_path: ''
card:
type: custom:bubble-card
card_type: button
button_type: state
entity: '[[entity]]'
name: '[[name]]'
tap_action:
action: navigate
navigation_path: '[[navigation_path]]'
double_tap_action:
action: none
hold_action:
action: more-info
button_action:
tap_action:
action: navigate
navigation_path: '[[navigation_path]]'
double_tap_action:
action: none
hold_action:
action: more-info
show_state: false
columns: '[[columns]]'
modules:
- main_button_state_red
main_button_name: main_button_name:
default: default:
- name: '' - name: ''
@ -271,13 +241,15 @@ streamline_templates:
state_color_button: state_color_button:
defaults: defaults:
- name: '' - name: ''
- columns: 2
- show_state: true
card: card:
type: custom:bubble-card type: custom:bubble-card
card_type: button card_type: button
button_type: state button_type: state
entity: '[[entity]]' entity: '[[entity]]'
name: '[[name]]' name: '[[name]]'
show_state: true show_state: '[[show_state]]'
tap_action: tap_action:
action: more-info action: more-info
double_tap_action: double_tap_action:
@ -289,6 +261,40 @@ streamline_templates:
action: none action: none
hold_action: hold_action:
action: none action: none
columns: '[[columns]]'
modules:
- default
- state_color_button
state_color_button:
color: '[[color]]'
state_color_button_nav:
defaults:
- name: ''
- columns: 2
- show_state: false
card:
type: custom:bubble-card
card_type: button
button_type: state
entity: '[[entity]]'
name: '[[name]]'
show_state: '[[show_state]]'
tap_action:
action: navigate
navigation_path: '[[navigation_path]]'
double_tap_action:
action: none
hold_action:
action: none
button_action:
tap_action:
action: navigate
navigation_path: '[[navigation_path]]'
double_tap_action:
action: none
hold_action:
action: none
columns: '[[columns]]'
modules: modules:
- default - default
- state_color_button - state_color_button
@ -429,12 +435,14 @@ views:
heading_style: title heading_style: title
icon: mdi:home-analytics icon: mdi:home-analytics
- type: custom:streamline-card - type: custom:streamline-card
template: main_button_state_red template: state_color_button_nav
variables: variables:
- name: Security - name: Security
- entity: binary_sensor.security_faults - entity: binary_sensor.security_faults
- navigation_path: '#security' - navigation_path: '#security'
- columns: 2 - columns: 2
- color: error-color
- show_state: false
grid_options: grid_options:
columns: 6 columns: 6
rows: auto rows: auto
@ -5998,12 +6006,6 @@ views:
heading: Templates heading: Templates
heading_style: title heading_style: title
icon: mdi:wrench icon: mdi:wrench
- type: custom:streamline-card
template: main_button_state_red
variables:
entity: binary_sensor.security_faults
name: Main Button State Red
navigation_path: '#security'
- type: custom:streamline-card - type: custom:streamline-card
template: main_button_name template: main_button_name
variables: variables:
@ -6042,36 +6044,21 @@ views:
entity: binary_sensor.living_room_front_motion entity: binary_sensor.living_room_front_motion
name: State Color Button name: State Color Button
color: accent-color color: accent-color
columns: '2'
- type: custom:streamline-card
template: state_color_button_nav
variables:
entity: binary_sensor.security_faults
name: State Color Button Nav
navigation_path: '#security'
color: error-color
columns: '2'
- type: grid - type: grid
cards: cards:
- type: heading - type: heading
heading: Template Development heading: Template Development
heading_style: title heading_style: title
icon: mdi:wrench-cog icon: mdi:wrench-cog
- type: custom:bubble-card
card_type: button
button_type: state
entity: binary_sensor.security_faults
name: Main Button State Red
tap_action:
action: navigate
navigation_path: '#security'
double_tap_action:
action: none
hold_action:
action: more-info
button_action:
tap_action:
action: navigate
navigation_path: '#security'
double_tap_action:
action: none
hold_action:
action: more-info
show_state: false
columns: 2
modules:
- main_button_state_red
- type: custom:bubble-card - type: custom:bubble-card
card_type: button card_type: button
button_type: name button_type: name
@ -6224,11 +6211,39 @@ views:
action: none action: none
hold_action: hold_action:
action: none action: none
columns: 2
modules: modules:
- default - default
- state_color_button - state_color_button
state_color_button: state_color_button:
color: accent-color color: accent-color
- type: custom:bubble-card
card_type: button
button_type: state
entity: binary_sensor.security_faults
name: State Color Button Nav
show_state: true
tap_action:
action: navigate
navigation_path: '#security'
double_tap_action:
action: none
hold_action:
action: none
button_action:
tap_action:
action: navigate
navigation_path: '#security'
double_tap_action:
action: none
hold_action:
action: none
columns: 2
modules:
- default
- state_color_button
state_color_button:
color: error-color
- type: grid - type: grid
cards: cards:
- type: heading - type: heading