Skip to content

Commit

Permalink
Merge pull request #548 from flixlix/424-bug-state_of_charge_unit_whi…
Browse files Browse the repository at this point in the history
…te_space-false-completely-ignored

fix: 🐛 display state of charge unit white space
  • Loading branch information
flixlix authored Apr 15, 2024
2 parents 2adc476 + c3f6660 commit 3a93761
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/battery.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const batteryElement = (
id="battery-state-of-charge-text"
>
${displayValue(main.hass, config, battery.state_of_charge.state, {
unit: battery.state_of_charge.unit,
unit: battery.state_of_charge.unit ?? "%",
unitWhiteSpace: battery.state_of_charge.unit_white_space,
decimals: battery.state_of_charge.decimals,
accept_negative: undefined,
Expand Down

0 comments on commit 3a93761

Please sign in to comment.