Skip to content

Commit

Permalink
Translations; ClimateControl Operations Modes low, boost, summer
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan Litzenburger authored and Jan Litzenburger committed Jan 20, 2021
1 parent 15be2d1 commit 12f33ea
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 10 deletions.
37 changes: 29 additions & 8 deletions templates/badges/ClimateControl.njk
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

{% if climateControlService.state.operationMode == "AUTOMATIC" %}
{% set icon = '<i class="far fa-clock"></i>' %}
{% set operationText %}
{{ "OP_MODE_AUTO" | translate | safe }}
{% endset %}
{% if climateControlService.state.setpointTemperature == climateControlService.state.setpointTemperatureForLevelComfort %}
{% set operationMode = "bsh-comfort" %}
{% elif climateControlService.state.setpointTemperature == climateControlService.state.setpointTemperatureForLevelEco %}
Expand All @@ -13,17 +16,35 @@
{% set operationMode = "bsh-manual" %}
{% endif %}
{% else %}
{% set icon = '<i class="fas fa-user-cog"></i>' %}
{% set operationMode = "bsh-manual" %}
{% if climateControlService.state.low %}
{% set icon = '<i class="fas fa-arrow-down"></i>' %}
{% set operationMode = "bsh-eco" %}
{% set operationText %}
{{ "OP_MODE_LOW" | translate | safe }}
{% endset %}
{% elif climateControlService.state.summermode %}
{% set icon = '<i class="fas fa-user-cog"></i>' %}
{% set operationMode = "bsh-manual" %}
{% set operationText %}
{{ "OP_MODE_SUMMER" | translate | safe }}
{% endset %}
{% elif climateControlService.state.boostmode %}
{% set icon = '<i class="fas fa-arrow-down"></i>' %}
{% set operationMode = "bsh-comfort" %}
{% set operationText %}
{{ "OP_MODE_BOOST" | translate | safe }}
{% endset %}
{% else %}
{% set icon = '<i class="fas fa-user-cog"></i>' %}
{% set operationMode = "bsh-manual" %}
{% set operationText %}
{{ "OP_MODE_MANUAL" | translate | safe }}
{% endset %}
{% endif %}
{% endif %}

<span class="bsh-badge climate-control {{ operationMode }}">
{{ icon | safe }}
{% if climateControlService.state.operationMode == "AUTOMATIC" %}
AUTO
{% else %}
MANUAL
{% endif %}
{{ icon | safe }} {{ operationText }}
</span>
{% endif %}
{% endmacro %}
7 changes: 6 additions & 1 deletion translations/de.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{
"TEMPERATURE_IS": "IST",
"TEMPERATURE_TARGET": "SOLL"
"TEMPERATURE_TARGET": "SOLL",
"OP_MODE_AUTO": "Auto",
"OP_MODE_MANUAL": "Manuell",
"OP_MODE_BOOST": "Boost",
"OP_MODE_SUMMER": "Aus",
"OP_MODE_LOW": "Low"
}
7 changes: 6 additions & 1 deletion translations/en.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{
"TEMPERATURE_IS": "Is",
"TEMPERATURE_TARGET": "Target"
"TEMPERATURE_TARGET": "Target",
"OP_MODE_AUTO": "Auto",
"OP_MODE_MANUAL": "Manual",
"OP_MODE_BOOST": "Boost",
"OP_MODE_SUMMER": "Off",
"OP_MODE_LOW": "Low"
}

0 comments on commit 12f33ea

Please sign in to comment.