Closed nagyrobi closed 3 years ago
It's just a binary sensor. How do you imagine adding translations?
The names. Snowtire, Winter, Summer, these would be nice to appear in my own language, not English.
English are not my own language too. The sensor name — "Snowtire" — is just default value. You are free to set any other sensor name your choose. The sensor, as I said, is binary. It only returns one of two values: "On" or "Off". We cannot change this. The values "Winter" and "Summer" are used only within the "tire_type" attribute. This attribute was added only for the convenience of understanding the main status — its value directly depends on the main status.
The most that can make sense is to translate these two words. But I'm not sure if it's worth doing. Since this will interfere with the visualization of the sensor and will violate the principle of separating the main logic of the sensor and visualization for the user.
From our discussion with you, I, however, had the idea that it is possible to change the values of the sensor states from "On" / "Off" to "Winter" / "Summer". Then the attribute will become unnecessary.
You are free to set any other sensor name your choose.
I am aware that I can chance the py files myself but an update would kill that.
You misunderstood. The name of the sensor is changed through the settings via the “name” field. You do not need to change the component code for this. https://github.com/Limych/ha-snowtire#configuration-variables
Oops sorry I didn't read below the patreon advert. The "Winter" and "Summer" would be nice to be customizable the same way, though. And having these instead of On/Off would be just great.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please add a way to add translations to this component.