Skip to content

3.2.10 - Better Buttons With Home Assistant Actions

Compare
Choose a tag to compare
@Nerwyn Nerwyn released this 29 Jan 00:35
· 1067 commits to main since this release

Changes in 3.2.10

  • Merge data, target, and service_data fields into data if any exist rather than on action type.

Do more with buttons!

This release is focused on improving buttons and custom actions. Custom actions now follow Home Assistant actions syntax, and supports most actions defined there along with the key and source actions from this card. Confirmations are also supported.

The following actions are supported:

  • key
  • source
  • call-service
  • navigate
  • url
  • assist
  • more-info
  • none

Buttons now support not only tap actions, but double tap and hold actions! Just like the touchpad center tap. The touchpad center double tap and hold actions are now configured in this way, and the old separate fields for enabling and remapping center taps have been deprecated. Also, double tap actions on buttons and the touchpad now work on iPhone!

custom_actions:
  light_color:
    icon: mdi:lightbulb{{ "-outline" if is_state("light.sunroom_ceiling", "off") }}
    style:
      color: rgb({{ state_attr("light.sunroom_ceiling", "rgb_color") }}
    tap_action:
      action: call-service
      service: light.turn_on
      data:
        entity_id: light.sunroom_ceiling
        color_name: red
    hold_action:
      action: call-service
      service: light.turn_on
      data:
        entity_id: light.sunroom_ceiling
        color_name: blue
    double_tap_action:
      action: call-service
      service: light.turn_on
      data:
        entity_id: light.sunroom_ceiling
        color_name: green

Other changes:

  • Remapped hold actions do not add hold_secs: 0.5 to remote.send_command service calls.
  • Deprecated options:
    • enable_double_click and double_click_keycode - touchpad double tap is now enabled and reassigned by creating a custom action for center and creating a double_tap_action.
    • long_click_keycode - now reassigned by creating a custom action for center and creating a hold_action.
    • custom_keys and custom_sources - are now just custom_actions.

Patch version changes:

  • Do not add hold_secs = 0.5 to data on custom hold call-service actions.
  • Use js-yaml to parse template results in rows array that are yaml strings so templating can be used to define multiple remote elements.
  • Sliders can now be used for any action.
  • Fixed url action to work better on mobile and to match Home Assistant frontend code.
  • Added assist and more-info actions.
  • Fix button mode icon.
  • Deprecate svg_path, use icon for icon packs, custom icons, and svg paths.
  • Users can now use default svg icons that come with this card for custom actions.
  • Fix icon so that templates can be used with non-pack icons.
  • Prevent button and slider actions when scrolling #50.
  • Update Apple TV example #51.
  • Further slider scrolling detection improvements.
  • Added missing Firefox slider styles.
  • Tweaked slider styles for better performance and customizability.
  • Support for older webviews that do not support the structuredClone function.
  • Merge data, target, and service_data fields into data if any exist rather than on action type.

Full Changelog: 3.1.3...3.2.10