Skip to content

Commit

Permalink
Fixed charge bar animation bar when not charging
Browse files Browse the repository at this point in the history
  • Loading branch information
Aephir authored Sep 3, 2023
1 parent b9ab08e commit 73451e9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tesla_floorplan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,11 @@ config:
- service: floorplan.style_set
service_data:
style: >
animation: charge-animation-variable ${entity.state === 'on' ? (5
/ 100 * (entity.attributes.charge_limit -
entity.attributes.battery_level)) : 0}s linear infinite;
--from-width: ${entity.attributes.battery_level}%; --to-width:
${entity.attributes.charge_limit}%;
animation: charge-animation-variable ${entity.state === 'on' ? (5 / 100 * (entity.attributes.charge_limit - entity.attributes.battery_level)) : 0}s linear infinite;
--from-width: ${entity.attributes.battery_level}%;
--to-width: ${entity.attributes.charge_limit}%;
width: ${entity.state === 'on' ? 'auto' : '0%'};
- name: Charge Port Icon
entities:
Expand Down

0 comments on commit 73451e9

Please sign in to comment.