PodPerson_HA

HA Dashboard - Button + Bubble Card

Jul 6th, 2024 (edited)
236
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 79.84 KB | Source Code | 0 0
  1.    title: Quick
  2.     icon: 'mdi:timer'
  3.     path: default_view
  4.     badges: []
  5.     cards:
  6.       - type: vertical-stack ## 1st Page Column
  7.         cards:
  8.         - type: vertical-stack ## Group 1 - Security Buttons/States
  9.           cards:        
  10.           - type: custom:bubble-card
  11.             card_type: separator
  12.             name: Home
  13.             icon: mdi:home
  14.                      
  15.           - type: custom:stack-in-card
  16.             mode: horizontal
  17.             style:
  18.                   .: |
  19.                    ha-card {
  20.                       border-radius: 30px;
  21.                       margin: 0 auto;
  22.                       padding-top: 0px;
  23.                     }
  24.  
  25.  
  26.             cards:
  27.                 - type: 'custom:button-card' # Alarm
  28.                   entity: alarm_control_panel.security
  29.                   template: 1_alarm
  30.                   show_state: true
  31.                  
  32.                 - type: 'custom:button-card' # Door Lock
  33.                   template: 1_lock
  34.                   entity: lock.front_door
  35.                   show_name: true
  36.                   name: Door Lock
  37.                   show_state: true
  38.  
  39.                 - type: 'custom:button-card' # External Door Sensors
  40.                   template: 1_state_small
  41.                   entity: group.door_sensors_external
  42.                   name: External
  43.                   show_name: true
  44.                   show_state: false
  45.                   show_icon: true
  46.                   show_label: false
  47.                   show_last_changed: true
  48.                   custom_fields:
  49.                     msen: >
  50.                      [[[
  51.                         if (states['group.door_sensors_external'].state === 'off') return 'Off';
  52.                         if (states['binary_sensor.d_back'].state === 'on') var Bk = "Bk. "; else var Bk = '';
  53.                         if (states['binary_sensor.d_screen'].state === 'on') var S = "S. "; else var S = '';
  54.                         if (states['binary_sensor.d_laundry'].state === 'on') var F = "F. "; else var F = '';
  55.                         return (F + S + Bk);
  56.                       ]]]
  57.                   state:
  58.                     - color: var(--secondary-button-colour)
  59.                       icon: 'mdi:door-open'
  60.                       value: 'on'
  61.                     - color: var(--primary-button-colour)
  62.                       icon: 'mdi:door-closed'
  63.                       value: 'off'  
  64.                   styles:
  65.                     grid:
  66.                       - grid-template-areas: ' "i" "n" "msen" "l" '
  67.                       - grid-template-columns: 1fr
  68.                       - grid-template-rows: 1fr min-content min-content min-content
  69.                     custom_fields:
  70.                       msen:
  71.                         - font-size: 13px
  72.                         - color: var(primary-text-color)
  73.                         - align-self: middle
  74.                         - justify-self: middle
  75.  
  76.                 - type: 'custom:button-card' # Garage Door
  77.                   template: 1_garage_door
  78.                   show_state: true
  79.                   entity: cover.d_garage
  80.                   name: Garage
  81.              
  82.  
  83.                 - type: 'custom:button-card' #Motion Sensors
  84.                   template: 1_state_small
  85.                   entity: group.motion_sensors
  86.                   show_name: true
  87.                   show_state: false
  88.                   show_icon: true
  89.                   show_label: false
  90.                   show_last_changed: true
  91.                   name: Motion
  92.                   icon: 'mdi:help'
  93.                   custom_fields:
  94.                     msen: >
  95.                      [[[
  96.                         if (states['group.motion_sensors'].state === 'off') return 'Off';
  97.                         if (states['binary_sensor.ms_lounge'].state === 'on') var L = "L. "; else var L = '';
  98.                         if (states['binary_sensor.ms_kitchen'].state === 'on') var K = "K. "; else var K = '';
  99.                         if (states['binary_sensor.ms_bedroom'].state === 'on') var Bd = "Bd. "; else var Bd = '';
  100.                         if (states['binary_sensor.ms_laundry'].state === 'on') var C = "C. "; else var C = '';
  101.                         if (states['binary_sensor.ms_bathroom'].state === 'on') var Bt = "Bt. "; else var Bt = '';
  102.                         if (states['binary_sensor.ms_toilet'].state === 'on') var T = "T. "; else var T = '';
  103.                         if (states['binary_sensor.ms_garage'].state === 'on') var G = "G. "; else var G = '';
  104.                         return (L + K + Bd + C + Bt + T + G);
  105.                       ]]]
  106.                   state:
  107.                     - color: var(--secondary-button-colour)
  108.                       icon: 'mdi:run-fast'
  109.                       value: 'on'
  110.                     - color: var(--primary-button-colour)
  111.                       icon: 'mdi:walk'
  112.                       value: 'off'
  113.                   styles:
  114.                     grid:
  115.                       - grid-template-areas: ' "i" "n" "msen" "l" '
  116.                       - grid-template-columns: 1fr
  117.                       - grid-template-rows: 1fr min-content min-content min-content
  118.                     custom_fields:
  119.                       msen:
  120.                         - font-size: 13px
  121.                         - color: var(primary-text-color)
  122.                         - align-self: middle
  123.                         - justify-self: middle
  124.  
  125.         - type: vertical-stack ## Group 2 - Music
  126.           cards:
  127.           - type: custom:bubble-card   #
  128.             card_type: separator
  129.             name: Music
  130.             icon: mdi:music
  131.  
  132.           - type: custom:stack-in-card  # Music Player
  133.             mode: vertical
  134.             cards:
  135.               - type: custom:mini-media-player  # Music Player
  136.                 entity: media_player.kbs_music
  137.                 icon: mdi:apple
  138.                 artwork: none
  139.                 show_source: true
  140.                 group: true
  141.                 show_progress: true
  142.                 # info: scroll
  143.                 hide:
  144.                   volume_level: false
  145.                 style:  |
  146.                  :host {
  147.                      background-color: var(--secondary-background-color);
  148.                      border-top-left-radius: 35px;
  149.                      border-top-right-radius: 35px;
  150.                         }
  151.  
  152.  
  153.               - type: horizontal-stack  # Volume Buttons
  154.                 cards:
  155.                   - type: custom:button-card  # Vol 3
  156.                     template: haptic
  157.                     entity: input_number.kbs_music_airplay_vol_cur
  158.                     show_name: true
  159.                     show_state: false
  160.                     show_icon: false
  161.                     show_label: false
  162.                     name: 3
  163.                     tap_action:
  164.                       action: call-service
  165.                       service: input_number.set_value
  166.                       service_data:
  167.                         entity_id: input_number.kbs_music_airplay_vol_new
  168.                         value: 4
  169.                     state:
  170.                       - operator: template
  171.                         value: '[[[ return entity.state <= 4; ]]]'
  172.                         styles:
  173.                           name:
  174.                             - color: var(--secondary-button-colour)
  175.                       - value: '[[[ return entity.state > 4; ]]]'
  176.                         styles:
  177.                           name:
  178.                             - color: var(--primary-button-color)
  179.  
  180.                   - type: custom:button-card   # Vol 5
  181.                     template: haptic
  182.                     entity: input_number.kbs_music_airplay_vol_cur
  183.                     show_name: true
  184.                     show_state: false
  185.                     show_icon: false
  186.                     show_label: false
  187.                     name: 5
  188.                     tap_action:
  189.                       action: call-service
  190.                       service: input_number.set_value
  191.                       service_data:
  192.                         entity_id: input_number.kbs_music_airplay_vol_new
  193.                         value: 5
  194.                     state:
  195.                       - operator: template
  196.                         value: '[[[ return entity.state <= 5 && entity.state > 3; ]]]'
  197.                         styles:
  198.                           name:
  199.                             - color: var(--secondary-button-colour)
  200.                       - value: '[[[ return entity.state < 3; ]]]'
  201.                         styles:
  202.                           name:
  203.                             - color: var(--primary-button-color)
  204.                       - value: '[[[ return entity.state > 5; ]]]'
  205.                         styles:
  206.                           name:
  207.                             - color: var(--primary-button-color)
  208.  
  209.                   - type: custom:button-card   # Vol 10
  210.                     template: haptic
  211.                     entity: input_number.kbs_music_airplay_vol_cur
  212.                     show_name: true
  213.                     show_state: false
  214.                     show_icon: false
  215.                     show_label: false
  216.                     name: 10
  217.                     tap_action:
  218.                       action: call-service
  219.                       service: input_number.set_value
  220.                       service_data:
  221.                         entity_id: input_number.kbs_music_airplay_vol_new
  222.                         value: 10
  223.                     state:
  224.                       - operator: template
  225.                         value: '[[[ return entity.state <= 10 && entity.state > 5; ]]]'
  226.                         styles:
  227.                           name:
  228.                             - color: var(--secondary-button-colour)
  229.                       - value: '[[[ return entity.state < 25; ]]]'
  230.                         styles:
  231.                           name:
  232.                             - color: var(--primary-button-color)
  233.                       - value: '[[[ return entity.state > 5; ]]]'
  234.                         styles:
  235.                           name:
  236.                             - color: var(--primary-button-color)
  237.  
  238.                   - type: custom:button-card   # Vol 15
  239.                     template: haptic
  240.                     entity: input_number.kbs_music_airplay_vol_cur
  241.                     show_name: true
  242.                     show_state: false
  243.                     show_icon: false
  244.                     show_label: false
  245.                     name: 15
  246.                     tap_action:
  247.                       action: call-service
  248.                       service: input_number.set_value
  249.                       service_data:
  250.                         entity_id: input_number.kbs_music_airplay_vol_new
  251.                         value: 15
  252.                     state:
  253.                       - operator: template
  254.                         value: '[[[ return entity.state <= 15 && entity.state > 10; ]]]'
  255.                         styles:
  256.                           name:
  257.                             - color: var(--secondary-button-colour)
  258.                       - value: '[[[ return entity.state < 10; ]]]'
  259.                         styles:
  260.                           name:
  261.                             - color: var(--primary-button-color)
  262.                       - value: '[[[ return entity.state > 15; ]]]'
  263.                         styles:
  264.                           name:
  265.                             - color: var(--primary-button-color)
  266.  
  267.                   - type: custom:button-card   # Vol 20
  268.                     template: haptic
  269.                     entity: input_number.kbs_music_airplay_vol_cur
  270.                     show_name: true
  271.                     show_state: false
  272.                     show_icon: false
  273.                     show_label: false
  274.                     name: 20
  275.                     tap_action:
  276.                       action: call-service
  277.                       service: input_number.set_value
  278.                       service_data:
  279.                         entity_id: input_number.kbs_music_airplay_vol_new
  280.                         value: 20
  281.                     state:
  282.                       - operator: template
  283.                         value: '[[[ return entity.state <= 20 && entity.state > 15; ]]]'
  284.                         styles:
  285.                           name:
  286.                             - color: var(--secondary-button-colour)
  287.                       - value: '[[[ return entity.state < 15; ]]]'
  288.                         styles:
  289.                           name:
  290.                             - color: var(--primary-button-color)
  291.                       - value: '[[[ return entity.state > 20; ]]]'
  292.                         styles:
  293.                           name:
  294.                             - color: var(--primary-button-color)
  295.  
  296.                   - type: custom:button-card   # Vol 25
  297.                     template: haptic
  298.                     entity: input_number.kbs_music_airplay_vol_cur
  299.                     show_name: true
  300.                     show_state: false
  301.                     show_icon: false
  302.                     show_label: false
  303.                     name: 25
  304.                     tap_action:
  305.                       action: call-service
  306.                       service: input_number.set_value
  307.                       service_data:
  308.                         entity_id: input_number.kbs_music_airplay_vol_new
  309.                         value: 25
  310.                     state:
  311.                       - operator: template
  312.                         value: '[[[ return entity.state <= 25 && entity.state > 20; ]]]'
  313.                         styles:
  314.                           name:
  315.                             - color: var(--secondary-button-colour)
  316.                       - value: '[[[ return entity.state < 20; ]]]'
  317.                         styles:
  318.                           name:
  319.                             - color: var(--primary-button-color)
  320.                       - value: '[[[ return entity.state > 25; ]]]'
  321.                         styles:
  322.                           name:
  323.                             - color: var(--primary-button-color)
  324.  
  325.                   - type: custom:button-card  # Vol 30
  326.                     template: haptic
  327.                     entity: input_number.kbs_music_airplay_vol_cur
  328.                     show_name: true
  329.                     show_state: false
  330.                     show_icon: false
  331.                     show_label: false
  332.                     name: 30
  333.                     tap_action:
  334.                       action: call-service
  335.                       service: input_number.set_value
  336.                       service_data:
  337.                         entity_id: input_number.kbs_music_airplay_vol_new
  338.                         value: 30
  339.                     state:
  340.                       - operator: template
  341.                         value: '[[[ return entity.state <= 30 && entity.state > 25; ]]]'
  342.                         styles:
  343.                           name:
  344.                             - color: var(--secondary-button-colour)
  345.                       - value: '[[[ return entity.state < 25; ]]]'
  346.                         styles:
  347.                           name:
  348.                             - color: var(--primary-button-color)
  349.  
  350.                       - value: '[[[ return entity.state > 30; ]]]'
  351.                         styles:
  352.                           name:
  353.                             - color: red
  354.  
  355.  
  356.         - type: vertical-stack ## Group 3 - Lights
  357.           cards:
  358.             - type: custom:bubble-card
  359.               card_type: separator
  360.               name: Lights
  361.               icon: mdi:lightbulb-group
  362.  
  363.             - type: horizontal-stack # 1st Row Lights
  364.               cards:
  365.                 - type: custom:bubble-card # Lounge Light
  366.                   card_type: button
  367.                   button_type: slider
  368.                   scrolling_effect: false
  369.                   show_last_changed: true
  370.                   show_attribute: false
  371.                   show_state: false
  372.                   show_name: false
  373.                   columns: 1
  374.                   card_layout: large-2-rows
  375.                   entity: light.lounge
  376.                   tap_action:
  377.                     action: toggle
  378.                   double_tap_action:
  379.                     action: more-info
  380.                   sub_button:
  381.                     - name: Mode
  382.                       entity: input_select.light_lounge_mode
  383.                       card_type: select
  384.                       button_type: state
  385.                       show_icon: true
  386.                       show_background: false
  387.                       show_state: true
  388.                       icon: mdi:lightbulb-group-outline
  389.  
  390.                     - name: Temp
  391.                       entity: sensor.temp_lounge
  392.                       show_icon: true
  393.                       show_background: false
  394.                       show_state: true
  395.                   styles: |
  396.                        .bubble-name-container {
  397.                           margin-left: 0px;
  398.                           margin-right: 0px;
  399.                           font-size: 12px !important;
  400.                             }
  401.  
  402.                         .bubble-icon-container {
  403.                           margin-left: 0px;
  404.                           margin-right: 1px;
  405.                             }
  406.  
  407.                         .bubble-sub-button {
  408.                           margin-left: 0px;
  409.                           margin-right: -25px;
  410.                           background: none !important;
  411.                           border-radius: 0;
  412.                           font-size: 8px !important;
  413.                             }
  414.                         .bubble-state {
  415.                           font-size: 8px !important;
  416.                             }
  417.  
  418.                         .bubble-sub-button-2 > ha-icon {
  419.                          color: ${hass.states['sensor.temp_lounge'].state <= 15 ? 'var(--low-colour)'
  420.                          : hass.states['sensor.temp_lounge'].state <= 25 ? 'var(--primary-button-colour)'
  421.                          : 'var(--high-colour)'} !important;
  422.                           }
  423.                         .bubble-sub-button-2 {
  424.                          color: ${hass.states['sensor.temp_lounge'].state <= 15 ? 'var(--low-colour)'
  425.                          : hass.states['sensor.temp_lounge'].state <= 25 ? 'var(--primary-button-colour)'
  426.                          : 'var(--high-colour)'} !important;
  427.                         }
  428.  
  429.                         .bubble-sub-button-1 {
  430.                          color: ${hass.states['input_select.light_lounge_mode'].state === 'Bright' ? 'var(--light-bright)'
  431.                          : hass.states['input_select.light_lounge_mode'].state === 'Soft' ? 'var(--light-soft)'  
  432.                          : hass.states['input_select.light_lounge_mode'].state === 'Dim' ? 'var(--light-dim)'
  433.                          : hass.states['input_select.light_lounge_mode'].state === 'Dark' ? 'var(--light-dark)'
  434.                          : hass.states['input_select.light_lounge_mode'].state === 'Night' ? 'var(--light-soft)'
  435.                          : 'var(--primary-button-colour)'} !important;
  436.                         }
  437.                         .bubble-sub-button-1 > ha-icon {
  438.                          color: ${hass.states['input_select.light_lounge_mode'].state === 'Bright' ? 'var(--light-bright)'
  439.                          : hass.states['input_select.light_lounge_mode'].state === 'Soft' ? 'var(--light-soft)'  
  440.                          : hass.states['input_select.light_lounge_mode'].state === 'Dim' ? 'var(--light-dim)'
  441.                          : hass.states['input_select.light_lounge_mode'].state === 'Dark' ? 'var(--light-dark)'
  442.                          : hass.states['input_select.light_lounge_mode'].state === 'Night' ? 'var(--light-soft)'
  443.                          : 'var(--primary-button-colour)'} !important;
  444.                         }
  445.  
  446.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_lounge'].state <= 15 ? 'mdi:thermometer-chevron-down'
  447.                           : hass.states['sensor.temp_lounge'].state <= 25 ? 'mdi:thermometer'
  448.                           : 'mdi:thermometer-chevron-up')}
  449.  
  450.                 - type: custom:bubble-card # Kitchen Light
  451.                   card_type: button
  452.                   button_type: slider
  453.                   scrolling_effect: false
  454.                   show_last_changed: true
  455.                   show_attribute: false
  456.                   show_state: false
  457.                   show_name: false
  458.                   columns: 1
  459.                   card_layout: large-2-rows
  460.                   entity: light.kitchen
  461.                   tap_action:
  462.                     action: toggle
  463.                   double_tap_action:
  464.                     action: more-info
  465.                   sub_button:
  466.                     - name: Mode
  467.                       entity: input_select.light_kitchen_mode
  468.                       show_icon: true
  469.                       icon:
  470.                       show_background: false
  471.                       show_state: true
  472.                       icon: mdi:lightbulb-group-outline
  473.  
  474.                     - name: Temp
  475.                       entity: sensor.temp_kitchen
  476.                       show_icon: true
  477.                       show_background: false
  478.                       show_state: true
  479.                   styles: |
  480.                         .bubble-name-container {
  481.                           margin-left: 0px;
  482.                           margin-right: 0px;
  483.                           font-size: 12px !important;
  484.                             }
  485.  
  486.                         .bubble-icon-container {
  487.                           margin-left: 0px;
  488.                           margin-right: 1px;
  489.                             }
  490.                         .bubble-sub-button {
  491.                           margin-left: 0px;
  492.                           margin-right: -25px;
  493.                           background: none !important;
  494.                           border-radius: 0;
  495.                           font-size: 8px !important;
  496.                             }
  497.                         .bubble-state {
  498.                           font-size: 8px !important;
  499.                             }
  500.  
  501.  
  502.                         .bubble-sub-button-2 > ha-icon {
  503.                          color: ${hass.states['sensor.temp_kitchen'].state <= 15 ? 'var(--low-colour)'
  504.                          : hass.states['sensor.temp_kitchen'].state <= 25 ? 'var(--primary-button-colour)'
  505.                          : 'var(--high-colour)'} !important;
  506.                           }
  507.                         .bubble-sub-button-2 {
  508.                          color: ${hass.states['sensor.temp_kitchen'].state <= 15 ? 'var(--low-colour)'
  509.                          : hass.states['sensor.temp_kitchen'].state <= 25 ? 'var(--primary-button-colour)'
  510.                          : 'var(--high-colour)'} !important;
  511.                         }
  512.  
  513.                         .bubble-sub-button-1 {
  514.                          color: ${hass.states['input_select.light_kitchen_mode'].state === 'Bright' ? 'var(--light-bright)'
  515.                          : hass.states['input_select.light_kitchen_mode'].state === 'Soft' ? 'var(--light-soft)'  
  516.                          : hass.states['input_select.light_kitchen_mode'].state === 'Dim' ? 'var(--light-dim)'
  517.                          : hass.states['input_select.light_kitchen_mode'].state === 'Dark' ? 'var(--light-dark)'
  518.                          : hass.states['input_select.light_kitchen_mode'].state === 'Night' ? 'var(--light-soft)'
  519.                          : 'var(--primary-button-colour)'} !important;
  520.                         }
  521.                         .bubble-sub-button-1 > ha-icon {
  522.                          color: ${hass.states['input_select.light_kitchen_mode'].state === 'Bright' ? 'var(--light-bright)'
  523.                          : hass.states['input_select.light_kitchen_mode'].state === 'Soft' ? 'var(--light-soft)'  
  524.                          : hass.states['input_select.light_kitchen_mode'].state === 'Dim' ? 'var(--light-dim)'
  525.                          : hass.states['input_select.light_kitchen_mode'].state === 'Dark' ? 'var(--light-dark)'
  526.                          : hass.states['input_select.light_kitchen_mode'].state === 'Night' ? 'var(--light-soft)'
  527.                          : 'var(--primary-button-colour)'} !important;
  528.                         }
  529.  
  530.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_kitchen'].state <= 15 ? 'mdi:thermometer-chevron-down'
  531.                           : hass.states['sensor.temp_kitchen'].state <= 25 ? 'mdi:thermometer'
  532.                           : 'mdi:thermometer-chevron-up')}
  533.  
  534.             - type: horizontal-stack # 2nd Row Lights
  535.               cards:
  536.                 - type: conditional # Bedroom Globe
  537.                   conditions:
  538.                     - entity: input_select.light_bedroom
  539.                       state: "Globe"
  540.                   card:
  541.                       type: custom:bubble-card
  542.                       card_type: button
  543.                       button_type: slider
  544.                       scrolling_effect: false
  545.                       show_last_changed: true
  546.                       show_attribute: false
  547.                       show_state: false
  548.                       show_name: false
  549.                       columns: 1
  550.                       card_layout: large-2-rows
  551.                       entity: light.bedroom_globe
  552.                       tap_action:
  553.                         action: toggle
  554.                       double_tap_action:
  555.                         action: more-info
  556.                       hold_action:
  557.                         action: call-service
  558.                         service: input_select.select_option
  559.                         data:
  560.                           entity_id: input_select.light_bedroom
  561.                           option: "Lamp"
  562.                       sub_button:
  563.                         - name: Mode
  564.                           entity: input_select.light_bedroom_globe_mode
  565.                           show_icon: true
  566.                           icon:
  567.                           show_background: false
  568.                           show_state: true
  569.                           icon: mdi:lightbulb-group-outline
  570.  
  571.                         - name: Temp
  572.                           entity: sensor.temp_bedroom
  573.                           show_icon: true
  574.                           show_background: false
  575.                           show_state: true
  576.                       styles: |
  577.                        .bubble-name-container {
  578.                           margin-left: 0px;
  579.                           margin-right: 0px;
  580.                           font-size: 12px !important;
  581.                             }
  582.  
  583.                         .bubble-icon-container {
  584.                           margin-left: 0px;
  585.                           margin-right: 1px;
  586.                             }
  587.  
  588.                         .bubble-sub-button {
  589.                           margin-left: 0px;
  590.                           margin-right: -25px;
  591.                           background: none !important;
  592.                           border-radius: 0;
  593.                           font-size: 8px !important;
  594.                             }
  595.                         .bubble-state {
  596.                           font-size: 8px !important;
  597.                             }
  598.  
  599.                         .bubble-sub-button-2 > ha-icon {
  600.                          color: ${hass.states['sensor.temp_bedroom'].state <= 15 ? 'var(--low-colour)'
  601.                          : hass.states['sensor.temp_bedroom'].state <= 25 ? 'var(--primary-button-colour)'
  602.                          : 'var(--high-colour)'} !important;
  603.                           }
  604.                         .bubble-sub-button-2 {
  605.                          color: ${hass.states['sensor.temp_bedroom'].state <= 15 ? 'var(--low-colour)'
  606.                          : hass.states['sensor.temp_bedroom'].state <= 25 ? 'var(--primary-button-colour)'
  607.                          : 'var(--high-colour)'} !important;
  608.                         }
  609.  
  610.                         .bubble-sub-button-1 {
  611.                          color: ${hass.states['input_select.light_bedroom_globe_mode'].state === 'Bright' ? 'var(--light-bright)'
  612.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Soft' ? 'var(--light-soft)'  
  613.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Dim' ? 'var(--light-dim)'
  614.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Dark' ? 'var(--light-dark)'
  615.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Night' ? 'var(--light-soft)'
  616.                          : 'var(--primary-button-colour)'} !important;
  617.                         }
  618.                         .bubble-sub-button-1 > ha-icon {
  619.                          color: ${hass.states['input_select.light_bedroom_globe_mode'].state === 'Bright' ? 'var(--light-bright)'
  620.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Soft' ? 'var(--light-soft)'  
  621.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Dim' ? 'var(--light-dim)'
  622.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Dark' ? 'var(--light-dark)'
  623.                          : hass.states['input_select.light_bedroom_globe_mode'].state === 'Night' ? 'var(--light-soft)'
  624.                          : 'var(--primary-button-colour)'} !important;
  625.                         }
  626.  
  627.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_bedroom'].state <= 15 ? 'mdi:thermometer-chevron-down'
  628.                           : hass.states['sensor.temp_bedroom'].state <= 25 ? 'mdi:thermometer'
  629.                           : 'mdi:thermometer-chevron-up')}
  630.  
  631.                 - type: conditional  # Bedroom Lamp
  632.                   conditions:
  633.                     - entity: input_select.light_bedroom
  634.                       state: "Lamp"
  635.                   card:
  636.                       type: custom:bubble-card
  637.                       card_type: button
  638.                       button_type: slider
  639.                       scrolling_effect: false
  640.                       show_last_changed: true
  641.                       show_attribute: false
  642.                       show_state: false
  643.                       show_name: false
  644.                       columns: 1
  645.                       card_layout: large-2-rows
  646.                       entity: light.bedroom_lamp
  647.                       tap_action:
  648.                         action: toggle
  649.                       double_tap_action:
  650.                         action: more-info
  651.                       hold_action:
  652.                         action: call-service
  653.                         service: input_select.select_option
  654.                         data:
  655.                           entity_id: input_select.light_bedroom
  656.                           option: "Globe"
  657.                       sub_button:
  658.                         - name: Mode
  659.                           entity: input_select.light_bedroom_lamp_mode
  660.                           show_icon: true
  661.                           icon:
  662.                           show_background: false
  663.                           show_state: true
  664.                           icon: mdi:lightbulb-group-outline
  665.  
  666.                         - name: Temp
  667.                           entity: sensor.temp_bedroom
  668.                           show_icon: true
  669.                           show_background: false
  670.                           show_state: true
  671.                       styles: |
  672.                        .bubble-name-container {
  673.                           margin-left: 0px;
  674.                           margin-right: 0px;
  675.                           font-size: 12px !important;
  676.                             }
  677.  
  678.                         .bubble-icon-container {
  679.                           margin-left: 0px;
  680.                           margin-right: 1px;
  681.                             }
  682.  
  683.                         .bubble-sub-button {
  684.                           margin-left: 0px;
  685.                           margin-right: -25px;
  686.                           background: none !important;
  687.                           border-radius: 0;
  688.                           font-size: 8px !important;
  689.                             }
  690.                         .bubble-state {
  691.                           font-size: 8px !important;
  692.                             }
  693.  
  694.                         .bubble-sub-button-2 > ha-icon {
  695.                          color: ${hass.states['sensor.temp_bedroom'].state <= 15 ? 'var(--low-colour)'
  696.                          : hass.states['sensor.temp_bedroom'].state <= 25 ? 'var(--primary-button-colour)'
  697.                          : 'var(--high-colour)'} !important;
  698.                           }
  699.                         .bubble-sub-button-2 {
  700.                          color: ${hass.states['sensor.temp_bedroom'].state <= 15 ? 'var(--low-colour)'
  701.                          : hass.states['sensor.temp_bedroom'].state <= 25 ? 'var(--primary-button-colour)'
  702.                          : 'var(--high-colour)'} !important;
  703.                         }
  704.  
  705.                         .bubble-sub-button-1 {
  706.                          color: ${hass.states['input_select.light_bedroom_lamp_mode'].state === 'Bright' ? 'var(--light-bright)'
  707.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Soft' ? 'var(--light-soft)'  
  708.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Dim' ? 'var(--light-dim)'
  709.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Dark' ? 'var(--light-dark)'
  710.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Night' ? 'var(--light-soft)'
  711.                          : 'var(--primary-button-colour)'} !important;
  712.                         }
  713.                         .bubble-sub-button-1 > ha-icon {
  714.                          color: ${hass.states['input_select.light_bedroom_lamp_mode'].state === 'Bright' ? 'var(--light-bright)'
  715.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Soft' ? 'var(--light-soft)'  
  716.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Dim' ? 'var(--light-dim)'
  717.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Dark' ? 'var(--light-dark)'
  718.                          : hass.states['input_select.light_bedroom_lamp_mode'].state === 'Night' ? 'var(--light-soft)'
  719.                          : 'var(--primary-button-colour)'} !important;
  720.                         }
  721.  
  722.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_bedroom'].state <= 15 ? 'mdi:thermometer-chevron-down'
  723.                           : hass.states['sensor.temp_bedroom'].state <= 25 ? 'mdi:thermometer'
  724.                           : 'mdi:thermometer-chevron-up')}
  725.  
  726.  
  727.                 - type: custom:bubble-card ## Bathroom Light
  728.                   card_type: button
  729.                   button_type: slider
  730.                   scrolling_effect: false
  731.                   show_last_changed: true
  732.                   show_attribute: false
  733.                   show_state: false
  734.                   show_name: false
  735.                   columns: 1
  736.                   card_layout: large-2-rows
  737.                   entity: light.bathroom
  738.                   tap_action:
  739.                     action: toggle
  740.                   double_tap_action:
  741.                     action: more-info
  742.                   sub_button:
  743.                     - name: Mode
  744.                       entity: input_select.light_bathroom_mode
  745.                       show_icon: true
  746.                       icon:
  747.                       show_background: false
  748.                       show_state: true
  749.                       icon: mdi:lightbulb-group-outline
  750.  
  751.                     - name: Temp
  752.                       entity: sensor.temp_bathroom
  753.                       show_icon: true
  754.                       show_background: false
  755.                       show_state: true
  756.                   styles: |
  757.                        .bubble-name-container {
  758.                           margin-left: 0px;
  759.                           margin-right: 0px;
  760.                           font-size: 12px !important;
  761.                             }
  762.  
  763.                         .bubble-icon-container {
  764.                           margin-left: 0px;
  765.                           margin-right: 1px;
  766.                             }
  767.  
  768.                         .bubble-sub-button {
  769.                           margin-left: 0px;
  770.                           margin-right: -25px;
  771.                           background: none !important;
  772.                           border-radius: 0;
  773.                           font-size: 8px !important;
  774.                             }
  775.  
  776.                         .bubble-state {
  777.                           font-size: 8px !important;
  778.                             }
  779.  
  780.                         .bubble-sub-button-2 > ha-icon {
  781.                          color: ${hass.states['sensor.temp_bathroom'].state <= 15 ? 'var(--low-colour)'
  782.                          : hass.states['sensor.temp_bathroom'].state <= 25 ? 'var(--primary-button-colour)'
  783.                          : 'var(--high-colour)'} !important;
  784.                           }
  785.                         .bubble-sub-button-2 {
  786.                          color: ${hass.states['sensor.temp_bathroom'].state <= 15 ? 'var(--low-colour)'
  787.                          : hass.states['sensor.temp_bathroom'].state <= 25 ? 'var(--primary-button-colour)'
  788.                          : 'var(--high-colour)'} !important;
  789.                         }
  790.  
  791.                         .bubble-sub-button-1 {
  792.                          color: ${hass.states['input_select.light_bathroom_mode'].state === 'Bright' ? 'var(--light-bright)'
  793.                          : hass.states['input_select.light_bathroom_mode'].state === 'Soft' ? 'var(--light-soft)'  
  794.                          : hass.states['input_select.light_bathroom_mode'].state === 'Dim' ? 'var(--light-dim)'
  795.                          : hass.states['input_select.light_bathroom_mode'].state === 'Dark' ? 'var(--light-dark)'
  796.                          : hass.states['input_select.light_bathroom_mode'].state === 'Night' ? 'var(--light-soft)'
  797.                          : 'var(--primary-button-colour)'} !important;
  798.                         }
  799.                         .bubble-sub-button-1 > ha-icon {
  800.                          color: ${hass.states['input_select.light_bathroom_mode'].state === 'Bright' ? 'var(--light-bright)'
  801.                          : hass.states['input_select.light_bathroom_mode'].state === 'Soft' ? 'var(--light-soft)'  
  802.                          : hass.states['input_select.light_bathroom_mode'].state === 'Dim' ? 'var(--light-dim)'
  803.                          : hass.states['input_select.light_bathroom_mode'].state === 'Dark' ? 'var(--light-dark)'
  804.                          : hass.states['input_select.light_bathroom_mode'].state === 'Night' ? 'var(--light-soft)'
  805.                          : 'var(--primary-button-colour)'} !important;
  806.                         }
  807.  
  808.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_bathroom'].state <= 15 ? 'mdi:thermometer-chevron-down'
  809.                           : hass.states['sensor.temp_bathroom'].state <= 25 ? 'mdi:thermometer'
  810.                           : 'mdi:thermometer-chevron-up')}
  811.                          
  812.             - type: horizontal-stack # 3rd Row Lights
  813.               cards:
  814.  
  815.                 - type: custom:bubble-card # Toilet Light
  816.                   card_type: button
  817.                   button_type: slider
  818.                   scrolling_effect: false
  819.                   show_last_changed: true
  820.                   show_attribute: false
  821.                   show_state: false
  822.                   show_name: false
  823.                   columns: 1
  824.                   card_layout: large-2-rows
  825.                   entity: light.toilet
  826.                   tap_action:
  827.                     action: toggle
  828.                   double_tap_action:
  829.                     action: more-info
  830.                   sub_button:
  831.                     - name: Mode
  832.                       entity: input_select.light_toilet_mode
  833.  
  834.                       show_icon: true
  835.                       icon:
  836.                       show_background: false
  837.                       show_state: true
  838.                       icon: mdi:lightbulb-group-outline
  839.  
  840.                     - name: Temp
  841.                       entity: sensor.temp_toilet
  842.                       show_icon: true
  843.                       show_background: false
  844.                       show_state: true
  845.                   styles: |
  846.                        .bubble-name-container {
  847.                           margin-left: 0px;
  848.                           margin-right: 0px;
  849.                           font-size: 12px !important;
  850.                             }
  851.  
  852.                         .bubble-icon-container {
  853.                           margin-left: 0px;
  854.                           margin-right: 1px;
  855.                             }
  856.  
  857.                         .bubble-sub-button {
  858.                           margin-left: 0px;
  859.                           margin-right: -25px;
  860.                           background: none !important;
  861.                           border-radius: 0;
  862.                           font-size: 8px !important;
  863.                             }
  864.                         .bubble-state {
  865.                           font-size: 8px !important;
  866.                             }
  867.  
  868.                         .bubble-sub-button-2 > ha-icon {
  869.                          color: ${hass.states['sensor.temp_toilet'].state <= 15 ? 'var(--low-colour)'
  870.                          : hass.states['sensor.temp_toilet'].state <= 25 ? 'var(--primary-button-colour)'
  871.                          : 'var(--high-colour)'} !important;
  872.                           }
  873.                         .bubble-sub-button-2 {
  874.                          color: ${hass.states['sensor.temp_toilet'].state <= 15 ? 'var(--low-colour)'
  875.                          : hass.states['sensor.temp_toilet'].state <= 25 ? 'var(--primary-button-colour)'
  876.                          : 'var(--high-colour)'} !important;
  877.                         }
  878.  
  879.                         .bubble-sub-button-1 {
  880.                          color: ${hass.states['input_select.light_toilet_mode'].state === 'Bright' ? 'var(--light-bright)'
  881.                          : hass.states['input_select.light_toilet_mode'].state === 'Soft' ? 'var(--light-soft)'  
  882.                          : hass.states['input_select.light_toilet_mode'].state === 'Dim' ? 'var(--light-dim)'
  883.                          : hass.states['input_select.light_toilet_mode'].state === 'Dark' ? 'var(--light-dark)'
  884.                          : hass.states['input_select.light_toilet_mode'].state === 'Night' ? 'var(--light-soft)'
  885.                          : 'var(--primary-button-colour)'} !important;
  886.                         }
  887.                         .bubble-sub-button-1 > ha-icon {
  888.                          color: ${hass.states['input_select.light_toilet_mode'].state === 'Bright' ? 'var(--light-bright)'
  889.                          : hass.states['input_select.light_toilet_mode'].state === 'Soft' ? 'var(--light-soft)'  
  890.                          : hass.states['input_select.light_toilet_mode'].state === 'Dim' ? 'var(--light-dim)'
  891.                          : hass.states['input_select.light_toilet_mode'].state === 'Dark' ? 'var(--light-dark)'
  892.                          : hass.states['input_select.light_toilet_mode'].state === 'Night' ? 'var(--light-soft)'
  893.                          : 'var(--primary-button-colour)'} !important;
  894.                         }
  895.  
  896.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_toilet'].state <= 15 ? 'mdi:thermometer-chevron-down'
  897.                           : hass.states['sensor.temp_toilet'].state <= 25 ? 'mdi:thermometer'
  898.                           : 'mdi:thermometer-chevron-up')}
  899.                          
  900.  
  901.                 - type: custom:bubble-card # Laundry Light
  902.                   card_type: button
  903.                   button_type: slider
  904.                   scrolling_effect: false
  905.                   show_last_changed: true
  906.                   show_attribute: false
  907.                   show_state: false
  908.                   show_name: false
  909.                   columns: 1
  910.                   card_layout: large-2-rows
  911.                   entity: light.laundry
  912.                   tap_action:
  913.                     action: toggle
  914.                   double_tap_action:
  915.                     action: more-info
  916.                   sub_button:
  917.                     - name: Mode
  918.                       entity: input_select.light_laundry_mode
  919.                       show_icon: true
  920.                       icon:
  921.                       show_background: false
  922.                       show_state: true
  923.                       icon: mdi:lightbulb-group-outline
  924.  
  925.                     - name: Temp
  926.                       entity: sensor.temp_laundry
  927.                       show_icon: true
  928.                       show_background: false
  929.                       show_state: true
  930.                   styles: |
  931.                        .bubble-name-container {
  932.                           margin-left: 0px;
  933.                           margin-right: 0px;
  934.                           font-size: 12px !important;
  935.                             }
  936.  
  937.                         .bubble-icon-container {
  938.                           margin-left: 0px;
  939.                           margin-right: 1px;
  940.                             }
  941.  
  942.                         .bubble-sub-button {
  943.                           margin-left: 0px;
  944.                           margin-right: -25px;
  945.                           background: none !important;
  946.                           border-radius: 0;
  947.                           font-size: 8px !important;
  948.                             }
  949.                         .bubble-state {
  950.                           font-size: 8px !important;
  951.                             }
  952.  
  953.                         .bubble-sub-button-2 > ha-icon {
  954.                          color: ${hass.states['sensor.temp_laundry'].state <= 15 ? 'var(--low-colour)'
  955.                          : hass.states['sensor.temp_laundry'].state <= 25 ? 'var(--primary-button-colour)'
  956.                          : 'var(--high-colour)'} !important;
  957.                           }
  958.                         .bubble-sub-button-2 {
  959.                          color: ${hass.states['sensor.temp_laundry'].state <= 15 ? 'var(--low-colour)'
  960.                          : hass.states['sensor.temp_laundry'].state <= 25 ? 'var(--primary-button-colour)'
  961.                          : 'var(--high-colour)'} !important;
  962.                         }
  963.  
  964.                         .bubble-sub-button-1 {
  965.                          color: ${hass.states['input_select.light_laundry_mode'].state === 'Bright' ? 'var(--light-bright)'
  966.                          : hass.states['input_select.light_laundry_mode'].state === 'Soft' ? 'var(--light-soft)'  
  967.                          : hass.states['input_select.light_laundry_mode'].state === 'Dim' ? 'var(--light-dim)'
  968.                          : hass.states['input_select.light_laundry_mode'].state === 'Dark' ? 'var(--light-dark)'
  969.                          : hass.states['input_select.light_laundry_mode'].state === 'Night' ? 'var(--light-soft)'
  970.                          : 'var(--primary-button-colour)'} !important;
  971.                         }
  972.                         .bubble-sub-button-1 > ha-icon {
  973.                          color: ${hass.states['input_select.light_laundry_mode'].state === 'Bright' ? 'var(--light-bright)'
  974.                          : hass.states['input_select.light_laundry_mode'].state === 'Soft' ? 'var(--light-soft)'  
  975.                          : hass.states['input_select.light_laundry_mode'].state === 'Dim' ? 'var(--light-dim)'
  976.                          : hass.states['input_select.light_laundry_mode'].state === 'Dark' ? 'var(--light-dark)'
  977.                          : hass.states['input_select.light_laundry_mode'].state === 'Night' ? 'var(--light-soft)'
  978.                          : 'var(--primary-button-colour)'} !important;
  979.                         }
  980.  
  981.                         ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_laundry'].state <= 15 ? 'mdi:thermometer-chevron-down'
  982.                           : hass.states['sensor.temp_laundry'].state <= 25 ? 'mdi:thermometer'
  983.                           : 'mdi:thermometer-chevron-up')}
  984.  
  985.  
  986.       - type: vertical-stack # 2nd Page Colum
  987.         cards:
  988.         - type: vertical-stack # Group 1 - Blinds
  989.           cards:
  990.           - type: custom:bubble-card
  991.             card_type: separator
  992.             name: Blinds
  993.             icon: mdi:roller-shade
  994.             show_state: true
  995.  
  996.  
  997.           - type: horizontal-stack
  998.             cards:
  999.               - type: custom:bubble-card  # Lounge Blinds
  1000.                 card_type: button
  1001.                 button_type: slider
  1002.                 entity: cover.curtain_lounge
  1003.                 name: Lounge
  1004.                 show_state: false
  1005.                 show_attribute: true
  1006.                 attribute: current_position
  1007.                 card_layout: normal
  1008.                 icon_open: mdi:blinds-vertical
  1009.                 icon: mdi:blinds-vertical-closed
  1010.                 styles: |
  1011.                  .bubble-range-fill {
  1012.                     background: var(--cover-colour) !important;
  1013.                     opacity: 1 !important;
  1014.                   }
  1015.                   .bubble-icon {
  1016.                     color: var(--cover-colour) !important;
  1017.                     opacity: 1 !important;
  1018.                   }
  1019.  
  1020.               - type: custom:bubble-card  # Laundry Blinds
  1021.                 card_type: button
  1022.                 name: Laundry
  1023.                 button_type: slider
  1024.                 entity: cover.curtain_laundry
  1025.                 show_state: false
  1026.                 show_attribute: true
  1027.                 attribute: current_position
  1028.                 scrolling_effect: true
  1029.                 card_layout: normal
  1030.                 icon_open: mdi:roller-shade
  1031.                 icon: mdi:roller-shade-closed
  1032.                 styles: |
  1033.                  .bubble-range-fill {
  1034.                     background: var(--cover-colour) !important;
  1035.                     opacity: 1 !important;
  1036.                   }
  1037.                   .bubble-icon {
  1038.                     color: var(--cover-colour) !important;
  1039.                     opacity: 1 !important;
  1040.                   }
  1041.  
  1042.         - type: vertical-stack # Group 2 - Climate
  1043.           cards:
  1044.           - type: custom:bubble-card
  1045.             card_type: separator
  1046.             name: Climate
  1047.             icon: mdi:home-assistant
  1048.  
  1049.           - type: custom:bubble-card # Row 1 - Aircon
  1050.             card_type: button
  1051.             button_type: switch
  1052.             scrolling_effect: false
  1053.             show_last_changed: false
  1054.             show_attribute: true
  1055.             show_state: false
  1056.             show_name: false
  1057.             name: Aircon
  1058.             card_layout: large-2-rows
  1059.             entity: switch.aircon_change_settings
  1060.             double_tap_action:
  1061.               action: call-service
  1062.               service: switch.turn_off
  1063.               service_data:
  1064.                 entity_id: switch.aircon
  1065.             tap_action:
  1066.               action: call-service
  1067.               service: input_boolean.turn_on
  1068.               service_data:
  1069.                 entity_id: input_boolean.aircon_change_settings
  1070.             hold_action:
  1071.                action: call-service
  1072.                service: input_select.select_next
  1073.                service_data:
  1074.                 entity_id: input_select.aircon_mode
  1075.             sub_button:
  1076.               - name: Current Speed Settings
  1077.                 entity: input_select.aircon_speed
  1078.                 show_icon: true
  1079.                 icon: mdi:fan
  1080.                 show_background: false
  1081.                 show_state: true
  1082.                 show_name: false
  1083.  
  1084.  
  1085.               - name: Mode
  1086.                 entity: input_number.aircon_temp
  1087.                 show_icon: true
  1088.                 show_background: false
  1089.                 show_state: true
  1090.  
  1091.  
  1092.               - name: Fan Increase
  1093.                 entity: input_select.aircon_speed
  1094.                 show_name: false
  1095.                 show_icon: true
  1096.                 icon: mdi:fan-plus
  1097.                 show_background: false
  1098.                 show_state: false
  1099.                 tap_action:
  1100.                   action: call-service
  1101.                   service: input_select.select_next
  1102.                   service_data:
  1103.                     entity_id: input_select.aircon_speed
  1104.  
  1105.               - name: Fan Increase
  1106.                 entity: input_select.aircon_speed
  1107.                 show_name: false
  1108.                 show_icon: true
  1109.                 icon: mdi:fan-minus
  1110.                 show_background: false
  1111.                 show_state: false
  1112.                 tap_action:
  1113.                   action: call-service
  1114.                   service: input_select.select_previous
  1115.                   service_data:
  1116.                     entity_id: input_select.aircon_speed
  1117.  
  1118.               - name: Temp Increase
  1119.                 entity: input_number.aircon_temp
  1120.                 show_name: false
  1121.                 show_icon: true
  1122.                 icon: mdi:thermometer-plus
  1123.                 show_background: false
  1124.                 show_state: false
  1125.                 tap_action:
  1126.                   action: call-service
  1127.                   service: input_number.increment
  1128.                   service_data:
  1129.                     entity_id: input_number.aircon_temp
  1130.  
  1131.               - name: Temp Decrease
  1132.                 entity: input_number.aircon_temp
  1133.                 show_name: false
  1134.                 show_icon: true
  1135.                 icon: mdi:thermometer-minus
  1136.                 show_background: false
  1137.                 show_state: false
  1138.                 tap_action:
  1139.                   action: call-service
  1140.                   service: input_number.decrement
  1141.                   service_data:
  1142.                     entity_id: input_number.aircon_temp
  1143.             styles: |
  1144.              .bubble-button-background {
  1145.                 background-color: var(--primary-background-colour) !important;
  1146.               }
  1147.               ${card.querySelector('.bubble-state').innerText = hass.states['input_text.aircon_settings_last_sent_to_aircon'].state}
  1148.               .bubble-icon-container {
  1149.                 margin-left: 0px;
  1150.                 margin-right: 1px;
  1151.                   }
  1152.  
  1153.               .bubble-state {
  1154.                 font-size: 10px !important;
  1155.                 color: ${hass.states['sensor.aircon_settings_not_updated_since_change'].state == 'True' ? 'var(--primary-button-colour)'
  1156.                 : '' }  !important;
  1157.                 animation: ${hass.states['sensor.aircon_settings_not_updated_since_change'].state == 'True' ? 'blink 3s linear infinite'
  1158.                 : '' }  !important;
  1159.                   }
  1160.  
  1161.               {}
  1162.               .bubble-icon {
  1163.                 animation: ${hass.states['switch.aircon'].state == 'off' ? 'var(--primary-button-colour)'
  1164.                 : hass.states['input_select.aircon_speed'].state == '0' ? 'rotate 6s linear infinite'
  1165.                 : hass.states['input_select.aircon_speed'].state == '1' ? 'rotate 5s linear infinite'
  1166.                 : hass.states['input_select.aircon_speed'].state == '2' ? 'rotate 4s linear infinite'
  1167.                 : hass.states['input_select.aircon_speed'].state == '3' ? 'rotate 3s linear infinite'
  1168.                 : hass.states['input_select.aircon_speed'].state == '4' ? 'rotate 2s linear infinite'
  1169.                 : hass.states['input_select.aircon_speed'].state == '5' ? 'rotate 1s linear infinite'
  1170.                 : ''};
  1171.                 color: ${hass.states['switch.aircon'].state == 'off' ? ' '
  1172.                 : hass.states['input_select.aircon_mode'].state === 'Fan' ? 'var(--secondary-button-colour)'
  1173.                 : hass.states['input_select.aircon_mode'].state === 'Heat' ? 'var(--high-colour)'
  1174.                 : hass.states['input_select.aircon_mode'].state === 'Cool' ? 'var(--low-colour)'
  1175.                 : hass.states['input_select.aircon_mode'].state === 'Dry' ? 'var(--mid-colour)'
  1176.                 : 'var(--primary-button-colour)' }  !important;
  1177.                            
  1178.                 }
  1179.                      
  1180.               ${icon.setAttribute("icon", hass.states['input_select.aircon_mode'].state === 'Fan' ? 'mdi:fan'
  1181.                 : hass.states['input_select.aircon_mode'].state === 'Heat' ? 'mdi:white-balance-sunny'
  1182.                 : hass.states['input_select.aircon_mode'].state === 'Cool' ? 'mdi:snowflake'
  1183.                 : hass.states['input_select.aircon_mode'].state === 'Dry' ? 'mdi:water-percent'
  1184.                 : 'mdi:air-conditioner')}  !important;
  1185.                 }
  1186.                 {}
  1187.               @keyframes rotate {
  1188.                     0% {
  1189.                       transform: rotate(0deg);
  1190.                     }
  1191.                     100% {
  1192.                       transform: rotate(360deg);
  1193.                     }
  1194.                   }
  1195.               @keyframes blink {
  1196.                 50% {opacity: 0; }
  1197.               }
  1198.  
  1199.               .bubble-sub-button-1 > ha-icon {
  1200.                 color: ${hass.states['input_select.aircon_speed'].state === '0' ? 'var(--low-colour)'
  1201.                 : hass.states['input_select.aircon_speed'].state === '1' ? 'var(--low-colour)'
  1202.                 : hass.states['input_select.aircon_speed'].state === '2' ? 'var(--mid-colour)'
  1203.                 : hass.states['input_select.aircon_speed'].state === '3' ? 'var(--mid-colour)'
  1204.                 : hass.states['input_select.aircon_speed'].state === '4' ? 'var(--high-colour)'
  1205.                 : hass.states['input_select.aircon_speed'].state === '5' ? 'var(--high-colour)'
  1206.                 : 'var(--high-colour)'
  1207.                 }}
  1208.                {}
  1209.               ${subButtonIcon[1].setAttribute("icon", hass.states['input_number.aircon_temp'].state <= 16 ? 'mdi:thermometer-chevron-down'
  1210.                 : hass.states['input_number.aircon_temp'].state <= 20 ? 'mdi:thermometer'
  1211.                 : 'mdi:thermometer-chevron-up')}
  1212.               {}
  1213.               .bubble-sub-button-2 > ha-icon {
  1214.                color: ${hass.states['input_number.aircon_temp'].state <= 16 ? 'var(--low-colour)'
  1215.                : hass.states['input_number.aircon_temp'].state <= 20 ? 'var(--primary-button-colour)'
  1216.                : 'var(--high-colour)'} !important;
  1217.               }
  1218.  
  1219.               ${subButtonIcon[1].setAttribute("icon", hass.states['input_number.aircon_temp'].state <= 16 ? 'mdi:thermometer-chevron-down'
  1220.                 : hass.states['input_number.aircon_temp'].state <= 20 ? 'mdi:thermometer'
  1221.                 : 'mdi:thermometer-chevron-up')}
  1222.                {}
  1223.               .bubble-sub-button-3 > ha-icon {
  1224.                 color: ${'var(--primary-button-colour)' }  !important;
  1225.                 }
  1226.               .bubble-sub-button-4 > ha-icon {
  1227.                 color: ${'var(--primary-button-colour)' }  !important;
  1228.                 }
  1229.               .bubble-sub-button-5 > ha-icon {
  1230.                 color: ${'var(--primary-button-colour)' }  !important;
  1231.                 }
  1232.               .bubble-sub-button-6 > ha-icon {
  1233.                 color: ${'var(--primary-button-colour)' }  !important;
  1234.                 }
  1235.  
  1236.  
  1237.           - type: custom:stack-in-card  # Row 2 - Switches
  1238.             mode: horizontal
  1239.             style:
  1240.                 .: |
  1241.                  ha-card {
  1242.                     border-radius: 35px;
  1243.                     overflow: hidden;
  1244.                     margin: 0 auto;
  1245.                     padding-top: 0px;
  1246.                   }
  1247.             cards:
  1248.  
  1249.               - type: 'custom:button-card' # Bedtime Mode
  1250.                 template: quick_switch_toggle_bedtime
  1251.                 entity: switch.bedtime
  1252.                 name: Bedtime
  1253.  
  1254.               - type: 'custom:button-card' # Bedroom Fan
  1255.                 template: quick_switch_toggle_fan
  1256.                 entity: switch.bedroom_fan
  1257.                 name: Bd. Fan
  1258.              
  1259.  
  1260.               - type: 'custom:button-card'  # Dehumidfier
  1261.                 template: quick_switch_toggle_dehumidifier
  1262.                 entity: fan.dehumidifier
  1263.                 name: d.Hum
  1264.  
  1265.               - type: 'custom:button-card' # Aircon Switch
  1266.                 template: quick_switch_toggle_aircon
  1267.                 entity: switch.aircon
  1268.                 name: Aircon
  1269.                
  1270.  
  1271.               - type: 'custom:button-card'  # Electric Blanket
  1272.                 template: quick_switch_toggle_blanket
  1273.                 entity: switch.blanket
  1274.                 name: Blanket
  1275.  
  1276.  
  1277.  
  1278.           - type: custom:bubble-card  # Row 3 - Weather
  1279.             card_type: button
  1280.             button_type: state
  1281.             entity: sensor.launceston_extended_text_0
  1282.             name: Weather
  1283.             scrolling_effect: true
  1284.             show_state: true
  1285.             card_layout: large-2-rows
  1286.             columns: 1
  1287.            
  1288.  
  1289.             styles: >-
  1290.               .bubble-icon {
  1291.                 color: var(--primary-button-colour) !important;
  1292.               }
  1293.               .bubble-state {
  1294.                 font-size: 9px !important;
  1295.                   }
  1296.               .bubble-sub-button {
  1297.                 background: none !important;
  1298.                 font-size: 10px !important;
  1299.                 align-content: right;
  1300.                   }
  1301.               ${icon.setAttribute("icon", getWeatherIcon(hass.states['weather.launceston'].state))}
  1302.               ${card.querySelector('.bubble-name').innerText = "Outside: " + hass.states['sensor.launceston_min_to_max'].state}
  1303.              
  1304.        - type: vertical-stack # Group 3 - Work
  1305.          cards:    
  1306.  
  1307.          - type: custom:bubble-card
  1308.            card_type: separator
  1309.            name: Work
  1310.            icon: mdi:home-assistant
  1311.        
  1312.          - type: 'custom:button-card'  # Row 4 - Work
  1313.            template: work_details
  1314.            entity: sensor.work_message
  1315.            style:
  1316.                  .: |
  1317.                    ha-card {
  1318.                      border-radius: 35px;
  1319.                      overflow: hidden;
  1320.                      margin: 0 auto;
  1321.                      padding-top: 0px;
  1322.                    }
  1323.  
  1324.  
  1325.  
  1326.  
  1327. #### ui-lovelace file for Button Card Templates
  1328.  
  1329. button_card_templates:
  1330.  haptic:
  1331.    # triggers_update: all
  1332.    tap_action:
  1333.      haptic: light
  1334.      action: more-info
  1335.    hold_action:
  1336.      haptic: success
  1337.      action: more-info
  1338.    double_tap_action:
  1339.      haptic: success
  1340.      action: more-info
  1341.    state:
  1342.      - value: Unknown
  1343.        icon: 'mdi:help'
  1344.        color: black
  1345.    styles:
  1346.      card:
  1347.        # - border-radius: 40%
  1348.        - --mdc-ripple-color: var(--secondary-button-colour)
  1349.        - --mdc-ripple-press-opacity: 0.5
  1350.    style: |
  1351.        ha-card {
  1352.          box-shadow: none;
  1353.          ha-card-border-radius: 50px
  1354.          overflow: hidden;
  1355.        }
  1356.  
  1357.  1_state_small:
  1358.    template: haptic
  1359.    show_name: true
  1360.    show_state: false
  1361.    show_icon: true
  1362.    show_label: false
  1363.    show_last_changed: true
  1364.    styles:
  1365.      card:
  1366.        - font-weight: bold
  1367.        - font-size: 13px
  1368.        - color: var(primary-text-color)
  1369.        - align-self: start
  1370.        - justify-self: start
  1371.        - padding-bottom: 4px
  1372.        - text-shadow: 0px 0px 5px black
  1373.        - text-transform: capitalize
  1374.        - color: auto
  1375.      name:
  1376.        - font-size: 13px
  1377.        - color: var(primary-text-color)
  1378.        - align-self: middle
  1379.        - justify-self: middle
  1380.      label:
  1381.        - font-size: 8px
  1382.        - color: var(primary-text-color)
  1383.        - align-self: middle
  1384.        - justify-self: middle
  1385.      state:
  1386.        - font-size: 13px
  1387.        - color: var(primary-text-color)
  1388.        - align-self: middle
  1389.        - justify-self: middle
  1390.  
  1391.  1_lock:
  1392.    template: 1_state_small
  1393.    entity: lock.front_door
  1394.    tap_action:
  1395.      action: call-service
  1396.      service: script.turn_on
  1397.      service_data:
  1398.        entity_id: script.lock_toggle
  1399.    hold_action:
  1400.      action: more-info
  1401.    double_tap_action:
  1402.      action: call-service
  1403.      service: lock.unlock
  1404.      service_data:
  1405.        entity_id: lock.front_door
  1406.    state:
  1407.      - color: var(--primary-button-colour)
  1408.        icon: mdi:door-closed-lock
  1409.        value: 'on'
  1410.      - color: var(--secondary-button-colour)
  1411.        icon: mdi:door-open
  1412.        value: 'off'
  1413.  
  1414.  1_alarm:
  1415.    template: 1_state_small
  1416.    show_state: true
  1417.    tap_action:
  1418.      action: call-service
  1419.      service: switch.toggle
  1420.      service_data:
  1421.        entity_id: switch.security_home
  1422.    hold_action:
  1423.      action: call-service
  1424.      service: alarm_control_panel.alarm_disarm
  1425.      service_data:
  1426.        entity_id: alarm_control_panel.security
  1427.    double_tap_action:
  1428.      action: more-info
  1429.    state:
  1430.      - color: var(--low-colour)
  1431.        icon: 'mdi:shield-off'
  1432.        operator: template
  1433.        value: >
  1434.          [[[
  1435.            var kitdis = states['input_boolean.security_disarmed_occupied_kitchen'].state;
  1436.            var security = states['alarm_control_panel.security'].state;
  1437.            return (security === 'disarmed' && kitdis === 'on');
  1438.          ]]]
  1439.        label: 'Disarmed'
  1440.      - color: var(--high-colour)
  1441.        icon: 'mdi:shield-off'
  1442.        operator: template
  1443.        value: >
  1444.          [[[
  1445.            var delayarm = states['input_boolean.security_home_delayed_by_screen_door'].state;
  1446.            var security = states['alarm_control_panel.security'].state;
  1447.            return (security === 'disarmed' && delayarm === 'on');
  1448.          ]]]      
  1449.        label: >
  1450.          [[[
  1451.            return states['sensor.security_delay_arm_end'].state;
  1452.          ]]]    
  1453.        styles:
  1454.          icon:
  1455.            - animation: >
  1456.                 [[[
  1457.                    var rem = states['sensor.security_delay_arm_end_seconds'].state;
  1458.                    if (rem > 300) return 'blink 10s ease infinite';
  1459.                    if (rem > 180) return 'blink 5s ease infinite';
  1460.                    if (rem > 120) return 'blink 3s ease infinite';
  1461.                    if (rem > 60) return 'blink 2s ease infinite';
  1462.                    return 'blink 1s ease infinite';
  1463.                 ]]]        
  1464.      - color: var(--primary-button-colour)
  1465.        icon: 'mdi:shield-off'
  1466.        value: disarmed
  1467.        label: 'Disarmed'
  1468.      - color: var(--primary-button-colour)
  1469.        icon: 'mdi:shield-home'
  1470.        value: armed_home
  1471.        label: Home
  1472.      - color: var(--primary-button-colour)
  1473.        icon: 'mdi:shield-lock'
  1474.        value: armed_night
  1475.        label: Night
  1476.      - color: var(--primary-button-colour)
  1477.        icon: 'mdi:shield-key'
  1478.        value: armed_away
  1479.        label: Away
  1480.      - color: var(--secondary-button-colour)
  1481.        icon: 'mdi:bell-alert'
  1482.        styles:
  1483.          card:
  1484.            - animation: blink 3s ease infinite
  1485.        value: triggered
  1486.        label: Alarm!!
  1487.      - color: var(--primary-button-colour)
  1488.        icon: 'mdi:bell-alert'
  1489.        value: pending
  1490.        label: Pendings
  1491.  
  1492.  1_garage_door:
  1493.    template: 1_state_small
  1494.    show_last_changed: true
  1495.    state:
  1496.      - color: var(--secondary-button-colour)
  1497.        icon: 'mdi:garage-open-variant'
  1498.        value: 'open'
  1499.      - color: var(--secondary-button-colour)
  1500.        icon: 'mdi:garage-open-variant'
  1501.        value: 'opening'
  1502.      - color: var(--secondary-button-colour)
  1503.        icon: 'mdi:garage-open-variant'
  1504.        value: 'closing'
  1505.      - color: var(--primary-button-colour)
  1506.        icon: 'mdi:garage-variant'
  1507.        value: 'closed'
  1508.  
  1509.  
  1510.  quick_switch_toggle:
  1511.    template: haptic
  1512.    tap_action:
  1513.      action: toggle
  1514.    hold_action:
  1515.      action: more-info
  1516.    show_label: true
  1517.    show_last_changed: true
  1518.    styles:
  1519.      card:
  1520.        - font-weight: bold
  1521.        - font-size: 13px
  1522.        - color: var(primary-text-color)
  1523.        - align-self: start
  1524.        - justify-self: start
  1525.        - padding-bottom: 4px
  1526.        - text-shadow: 0px 0px 5px black
  1527.        - text-transform: capitalize
  1528.        - color: auto
  1529.      name:
  1530.        - font-weight: bold
  1531.        - font-size: 13px
  1532.        - color: var(primary-text-color)
  1533.        - align-self: middle
  1534.        - justify-self: middle
  1535.        - padding-bottom: 4px
  1536.      label:
  1537.        - font-size: 8px
  1538.        - color: var(primary-text-color)
  1539.        - align-self: middle
  1540.        - justify-self: middle
  1541.  
  1542.  quick_switch_toggle_bedtime:
  1543.    template: quick_switch_toggle
  1544.    state:
  1545.      - color: var(--secondary-button-colour)
  1546.        icon: 'mdi:sleep'
  1547.        value: 'on'
  1548.      - color: var(--primary-button-colour)
  1549.        icon: 'mdi:sleep-off'
  1550.        value: 'off'
  1551.  
  1552.  quick_switch_toggle_fan:  
  1553.    template: quick_switch_toggle
  1554.    name: Fan
  1555.    state:
  1556.      - color: var(--secondary-button-colour)
  1557.        icon: 'mdi:fan'
  1558.        value: 'on'
  1559.      - color: var(--primary-button-colour)
  1560.        icon: 'mdi:fan-off'
  1561.        value: 'off'
  1562.  
  1563.  quick_switch_toggle_dehumidifier:  
  1564.    template: quick_switch_toggle
  1565.    state:
  1566.      - color: var(--secondary-button-colour)
  1567.        icon: 'mdi:air-humidifier'
  1568.        value: 'on'
  1569.      - color: var(--primary-button-colour)
  1570.        icon: 'mdi:air-humidifier-off'
  1571.        value: 'off'
  1572.  
  1573.  quick_switch_toggle_bedtime:
  1574.    template: quick_switch_toggle
  1575.    state:
  1576.      - color: var(--secondary-button-colour)
  1577.        icon: 'mdi:sleep'
  1578.        value: 'on'
  1579.      - color: var(--primary-button-colour)
  1580.        icon: 'mdi:sleep-off'
  1581.        value: 'off'
  1582.  
  1583.  quick_switch_toggle_blanket:  
  1584.    template: quick_switch_toggle
  1585.    tap_action:
  1586.      action: toggle
  1587.    double_tap_action:
  1588.      action: call-service
  1589.      service: script.turn_on
  1590.      service_data:
  1591.        entity_id: script.blanket_10_minutes
  1592.    state:
  1593.      - color: var(--primary-button-colour)
  1594.        icon: 'mdi:heating-coil'
  1595.        value: 'off'
  1596.          
  1597.      - color: var(--high-colour)
  1598.        icon: 'mdi:heating-coil'
  1599.        value: 'on'
  1600.  
  1601.  quick_switch_toggle_aircon:  
  1602.    template: quick_switch_toggle
  1603.    double_tap_action:
  1604.      action: call-service
  1605.      service: input_select.select_next
  1606.      service_data:
  1607.        entity_id: input_select.aircon_mode
  1608.    state:
  1609.      - color: var(--primary-button-colour)
  1610.        icon: 'mdi:fan'
  1611.        operator: template
  1612.        value: >
  1613.          [[[
  1614.            var ac = states['switch.aircon'].state;
  1615.            return (ac === 'off' && /F/.test(states['input_select.aircon_mode'].state));
  1616.          ]]]
  1617.          
  1618.      - color: var(--secondary-button-colour)
  1619.        icon: 'mdi:fan'
  1620.        operator: template
  1621.        value: >
  1622.          [[[
  1623.            var ac = states['switch.aircon'].state;
  1624.            return (ac === 'on' &&  /F/.test(states['input_select.aircon_mode'].state));
  1625.          ]]]
  1626.      - color: var(--primary-button-colour)
  1627.        icon: 'mdi:snowflake'
  1628.        operator: template
  1629.        value: >
  1630.          [[[
  1631.            var ac = states['switch.aircon'].state;
  1632.            return (ac === 'off' && /C/.test(states['input_select.aircon_mode'].state));
  1633.          ]]]
  1634.      - color: var(--secondary-button-colour)
  1635.        icon: 'mdi:snowflake'
  1636.        operator: template
  1637.        value: >
  1638.          [[[
  1639.            var ac = states['switch.aircon'].state;
  1640.            return (ac === 'on' && /C/.test(states['input_select.aircon_mode'].state));
  1641.          ]]]
  1642.      - color: var(--primary-button-colour)
  1643.        icon: 'mdi:white-balance-sunny'
  1644.        operator: template
  1645.        value: >
  1646.          [[[
  1647.            var ac = states['switch.aircon'].state;
  1648.            return (ac === 'off' && /H/.test(states['input_select.aircon_mode'].state));
  1649.          ]]]
  1650.      - color: var(--secondary-button-colour)
  1651.        icon: 'mdi:white-balance-sunny'
  1652.        operator: template
  1653.        value: >
  1654.          [[[
  1655.            var ac = states['switch.aircon'].state;
  1656.            return (ac === 'on' && /H/.test(states['input_select.aircon_mode'].state));
  1657.          ]]]
  1658.  
  1659.  work_details:
  1660.    template: haptic
  1661.    show_icon: false
  1662.    show_state: true
  1663.    show_label: true
  1664.    show_name: false
  1665.    icon: 'mdi:store'
  1666.    styles:
  1667.      grid:
  1668.        - grid-template-areas: '"s" "l"'
  1669.        - grid-template-columns: 1fr
  1670.        - grid-template-rows: 1fr min-content
  1671.    tap_action:
  1672.      action: call-service
  1673.      service: input_boolean.toggle
  1674.      service_data:
  1675.        entity_id: input_boolean.work_annual_leave
  1676.    label: >
  1677.      [[[
  1678.        return states['sensor.work_lovelace_script'].state ;
  1679.      ]]]
  1680.    state:
  1681.      - operator: template
  1682.        value: >
  1683.          [[[
  1684.            return states['sensor.work_today_state'].state === 'At Work';
  1685.          ]]]
  1686.        color: var(--low-colour)
  1687.        icon: 'mdi:store'
  1688.      - operator: template
  1689.        value: >
  1690.          [[[
  1691.           return states['sensor.work_today_state'].state === 'On Leave';
  1692.          ]]]
  1693.        color: var(--secondary-button-colour)  
  1694.        icon: 'mdi:home-floor-l'
  1695.      - value: >
  1696.          [[[
  1697.           return states['sensor.work_today_state'].state === 'No Work Today';
  1698.          ]]]
  1699.        icon: 'mdi:store'
  1700.        color: var(--secondary-button-colour)
  1701.      - value: >
  1702.          [[[
  1703.           return states['sensor.work_today_state'].state === 'Working Today';
  1704.          ]]]
  1705.        icon: 'mdi:store'
  1706.        color: var(--primary-button-colour)
  1707.  
  1708.  
  1709. ### Light Button with 6 Sub buttons
  1710.  
  1711.  
  1712.            - type: custom:bubble-card
  1713.              card_type: button
  1714.              button_type: slider
  1715.              scrolling_effect: false
  1716.              show_last_changed: true
  1717.              show_attribute: true
  1718.              show_state: false
  1719.              show_name: false
  1720.              card_layout: large-2-rows
  1721.              entity: light.lounge
  1722.              tap_action:
  1723.                action: toggle
  1724.              double_tap_action:
  1725.                action: more-info
  1726.              hold_action:
  1727.                action: call-service
  1728.                data:
  1729.                  entity_id: input_select.light_lounge_mode
  1730.                  service: input_select.select_next
  1731.              sub_button:
  1732.  
  1733.                - name: Motion
  1734.                  entity: binary_sensor.ms_lounge
  1735.                  show_icon: true
  1736.                  show_background: false
  1737.                  show_state: true
  1738.  
  1739.                - name: Motion
  1740.                  entity: sensor.temp_lounge
  1741.                  show_icon: true
  1742.                  show_background: false
  1743.                  show_state: true
  1744.  
  1745.                - name: Mode
  1746.                  entity: input_select.light_lounge_mode
  1747.                  show_icon: true
  1748.                  icon: mdi:lightbulb-group-outline
  1749.                  show_background: false
  1750.                  show_state: true
  1751.  
  1752.                - name: Auto Mode
  1753.                  entity: switch.light_lounge_auto_default_mode
  1754.                  show_name: false
  1755.                  show_icon: true
  1756.                  show_background: false
  1757.                  show_state: true
  1758.  
  1759.  
  1760.                - name: Auto On
  1761.                  entity: automation.light_lounge_auto_on
  1762.                  show_name: false
  1763.                  show_icon: true
  1764.                  show_background: false
  1765.                  show_state: true
  1766.  
  1767.                - name: Auto Off
  1768.                  entity: automation.light_lounge_auto_off
  1769.                  show_name: false
  1770.                  show_icon: true
  1771.                  show_background: false
  1772.                  show_state: true
  1773.              styles: |
  1774.  
  1775.                ${subButtonIcon[0].setAttribute("icon", hass.states['binary_sensor.ms_lounge'].state === 'on' ? 'mdi:run-fast' : 'mdi:walk')}
  1776.                
  1777.                ${subButtonIcon[1].setAttribute("icon", hass.states['sensor.temp_lounge'].state <= 15 ? 'mdi:thermometer-chevron-down'
  1778.                  : hass.states['sensor.temp_lounge'].state <= 25 ? 'mdi:thermometer'
  1779.                  : 'mdi:thermometer-chevron-up')}
  1780.                  
  1781.                ${subButtonIcon[3].setAttribute("icon", hass.states['switch.light_lounge_auto_default_mode'].state === 'off' ? 'mdi:transition-masked' : 'mdi:transition')}
  1782.                ${subButtonIcon[4].setAttribute("icon", hass.states['automation.light_lounge_auto_on'].state === 'off' ? 'mdi:motion-sensor-off' : 'mdi:motion-sensor')}
  1783.                ${subButtonIcon[5].setAttribute("icon", hass.states['automation.light_lounge_auto_off'].state === 'off' ? 'mdi:light-switch-off' : 'mdi:light-switch')}
  1784.  
  1785.                .bubble-icon-container {
  1786.                  margin-left: 0px;
  1787.                  margin-right: 1px;
  1788.                    }
  1789.  
  1790.                .bubble-state {
  1791.                  font-size: 10px !important
  1792.                    }
  1793.  
  1794.  
  1795.                .bubble-sub-button-1 {
  1796.                  color: ${hass.states['binary_sensor.ms_lounge'].state === 'on' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1797.                  }
  1798.                .bubble-sub-button-1 > ha-icon {
  1799.                  color: ${hass.states['binary_sensor.ms_lounge'].state === 'on' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1800.                  }
  1801.              
  1802.  
  1803.                .bubble-sub-button-2 {
  1804.                 color: ${hass.states['sensor.temp_lounge'].state <= 15 ? 'var(--low-colour)'
  1805.                 : hass.states['sensor.temp_lounge'].state <= 25 ? 'var(--primary-button-colour)'
  1806.                 : 'var(--high-colour)'} !important;
  1807.                }
  1808.                .bubble-sub-button-2 > ha-icon {
  1809.                 color: ${hass.states['sensor.temp_lounge'].state <= 15 ? 'var(--low-colour)'
  1810.                 : hass.states['sensor.temp_lounge'].state <= 25 ? 'var(--primary-button-colour)'
  1811.                 : 'var(--high-colour)'} !important;
  1812.                }
  1813.  
  1814.  
  1815.                .bubble-sub-button-3 {
  1816.                 color: ${hass.states['input_select.light_lounge_mode'].state === 'Bright' ? 'var(--light-bright)'
  1817.                 : hass.states['input_select.light_lounge_mode'].state === 'Soft' ? 'var(--light-soft)'  
  1818.                 : hass.states['input_select.light_lounge_mode'].state === 'Dim' ? 'var(--light-dim)'
  1819.                 : hass.states['input_select.light_lounge_mode'].state === 'Dark' ? 'var(--light-dark)'
  1820.                 : hass.states['input_select.light_lounge_mode'].state === 'Night' ? 'var(--light-soft)'
  1821.                 : 'var(--primary-button-colour)'} !important;
  1822.                }
  1823.                .bubble-sub-button-3 > ha-icon {
  1824.                 color: ${hass.states['input_select.light_lounge_mode'].state === 'Bright' ? 'var(--light-bright)'
  1825.                 : hass.states['input_select.light_lounge_mode'].state === 'Soft' ? 'var(--light-soft)'  
  1826.                 : hass.states['input_select.light_lounge_mode'].state === 'Dim' ? 'var(--light-dim)'
  1827.                 : hass.states['input_select.light_lounge_mode'].state === 'Dark' ? 'var(--light-dark)'
  1828.                 : hass.states['input_select.light_lounge_mode'].state === 'Night' ? 'var(--light-soft)'
  1829.                 : 'var(--primary-button-colour)'} !important;
  1830.                }
  1831.  
  1832.  
  1833.                .bubble-sub-button-4 {
  1834.                  color: ${hass.states['switch.light_lounge_auto_default_mode'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1835.                }
  1836.                .bubble-sub-button-4 > ha-icon {
  1837.                  color: ${hass.states['switch.light_lounge_auto_default_mode'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1838.                }
  1839.  
  1840.                .bubble-sub-button-5  {
  1841.                  color: ${hass.states['automation.light_lounge_auto_on'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1842.                }
  1843.                .bubble-sub-button-5 > ha-icon {
  1844.                  color: ${hass.states['automation.light_lounge_auto_on'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1845.                }
  1846.  
  1847.  
  1848.                .bubble-sub-button-6 {
  1849.                  color: ${hass.states['automation.light_lounge_auto_off'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1850.                }
  1851.                .bubble-sub-button-6 > ha-icon {
  1852.                  color: ${hass.states['automation.light_lounge_auto_off'].state === 'off' ? 'var(--secondary-button-colour)' : 'var(--primary-button-colour)'} !important;
  1853.                }
  1854.  
  1855.  
Advertisement
Add Comment
Please, Sign In to add comment