Closed flipdream closed 4 months ago
secondary: >-
{{relative_time(states[config.entity].last_changed)}} ago
Perfect, thanks ildar170975
Close the issue then if solved
secondary: >- {{relative_time(states[config.entity].last_changed)}} ago
Unfortunately depending on your local language that's a bit more difficult. Here's a working example for German:
secondary: >
Vor {{ relative_time(states[config.entity].last_changed) | replace ('seconds','Sekunden') | replace ('minutes','Minuten') |
replace ('hours','Stunden') | replace ('hour','Stunde') | replace
('days','Tagen') | replace ('day','Tag') | replace
('weeks','Wochen') }}
"Templates engine" is provided by HA, and German users must be happy to have at least SOME localizations, and other humans may not be so lucky:
Any option to add "secondary_info: last-changed" for a entity in with this card?