Skip to content

3.4.0-0

Pre-release
Pre-release
Compare
Choose a tag to compare
@RomRider RomRider released this 04 Oct 22:33
· 134 commits to master since this release

New Features

  • Support for configuring the card size for the auto-layout feature of lovelace using card_size. Default value is still 3, but you can now override it. Lovelace multiplies the value by about 50px for the auto layout feature.
    type: custom:button-card
    entity: switch.my_switch
    card_size: 42
  • Support for displaying a tooltip while hoovering the card for 1.5s using the tooltip parameter. It supports javascript templates. You can also apply any CSS style to the tooltip (either in the main styles config object or in any of the state entry).
    type: custom:button-card
    entity: switch.my_switch
    tooltip: |
      [[[
        return entity.state
      ]]]
    styles:
      tooltip:
        - color: '[[[ return entity.state === "on" ? "red" : "green" ]]]'
    or
    type: custom:button-card
    entity: switch.my_switch
    tooltip: |
      [[[
        return entity.state
      ]]]
    state:
      - value: 'on'
        styles:
          tooltip:
            - color: red
      - value: 'off'
        styles:
          tooltip:
            - color: green