mirror of
https://github.com/joBr99/nspanel-lovelace-ui.git
synced 2025-12-22 07:24:24 +01:00
add input_text to entities page
This commit is contained in:
@@ -16,7 +16,7 @@ Content of the screen is controlled by a AppDaemon Python Script installed on yo
|
||||
|
||||
## Features
|
||||
|
||||
- Entities Page with support for cover, switch, input_boolean, binary_sensor, sensor, button, number, scenes, script, input_button and light
|
||||
- Entities Page with support for cover, switch, input_boolean, binary_sensor, sensor, button, number, scenes, script, input_button and light, input_text (read-only)
|
||||
- Grid Page with support for cover, switch, input_boolean, button, scenes, and light
|
||||
- Detail Pages for Lights (Brightness, Temperature and Color of the Light) and for Covers (Position)
|
||||
- Thermostat Page
|
||||
|
||||
@@ -174,6 +174,10 @@ class LuiPagesGen(object):
|
||||
min_v = entity.attributes.get("min", 0)
|
||||
max_v = entity.attributes.get("max", 100)
|
||||
return f"~number~{entityId}~{icon_id}~17299~{name}~{entity.state}|{min_v}|{max_v}"
|
||||
if entityType == "input_text":
|
||||
icon_id = get_icon_id_ha("input_text", overwrite=icon)
|
||||
value = entity.state
|
||||
return f"~text~{entityId}~{icon_id}~17299~{name}~{value}"
|
||||
return f"~text~{entityId}~{get_icon_id('alert-circle-outline')}~17299~error~"
|
||||
|
||||
def generate_entities_page(self, navigation, heading, items):
|
||||
|
||||
Reference in New Issue
Block a user