UI-Lovelace-Minimalist / UI

UI-Lovelace-Minimalist is a "theme" for HomeAssistant
https://ui-lovelace-minimalist.github.io/UI/
Other
1.64k stars 432 forks source link

unit_of_measurement on Icon State Chip and Mdi:icon State Chip #1134

Open nick03nick opened 1 year ago

nick03nick commented 1 year ago

Describe the bug I set 2 chips, Icon State Chip and Mdi:icon State Chip, with the same entity but the results are different on the label. In case of Mdi:icon State Chip does not display the unit of measure but from the documentation it should show it.

The sensor is a Shelly EM.

This is the code I used:

- type: "custom:button-card"
  template: chip_mdi_icon_state
  variables:
    ulm_chip_mdi_icon_state_entity: sensor.misuratore_corrente_e_tensione_channel_1_power
    ulm_chip_mdi_icon_state_icon: mdi:flash
- type: "custom:button-card"
  template: chip_icon_state
  variables:
    ulm_chip_icon_state_icon: "⚡"
    ulm_chip_icon_state_entity: sensor.misuratore_corrente_e_tensione_channel_1_power

Expected behavior Icon State Chip correctly displays the unit of measure Mdi:icon State Chip correctly displays the unit of measure

Screenshots From the code pasted above

Screenshot 2022-12-31 160754

shogun160 commented 1 year ago

See #1073. Will be available with the next release. Until then you can change the file yourself.