mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-19 07:17:14 +00:00
Add selectors for text and arbitrary objects (#16322)
This commit is contained in:
parent
72cb1e2267
commit
588acc84aa
@ -21,7 +21,9 @@ The following selectors are currently available:
|
||||
- [Device selector](#device-selector)
|
||||
- [Entity selector](#entity-selector)
|
||||
- [Number selector](#number-selector)
|
||||
- [Object selector](#object-selector)
|
||||
- [Target selector](#target-selector)
|
||||
- [Text selector](#text-selector)
|
||||
- [Time selector](#time-selector)
|
||||
|
||||
If no selector is defined, a text input for a single line will be shown.
|
||||
@ -367,6 +369,18 @@ number:
|
||||
mode: slider
|
||||
```
|
||||
|
||||
## Object selector
|
||||
|
||||
The object selector can be used to input arbitrary data in YAML form. This is useful for e.g. lists and dictionaries like service data. The value of the input will contain the provided data.
|
||||
|
||||

|
||||
|
||||
This selector does not have any other options; therefore, it only has its key.
|
||||
|
||||
```yaml
|
||||
object:
|
||||
```
|
||||
|
||||
## Target selector
|
||||
|
||||
The target selector is a rather special selector, allowing the user to selector
|
||||
@ -477,6 +491,26 @@ target:
|
||||
model: TRADFRI remote control
|
||||
```
|
||||
|
||||
## Text selector
|
||||
|
||||
The text selector can be used to input a text string. The value of the input will contain the selected text.
|
||||
|
||||

|
||||
|
||||
Unless `multiline` is set to `true`, this selector behaves exactly like if no selector at all was specified, and will display a single line text input box on the user interface.
|
||||
|
||||
```yaml
|
||||
text:
|
||||
```
|
||||
|
||||
{% configuration text %}
|
||||
multiline:
|
||||
description: Set to true to display the input as a multi-line text box on the user interface.
|
||||
type: boolean
|
||||
default: false
|
||||
required: false
|
||||
{% endconfiguration %}
|
||||
|
||||
## Time selector
|
||||
|
||||
The time selector shows a time input that allows the user to specify a time
|
||||
|
BIN
source/images/blueprints/selector-object.png
Normal file
BIN
source/images/blueprints/selector-object.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 22 KiB |
BIN
source/images/blueprints/selector-text.png
Normal file
BIN
source/images/blueprints/selector-text.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 19 KiB |
Loading…
x
Reference in New Issue
Block a user