diff --git a/esphome/nspanel_esphome_core.yaml b/esphome/nspanel_esphome_core.yaml index 4491a56..3e41550 100644 --- a/esphome/nspanel_esphome_core.yaml +++ b/esphome/nspanel_esphome_core.yaml @@ -17,7 +17,7 @@ substitutions: invalid_cooldown: "100ms" bytes_per_char: "1" ##### DON'T CHANGE THIS ###### - version: "4.3.5" + version: "4.3.6" ############################## ##### External components ##### @@ -27,7 +27,7 @@ external_components: # path: packages/Blackymas/components type: git url: https://github.com/Blackymas/NSPanel_HA_Blueprint - ref: v4.3.5 + ref: v4.3.6 components: - nspanel_ha_blueprint refresh: 300s @@ -2380,7 +2380,6 @@ script: command: string then: - lambda: |- - if (id(is_uploading_tft)) ha_button->stop(); timer_reset_all->execute(); esphome::api::CustomAPIDevice ha_event; ha_event.fire_homeassistant_event("esphome.nspanel_ha_blueprint", diff --git a/hmi/dev/nspanel_CJK_eu_code/boot.txt b/hmi/dev/nspanel_CJK_eu_code/boot.txt index 25fbaf9..5e5a8c5 100644 --- a/hmi/dev/nspanel_CJK_eu_code/boot.txt +++ b/hmi/dev/nspanel_CJK_eu_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Text esph_version diff --git a/hmi/dev/nspanel_CJK_us_code/boot.txt b/hmi/dev/nspanel_CJK_us_code/boot.txt index 9eb0038..f59bd17 100644 --- a/hmi/dev/nspanel_CJK_us_code/boot.txt +++ b/hmi/dev/nspanel_CJK_us_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Events diff --git a/hmi/dev/nspanel_CJK_us_land_code/boot.txt b/hmi/dev/nspanel_CJK_us_land_code/boot.txt index 25fbaf9..5e5a8c5 100644 --- a/hmi/dev/nspanel_CJK_us_land_code/boot.txt +++ b/hmi/dev/nspanel_CJK_us_land_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Text esph_version diff --git a/hmi/dev/nspanel_eu_code/boot.txt b/hmi/dev/nspanel_eu_code/boot.txt index 25fbaf9..5e5a8c5 100644 --- a/hmi/dev/nspanel_eu_code/boot.txt +++ b/hmi/dev/nspanel_eu_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Text esph_version diff --git a/hmi/dev/nspanel_us_code/boot.txt b/hmi/dev/nspanel_us_code/boot.txt index 9eb0038..f59bd17 100644 --- a/hmi/dev/nspanel_us_code/boot.txt +++ b/hmi/dev/nspanel_us_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Events diff --git a/hmi/dev/nspanel_us_land_code/boot.txt b/hmi/dev/nspanel_us_land_code/boot.txt index 25fbaf9..5e5a8c5 100644 --- a/hmi/dev/nspanel_us_land_code/boot.txt +++ b/hmi/dev/nspanel_us_land_code/boot.txt @@ -95,7 +95,7 @@ Text tft_version Dragging : 0 Send Component ID : on press and release Associated Keyboard: none - Text : 4.3.5 + Text : 4.3.6 Max. Text Size : 10 Text esph_version diff --git a/hmi/nspanel_CJK_eu.HMI b/hmi/nspanel_CJK_eu.HMI index 3696e9a..25a13e1 100644 Binary files a/hmi/nspanel_CJK_eu.HMI and b/hmi/nspanel_CJK_eu.HMI differ diff --git a/hmi/nspanel_CJK_eu.tft b/hmi/nspanel_CJK_eu.tft index aea5bda..ba2bf9b 100644 Binary files a/hmi/nspanel_CJK_eu.tft and b/hmi/nspanel_CJK_eu.tft differ diff --git a/hmi/nspanel_CJK_us.HMI b/hmi/nspanel_CJK_us.HMI index ac0fa16..e869167 100644 Binary files a/hmi/nspanel_CJK_us.HMI and b/hmi/nspanel_CJK_us.HMI differ diff --git a/hmi/nspanel_CJK_us.tft b/hmi/nspanel_CJK_us.tft index 9d1d5f2..ff4881f 100644 Binary files a/hmi/nspanel_CJK_us.tft and b/hmi/nspanel_CJK_us.tft differ diff --git a/hmi/nspanel_CJK_us_land.HMI b/hmi/nspanel_CJK_us_land.HMI index aeca1f6..6467529 100644 Binary files a/hmi/nspanel_CJK_us_land.HMI and b/hmi/nspanel_CJK_us_land.HMI differ diff --git a/hmi/nspanel_CJK_us_land.tft b/hmi/nspanel_CJK_us_land.tft index ba90e60..4891f19 100644 Binary files a/hmi/nspanel_CJK_us_land.tft and b/hmi/nspanel_CJK_us_land.tft differ diff --git a/hmi/nspanel_eu.HMI b/hmi/nspanel_eu.HMI index 072fbc2..51405a5 100644 Binary files a/hmi/nspanel_eu.HMI and b/hmi/nspanel_eu.HMI differ diff --git a/hmi/nspanel_eu.tft b/hmi/nspanel_eu.tft index e684378..83675d5 100644 Binary files a/hmi/nspanel_eu.tft and b/hmi/nspanel_eu.tft differ diff --git a/hmi/nspanel_us.HMI b/hmi/nspanel_us.HMI index e7ebe21..a423909 100644 Binary files a/hmi/nspanel_us.HMI and b/hmi/nspanel_us.HMI differ diff --git a/hmi/nspanel_us.tft b/hmi/nspanel_us.tft index 2c3084b..446cc93 100644 Binary files a/hmi/nspanel_us.tft and b/hmi/nspanel_us.tft differ diff --git a/hmi/nspanel_us_land.HMI b/hmi/nspanel_us_land.HMI index 4fa7770..fd13843 100644 Binary files a/hmi/nspanel_us_land.HMI and b/hmi/nspanel_us_land.HMI differ diff --git a/hmi/nspanel_us_land.tft b/hmi/nspanel_us_land.tft index e656512..e296dea 100644 Binary files a/hmi/nspanel_us_land.tft and b/hmi/nspanel_us_land.tft differ diff --git a/nspanel_blueprint.yaml b/nspanel_blueprint.yaml index 0b031ca..98f0398 100644 --- a/nspanel_blueprint.yaml +++ b/nspanel_blueprint.yaml @@ -10,7 +10,7 @@ blueprint: description: > # NSPanel Configuration via Blueprint: Complete UI-Based Setup - **Version**: v4.3.5 + **Version**: v4.3.6 This project enables comprehensive configuration of your NSPanel through a Blueprint featuring a user interface. @@ -3826,7 +3826,7 @@ trigger_variables: group06: !input utilities_page01_group06_line_reference variables: - blueprint_version: '4.3.5' + blueprint_version: '4.3.6' pages: current: '{{ states(currentpage) }}' home: "home" @@ -9155,36 +9155,47 @@ action: }} - &variables_light_modes variables: + entity_id_valid: '{{ entity_id is defined and entity_id is string and entity_id.split(".") | count == 2 }}' + entity_domain: '{{ entity_id.split(".")[0] if entity_id_valid }}' supported_features: '{{ state_attr(entity_id, "supported_features") | int(0) }}' - supported_color_modes: '{{ state_attr(entity_id, "supported_color_modes") | default("unknown") }}' + supported_color_modes_temp: '{{ state_attr(entity_id, "supported_color_modes") | default([]) }}' + supported_color_modes: '{{ supported_color_modes_temp if supported_color_modes_temp else [] }}' color_mode_brightness: > {{ - supported_features | bitwise_and(1) > 0 or - enum.ColorMode.BRIGHTNESS in supported_color_modes or - "brightness" in supported_color_modes or - state_attr(entity_id, "brightness") | int(-1) >= 0 + entity_domain == "light" and + ( + supported_features | bitwise_and(1) > 0 or + enum.ColorMode.BRIGHTNESS in supported_color_modes or + "brightness" in supported_color_modes or + state_attr(entity_id, "brightness") | int(-1) >= 0 + ) }} color_mode_color: > {{ - supported_features | bitwise_and(16) > 0 or - enum.ColorMode.HS in supported_color_modes or - enum.ColorMode.XY in supported_color_modes or - enum.ColorMode.RGB in supported_color_modes or - enum.ColorMode.RGBW in supported_color_modes or - enum.ColorMode.RGBWW in supported_color_modes or - "hs" in supported_color_modes or - "xy" in supported_color_modes or - "rgb" in supported_color_modes or - "rgbw" in supported_color_modes or - "rgbww" in supported_color_modes or - state_attr(entity_id, "rgb_color") is sequence + entity_domain == "light" and + ( + supported_features | bitwise_and(16) > 0 or + enum.ColorMode.HS in supported_color_modes or + enum.ColorMode.XY in supported_color_modes or + enum.ColorMode.RGB in supported_color_modes or + enum.ColorMode.RGBW in supported_color_modes or + enum.ColorMode.RGBWW in supported_color_modes or "hs" in supported_color_modes or + "xy" in supported_color_modes or + "rgb" in supported_color_modes or + "rgbw" in supported_color_modes or + "rgbww" in supported_color_modes or + state_attr(entity_id, "rgb_color") | default("unknown") is sequence + ) }} color_mode_color_temp: > {{ - supported_features | bitwise_and(2) > 0 or - enum.ColorMode.COLOR_TEMP in supported_color_modes or - "color_temp" in supported_color_modes or - state_attr(entity_id, "color_temp") | int(-1) >= 0 + entity_domain == "light" and + ( + supported_features | bitwise_and(2) > 0 or + enum.ColorMode.COLOR_TEMP in supported_color_modes or + "color_temp" in supported_color_modes or + state_attr(entity_id, "color_temp") | int(-1) >= 0 + ) }} ##### LIGHT State ##### - variables: @@ -10745,6 +10756,7 @@ action: sequence: - variables: last_click_button: '{{ home_page.custom_buttons | selectattr("component", "defined") | selectattr("component", "eq", nspanel_event.component) | list }}' + continue_on_error: true - condition: '{{ last_click_button | count >= 0 }}' - variables: last_click_button: '{{ last_click_button[0] }}' @@ -10752,9 +10764,8 @@ action: overlap: icon: '{{ last_click_button.icon if last_click_button.icon is defined else None }}' name: '{{ last_click_button.name if last_click_button.name is defined else None }}' - - *variable_entity - - condition: '{{ entity_id_valid }}' - *variables_light_modes + - condition: '{{ entity_id_valid }}' - if: > {{ entity_domain in ["alarm_control_panel", "climate", "media_player"] or @@ -10765,6 +10776,7 @@ action: then: - variables: back_page: '{{ pages.home }}' + - *variable_entity - *entity_details_show else: - *short_press-service_call