Modify service field filter documentation (#1740)

Co-authored-by: Franck Nijhof <git@frenck.dev>
This commit is contained in:
Erik Montnemery 2023-04-03 21:49:30 +02:00 committed by GitHub
parent c555a4d4d6
commit 4e5fc3a55a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -128,14 +128,19 @@ In some cases, entities from a service's domain may not support all service fiel
providing a `filter` for the field description, the field will only be shown if at least
one selected entity supports the field according to the configured filter.
If multiple filters are specified, the field will be shown if at least one selected entity
passes at least one filter.
A filter must specify either `supported_features` or `attribute`, combing both is not
supported.
The filter supports filtering on `supported_features` as well as on state attribute values
in general.
A `supported_features` filter is specified by of a list of supported features. The field
will be shown if at least one selected entity supports at least one of the listed features.
An `attribute` filter combines an attribute with a list of values. The field will be
shown if at least one selected entity's attribute is set to one of the listed attribute states.
If the attribute state is a list, the field will be shown if at least one item in a selected
entity's attribute state is set to one of the listed attribute states.
This is a partial example of a field which is only shown if at least one selected entity
has the needed `supported_features`:
supports `ClimateEntityFeature.TARGET_TEMPERATURE`:
```yaml
fields: