Skip to content

Commit 79a78f2

Browse files
authored
Update Configuration Variables section
1 parent 0db5228 commit 79a78f2

File tree

1 file changed

+8
-23
lines changed

1 file changed

+8
-23
lines changed

source/_components/cover.template.markdown

Lines changed: 8 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,9 @@ ha_iot_class: "Local Push"
1313
logo: home-assistant.png
1414
---
1515

16-
The `template` platform can create covers that combine components and provides
17-
the ability to run scripts or invoke services for each of the open, close,
18-
stop, position, and tilt commands of a cover.
16+
The `template` platform can create covers that combine components and provides the ability to run scripts or invoke services for each of the open, close, stop, position, and tilt commands of a cover.
1917

20-
To enable Template Covers in your installation, add the following to your
21-
`configuration.yaml` file:
18+
To enable Template Covers in your installation, add the following to your `configuration.yaml` file:
2219

2320
{% raw %}
2421
```yaml
@@ -87,12 +84,12 @@ cover:
8784
optimistic:
8885
description: Force cover position to use [optimistic mode](#optimistic-mode).
8986
required: false
90-
type: bool
87+
type: boolean
9188
default: false
9289
tilt_optimistic:
9390
description: Force cover tilt position to use [optimistic mode](#optimistic-mode).
9491
required: false
95-
type: bool
92+
type: boolean
9693
default: false
9794
tilt_template:
9895
description: Defines a template to get the tilt state of the cover. Legal values are numbers between `0` (closed) and `100` (open).
@@ -102,36 +99,24 @@ cover:
10299

103100
## {% linkable_title Considerations %}
104101

105-
If you are using the state of a platform that takes extra time to load, the
106-
Template Cover may get an `unknown` state during startup. This results
107-
in error messages in your log file until that platform has completed loading.
102+
If you are using the state of a platform that takes extra time to load, the Template Cover may get an `unknown` state during startup. This results in error messages in your log file until that platform has completed loading.
108103
If you use `is_state()` function in your template, you can avoid this situation.
109104
For example, you would replace
110105
{% raw %}`{{ states.switch.source.state == 'on' }}`{% endraw %}
111-
with this equivalent that returns `true`/`false` and never gives an unknown
112-
result:
106+
with this equivalent that returns `true`/`false` and never gives an unknown result:
113107
{% raw %}`{{ is_state('switch.source', 'on') }}`{% endraw %}
114108

115109
## {% linkable_title Optimistic Mode %}
116110

117-
In optimistic mode, the cover position state is maintained internally. This
118-
mode is automatically enabled if neither [`value_template`](#value_template) or
119-
[`position_template`](#position_template) are specified. Note that this is
120-
unlikely to be very reliable without some feedback mechanism, since there is
121-
otherwise no way to know if the cover is moving properly. The cover can be
122-
forced into optimistic mode by using the [`optimistic`](#optimistic)
123-
attribute. There is an equivalent mode for `tilt_position` that is enabled
124-
when [`tilt_template`](#tilt_template) is not specified or when the
125-
[`tilt_optimistic`](#tilt_optimistic) attribute is used.
111+
In optimistic mode, the cover position state is maintained internally. This mode is automatically enabled if neither [`value_template`](#value_template) or [`position_template`](#position_template) are specified. Note that this is unlikely to be very reliable without some feedback mechanism, since there is otherwise no way to know if the cover is moving properly. The cover can be forced into optimistic mode by using the [`optimistic`](#optimistic) attribute. There is an equivalent mode for `tilt_position` that is enabled when [`tilt_template`](#tilt_template) is not specified or when the [`tilt_optimistic`](#tilt_optimistic) attribute is used.
126112

127113
## {% linkable_title Examples %}
128114

129115
In this section you will find some real life examples of how to use this cover.
130116

131117
### {% linkable_title Garage Door %}
132118

133-
This example converts a garage door with a controllable switch and position
134-
sensor into a cover.
119+
This example converts a garage door with a controllable switch and position sensor into a cover.
135120

136121
{% raw %}
137122
```yaml

0 commit comments

Comments
 (0)