Skip to content

Commit

Permalink
Add actions to auto-fan
Browse files Browse the repository at this point in the history
  • Loading branch information
Jean-Marc Collin committed Dec 10, 2023
1 parent 955b795 commit e4e19ff
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 5 deletions.
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ Note: those options should be improved with official release
| disable_off | boolean | **optional** | turn off the off button |
| disable_buttons | boolean | **optional** | turn off the plus/minus buttons |
| disable_security_warning | boolean | **optional** | turn off the security warning (when a temperature sensor is out) |
| disable_power_infos | boolean | **optional** | turn off the power informations |
| disable_auto_fan_infos | boolean | **optional** | turn off the auto-fan informations |
| name | string/boolean | **optional** | override the default entity name |
| set_current_as_main | boolean | **optional** | Exchange target temperature and room temperature |

Expand All @@ -94,9 +96,34 @@ disable_off: false
disable_security_warning: false
set_current_as_main: true
disable_buttons: false
disable_power_infos: false
disable_auto_fan_infos: false
name: Chambre
```

# Actions
Some actions are available directly on the card.

__Note:__ all actions done on the card and resetted if the VTherm integration restarts. If you want persistant change, you must edit the configuration of the VTherm itself on the Versatile Thermostat integration.

## Change the preset temperature
Preset temperature cann be changed directly from the card with the following actions:
1. select the preset, you want to change,
2. select the temperature you want to set with the selector or the +/- buttons,
3. double click on the preset you want to change. When this action occurs, the preset rapidly change to the previous value and then to the new value to indicate that it is stored.

You can do this operations for all displayed presets but not on the `Activity` preset because this preset uses the temperature values of the others preset. See documentation of [versatile_thermostat README](https://github.com/jmcollin78/versatile_thermostat/blob/main/README.md#configure-the-activity-mode-or-motion-detection).

Of course you should have displayed the presets to be able to do so.

## Disable the auto-fan mode
For `over_climate` you have the possibility to configure the `auto-fan` mode feature. See [versatile_thermostat README](https://github.com/jmcollin78/versatile_thermostat/blob/main/README.md#auto-fan-mode).

If the `auto-fan` mode is configured, you can toggle between the configured `auto_fan_mode` configured for the VTherm and the None mode (which disable the auto-fan mode).

To toggle the auto-fan mode you must:
1. click on the `Auto-fan` icon at the left of the Thermostat.

## Help wanted!

It would be awsome if you help me to translate this card to other languages.
Expand Down
4 changes: 2 additions & 2 deletions dist/versatile-thermostat-ui-card.js

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion src/localize/languages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,14 @@
"frost": "Frost",
"power": "Overpowering",
"activity": "Activity",
"undefined": "None",
"auto_regulation_light": "Light",
"auto_regulation_medium": "Medium",
"auto_regulation_strong": "Strong",
"auto_regulation_slow": "Slow",
"auto_regulation_expert": "Expert",
"auto_fan_mode": "Auto-fan",
"auto_fan_mode_off": "None",
"auto_fan_none": "None",
"auto_fan_low": "Low",
"auto_fan_medium": "Medium",
Expand All @@ -55,6 +57,7 @@
"fan_mute": "Mute",
"fan_turbo": "Turbo",
"fan_none": "None",
"change_message": "Double click to change preset"
"change_message": "Double click to change preset",
"toggle_message": "Click to toggle"
}
}
4 changes: 3 additions & 1 deletion src/localize/languages/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"auto_regulation_slow": "Lente",
"auto_regulation_expert": "Expert",
"auto_fan_mode": "Auto-fan",
"auto_fan_mode_off": "Aucun",
"auto_fan_none": "Aucun",
"auto_fan_low": "Bas",
"auto_fan_medium": "Moyen",
Expand All @@ -53,6 +54,7 @@
"fan_mute": "Silence",
"fan_turbo": "Turbo",
"fan_none": "Aucun",
"change_message": "Double clic pour changer le preset"
"change_message": "Double clic pour changer le preset",
"toggle_message": "Clic pour basculer"
}
}
6 changes: 5 additions & 1 deletion src/versatile-thermostat-ui.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1187,7 +1187,11 @@ export class VersatileThermostatUi extends LitElement implements LovelaceCard {
}

private _renderAutoFanInfo(info: any): TemplateResult {
const localizeInfo = this.hass!.localize(`component.climate.state._.${info.name}`) || localize({ hass: this.hass, string: `extra_states.${info.name}` });
const localizeInfo =
(this.hass!.localize(`component.climate.state._.${info.name}`) ||
localize({ hass: this.hass, string: `extra_states.${info.name}` }))
+ "\n" + localize({ hass: this.hass, string: `extra_states.toggle_message` });

return html `
<div class="left-info-label">
<span>
Expand Down

0 comments on commit e4e19ff

Please sign in to comment.