Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Variables

Common variables and configurations for card templates.

Available Variables

Discovery

  • anchor - anchor of the current URL

Responsiveness

  • is_mobile - if we're on mobile or not

Usage Example

type: custom:button-card
template:
    - responsive_variables
    - discovery_variables

  styles:
    custom_fields:
      item1:
        - margin-bottom: '[[[ if (variables.is_mobile) return "20px" ]]]'

Notes

  • Use variables. to access variables.
  • Variables can be overridden in individual cards