home-assistant / architecture

Repo to discuss Home Assistant architecture
317 stars 100 forks source link

Add device_class Heater #840

Closed Mariusthvdb closed 1 year ago

Mariusthvdb commented 1 year ago

Context

The issue motivating this decision, and any context that influences or constrains the decision. Your motivation cannot include that the frontend is not representing the data correctly, as that is a frontend issue.

Suggesting to add a dedicated device_class: heater to be able to have the many heating devices adopt the new color scheme in 2022.12, and set a appropriate icon, all default in core HA.

If available in the backend we can set mdi:radiator for on, mdi:radiator-off and have the colors turn 'red' for on, default off for 'off'

some background: https://github.com/home-assistant/frontend/pull/14637#issuecomment-1348145371

Proposal

The change that you're proposing.

https://github.com/home-assistant/core/pull/83925

Consequences

What becomes easier or more difficult to do and any risks introduced by the change that will need to be mitigated.

With this change, we can easily set color vars and have the frontend color that correctly. Without an explicit class, these binaries are colored blue in default schematics, and that is not very appropriate for a Heating device

No risks are involved as far as I can see. Given this is a backend addition required for fixing a frontend issue mainly, there would be no backend issue in the first place, and only advantage in the frontend.

MartinHjelmare commented 1 year ago

Please open a discussion instead.

https://github.com/home-assistant/architecture/discussions

Mariusthvdb commented 1 year ago

ok, please see: https://github.com/home-assistant/architecture/discussions/841