This project was bootstrapped from the homeassistant-react-lovelace Repo which provides a minimal setup to get vite working in Home Assistant with some ESLint rules.
- Add this repository as a custom repository in HACS.
- Install the ha-draw card via HACS.
- Reload your Home Assistant.
- Create your custom card
- type: custom:ha-draw
name: filename_addition #the addition to the filename
groups:
- entities: #a list of entities when one of them changes the tldraw Component is updated
- sensor.plug_pcsetup_leistung
template: | #the Template which Result Value is used on the parameter
{{ states('sensor.plug_pcsetup_leistung', with_unit=true) }}
tldraw:
ids:
- MUdaPeWuusluTr7_5Ri5A #the ID of the Shape without shape:
parameter: props.text #the parameter of the tldraw Component which is changed
valuetype: current # current or absolut. current is the current value.
#Absolute adds the values just possible with numbers
on_error: previous #if previous the last working value is displayed
- entities:
- sensor.plug_minipc_leistung
template: |
{% if states('sensor.plug_minipc_leistung') | float > 7 %}
red
{% else %}
green
{% endif %}
tldraw:
ids:
- Sh5qeuGuvPte75xd4euyN
parameter: props.color
valuetype: current
on_error: previous
Note: Be sure to open Home Assistant using its local address if your component does not seem to update after inserting a new version.