Add text sensor support to CYD config generator and YAML output#44
Draft
Add text sensor support to CYD config generator and YAML output#44
Conversation
Open
Agent-Logs-Url: https://github.com/element-software/CYD-ESPHome-HA-Monitor/sessions/ca3ac477-e9f4-433b-a3b2-fb2688dbf393 Co-authored-by: element-software <81567707+element-software@users.noreply.github.com>
Agent-Logs-Url: https://github.com/element-software/CYD-ESPHome-HA-Monitor/sessions/ca3ac477-e9f4-433b-a3b2-fb2688dbf393 Co-authored-by: element-software <81567707+element-software@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add text sensor support for HAS dashboard
Add text sensor support to CYD config generator and YAML output
Apr 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change adds first-class support for Home Assistant text-based sensors in the CYD dashboard flow. Users can now configure a slot as a text sensor in the generator and get valid ESPHome YAML that updates the displayed text value.
Config model + sensor type support
textto theSensorConfigunion viaTextSensorConfig(type,icon,iconColor).Generator UI updates
SensorConfigPanel.Preview behavior
CydScreenGridto render text sensor icon/icon color and show a sample text value, matching the new type semantics.YAML generation
substitutionsnow emits text sensor icon fields:${id}_type: "text"${id}_icon${id}_icon_colortext_sensor:Home Assistant block generation that updates tile value labels onon_value.text_sensorgeneration into the maingenerateYaml(...)composition flow.Focused coverage
textSensor.test.tsto verify:text_sensorYAML section and update lambda