Add country selector (#29242)

* Add country selector

* Add country selector image
This commit is contained in:
G Johansson 2023-10-12 16:45:26 +02:00 committed by GitHub
parent 279416067f
commit e2332b2022
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 0 deletions

View File

@ -28,6 +28,7 @@ The following selectors are currently available:
- [Config entry selector](#config-entry-selector)
- [Constant selector](#constant-selector)
- [Conversation agent selector](#conversation-agent-selector)
- [Country selector](#country-selector)
- [Date selector](#date-selector)
- [Date \& time selector](#date--time-selector)
- [Device selector](#device-selector)
@ -427,6 +428,32 @@ date:
The output of this selector will contain the date in Year-Month-Day
(`YYYY-MM-DD`) format, for example, `2022-02-22`.
## Country selector
The country selector allows a user to pick a country from a list of countries.
![Screenshot of a country selector](/images/blueprints/country_selector.png)
```yaml
country:
```
{% configuration entity %}
countries:
description: A list of countries to pick from, this should be ISO 3166 country codes.
type: list
default: The available countries in the Home Assistant frontend
required: false
no_sort:
description: >
Should the options be sorted by name, if set to true, the order of the provided countries is kept.
type: boolean
default: false
required: false
{% endconfiguration %}
The output of this selector is an ISO 3166 country code.
## Date & time selector
The date selector shows a date and time input that allows the user to specify a

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB